This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// CommonMacro.h | |
// | |
// | |
// Created by Haven on 26/9/13. | |
// Copyright (c) 2013 LF. All rights reserved. | |
// | |
#import <CoreTelephony/CTTelephonyNetworkInfo.h> | |
#import <CoreTelephony/CTCarrier.h> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- (UIImage *)imageWithColor:(UIColor *)color { | |
CGRect rect = CGRectMake(0.0f, 0.0f, 1.0f, 1.0f); | |
UIGraphicsBeginImageContext(rect.size); | |
CGContextRef context = UIGraphicsGetCurrentContext(); | |
CGContextSetFillColorWithColor(context, [color CGColor]); | |
CGContextFillRect(context, rect); | |
UIImage *image = UIGraphicsGetImageFromCurrentImageContext(); | |
UIGraphicsEndImageContext(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// NSObject+Association.h | |
// | |
// Created by Maciej Swic on 03/12/13. | |
// Released under the MIT license. | |
// | |
#import <Foundation/Foundation.h> | |
@interface NSObject (Association) |