mirror of
https://github.com/macvim-dev/macvim.git
synced 2026-06-07 15:37:14 +02:00
Merge pull request #86 from macvim-dev/fix/el-capitan-split-view-issue
Fix rendering issue in Split View on El Capitan
This commit is contained in:
@@ -1021,13 +1021,19 @@
|
||||
|
||||
- (void)windowDidResize:(id)sender
|
||||
{
|
||||
if (resizingDueToMove)
|
||||
{
|
||||
if (resizingDueToMove) {
|
||||
resizingDueToMove = NO;
|
||||
return;
|
||||
}
|
||||
|
||||
if (!setupDone || fullScreenEnabled) return;
|
||||
if (!setupDone)
|
||||
return;
|
||||
|
||||
// NOTE: We need to update the window frame size for Split View even though
|
||||
// in full-screen on El Capitan or later.
|
||||
if (floor(NSAppKitVersionNumber) <= NSAppKitVersionNumber10_10_Max
|
||||
&& fullScreenEnabled)
|
||||
return;
|
||||
|
||||
// NOTE: Since we have no control over when the window may resize (Cocoa
|
||||
// may resize automatically) we simply set the view to fill the entire
|
||||
@@ -1212,6 +1218,15 @@
|
||||
}
|
||||
}
|
||||
|
||||
- (void)windowDidEnterFullScreen:(NSNotification *)notification
|
||||
{
|
||||
if (floor(NSAppKitVersionNumber) > NSAppKitVersionNumber10_10_Max) {
|
||||
// NOTE: On El Capitan, we need to redraw the view when entering
|
||||
// full-screen using :fullscreen option (including Ctrl-Cmd-f).
|
||||
[vimController sendMessage:BackingPropertiesChangedMsgID data:nil];
|
||||
}
|
||||
}
|
||||
|
||||
- (void)windowDidFailToEnterFullScreen:(NSWindow *)window
|
||||
{
|
||||
// NOTE: This message can be called without
|
||||
@@ -1280,6 +1295,15 @@
|
||||
}
|
||||
}
|
||||
|
||||
- (void)windowDidExitFullScreen:(NSNotification *)notification
|
||||
{
|
||||
if (floor(NSAppKitVersionNumber) > NSAppKitVersionNumber10_10_Max) {
|
||||
// NOTE: On El Capitan, we need to redraw the view when leaving
|
||||
// full-screen by moving the window out from Split View.
|
||||
[vimController sendMessage:BackingPropertiesChangedMsgID data:nil];
|
||||
}
|
||||
}
|
||||
|
||||
- (void)windowDidFailToExitFullScreen:(NSWindow *)window
|
||||
{
|
||||
// TODO: Is this the correct way to deal with this message? Are we still
|
||||
|
||||
Reference in New Issue
Block a user