Skip to content

Commit

Permalink
Attempt at working around another 10.14 drawing issue (#3271)
Browse files Browse the repository at this point in the history
  • Loading branch information
dmoagx committed Nov 8, 2018
1 parent 81986f5 commit dee3201
Show file tree
Hide file tree
Showing 6 changed files with 100 additions and 74 deletions.
14 changes: 7 additions & 7 deletions Frameworks/PSMTabBar/PSMRolloverButton.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,19 +16,19 @@
}

// the regular image
- (void)setUsualImage:(nullable NSImage *)newImage;
- (nullable NSImage *)usualImage;
- (void)setUsualImage:(NSImage *)newImage;
- (NSImage *)usualImage;

// the rollover image
- (void)setRolloverImage:(nullable NSImage *)newImage;
- (nullable NSImage *)rolloverImage;
- (void)setRolloverImage:(NSImage *)newImage;
- (NSImage *)rolloverImage;

// tracking rect for mouse events
- (void)rolloverFrameDidChange:(nonnull NSNotification *)notification;
- (void)rolloverFrameDidChange:(NSNotification *)notification;
- (void)addTrackingRect;
- (void)removeTrackingRect;

- (void)mouseEntered:(nullable NSEvent *)event;
- (void)mouseExited:(nullable NSEvent *)event;
- (void)mouseEntered:(NSEvent *)event;
- (void)mouseExited:(NSEvent *)event;

@end
4 changes: 2 additions & 2 deletions Frameworks/PSMTabBar/PSMRolloverButton.m
Original file line number Diff line number Diff line change
Expand Up @@ -118,15 +118,15 @@ - (void)removeTrackingRect
}

// override for rollover effect
- (void)mouseEntered:(nullable NSEvent *)event
- (void)mouseEntered:(NSEvent *)event
{
// set rollover image
[self setImage:_rolloverImage];

[super mouseEntered:event];
}

- (void)mouseExited:(nullable NSEvent *)event
- (void)mouseExited:(NSEvent *)event
{
// restore usual image
[self setImage:_usualImage];
Expand Down
Loading

0 comments on commit dee3201

Please sign in to comment.