Author: scabanovich
Date: 2009-11-19 11:37:19 -0500 (Thu, 19 Nov 2009)
New Revision: 18749
Modified:
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/OpenEditorWizard.java
Log:
Modified:
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/OpenEditorWizard.java
===================================================================
---
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/OpenEditorWizard.java 2009-11-19
16:15:17 UTC (rev 18748)
+++
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/OpenEditorWizard.java 2009-11-19
16:37:19 UTC (rev 18749)
@@ -86,6 +86,11 @@
editor = IDE.openEditor(workbenchPage, f, true);
}
} else {
+ if(id == null) {
+ IEditorDescriptor d = IDE.getEditorDescriptor(input.getName());
+ if(d != null) id = d.getId();
+ if(id == null) id = "org.eclipse.ui.DefaultTextEditor";
+ }
editor = workbenchPage.openEditor(input, id);
}
} else {