Commit e2680bfc authored by Felix Paul Kühne's avatar Felix Paul Kühne

macosx: updated window styles for VLCControllerWindow and VLCEmbeddedWindow...

macosx: updated window styles for VLCControllerWindow and VLCEmbeddedWindow based upon a patch by Georg Seifert

Some tweaks to the nib file (so VLCControllerWindow looks all textured again) will be submitted later on.
parent e7b350ab
......@@ -41,6 +41,22 @@
@implementation VLCEmbeddedWindow
- (id)initWithContentRect:(NSRect)contentRect styleMask: (NSUInteger)windowStyle backing:(NSBackingStoreType)bufferingType defer:(BOOL)deferCreation
{
BOOL b_useTextured = YES;
if( [[NSWindow class] instancesRespondToSelector:@selector(setContentBorderThickness:forEdge:)] )
{
b_useTextured = NO;
windowStyle ^= NSTexturedBackgroundWindowMask;
}
self = [super initWithContentRect:contentRect styleMask:windowStyle backing:bufferingType defer:deferCreation];
if(! b_useTextured )
{
[self setContentBorderThickness:28.0 forEdge:NSMinYEdge];
}
return self;
}
- (void)awakeFromNib
{
[self setDelegate: self];
......
......@@ -406,12 +406,23 @@ static NSMutableArray *blackoutWindows = NULL;
- (id)initWithContentRect:(NSRect)contentRect styleMask:(NSUInteger)styleMask
backing:(NSBackingStoreType)backingType defer:(BOOL)flag
{
BOOL b_useTextured = YES;
if( [[NSWindow class] instancesRespondToSelector:@selector(setContentBorderThickness:forEdge:)] )
{
b_useTextured = NO;
styleMask ^= NSTexturedBackgroundWindowMask;
}
self = [super initWithContentRect:contentRect styleMask:styleMask //& ~NSTitledWindowMask
backing:backingType defer:flag];
[[VLCMain sharedInstance] updateTogglePlaylistState];
return( self );
if(! b_useTextured )
{
[self setContentBorderThickness:28.0 forEdge:NSMinYEdge];
}
return self;
}
- (BOOL)performKeyEquivalent:(NSEvent *)o_event
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment