Permalink
Browse files

Rename keyboard notification methods. Some overlap with UITextView in…

…ternal methods.
  • Loading branch information...
danielamitay committed Aug 3, 2012
1 parent b39ce28 commit c3099f1d7f1917df02b1d43ea8c1962ad4ab1afd
Showing with 12 additions and 12 deletions.
  1. +12 −12 DAKeyboardControl/DAKeyboardControl.m
@@ -55,30 +55,30 @@ - (void)addKeyboardControl:(BOOL)panning actionHandler:(DAKeyboardDidMoveBlock)a
// Register for keyboard notifications
[[NSNotificationCenter defaultCenter] addObserver:self
- selector:@selector(keyboardWillShow:)
+ selector:@selector(inputKeyboardWillShow:)
name:UIKeyboardWillShowNotification
object:nil];
[[NSNotificationCenter defaultCenter] addObserver:self
- selector:@selector(keyboardDidShow:)
+ selector:@selector(inputKeyboardDidShow:)
name:UIKeyboardDidShowNotification
object:nil];
// For the sake of 4.X compatibility
[[NSNotificationCenter defaultCenter] addObserver:self
- selector:@selector(keyboardWillChangeFrame:)
+ selector:@selector(inputKeyboardWillChangeFrame:)
name:@"UIKeyboardWillChangeFrameNotification"
object:nil];
[[NSNotificationCenter defaultCenter] addObserver:self
- selector:@selector(keyboardDidChangeFrame:)
+ selector:@selector(inputKeyboardDidChangeFrame:)
name:@"UIKeyboardDidChangeFrameNotification"
object:nil];
[[NSNotificationCenter defaultCenter] addObserver:self
- selector:@selector(keyboardWillHide:)
+ selector:@selector(inputKeyboardWillHide:)
name:UIKeyboardWillHideNotification
object:nil];
[[NSNotificationCenter defaultCenter] addObserver:self
- selector:@selector(keyboardDidHide:)
+ selector:@selector(inputKeyboardDidHide:)
name:UIKeyboardDidHideNotification
object:nil];
@@ -172,7 +172,7 @@ - (void)responderDidBecomeActive:(NSNotification *)notification
#pragma mark - Keyboard Notifications
-- (void)keyboardWillShow:(NSNotification *)notification
+- (void)inputKeyboardWillShow:(NSNotification *)notification
{
CGRect keyboardEndFrameWindow;
[[notification.userInfo valueForKey:UIKeyboardFrameEndUserInfoKey] getValue: &keyboardEndFrameWindow];
@@ -198,7 +198,7 @@ - (void)keyboardWillShow:(NSNotification *)notification
}];
}
-- (void)keyboardDidShow:(NSNotification *)notification
+- (void)inputKeyboardDidShow:(NSNotification *)notification
{
// Grab the keyboard view
self.keyboardActiveView = self.keyboardActiveInput.inputAccessoryView.superview;
@@ -212,7 +212,7 @@ - (void)keyboardDidShow:(NSNotification *)notification
}
}
-- (void)keyboardWillChangeFrame:(NSNotification *)notification
+- (void)inputKeyboardWillChangeFrame:(NSNotification *)notification
{
CGRect keyboardEndFrameWindow;
[[notification.userInfo valueForKey:UIKeyboardFrameEndUserInfoKey] getValue: &keyboardEndFrameWindow];
@@ -236,12 +236,12 @@ - (void)keyboardWillChangeFrame:(NSNotification *)notification
}];
}
-- (void)keyboardDidChangeFrame:(NSNotification *)notification
+- (void)inputKeyboardDidChangeFrame:(NSNotification *)notification
{
// Nothing to see here
}
-- (void)keyboardWillHide:(NSNotification *)notification
+- (void)inputKeyboardWillHide:(NSNotification *)notification
{
CGRect keyboardEndFrameWindow;
[[notification.userInfo valueForKey:UIKeyboardFrameEndUserInfoKey] getValue: &keyboardEndFrameWindow];
@@ -265,7 +265,7 @@ - (void)keyboardWillHide:(NSNotification *)notification
}];
}
-- (void)keyboardDidHide:(NSNotification *)notification
+- (void)inputKeyboardDidHide:(NSNotification *)notification
{
self.keyboardActiveView.hidden = NO;
self.keyboardActiveView.userInteractionEnabled = YES;

0 comments on commit c3099f1

Please sign in to comment.