Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

added another method of specifying what is/isn't allowed in the text …

…field
  • Loading branch information...
commit ba3cbc67e6dc52cc2fc08a1269971158af3a9a32 1 parent 56b1278
@barrettj authored
View
1  BlockAlertsDemo/BlockTextPromptAlertView.h
@@ -29,6 +29,7 @@ typedef BOOL (^BlockTextPromptAlertShouldDismiss)(NSInteger buttonIndex, BlockTe
@property (readwrite, copy) BlockTextPromptAlertShouldDismiss shouldDismiss;
- (void)setAllowableCharacters:(NSString*)accepted;
+- (void)setUnacceptedInput:(NSCharacterSet*)charSet;
- (void)setMaxLength:(NSInteger)max;
- (void)setButtonIndexForReturn:(NSInteger)index;
View
4 BlockAlertsDemo/BlockTextPromptAlertView.m
@@ -147,6 +147,10 @@ - (void)setAllowableCharacters:(NSString*)accepted {
unacceptedInput = [[[NSCharacterSet characterSetWithCharactersInString:accepted] invertedSet] retain];
}
+- (void)setUnacceptedInput:(NSCharacterSet*)charSet {
+ unacceptedInput = [charSet copy];
+}
+
- (void)setMaxLength:(NSInteger)max {
maxLength = max;
}

0 comments on commit ba3cbc6

Please sign in to comment.
Something went wrong with that request. Please try again.