FLEXWindow.h 786 B

123456789101112131415161718192021222324252627282930
  1. //
  2. // FLEXWindow.h
  3. // Flipboard
  4. //
  5. // Created by Ryan Olson on 4/13/14.
  6. // Copyright (c) 2020 FLEX Team. All rights reserved.
  7. //
  8. #import <UIKit/UIKit.h>
  9. @protocol FLEXWindowEventDelegate <NSObject>
  10. - (BOOL)shouldHandleTouchAtPoint:(CGPoint)pointInWindow;
  11. - (BOOL)canBecomeKeyWindow;
  12. @end
  13. #pragma mark -
  14. @interface FLEXWindow : UIWindow
  15. @property (nonatomic, weak) id <FLEXWindowEventDelegate> eventDelegate;
  16. /// Tracked so we can restore the key window after dismissing a modal.
  17. /// We need to become key after modal presentation so we can correctly capture input.
  18. /// If we're just showing the toolbar, we want the main app's window to remain key
  19. /// so that we don't interfere with input, status bar, etc.
  20. @property (nonatomic, readonly) UIWindow *previousKeyWindow;
  21. @end