From f32a2ed157ab860b62d8954a5c2aaea08e445661 Mon Sep 17 00:00:00 2001 From: Bogdan Gheorghe Date: Thu, 26 Apr 2012 16:16:45 -0400 Subject: Fix console warning in ToolItem --- .../gtk/org/eclipse/swt/widgets/ToolItem.java | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) (limited to 'bundles') diff --git a/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/ToolItem.java b/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/ToolItem.java index 5075f7c250..735b54ca2b 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/ToolItem.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/ToolItem.java @@ -584,11 +584,17 @@ int /*long*/ gtk_create_menu_proxy (int /*long*/ widget) { if (index != -1) { int /*long*/ pixbuf = imageList.getPixbuf (index); byte[] label = null; - int [] showImages = new int []{1}; - int /*long*/ settings = OS.gtk_settings_get_default(); - if (settings != 0) { - OS.g_object_get (settings, OS.gtk_menu_images, showImages, 0); - } + int [] showImages = new int [1]; + /* + * This code is intentionally commented out because it is outputting + * warnings to the console. If there is no text then the tooltip text + * will be used for overflow menu items. + */ +// int /*long*/ settings = OS.gtk_settings_get_default(); +// if (settings != 0) { +// OS.g_object_get (settings, OS.gtk_menu_images, showImages, 0); +// } + /* * GTK tool items with only image appear as blank items * in overflow menu when the system property "gtk-menu-images" -- cgit