Project: Eclipse_Platform_UI
Bug 180928 [Commands] NPE in ToggleBreakpointAction.getDocument
Reported: 2007-04-04 08:22:57 | Status: verified fixed

I20070403-1110 Steps: - new workspace - new Java Project - open type Integer - press Ctrl+F10, Esc - open type Number - press Ctrl+F10, Esc - activate editor for Integer - press Ctrl+F10, Esc - press Ctrl+F10, Esc If you have not changed anything in the vicinity, then this is likely a problem in Platform/UI's action delegate handler contribution story. java.lang.NullPointerException at org.eclipse.debug.ui.actions.ToggleBreakpointAction.getDocument(ToggleBreakpointAction.java:156) at org.eclipse.debug.ui.actions.ToggleBreakpointAction.update(ToggleBreakpointAction.java:168) at org.eclipse.ui.texteditor.AbstractRulerActionDelegate.update(AbstractRulerActionDelegate.java:133) at org.eclipse.ui.texteditor.AbstractRulerActionDelegate.menuAboutToShow(AbstractRulerActionDelegate.java:145) at org.eclipse.ui.texteditor.AbstractTextEditor.rulerContextMenuAboutToShow(AbstractTextEditor.java:5607) at org.eclipse.ui.texteditor.AbstractDecoratedTextEditor.rulerContextMenuAboutToShow(AbstractDecoratedTextEditor.java:1390) at org.eclipse.jdt.internal.ui.javaeditor.JavaEditor.rulerContextMenuAboutToShow(JavaEditor.java:3505) at org.eclipse.ui.texteditor.AbstractTextEditor$13.menuAboutToShow(AbstractTextEditor.java:2774) at org.eclipse.jface.action.MenuManager.fireAboutToShow(MenuManager.java:289) at org.eclipse.jface.action.MenuManager.handleAboutToShow(MenuManager.java:394) at org.eclipse.jface.action.MenuManager.access$1(MenuManager.java:390) at org.eclipse.jface.action.MenuManager$2.menuShown(MenuManager.java:416) at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:234) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:938) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:962) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:943) at org.eclipse.swt.widgets.Control.WM_INITMENUPOPUP(Control.java:3979) at org.eclipse.swt.widgets.Control.windowProc(Control.java:3696) at org.eclipse.swt.widgets.Decorations.windowProc(Decorations.java:1554) at org.eclipse.swt.widgets.Shell.windowProc(Shell.java:1752) at org.eclipse.swt.widgets.Display.windowProc(Display.java:4342) at org.eclipse.swt.internal.win32.OS.TrackPopupMenu(Native Method) at org.eclipse.swt.widgets.Menu._setVisible(Menu.java:227) at org.eclipse.swt.widgets.Display.runPopups(Display.java:3699) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3278) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2361) at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2325) at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2200) at org.eclipse.ui.internal.Workbench$4.run(Workbench.java:466) at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:289) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:461) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149) at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:101) at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:152) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:106) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:76) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:359) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:174) 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:585) at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:476) at org.eclipse.equinox.launcher.Main.basicRun(Main.java:416) at org.eclipse.equinox.launcher.Main.run(Main.java:1141) at org.eclipse.equinox.launcher.Main.main(Main.java:1116)

Files changed in fix:
bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/PluginActionContributionItem.java bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/PopupMenuExtender.java