Project: Eclipse_Platform_UI
Bug 66357 Eclipse stops opening editors
Reported: 2004-06-09 13:34:49 | Status: verified fixed

I200406082000 1) start with an empty workspace 2) create a simple project A 3) create a file f.txt in A 4) tranfer focus to the Navigator 5) modify f.txt externally 6) activate Eclipse without changing the active part 7) press close box of editor open for f.txt -> A file changed dialog is posted by the editor. While the modal dialog is open, the editor gets closed. (see stack trace below) 8) press No in the dialog 9) double click on f.txt to open it again -> nothing happens, no editor is opened (This is also the case when you have more files in the workspace and try to open an editor on some other file.) Observation: I see that the editor is created and its init method is called. I also see that its createPartControl method is not called. I haven't seen any thrown exception in the process of opening the editor. Stack trace of how the original editor on f.txt gets disposed. I'd suspect that the problem is related to the fact the part is closed while its activation event is being processed. TextEditor(AbstractTextEditor).dispose() line: 2827 TextEditor(AbstractDecoratedTextEditor).dispose() line: 216 TextEditor.dispose() line: 108 EditorManager$Editor(WorkbenchPartReference).dispose() line: 391 EditorManager$Editor.dispose() line: 1420 WorkbenchPage$5.run() line: 1189 InternalPlatform.run(ISafeRunnable) line: 615 Platform.run(ISafeRunnable) line: 758 WorkbenchPage.disposePart(IWorkbenchPartReference) line: 1187 WorkbenchPage.closeEditor(IEditorPart, boolean) line: 988 WorkbenchPage.closeEditor(IEditorReference, boolean) line: 947 EditorPane.doHide() line: 95 EditorStack(PartStack).close(IPresentablePart) line: 339 EditorStack.close(IPresentablePart[]) line: 203 PartStack$1.close(IPresentablePart[]) line: 74 DefaultPartPresentation$1.closeButtonPressed(CTabItem) line: 107 PaneFolder.notifyCloseListeners(CTabItem) line: 484 PaneFolder$3.close(CTabFolderEvent) line: 169 CTabFolder.onMouse(Event) line: 2008 CTabFolder$1.handleEvent(Event) line: 293 EventTable.sendEvent(Event) line: 82 CTabFolder(Widget).sendEvent(Event) line: 796 Display.runDeferredEvents() line: 2719 Display.readAndDispatch() line: 2385 MessageDialog(Window).runEventLoop(Shell) line: 668 MessageDialog(Window).open() line: 648 MessageDialog.openQuestion(Shell, String, String) line: 342 TextEditor(AbstractTextEditor).handleEditorInputChanged() line: 3133 TextEditor(AbstractTextEditor).sanityCheckState(IEditorInput) line: 3263 TextEditor(StatusTextEditor).sanityCheckState(IEditorInput) line: 193 TextEditor(AbstractTextEditor).safelySanityCheckState(IEditorInput) line: 3241 AbstractTextEditor$ActivationListener.handleActivation() line: 767 AbstractTextEditor$ActivationListener.partActivated(IWorkbenchPart) line: 713 PartListenerList$1.run() line: 49 InternalPlatform.run(ISafeRunnable) line: 615 Platform.run(ISafeRunnable) line: 758 PartListenerList.firePartActivated(IWorkbenchPart) line: 47 WWinPartService$1.partActivated(IWorkbenchPartReference) line: 27 PartListenerList2$1.run() line: 45 InternalPlatform.run(ISafeRunnable) line: 615 Platform.run(ISafeRunnable) line: 758 PartListenerList2.firePartActivated(IWorkbenchPartReference) line: 43 WorkbenchPage.firePartActivated(IWorkbenchPart) line: 1358 WorkbenchPage.setActivePart(IWorkbenchPart) line: 2663 WorkbenchPage.requestActivation(IWorkbenchPart) line: 2358 EditorPane(PartPane).requestActivation() line: 304 EditorPane.requestActivation() line: 127 EditorPane(PartPane).setFocus() line: 325 EditorPane.setFocus() line: 154 PresentablePart.setFocus() line: 129 DefaultPartPresentation$2.mouseDown(MouseEvent) line: 132 TypedListener.handleEvent(Event) line: 132 EventTable.sendEvent(Event) line: 82 CTabFolder(Widget).sendEvent(Event) line: 796 Display.runDeferredEvents() line: 2719 Display.readAndDispatch() line: 2385 Workbench.runEventLoop(Window$IExceptionHandler, Display) line: 1362 Workbench.runUI() line: 1333 Workbench.createAndRunWorkbench(Display, WorkbenchAdvisor) line: 252 PlatformUI.createAndRunWorkbench(Display, WorkbenchAdvisor) line: 141 IDEApplication.run(Object) line: 96 PlatformActivator$1.run(Object) line: 334 EclipseStarter.run(Object) line: 272 EclipseStarter.run(String[], Runnable) line: 128 NativeMethodAccessorImpl.invoke0(Method, Object, Object[]) line: not available [native method] NativeMethodAccessorImpl.invoke(Object, Object[]) line: 84 NativeMethodAccessorImpl.invoke(Method, Object, Object[]) line: 57 DelegatingMethodAccessorImpl.invoke(Method, Object, Object[]) line: 59 Method.invoke(Object, Object[]) line: 390 Main.basicRun(String[]) line: 185 Main.run(String[]) line: 638 Main.main(String[]) line: 622

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