mirror of
https://github.com/viq/NewsBlur.git
synced 2025-08-05 16:49:45 +00:00

Use the same popover creation code in more places, which adds Escape and Command-. to dismiss popovers. Ensure that popovers both get and can accept first responder, preventing keyboard input from leaking through to an underlying view controller. Without this, it can be confusing as, for example, you can navigate to a different story while you’ve got a ‘mark read’ popover shown for another story.
15 lines
248 B
Objective-C
15 lines
248 B
Objective-C
//
|
|
// UIViewController+HidePopover.h
|
|
// NewsBlur
|
|
//
|
|
// Created by Nicholas Riley on 3/19/16.
|
|
// Copyright © 2016 NewsBlur. All rights reserved.
|
|
//
|
|
|
|
#import <UIKit/UIKit.h>
|
|
|
|
@interface UIViewController (HidePopover)
|
|
|
|
- (void)hidePopover;
|
|
|
|
@end
|