Bug 63546 [OLE] In-place editor fails with: Class ID not found in registry
Try and open a file with the "In-place Editor". I tried opening both a Java file and a text file, both failed and resulted in the following stack trace: !MESSAGE Problems occurred when invoking code from plug- in: "org.eclipse.core.runtime". !STACK 0 org.eclipse.swt.SWTException: Class ID not found in registry result = - 2147221018 at org.eclipse.swt.ole.win32.OLE.error(OLE.java:317) at org.eclipse.swt.ole.win32.OleClientSite.<init> (OleClientSite.java:178) at org.eclipse.ui.internal.editorsupport.win32.OleEditor.createClientSite (OleEditor.java:227) at org.eclipse.ui.internal.editorsupport.win32.OleEditor.createPartControl (OleEditor.java:215) at org.eclipse.ui.internal.PartPane$2.run(PartPane.java:124) at org.eclipse.core.internal.runtime.InternalPlatform.run (InternalPlatform.java:608) at org.eclipse.core.runtime.Platform.run(Platform.java:758) at org.eclipse.ui.internal.PartPane.createChildControl (PartPane.java:120) at org.eclipse.ui.internal.PartPane.createControl(PartPane.java:182) at org.eclipse.ui.internal.PartStack.refreshPresentationSelection (PartStack.java:912) at org.eclipse.ui.internal.PartStack.setSelection(PartStack.java:894) at org.eclipse.ui.internal.PartStack.add(PartStack.java:283) at org.eclipse.ui.internal.EditorStack.add(EditorStack.java:103) at org.eclipse.ui.internal.EditorSashContainer.addEditor (EditorSashContainer.java:57) at org.eclipse.ui.internal.EditorAreaHelper.openEditor (EditorAreaHelper.java:264) at org.eclipse.ui.internal.EditorManager$2.run(EditorManager.java:552) at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:69) at org.eclipse.ui.internal.EditorManager.createEditorTab (EditorManager.java:541) at org.eclipse.ui.internal.EditorManager.openSystemInPlaceEditor (EditorManager.java:691) at org.eclipse.ui.internal.EditorManager.openEditorFromDescriptor (EditorManager.java:443) at org.eclipse.ui.internal.EditorManager.openEditor (EditorManager.java:428) at org.eclipse.ui.internal.WorkbenchPage.busyOpenEditorBatched (WorkbenchPage.java:2165) at org.eclipse.ui.internal.WorkbenchPage.busyOpenEditor (WorkbenchPage.java:2098) at org.eclipse.ui.internal.WorkbenchPage.access$6 (WorkbenchPage.java:2090) at org.eclipse.ui.internal.WorkbenchPage$9.run(WorkbenchPage.java:2077) at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:69) at org.eclipse.ui.internal.WorkbenchPage.openEditor (WorkbenchPage.java:2072) at org.eclipse.ui.internal.WorkbenchPage.openEditor (WorkbenchPage.java:2055) at org.eclipse.ui.actions.OpenWithMenu.openEditor(OpenWithMenu.java:258) at org.eclipse.ui.actions.OpenWithMenu.access$0(OpenWithMenu.java:251) at org.eclipse.ui.actions.OpenWithMenu$2.handleEvent (OpenWithMenu.java:166) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:82) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:796) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:2716) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2382) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1363) at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1334) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench (Workbench.java:253) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:141) at org.eclipse.ui.internal.ide.IDEApplication.run (IDEApplication.java:97) at org.eclipse.core.internal.runtime.PlatformActivator$1.run (PlatformActivator.java:307) at org.eclipse.core.runtime.adaptor.EclipseStarter.run (EclipseStarter.java:256) at org.eclipse.core.runtime.adaptor.EclipseStarter.run (EclipseStarter.java:127) 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.core.launcher.Main.basicRun(Main.java:185) at org.eclipse.core.launcher.Main.run(Main.java:638) at org.eclipse.core.launcher.Main.main(Main.java:622)
bundles/org.eclipse.ui.win32/src/org/eclipse/ui/internal/editorsupport/win32/OleEditor.java
*/
	private void sourceChanged(IFile newFile) {
		FileEditorInput newInput = new FileEditorInput(newFile);
		setInput(newInput);
		setResource(newFile);
		sourceChanged = true;
		setTitle(newInput.getName());
	}
	/* 
	 * See IEditorPart.isSaveOnCloseNeeded() 
	 */
	public boolean isSaveOnCloseNeeded() {
		return !sourceDeleted && super.isSaveOnCloseNeeded();
	}
	/**
	 * Posts the update code "behind" the running operation.
	 *
	 * @param runnable the update code
	 */
	private void update(Runnable runnable) {
		IWorkbench workbench = PlatformUI.getWorkbench();
		IWorkbenchWindow[] windows = workbench.getWorkbenchWindows();
		if (windows != null && windows.length > 0) {
			Display display = windows[0].getShell().getDisplay();
			display.asyncExec(runnable);
		} else
			runnable.run();
	}
}