Browse Source

Correctly disable text checking on later OS X versions.

woollybah 11 years ago
parent
commit
39ddfa135e
1 changed files with 8 additions and 1 deletions
  1. 8 1
      cocoamaxgui.mod/cocoa.macos.m

+ 8 - 1
cocoamaxgui.mod/cocoa.macos.m

@@ -1533,7 +1533,14 @@ tableColumn:(NSTableColumn *)aTableColumn row:(int)row mouseLocation:(NSPoint)mo
 		[self setAutomaticTextReplacementEnabled: NO];
 	if ([self respondsToSelector: @selector(setAutomaticDataDetectionEnabled)])
 		[self setAutomaticDataDetectionEnabled: NO];
-	
+		
+// on OS X 10.6+, disable all TextCheckingTypes, as the above code has no effect.
+#ifdef __MAC_OS_X_VERSION_MAX_ALLOWED
+#if __MAC_OS_X_VERSION_MAX_ALLOWED >= 1060
+	[self setEnabledTextCheckingTypes:0];
+#endif
+#endif
+
 	return self;
 }
 -(void)free{