From: <uj...@us...> - 2011-12-05 01:07:55
|
Revision: 1879 http://iterm.svn.sourceforge.net/iterm/?rev=1879&view=rev Author: ujwal Date: 2011-12-05 01:07:49 +0000 (Mon, 05 Dec 2011) Log Message: ----------- Disabled CGSInternal calls. Not compiling on Lion. Modified Paths: -------------- trunk/PTYWindow.m Modified: trunk/PTYWindow.m =================================================================== --- trunk/PTYWindow.m 2009-10-19 02:45:25 UTC (rev 1878) +++ trunk/PTYWindow.m 2011-12-05 01:07:49 UTC (rev 1879) @@ -33,7 +33,6 @@ #import <iTerm/PreferencePanel.h> #import <iTerm/PseudoTerminal.h> #import <iTerm/iTermController.h> -#import <CGSInternal.h> #define DEBUG_METHOD_ALLOC 0 #define DEBUG_METHOD_TRACE 0 @@ -78,48 +77,7 @@ } -- (void)enableBlur -{ -#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_4 - // Only works in Leopard (or hopefully later) - if (!OSX_LEOPARDORLATER) return; - - if (blurFilter) - return; - CGSConnectionID con = CGSMainConnectionID(); - if (!con) - return; - - if (CGSNewCIFilterByName(con, (CFStringRef)@"CIGaussianBlur", &blurFilter)) - return; - - // should really set this from options: - NSDictionary *optionsDict = [NSDictionary dictionaryWithObject:[NSNumber numberWithFloat:2.0] forKey:@"inputRadius"]; - CGSSetCIFilterValuesFromDictionary(con, blurFilter, (CFDictionaryRef)optionsDict); - - CGSAddWindowFilter(con, [self windowNumber], blurFilter, kCGWindowFilterUnderlay); -#endif -} - -- (void)disableBlur -{ -#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_4 - //only works in Leopard (or hopefully later) - if (!OSX_LEOPARDORLATER) return; - - if (blurFilter) { - CGSConnectionID con = CGSMainConnectionID(); - if (!con) - return; - - CGSRemoveWindowFilter(con, (CGSWindowID)[self windowNumber], blurFilter); - CGSReleaseCIFilter(CGSMainConnectionID(), blurFilter); - blurFilter = 0; - } -#endif -} - - (int)screenNumber { return [[[[self screen] deviceDescription] objectForKey:@"NSScreenNumber"] intValue]; @@ -129,13 +87,6 @@ { NSEnumerator* iterator; -#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_4 - CGSConnectionID con = CGSMainConnectionID(); - if (!con) return; - CGSWorkspaceID currentSpace = -1; - CGSGetWorkspace(con, ¤tSpace); -#endif - int currentScreen = [self screenNumber]; NSRect screenRect = [[self screen] visibleFrame]; @@ -150,12 +101,6 @@ int otherScreen = [otherWindow screenNumber]; if(otherScreen != currentScreen) continue; -#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_4 - CGSWorkspaceID otherSpace = -1; - CGSGetWindowWorkspace(con, [otherWindow windowNumber], &otherSpace); - if(otherSpace != currentSpace) continue; -#endif - [windows addObject:otherWindow]; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |