Bug 116685 [CommonNavigator] ClassCastException trying to execute action
Prevents action contributions from being executed. This exception was created using a popupMenu objectContribution extension (using DTP with its sample connection profile plug-in). java.lang.ClassCastException at org.eclipse.ui.navigator.internal.NavigatorContentService$1.compare (NavigatorContentService.java:669) at java.util.Arrays.mergeSort(Arrays.java:1278) at java.util.Arrays.sort(Arrays.java:1219) at org.eclipse.ui.navigator.internal.NavigatorContentService.extractDescriptorInsta nces(NavigatorContentService.java:640) at org.eclipse.ui.navigator.internal.NavigatorContentService.extractDescriptorInsta nces(NavigatorContentService.java:617) at org.eclipse.ui.navigator.internal.NavigatorContentService.findRelevantContentExt ensions(NavigatorContentService.java:272) at org.eclipse.ui.navigator.internal.NavigatorActionService.addContentDescriptorMen u(NavigatorActionService.java:194) at org.eclipse.ui.navigator.internal.NavigatorActionService.fillContextMenu (NavigatorActionService.java:159) at org.eclipse.ui.navigator.CommonNavigatorManager.fillContextMenu (CommonNavigatorManager.java:158) at org.eclipse.ui.navigator.CommonNavigatorManager$1.menuAboutToShow (CommonNavigatorManager.java:177) at org.eclipse.jface.action.MenuManager.fireAboutToShow(MenuManager.java:285) at org.eclipse.jface.action.MenuManager.handleAboutToShow(MenuManager.java:372) at org.eclipse.jface.action.MenuManager.access$0(MenuManager.java:369) at org.eclipse.jface.action.MenuManager$2.menuShown(MenuManager.java:386) at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:117) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:896) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:920) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:901) at org.eclipse.swt.widgets.Control.WM_INITMENUPOPUP(Control.java:3451) at org.eclipse.swt.widgets.Control.windowProc(Control.java:3168) at org.eclipse.swt.widgets.Decorations.windowProc(Decorations.java:1538) at org.eclipse.swt.widgets.Display.windowProc(Display.java:3908) at org.eclipse.swt.internal.win32.OS.TrackPopupMenu(Native Method) at org.eclipse.swt.widgets.Menu._setVisible(Menu.java:225) at org.eclipse.swt.widgets.Display.runPopups(Display.java:3262) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2850) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1774) at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1738) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:376) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:143) at org.eclipse.ui.internal.ide.IDEApplication.run(IDEApplication.java:106) at org.eclipse.core.internal.runtime.PlatformActivator$1.run (PlatformActivator.java:226) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:376) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:165) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:324) at org.eclipse.core.launcher.Main.invokeFramework(Main.java:338) at org.eclipse.core.launcher.Main.basicRun(Main.java:282) at org.eclipse.core.launcher.Main.run(Main.java:977) at org.eclipse.core.launcher.Main.main(Main.java:952)
bundles/org.eclipse.ui.navigator/src-navigator/org/eclipse/ui/navigator/internal/extensions/NavigatorContentDescriptor.java
name = configElement.getAttribute(ATT_NAME);
		className = configElement.getAttribute(ATT_CLASS);
		String priorityString = configElement.getAttribute(ATT_PRIORITY);
		icon = configElement.getAttribute(ATT_ICON);
		rootLabel = configElement.getAttribute(ATT_ROOT_LABEL);
		
		declaringPluginId = configElement.getDeclaringExtension().getDeclaringPluginDescriptor().getUniqueIdentifier();
		String enabledByDefaultString = configElement.getAttribute(ENABLED_BY_DEFAULT);
		enabledByDefault = (enabledByDefaultString != null && enabledByDefaultString.length() > 0) ? Boolean.valueOf(configElement.getAttribute(ENABLED_BY_DEFAULT)).booleanValue() : true;
		if (className == null && (configElement.getAttribute(ATT_CONTENT_PROVIDER) == null || configElement.getAttribute(ATT_LABEL_PROVIDER) == null))
			throw new WorkbenchException("Missing attribute: " + 
						ATT_CLASS + " or one or both of " + 
						ATT_CONTENT_PROVIDER + " and " + 
						ATT_LABEL_PROVIDER + " in navigator extension: " + 
						configElement.getDeclaringExtension().getUniqueIdentifier());
		if (priorityString != null) {
			try {
				Priority p = Priority.get(priorityString);
				priority = p != null ? p.getValue() : -1; 
			} catch (NumberFormatException exception) {
			}
		}
		if (id == null) {
			throw new WorkbenchException("Missing attribute: " + 
						ATT_ID + " in navigator extension: " + 
						configElement.getDeclaringExtension().getUniqueIdentifier());
		}
		IConfigurationElement[] children = configElement.getChildren(CHILD_ENABLEMENT);
		if (children.length == 1) {
			enablement = new ActionExpression(children[0]);