Author: vrubezhny
Date: 2007-10-22 13:57:57 -0400 (Mon, 22 Oct 2007)
New Revision: 4419
Modified:
trunk/hibernatetools/plugins/org.jboss.tools.hibernate.xml.ui/META-INF/MANIFEST.MF
trunk/hibernatetools/plugins/org.jboss.tools.hibernate.xml.ui/plugin.xml
trunk/hibernatetools/plugins/org.jboss.tools.hibernate.xml.ui/src/org/jboss/tools/hibernate/ui/xml/editor/HibConfig3CompoundEditor.java
trunk/hibernatetools/plugins/org.jboss.tools.hibernate.xml.ui/src/org/jboss/tools/hibernate/ui/xml/editor/Hibernate3CompoundEditor.java
Log:
http://jira.jboss.org/jira/browse/JBIDE-1124 hibernate tools code completion are no longer
available in hbm.xml editing
Issue is fixed.
Modified:
trunk/hibernatetools/plugins/org.jboss.tools.hibernate.xml.ui/META-INF/MANIFEST.MF
===================================================================
---
trunk/hibernatetools/plugins/org.jboss.tools.hibernate.xml.ui/META-INF/MANIFEST.MF 2007-10-22
17:48:30 UTC (rev 4418)
+++
trunk/hibernatetools/plugins/org.jboss.tools.hibernate.xml.ui/META-INF/MANIFEST.MF 2007-10-22
17:57:57 UTC (rev 4419)
@@ -24,6 +24,8 @@
org.jboss.tools.common.kb,
org.jboss.tools.common.model,
org.jboss.tools.common.model.ui,
- org.jboss.tools.hibernate.xml
+ org.jboss.tools.hibernate.xml,
+ org.hibernate.eclipse.mapper,
+ org.eclipse.wst.xml.ui
Bundle-Version: 2.0.0
Modified: trunk/hibernatetools/plugins/org.jboss.tools.hibernate.xml.ui/plugin.xml
===================================================================
--- trunk/hibernatetools/plugins/org.jboss.tools.hibernate.xml.ui/plugin.xml 2007-10-22
17:48:30 UTC (rev 4418)
+++ trunk/hibernatetools/plugins/org.jboss.tools.hibernate.xml.ui/plugin.xml 2007-10-22
17:57:57 UTC (rev 4419)
@@ -2,19 +2,44 @@
<?eclipse version="3.0"?>
<plugin>
<extension id="e" name="XML Editors"
point="org.jboss.tools.common.model.ui.xmlEditor">
- <xmlEditor
class="org.jboss.tools.hibernate.ui.xml.editor.Hibernate3CompoundEditor"
+ <!-- xmlEditor
class="org.jboss.tools.hibernate.ui.xml.editor.Hibernate3CompoundEditor"
contributorClass="org.jboss.tools.common.model.ui.texteditors.MultiPageContributor"
entities="FileHibernate3"
icon="images/xstudio/editors/hibernate_file.gif"
name="Hibernate 3.0 XML Editor">
- </xmlEditor>
- <xmlEditor
class="org.jboss.tools.hibernate.ui.xml.editor.HibConfig3CompoundEditor"
+ </xmlEditor -->
+ <!-- xmlEditor
class="org.jboss.tools.hibernate.ui.xml.editor.HibConfig3CompoundEditor"
contributorClass="org.jboss.tools.common.model.ui.texteditors.MultiPageContributor"
entities="FileHibConfig3"
icon="images/xstudio/editors/hibernate_file.gif"
name="Hibernate Configuration 3.0 XML Editor">
- </xmlEditor>
+ </xmlEditor -->
</extension>
+
+ <extension point="org.eclipse.ui.editors">
+ <editor
+
class="org.jboss.tools.hibernate.ui.xml.editor.Hibernate3CompoundEditor"
+
contributorClass="org.jboss.tools.common.model.ui.texteditors.MultiPageContributor"
+ default="true"
+ icon="images/xstudio/editors/hibernate_file.gif"
+
id="org.jboss.tools.hibernate.ui.xml.editor.Hibernate3CompoundEditor"
+ matchingStrategy =
"org.jboss.tools.common.core.resources.MatchingStrategyImpl"
+ name="Hibernate 3.0 XML Editor">
+ <contentTypeBinding
contentTypeId="org.hibernate.eclipse.mapper.hbmxmlsource"/>
+ </editor>
+ <editor
+
class="org.jboss.tools.hibernate.ui.xml.editor.HibConfig3CompoundEditor"
+
contributorClass="org.jboss.tools.common.model.ui.texteditors.MultiPageContributor"
+ default="true"
+ icon="images/xstudio/editors/hibernate_file.gif"
+
id="org.jboss.tools.hibernate.ui.xml.editor.HibConfig3CompoundEditor"
+ matchingStrategy =
"org.jboss.tools.common.core.resources.MatchingStrategyImpl"
+ name="Hibernate Configuration 3.0 XML Editor">
+ <contentTypeBinding
contentTypeId="org.hibernate.eclipse.mapper.cfgxmlsource"/>
+ </editor>
+ </extension>
+
+
<extension
point="org.jboss.tools.common.model.resourceMapping">
<mapping
Modified:
trunk/hibernatetools/plugins/org.jboss.tools.hibernate.xml.ui/src/org/jboss/tools/hibernate/ui/xml/editor/HibConfig3CompoundEditor.java
===================================================================
---
trunk/hibernatetools/plugins/org.jboss.tools.hibernate.xml.ui/src/org/jboss/tools/hibernate/ui/xml/editor/HibConfig3CompoundEditor.java 2007-10-22
17:48:30 UTC (rev 4418)
+++
trunk/hibernatetools/plugins/org.jboss.tools.hibernate.xml.ui/src/org/jboss/tools/hibernate/ui/xml/editor/HibConfig3CompoundEditor.java 2007-10-22
17:57:57 UTC (rev 4419)
@@ -10,9 +10,11 @@
******************************************************************************/
package org.jboss.tools.hibernate.ui.xml.editor;
+import org.hibernate.eclipse.mapper.editors.CFGXMLStructuredTextViewerConfiguration;
import org.jboss.tools.common.editor.TreeFormPage;
import org.jboss.tools.common.model.ui.editor.EditorDescriptor;
import org.jboss.tools.common.model.ui.editors.multipage.DefaultMultipageEditor;
+import org.jboss.tools.common.model.ui.texteditors.XMLTextEditorComponent;
import org.jboss.tools.hibernate.ui.xml.HibernateUIXMLPlugin;
import org.jboss.tools.hibernate.xml.model.FileHibernateFilteredTreeConstraint;
@@ -94,4 +96,9 @@
return super.getAdapter(adapter);
}
+ protected XMLTextEditorComponent createTextEditorComponent() {
+ final CFGXMLStructuredTextViewerConfiguration svc = new
CFGXMLStructuredTextViewerConfiguration();
+ return new XMLTextEditorComponent(svc);
+ }
+
}
Modified:
trunk/hibernatetools/plugins/org.jboss.tools.hibernate.xml.ui/src/org/jboss/tools/hibernate/ui/xml/editor/Hibernate3CompoundEditor.java
===================================================================
---
trunk/hibernatetools/plugins/org.jboss.tools.hibernate.xml.ui/src/org/jboss/tools/hibernate/ui/xml/editor/Hibernate3CompoundEditor.java 2007-10-22
17:48:30 UTC (rev 4418)
+++
trunk/hibernatetools/plugins/org.jboss.tools.hibernate.xml.ui/src/org/jboss/tools/hibernate/ui/xml/editor/Hibernate3CompoundEditor.java 2007-10-22
17:57:57 UTC (rev 4419)
@@ -10,9 +10,15 @@
******************************************************************************/
package org.jboss.tools.hibernate.ui.xml.editor;
+import org.eclipse.jface.text.source.SourceViewerConfiguration;
+import org.eclipse.ui.editors.text.TextEditor;
+import org.eclipse.wst.sse.ui.StructuredTextViewerConfiguration;
+import org.eclipse.wst.xml.ui.StructuredTextViewerConfigurationXML;
+import org.hibernate.eclipse.mapper.editors.HBMXMLStructuredTextViewerConfiguration;
import org.jboss.tools.common.editor.TreeFormPage;
import org.jboss.tools.common.model.ui.editor.EditorDescriptor;
import org.jboss.tools.common.model.ui.editors.multipage.DefaultMultipageEditor;
+import org.jboss.tools.common.model.ui.texteditors.XMLTextEditorComponent;
import org.jboss.tools.hibernate.xml.model.FileHibernateFilteredTreeConstraint;
@@ -37,4 +43,10 @@
return new EditorDescriptor("Hibernate3.0");
return super.getAdapter(adapter);
}
+
+ protected XMLTextEditorComponent createTextEditorComponent() {
+ final HBMXMLStructuredTextViewerConfiguration svc = new
HBMXMLStructuredTextViewerConfiguration();
+ return new XMLTextEditorComponent(svc);
+ }
+
}
\ No newline at end of file