Skip to content

Commit

Permalink
484487: Wizard fails to open in Neon
Browse files Browse the repository at this point in the history
Reverted workaround after fix was merged upstream in P2

Bug: 484487
Task-Url: https://bugs.eclipse.org/bugs/show_bug.cgi?id=484487
  • Loading branch information
creckord committed Feb 22, 2017
1 parent 7a24e45 commit c02c804
Showing 1 changed file with 0 additions and 40 deletions.
Expand Up @@ -56,7 +56,6 @@
import org.eclipse.jface.layout.GridLayoutFactory;
import org.eclipse.jface.operation.IRunnableWithProgress;
import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.jface.resource.JFaceResources;
import org.eclipse.jface.util.IPropertyChangeListener;
import org.eclipse.jface.util.PropertyChangeEvent;
import org.eclipse.jface.viewers.ISelectionChangedListener;
Expand All @@ -80,8 +79,6 @@
import org.eclipse.swt.widgets.Link;
import org.eclipse.swt.widgets.TabFolder;
import org.eclipse.swt.widgets.TabItem;
import org.eclipse.ui.PlatformUI;
import org.eclipse.ui.plugin.AbstractUIPlugin;

/**
* @author Steffen Pingel
Expand Down Expand Up @@ -109,43 +106,6 @@ public class MarketplacePage extends CatalogPage implements IWizardButtonLabelPr

private static final String CONTENT_TYPE_KEY = ContentType.class.getName();

static {
registerSearchControlIcons();
}

/**
* Workaround for bug 484487
*/
private static void registerSearchControlIcons() {
String clearIconKey = "org.eclipse.ui.internal.dialogs.CLEAR_ICON"; //$NON-NLS-1$
String findIconKey = "org.eclipse.ui.internal.dialogs.FIND_ICON"; //$NON-NLS-1$
ImageDescriptor clearDescriptor = JFaceResources.getImageRegistry().getDescriptor(clearIconKey);
ImageDescriptor findDescriptor = JFaceResources.getImageRegistry().getDescriptor(findIconKey);
if (clearDescriptor == null || findDescriptor == null) {
try {
Class.forName(
"org.eclipse.equinox.internal.p2.ui.discovery.util.TextSearchControl", true, //$NON-NLS-1$
MarketplacePage.class.getClassLoader());
clearDescriptor = JFaceResources.getImageRegistry().getDescriptor(clearIconKey);
findDescriptor = JFaceResources.getImageRegistry().getDescriptor(findIconKey);
} catch (ClassNotFoundException e) {
//ignore
}
}
if (clearDescriptor == null) {
clearDescriptor = AbstractUIPlugin.imageDescriptorFromPlugin(PlatformUI.PLUGIN_ID,
"$nl$/icons/full/etool16/clear_co.png"); //$NON-NLS-1$
if (clearDescriptor == null) {
clearDescriptor = ImageDescriptor.getMissingImageDescriptor();
}
JFaceResources.getImageRegistry().put(clearIconKey, clearDescriptor);
}
if (findDescriptor == null) {
findDescriptor = ImageDescriptor.getMissingImageDescriptor();
JFaceResources.getImageRegistry().put(findIconKey, findDescriptor);
}
}

private final MarketplaceCatalogConfiguration configuration;

private CatalogDescriptor previousCatalogDescriptor;
Expand Down

0 comments on commit c02c804

Please sign in to comment.