forked from bartvdbraak/blender
Bugfix, IRC report
(Error in 2.65 release too) Mac OS X: on closing Blender, it 'flashed', which appeared to be a white window opening and closing quickly. Caused by code trying to send focus to another opened window, and accidentally focusing the closed one - causing it to reopen.
This commit is contained in:
parent
c12a1368ff
commit
d06876f45a
@ -622,14 +622,19 @@ GHOST_WindowCocoa::~GHOST_WindowCocoa()
|
||||
// back to YES right before closing
|
||||
[m_window setReleasedWhenClosed:YES];
|
||||
[m_window close];
|
||||
m_window = nil;
|
||||
}
|
||||
|
||||
//Check for other blender opened windows and make the frontmost key
|
||||
// Check for other blender opened windows and make the frontmost key
|
||||
// Note: for some reason the closed window is still in the list
|
||||
NSArray *windowsList = [NSApp orderedWindows];
|
||||
if ([windowsList count]) {
|
||||
[[windowsList objectAtIndex:0] makeKeyAndOrderFront:nil];
|
||||
for (int a = 0; a < [windowsList count]; a++) {
|
||||
if (m_window != (CocoaWindow *)[windowsList objectAtIndex:a]) {
|
||||
[[windowsList objectAtIndex:a] makeKeyAndOrderFront:nil];
|
||||
break;
|
||||
}
|
||||
}
|
||||
m_window = nil;
|
||||
|
||||
[pool drain];
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user