Responder+Keyboard.h 724 B

123456789101112131415161718192021222324252627282930
  1. //
  2. // Responder+Keyboard.h
  3. // UIKitSupport
  4. //
  5. // Created by RICHWARE SYSTEMS.
  6. // Copyright © 2016년 RICHWARE SYSTEMS. All rights reserved.
  7. //
  8. #import <UIKit/UIKit.h>
  9. typedef void(^KeyboardDisplayBlock)(CGRect frame, CGFloat duration, BOOL display);
  10. @interface UIResponder(Keyboard)
  11. + (void)cacheKeyboard;
  12. + (void)cacheKeyboard:(BOOL)onNextRunloop;
  13. - (void)addObserverKeyboardFrameChanged:(id)delegate ;//Delegate사용
  14. - (void)addObserverKeyboardDisplay:(KeyboardDisplayBlock)keyboardDisplayBlock ;//Block사용
  15. - (void)removeObserverKeyboard ;
  16. @end
  17. @protocol KeyboardFrameChangedDelegate <NSObject>
  18. @optional
  19. - (void)keyboardFrameChanged:(CGRect)frame duration:(CGFloat)duration display:(BOOL)display ;
  20. @end