Skip to content

Gavingsk/GVPackages

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

GVPackages

CI Status Version License Platform

Example

To run the example project, clone the repo, and run pod install from the Example directory first.

    UIView *newView.cornerRadius = [UIView viewWithColor:[UIColor yellowColor] size:CGSizeZero];
    //直接更改view的坐标
    newView.width = 100;
    newView.x = 100;
    newView.y = 100;
    newView.height = 100;
    newView.cornerRadius = 5;
    //支持16进制颜色
    UIColor *hexColor = [UIColor colorFromHexRGB:@"48AD32"];
    newView.backgroundColor = hexColor;
    [self.view addSubview:newView];

    //这一句
    __unsafe_unretained GVViewController *__weakSelf = self;
    //等价于
    GVWeekRef(self);
    // __weakSelf == __self;

    void(^block1)() = ^{

    [__weakSelf view];
    [__self view];

    };

    block1();

    UIWindow *window = __self.view.window;
    UIWindow *keyWindow = GVKeyWindow;
    NSString *str = [NSString stringWithFormat:@"%@%@%@",@"a",@"b",@"c",@"d"];
    NSString *newStr = GVString(@"%@%@%@",@"a",@"b");
    NSLog(@"%@",str);
    GVLog(@"%@",newStr); //在Release模式 不打印

Requirements

Installation

GVPackages is available through CocoaPods. To install it, simply add the following line to your Podfile:

pod "GVPackages"

Author

Gavingsk, gavin_gushaokun@126.com

License

GVPackages is available under the MIT license. See the LICENSE file for more info.

About

A collection of commonly used classes and methods in iOS development

Resources

License

Stars

Watchers

Forks

Packages

No packages published