Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKaloyan Raev2015-12-16 15:17:40 +0000
committerKaloyan Raev2016-09-01 08:37:19 +0000
commitb61781c7616a532e2802b067dba828972cb61f40 (patch)
tree03ab4dff78ab12ef17d085a039bb14e3c04f9fda
parenteb2b55c22a0b43e2904ad1392b8b6880bc6863c3 (diff)
downloadrt.equinox.p2-b61781c7616a532e2802b067dba828972cb61f40.tar.gz
rt.equinox.p2-b61781c7616a532e2802b067dba828972cb61f40.tar.xz
rt.equinox.p2-b61781c7616a532e2802b067dba828972cb61f40.zip
Bug 482765 - NullPointerException in
TextSearchControl.createLabelButtonControl(198) Changed the broken icon path to point to the png version. Fall back to "missing image" descriptor when the provided descriptor is null. Change-Id: Iddfb18c36dda8dd29bddd0bc05f4b1fe3746456c Signed-off-by: Kaloyan Raev <kaloyan.r@zend.com> Also-by: Carsten Reckord <reckord@yatta.de>
-rw-r--r--bundles/org.eclipse.equinox.p2.ui.discovery/src/org/eclipse/equinox/internal/p2/ui/discovery/util/TextSearchControl.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/bundles/org.eclipse.equinox.p2.ui.discovery/src/org/eclipse/equinox/internal/p2/ui/discovery/util/TextSearchControl.java b/bundles/org.eclipse.equinox.p2.ui.discovery/src/org/eclipse/equinox/internal/p2/ui/discovery/util/TextSearchControl.java
index 490b8fb8a..5f545f7db 100644
--- a/bundles/org.eclipse.equinox.p2.ui.discovery/src/org/eclipse/equinox/internal/p2/ui/discovery/util/TextSearchControl.java
+++ b/bundles/org.eclipse.equinox.p2.ui.discovery/src/org/eclipse/equinox/internal/p2/ui/discovery/util/TextSearchControl.java
@@ -62,7 +62,7 @@ public class TextSearchControl extends Composite {
* Get image descriptors for the clear button.
*/
static {
- ImageDescriptor descriptor = AbstractUIPlugin.imageDescriptorFromPlugin(PlatformUI.PLUGIN_ID, "$nl$/icons/full/etool16/clear_co.gif"); //$NON-NLS-1$
+ ImageDescriptor descriptor = AbstractUIPlugin.imageDescriptorFromPlugin(PlatformUI.PLUGIN_ID, "$nl$/icons/full/etool16/clear_co.png"); //$NON-NLS-1$
if (descriptor != null) {
JFaceResources.getImageRegistry().put(CLEAR_ICON, descriptor);
}
@@ -195,7 +195,7 @@ public class TextSearchControl extends Composite {
final Image nativeImage = parent.getDisplay().getSystemImage(detail);
- final Image activeImage = nativeImage != null ? nativeImage : activeImageDescriptor.createImage();
+ final Image activeImage = nativeImage != null ? nativeImage : activeImageDescriptor == null ? ImageDescriptor.getMissingImageDescriptor().createImage() : activeImageDescriptor.createImage();
final Image inactiveImage = new Image(parent.getDisplay(), activeImage, SWT.IMAGE_GRAY);
final Image pressedImage = inactiveImage;

Back to the top