[vlc-commits] macosx: support the Lion-style resizing within the black main window when _compiling_ (no joke) on Lion
Felix Paul Kühne
git at videolan.org
Fri Dec 23 19:53:16 CET 2011
vlc | branch: master | Felix Paul Kühne <fkuehne at videolan.org> | Fri Dec 23 19:53:08 2011 +0100| [c30858cfe6e1ca7d0e9d6c7cbc626c736c3fa542] | committer: Felix Paul Kühne
macosx: support the Lion-style resizing within the black main window when _compiling_ (no joke) on Lion
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=c30858cfe6e1ca7d0e9d6c7cbc626c736c3fa542
---
modules/gui/macosx/MainWindow.m | 20 +++++++++-----------
1 files changed, 9 insertions(+), 11 deletions(-)
diff --git a/modules/gui/macosx/MainWindow.m b/modules/gui/macosx/MainWindow.m
index b367ca8..41d718e 100644
--- a/modules/gui/macosx/MainWindow.m
+++ b/modules/gui/macosx/MainWindow.m
@@ -73,17 +73,14 @@ static VLCMainWindow *_o_sharedInstance = nil;
b_dark_interface = config_GetInt( VLCIntf, "macosx-interfacestyle" );
if (b_dark_interface)
- {
+#ifdef MAC_OS_X_VERSION_10_7
+ styleMask = NSBorderlessWindowMask | NSResizableWindowMask;
+#else
styleMask = NSBorderlessWindowMask;
- self = [super initWithContentRect:contentRect styleMask:styleMask
- backing:backingType defer:flag];
- }
- else
- {
- self = [super initWithContentRect:contentRect styleMask:styleMask
- backing:backingType defer:flag];
- }
-
+#endif
+
+ self = [super initWithContentRect:contentRect styleMask:styleMask
+ backing:backingType defer:flag];
[[VLCMain sharedInstance] updateTogglePlaylistState];
@@ -401,6 +398,7 @@ static VLCMainWindow *_o_sharedInstance = nil;
winrect.size.height = winrect.size.height - f_titleBarHeight;
[o_split_view setFrame: winrect];
[o_video_view setFrame: winrect];
+
[self display];
}
else
@@ -916,7 +914,7 @@ static VLCMainWindow *_o_sharedInstance = nil;
if ([o_video_view window] != self)
{
[o_video_view removeFromSuperviewWithoutNeedingDisplay];
- [o_video_view setFrame: [o_right_split_view frame]];
+ [o_video_view setFrame: [o_split_view frame]];
[[self contentView] addSubview:o_video_view positioned:NSWindowAbove relativeTo:nil];
}
b_nonembedded = NO;
More information about the vlc-commits
mailing list