diff options
author | Silenio Quarti <silenio> | 2002-07-09 21:43:50 +0000 |
---|---|---|
committer | Silenio Quarti <silenio> | 2002-07-09 21:43:50 +0000 |
commit | 4304c6f340155211dacd163b089d448e5135face (patch) | |
tree | 8e95ee0b79926573f0b89f777bc65e074d6bb1f4 /bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Caret.java | |
parent | 25c9a329ccc25aa0accc7e7004e756bf66f3d2fd (diff) | |
download | eclipse.platform.swt-4304c6f340155211dacd163b089d448e5135face.tar.gz eclipse.platform.swt-4304c6f340155211dacd163b089d448e5135face.tar.xz eclipse.platform.swt-4304c6f340155211dacd163b089d448e5135face.zip |
21223
Diffstat (limited to 'bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Caret.java')
-rw-r--r-- | bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Caret.java | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Caret.java b/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Caret.java index b1c6916937..ad1f34c4bd 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Caret.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Caret.java @@ -285,7 +285,7 @@ void releaseWidget () { super.releaseWidget (); Display display = getDisplay (); if (display.currentCaret == this) { - if (isShowing) hideCaret (); + hideCaret (); display.setCurrentCaret (null); } parent = null; @@ -311,12 +311,11 @@ void releaseWidget () { public void setBounds (int x, int y, int width, int height) { checkWidget(); if (this.x == x && this.y == y && this.width == width && this.height == height) return; - boolean showing = isShowing; boolean isFocus = isFocusCaret (); - if (isFocus && showing) hideCaret (); + if (isFocus) hideCaret (); this.x = x; this.y = y; this.width = width; this.height = height; - if (isFocus && showing) showCaret (); + if (isFocus) showCaret (); } /**
@@ -387,11 +386,10 @@ public void setImage (Image image) { if (image != null && image.isDisposed ()) { error (SWT.ERROR_INVALID_ARGUMENT); } - boolean showing = isShowing; boolean isFocus = isFocusCaret (); - if (isFocus && showing) hideCaret (); + if (isFocus) hideCaret (); this.image = image; - if (isFocus && showing) showCaret (); + if (isFocus) showCaret (); } /**
|