Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion WYPopoverController/WYPopoverController.h
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ typedef NS_OPTIONS(NSUInteger, WYPopoverAnimationOptions) {
@property (nonatomic, strong, readonly) UIViewController *contentViewController;
@property (nonatomic, assign) CGSize popoverContentSize;
@property (nonatomic, assign) float animationDuration;

@property (nonatomic, assign, getter = isOverlayEnabled) BOOL overlayEnabled;
@property (nonatomic, strong) WYPopoverTheme *theme;

+ (void)setDefaultTheme:(WYPopoverTheme *)theme;
Expand Down
5 changes: 4 additions & 1 deletion WYPopoverController/WYPopoverController.m
Original file line number Diff line number Diff line change
Expand Up @@ -1684,6 +1684,7 @@ - (id)init
themeUpdatesEnabled = YES;

popoverContentSize_ = CGSizeZero;
self.overlayEnabled = YES;
}

return self;
Expand Down Expand Up @@ -1935,7 +1936,9 @@ - (void)presentPopoverFromRect:(CGRect)aRect
backgroundView.hidden = YES;

[inView.window addSubview:backgroundView];
[inView.window insertSubview:overlayView belowSubview:backgroundView];
if( self.isOverlayEnabled ) {
[inView.window insertSubview:overlayView belowSubview:backgroundView];
}
}

[self updateThemeUI];
Expand Down