Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Attempt to fix an issue with split view drawing artifacts on 10.14
  • Loading branch information
dmoagx committed Nov 2, 2018
1 parent a2e6c11 commit 0d5d072
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions Source/SPSplitView.m
Expand Up @@ -1208,6 +1208,13 @@ - (id)initWithParent:(SPSplitView *)aSplitView
- (void)_animationStep:(NSTimer *)aTimer
{
[parentSplitView adjustSubviews];

// this is required on 10.14 in order to have the dividers move properly, because that OS version forces a layer-backed
// view and at the same time calls -layout much less often than previous OS X versions, resulting in outdated dividers.
// That is not an issue on older OS X versions where -drawRect: was used.
if(isOSAtLeast10_7) {
[parentSplitView setNeedsLayout:YES]; // 10.7+
}
}

@end
Expand Down

0 comments on commit 0d5d072

Please sign in to comment.