diff options
author | Silenio Quarti <silenio_quarti@ca.ibm.com> | 2012-06-22 17:33:46 -0400 |
---|---|---|
committer | Silenio Quarti <silenio_quarti@ca.ibm.com> | 2012-06-22 17:33:46 -0400 |
commit | f57bfc6f6b21043911a0f475af171f3f120888f2 (patch) | |
tree | ac3d9cb0316a42a17f324781392f8f7bf47d2dd0 /bundles/org.eclipse.swt/Eclipse SWT/cocoa | |
parent | 066de63c98ed4e9f7a0fb031abd659c80a8f3c05 (diff) | |
download | eclipse.platform.swt-f57bfc6f6b21043911a0f475af171f3f120888f2.tar.gz eclipse.platform.swt-f57bfc6f6b21043911a0f475af171f3f120888f2.tar.xz eclipse.platform.swt-f57bfc6f6b21043911a0f475af171f3f120888f2.zip |
Bug 377597 - Mac OS X cursor blinking dos not honor NSTextInsertionPointBlinkPeriod
Diffstat (limited to 'bundles/org.eclipse.swt/Eclipse SWT/cocoa')
-rw-r--r-- | bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Display.java | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Display.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Display.java index 798f1d6189..a6b1299851 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Display.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Display.java @@ -128,6 +128,7 @@ public class Display extends Device { boolean sendEvent; int clickCountButton, clickCount; + int blinkTime; Control currentControl, trackingControl, tooltipControl; Widget tooltipTarget; @@ -1299,7 +1300,7 @@ public static Display getCurrent () { int getCaretBlinkTime () { // checkDevice (); - return 560; + return blinkTime; } /** @@ -2224,6 +2225,10 @@ protected void init () { markedAttributes.retain (); textView.release (); + id blink = NSUserDefaults.standardUserDefaults().objectForKey(NSString.stringWith("NSTextInsertionPointBlinkPeriod")); + if (blink != null) blinkTime = (int)new NSNumber(blink).integerValue(); + if (blinkTime == 0) blinkTime = 560; + isPainting = (NSMutableArray)new NSMutableArray().alloc(); isPainting = isPainting.initWithCapacity(12); } |