Validate screen before constraining window
commit5e03d4f5baaf4a5024600166aef5e2e87849d2d9
authorBjorn Winckler <bjorn.winckler@gmail.com>
Sun, 29 Mar 2009 14:35:47 +0000 (29 16:35 +0200)
committerBjorn Winckler <bjorn.winckler@gmail.com>
Sun, 29 Mar 2009 14:35:47 +0000 (29 16:35 +0200)
tree38ca400226905157905e4196a6115826fcf5cf59
parentaef7ea3f258ba9b4b75859724ab3ef3b030a69b9
Validate screen before constraining window

If a window is on a screen that gets unplugged it may happen that
[NSWindow screen] returns nil.  Guard against this when constraining
the window frame to the screen frame.

This fixes a bug where a window could "disappear" if it was on a screen
that got unplugged.
src/MacVim/MMAppController.m
src/MacVim/MMWindow.m
src/MacVim/MMWindowController.m