Uploaded image for project: 'IvyDE'
  1. IvyDE
  2. IVYDE-386

ClassCastException on Menu Display, IvyDE 2.3.0 beta1, Eclipse Oxygen.2

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: master
    • Fix Version/s: master
    • Component/s: None
    • Labels:
      None
    • Environment:

      Description

      When opening a context menu on Eclipse a project or file the following error occurs.

      [code]
      org.eclipse.e4.core.di.InjectionException: java.lang.ClassCastException: org.eclipse.ui.menus.CommandContributionItem cannot be cast to org.eclipse.jface.action.MenuManager
      at org.eclipse.e4.core.internal.di.MethodRequestor.execute(MethodRequestor.java:65)
      at org.eclipse.e4.ui.internal.di.UIEventObjectSupplier$UIEventHandler$1.run(UIEventObjectSupplier.java:64)
      at org.eclipse.swt.widgets.Synchronizer.syncExec(Synchronizer.java:233)
      at org.eclipse.ui.internal.UISynchronizer.syncExec(UISynchronizer.java:144)
      at org.eclipse.swt.widgets.Display.syncExec(Display.java:4889)
      at org.eclipse.e4.ui.internal.workbench.swt.E4Application$1.syncExec(E4Application.java:212)
      at org.eclipse.e4.ui.internal.di.UIEventObjectSupplier$UIEventHandler.handleEvent(UIEventObjectSupplier.java:61)
      at org.eclipse.equinox.internal.event.EventHandlerWrapper.handleEvent(EventHandlerWrapper.java:201)
      at org.eclipse.equinox.internal.event.EventHandlerTracker.dispatchEvent(EventHandlerTracker.java:197)
      at org.eclipse.equinox.internal.event.EventHandlerTracker.dispatchEvent(EventHandlerTracker.java:1)
      at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
      at org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:148)
      at org.eclipse.equinox.internal.event.EventAdminImpl.dispatchEvent(EventAdminImpl.java:135)
      at org.eclipse.equinox.internal.event.EventAdminImpl.sendEvent(EventAdminImpl.java:78)
      at org.eclipse.equinox.internal.event.EventComponent.sendEvent(EventComponent.java:39)
      at org.eclipse.e4.ui.services.internal.events.EventBroker.send(EventBroker.java:52)
      at org.eclipse.e4.ui.internal.workbench.UIEventPublisher.notifyChanged(UIEventPublisher.java:60)
      at org.eclipse.emf.common.notify.impl.BasicNotifierImpl.eNotify(BasicNotifierImpl.java:374)
      at org.eclipse.emf.ecore.util.EcoreEList.dispatchNotification(EcoreEList.java:249)
      at org.eclipse.emf.common.notify.impl.NotifyingListImpl.addUnique(NotifyingListImpl.java:356)
      at org.eclipse.emf.common.util.AbstractEList.add(AbstractEList.java:343)
      at org.eclipse.e4.ui.workbench.renderers.swt.ContributionRecord.mergeIntoModel(ContributionRecord.java:250)
      at org.eclipse.e4.ui.workbench.renderers.swt.MenuManagerRenderer.processAddition(MenuManagerRenderer.java:546)
      at org.eclipse.e4.ui.workbench.renderers.swt.MenuManagerRenderer.generateContributions(MenuManagerRenderer.java:525)
      at org.eclipse.e4.ui.workbench.renderers.swt.MenuManagerRenderer.processContributions(MenuManagerRenderer.java:493)
      at org.eclipse.ui.internal.PopupMenuExtender.addMenuContributions(PopupMenuExtender.java:410)
      at org.eclipse.ui.internal.PopupMenuExtender.menuAboutToShow(PopupMenuExtender.java:382)
      at org.eclipse.jface.action.MenuManager.fireAboutToShow(MenuManager.java:339)
      at org.eclipse.jface.action.MenuManager.handleAboutToShow(MenuManager.java:470)
      at org.eclipse.jface.action.MenuManager.access$1(MenuManager.java:465)
      at org.eclipse.jface.action.MenuManager$2.menuShown(MenuManager.java:497)
      at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:256)
      at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:86)
      at org.eclipse.swt.widgets.Display.sendEvent(Display.java:4428)
      at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1079)
      at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1103)
      at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1084)
      at org.eclipse.swt.widgets.Control.WM_INITMENUPOPUP(Control.java:5204)
      at org.eclipse.swt.widgets.Control.windowProc(Control.java:4872)
      at org.eclipse.swt.widgets.Canvas.windowProc(Canvas.java:359)
      at org.eclipse.swt.widgets.Decorations.windowProc(Decorations.java:1657)
      at org.eclipse.swt.widgets.Shell.windowProc(Shell.java:2199)
      at org.eclipse.swt.widgets.Display.windowProc(Display.java:5178)
      at org.eclipse.swt.internal.win32.OS.TrackPopupMenu(Native Method)
      at org.eclipse.swt.widgets.Menu._setVisible(Menu.java:262)
      at org.eclipse.swt.widgets.Display.runPopups(Display.java:4279)
      at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3811)
      at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$5.run(PartRenderingEngine.java:1150)
      at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:336)
      at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:1039)
      at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:153)
      at org.eclipse.ui.internal.Workbench.lambda$3(Workbench.java:680)
      at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:336)
      at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:594)
      at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:148)
      at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:151)
      at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
      at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:134)
      at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:104)
      at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:388)
      at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:243)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
      at java.lang.reflect.Method.invoke(Unknown Source)
      at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:653)
      at org.eclipse.equinox.launcher.Main.basicRun(Main.java:590)
      at org.eclipse.equinox.launcher.Main.run(Main.java:1499)
      Caused by: java.lang.ClassCastException: org.eclipse.ui.menus.CommandContributionItem cannot be cast to org.eclipse.jface.action.MenuManager
      at org.apache.ivyde.internal.eclipse.ui.menu.IvyMenuContributionItem.fillMenu(IvyMenuContributionItem.java:196)
      at org.apache.ivyde.internal.eclipse.ui.menu.IvyMenuContributionItem.addCommand(IvyMenuContributionItem.java:188)
      at org.apache.ivyde.internal.eclipse.ui.menu.IvyMenuContributionItem.getContributionItems(IvyMenuContributionItem.java:179)
      at org.eclipse.ui.actions.CompoundContributionItem.getContributionItemsToFill(CompoundContributionItem.java:80)
      at org.eclipse.ui.actions.CompoundContributionItem.fill(CompoundContributionItem.java:54)
      at org.eclipse.ui.internal.menus.DynamicMenuContributionItem.fill(DynamicMenuContributionItem.java:147)
      at org.eclipse.jface.action.MenuManager.doItemFill(MenuManager.java:728)
      at org.eclipse.jface.action.MenuManager.update(MenuManager.java:810)
      at org.eclipse.jface.action.MenuManager.update(MenuManager.java:669)
      at org.eclipse.e4.ui.workbench.renderers.swt.MenuManagerRenderer.scheduleManagerUpdate(MenuManagerRenderer.java:1214)
      at org.eclipse.e4.ui.workbench.renderers.swt.MenuManagerRenderer.processContents(MenuManagerRenderer.java:649)
      at org.eclipse.e4.ui.workbench.renderers.swt.MenuManagerRenderer.subscribeTopicChildAdded(MenuManagerRenderer.java:324)
      at sun.reflect.GeneratedMethodAccessor18.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
      at java.lang.reflect.Method.invoke(Unknown Source)
      at org.eclipse.e4.core.internal.di.MethodRequestor.execute(MethodRequestor.java:55)
      ... 67 more
      [/code]

        Attachments

          Activity

            People

            • Assignee:
              jaikiran Jaikiran Pai
              Reporter:
              jonl-percsol Jonathon Lamon
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: