From ba0496f9a8a66760fc94c587abb32b76fa4bc8d3 Mon Sep 17 00:00:00 2001 From: Silenio Quarti Date: Thu, 23 Aug 2012 16:45:01 -0400 Subject: Bug 387496 - JVM crashes when running jdtuirefactoring tests on hudson: im-xim.so+0x3b04 (REVERT SUSPICIOUS CHANGE TO RUN JUNIT IN NIGHTLY) --- .../Eclipse SWT/gtk/org/eclipse/swt/widgets/Control.java | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Control.java b/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Control.java index ec35babb3f..fb6ac2cc49 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Control.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Control.java @@ -3100,19 +3100,18 @@ int /*long*/ gtk_focus_out_event (int /*long*/ widget, int /*long*/ event) { } int /*long*/ gtk_key_press_event (int /*long*/ widget, int /*long*/ event) { + if (!hasFocus ()) return 0; GdkEventKey gdkEvent = new GdkEventKey (); OS.memmove (gdkEvent, event, GdkEventKey.sizeof); - - if (filterKey (gdkEvent.keyval, event)) return 1; - // widget could be disposed at this point - if (isDisposed ()) return 0; - - if (!hasFocus ()) return 0; if (translateMnemonic (gdkEvent.keyval, gdkEvent)) return 1; // widget could be disposed at this point if (isDisposed ()) return 0; + if (filterKey (gdkEvent.keyval, event)) return 1; + // widget could be disposed at this point + if (isDisposed ()) return 0; + if (translateTraversal (gdkEvent)) return 1; // widget could be disposed at this point if (isDisposed ()) return 0; -- cgit From ddd37d85332b6f06048142632a9d3dfc9239b814 Mon Sep 17 00:00:00 2001 From: Silenio Quarti Date: Fri, 24 Aug 2012 16:24:39 -0400 Subject: Bug 387518 - Extremely wide combo box causes X11 crash --- .../org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Combo.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Combo.java b/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Combo.java index b34449a7ea..942aa0c249 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Combo.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Combo.java @@ -341,7 +341,7 @@ void clearText () { public Point computeSize (int wHint, int hHint, boolean changed) { checkWidget (); - if ((style & SWT.READ_ONLY) != 0) { + if ((style & SWT.READ_ONLY) != 0 || menuHandle != 0) { return computeNativeSize (handle, wHint, hHint, changed); } if (wHint != SWT.DEFAULT && wHint < 0) wHint = 0; -- cgit