Commit 1a54bf7c authored by Felix Paul Kühne's avatar Felix Paul Kühne

macosx: clean up

parent c5f9ea13
......@@ -56,6 +56,11 @@ enum {
NSApplicationPresentationDisableHideApplication = (1 << 8),
NSApplicationPresentationDisableMenuBarTransparency = (1 << 9)
};
@interface NSWindow (IntroducedInLion) // just to shut off warnings, not implemented!
- (void)setRestorable:(BOOL);
@end
#endif
#pragma mark -
......
......@@ -80,7 +80,7 @@ static VLCMainWindow *_o_sharedInstance = nil;
[self setMovableByWindowBackground: YES];
/* we don't want this window to be restored on relaunch */
if ([self respondsToSelector:@selector(setRestorable:)])
if (OSX_LION)
[self setRestorable:NO];
return self;
......
......@@ -397,10 +397,7 @@ int DeviceCallback( vlc_object_t *p_this, const char *psz_variable,
- (void)renewGState
{
NSWindow *window = [self window];
if ([window respondsToSelector:@selector(disableScreenUpdatesUntilFlush)])
[window disableScreenUpdatesUntilFlush];
[[self window] disableScreenUpdatesUntilFlush];
[super renewGState];
}
......
......@@ -252,7 +252,7 @@
{
intf_thread_t * p_intf = VLCIntf;
BOOL b_invertedEventFromDevice = NO;
if ([theEvent respondsToSelector:@selector(isDirectionInvertedFromDevice)])
if (OSX_LION)
{
if ([theEvent isDirectionInvertedFromDevice])
b_invertedEventFromDevice = YES;
......
......@@ -190,7 +190,7 @@ static NSMutableArray *blackoutWindows = NULL;
{
b_isset_canBecomeKeyWindow = NO;
/* we don't want this window to be restored on relaunch */
if ([self respondsToSelector:@selector(setRestorable:)])
if (OSX_LION)
[self setRestorable:NO];
}
return self;
......
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