Skip to content

Commit

Permalink
优化
Browse files Browse the repository at this point in the history
  • Loading branch information
boai committed May 23, 2016
1 parent 2b72e93 commit f249571
Show file tree
Hide file tree
Showing 5 changed files with 212 additions and 195 deletions.
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -77,5 +77,37 @@
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "Yes"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "demoTest/BATools(&#x5de5;&#x5177;&#x7c7b;)/BACategory(&#x5206;&#x7c7b;)/UIViewController+BAAlertView.m"
timestampString = "485677071.49276"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "252"
endingLineNumber = "252"
landmarkName = "-BAAlertWithTitle:message:buttons:textFieldNumber:configuration:animated:action:"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "Yes"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "demoTest/BATools(&#x5de5;&#x5177;&#x7c7b;)/BACategory(&#x5206;&#x7c7b;)/UIViewController+BAAlertView.m"
timestampString = "485677081.602424"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "64"
endingLineNumber = "64"
landmarkName = "-BAAlertWithTitle:message:andOthers:animated:action:"
landmarkType = "5">
</BreakpointContent>
</BreakpointProxy>
</Breakpoints>
</Bucket>
Original file line number Diff line number Diff line change
Expand Up @@ -8,27 +8,19 @@

#import <UIKit/UIKit.h>

#if __IPHONE_OS_VERSION_MAX_ALLOWED < __IPHONE_8_0
#define IPHONE_OS_VERSION_MIN_IPHONE_8_0 //less than 8.0
#else
#define IPHONE_OS_VERSION_MAX_IPHONE_8_0 //greater than or equal to 8.0
#endif
#define IOS8x ([[[UIDevice currentDevice] systemVersion] floatValue] >= 8.0)

#define NO_USE -1000


typedef void(^click)(NSInteger index);
typedef void(^configuration)(UITextField *field, NSInteger index);
typedef void(^clickHaveField)(NSArray<UITextField *> *fields, NSInteger index);

@interface UIViewController (BAAlertView)

#ifdef IPHONE_OS_VERSION_MIN_IPHONE_8_0
<
UIAlertViewDelegate,
UIActionSheetDelegate
>
#endif

/*!
* use alert
Expand Down Expand Up @@ -76,16 +68,10 @@ typedef void(^clickHaveField)(NSArray<UITextField *> *fields, NSInteger index);
* @param click button action
*/
- (void)BAAlertWithTitle:(NSString *)title
message:(NSString *)message
buttons:(NSArray<NSString *> *)buttons
textFieldNumber:(NSInteger )number
configuration:(configuration )configuration
animated:(BOOL )animated
action:(clickHaveField )click;






message:(NSString *)message
buttons:(NSArray<NSString *> *)buttons
textFieldNumber:(NSInteger )number
configuration:(configuration )configuration
animated:(BOOL )animated
action:(clickHaveField )click;
@end
Loading

0 comments on commit f249571

Please sign in to comment.