JBoss Tools SVN: r31061 - trunk/cdi/plugins/org.jboss.tools.cdi.seam.text.ext.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2011-05-03 22:27:57 -0400 (Tue, 03 May 2011)
New Revision: 31061
Modified:
trunk/cdi/plugins/org.jboss.tools.cdi.seam.text.ext/plugin.xml
Log:
JBIDE-8845
https://issues.jboss.org/browse/JBIDE-8845
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.seam.text.ext/plugin.xml
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.seam.text.ext/plugin.xml 2011-05-04 02:26:16 UTC (rev 31060)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.seam.text.ext/plugin.xml 2011-05-04 02:27:57 UTC (rev 31061)
@@ -21,14 +21,20 @@
id="org.jboss.tools.cdi.seam.text.ext.hyperlink.SeamConfigTagNameHyperlinkPartitioner"
class="org.jboss.tools.cdi.seam.text.ext.hyperlink.SeamConfigTagNameHyperlinkPartitioner">
<contentType id="org.jboss.tools.common.model.ui.xml">
- <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ELEMENT">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ELEMENT_NAME">
<axis path="/beans/*"/>
</partitionType>
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_NAME">
+ <axis path="/beans/*"/>
+ </partitionType>
</contentType>
<contentType id="org.eclipse.core.runtime.xml">
- <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ELEMENT">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ELEMENT_NAME">
<axis path="/beans/*"/>
</partitionType>
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_NAME">
+ <axis path="/beans/*"/>
+ </partitionType>
</contentType>
</hyperlinkPartitioner>
</extension>
13 years, 2 months
JBoss Tools SVN: r31060 - trunk/jsf/plugins/org.jboss.tools.jsf.text.ext/src/org/jboss/tools/jsf/text/ext/hyperlink.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2011-05-03 22:26:16 -0400 (Tue, 03 May 2011)
New Revision: 31060
Modified:
trunk/jsf/plugins/org.jboss.tools.jsf.text.ext/src/org/jboss/tools/jsf/text/ext/hyperlink/JsfJSPTagAttributeHyperlink.java
Log:
JBIDE-8845
https://issues.jboss.org/browse/JBIDE-8845
Modified: trunk/jsf/plugins/org.jboss.tools.jsf.text.ext/src/org/jboss/tools/jsf/text/ext/hyperlink/JsfJSPTagAttributeHyperlink.java
===================================================================
--- trunk/jsf/plugins/org.jboss.tools.jsf.text.ext/src/org/jboss/tools/jsf/text/ext/hyperlink/JsfJSPTagAttributeHyperlink.java 2011-05-04 02:25:58 UTC (rev 31059)
+++ trunk/jsf/plugins/org.jboss.tools.jsf.text.ext/src/org/jboss/tools/jsf/text/ext/hyperlink/JsfJSPTagAttributeHyperlink.java 2011-05-04 02:26:16 UTC (rev 31060)
@@ -18,6 +18,7 @@
import org.eclipse.jface.text.BadLocationException;
import org.eclipse.jface.text.IRegion;
import org.eclipse.jface.text.Region;
+import org.eclipse.wst.xml.core.internal.provisional.document.IDOMNode;
import org.jboss.tools.common.model.XModel;
import org.jboss.tools.common.text.ext.hyperlink.AbstractHyperlink;
import org.jboss.tools.common.text.ext.util.StructuredModelWrapper;
@@ -91,13 +92,14 @@
Node n = Utils.findNodeForOffset(xmlDocument, region.getOffset());
+ Node node = null;
if (n instanceof Attr) {
- n = ((Attr)n).getOwnerElement();
+ node = ((Attr)n).getOwnerElement();
+ } else {
+ node = n.getParentNode();
}
- if (!(n instanceof Element)) return null;
+ if (!(node instanceof Element)) return null;
- Node node = n.getParentNode();
-
String nodeName = node.getNodeName();
if (nodeName.indexOf(':') == -1) return null;
@@ -125,13 +127,14 @@
Node n = Utils.findNodeForOffset(xmlDocument, region.getOffset());
+ Node node = null;
if (n instanceof Attr) {
- n = ((Attr)n).getOwnerElement();
+ node = ((Attr)n).getOwnerElement();
+ } else {
+ node = n.getParentNode();
}
- if (!(n instanceof Element)) return null;
+ if (!(node instanceof Element)) return null;
- Node node = n.getParentNode();
-
String tagName = node.getNodeName();
if (tagName.indexOf(':') == -1) return null;
@@ -151,12 +154,22 @@
}
private String getTagAttributeName(IRegion region) {
- if(region == null || getDocument() == null) return null;
+ if(region == null) return null;
+ StructuredModelWrapper smw = new StructuredModelWrapper();
+ smw.init(getDocument());
try {
- return Utils.trimQuotes(getDocument().get(region.getOffset(), region.getLength()));
- } catch (BadLocationException x) {
- JSFExtensionsPlugin.log("", x); //$NON-NLS-1$
+ Document xmlDocument = smw.getDocument();
+ if (xmlDocument == null) return null;
+
+ Node n = Utils.findNodeForOffset(xmlDocument, region.getOffset());
+
+ Node node = null;
+ if (n instanceof Attr) {
+ return ((Attr)n).getName();
+ }
return null;
+ } finally {
+ smw.dispose();
}
}
@@ -171,10 +184,10 @@
Node n = Utils.findNodeForOffset(xmlDocument, offset);
if (n == null || !(n instanceof Attr || n instanceof Text)) return null;
+ IDOMNode node = (IDOMNode)n;
+ int start =node.getStartOffset();
+ int end = node.getEndOffset();
- int start = Utils.getValueStart(n);
- int end = Utils.getValueEnd(n);
-
if (start > offset || end < offset) return null;
String text = getDocument().get(start, end - start);
13 years, 2 months
JBoss Tools SVN: r31059 - trunk/jsf/plugins/org.jboss.tools.jsf.text.ext/src/org/jboss/tools/jsf/text/ext/hyperlink.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2011-05-03 22:25:58 -0400 (Tue, 03 May 2011)
New Revision: 31059
Modified:
trunk/jsf/plugins/org.jboss.tools.jsf.text.ext/src/org/jboss/tools/jsf/text/ext/hyperlink/JsfJSPTagAttributeHyperlinkPartitioner.java
Log:
JBIDE-8845
https://issues.jboss.org/browse/JBIDE-8845
Modified: trunk/jsf/plugins/org.jboss.tools.jsf.text.ext/src/org/jboss/tools/jsf/text/ext/hyperlink/JsfJSPTagAttributeHyperlinkPartitioner.java
===================================================================
--- trunk/jsf/plugins/org.jboss.tools.jsf.text.ext/src/org/jboss/tools/jsf/text/ext/hyperlink/JsfJSPTagAttributeHyperlinkPartitioner.java 2011-05-04 02:24:51 UTC (rev 31058)
+++ trunk/jsf/plugins/org.jboss.tools.jsf.text.ext/src/org/jboss/tools/jsf/text/ext/hyperlink/JsfJSPTagAttributeHyperlinkPartitioner.java 2011-05-04 02:25:58 UTC (rev 31059)
@@ -110,7 +110,7 @@
IDOMNode node = (IDOMNode)n;
int start = node.getStartOffset();
- int end = node.getEndOffset();
+ int end = (n instanceof Attr) ? start + ((Attr)n).getNodeName().length() : node.getEndOffset();
if (start > offset || end < offset) return null;
13 years, 2 months
JBoss Tools SVN: r31058 - in trunk/common/plugins/org.jboss.tools.common.text.ext: src/org/jboss/tools/common/text/ext/hyperlink/xml and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2011-05-03 22:24:51 -0400 (Tue, 03 May 2011)
New Revision: 31058
Added:
trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLElementAttributeNameHyperlinkPartitioner.java
Modified:
trunk/common/plugins/org.jboss.tools.common.text.ext/plugin.xml
Log:
JBIDE-8845
https://issues.jboss.org/browse/JBIDE-8845
Modified: trunk/common/plugins/org.jboss.tools.common.text.ext/plugin.xml
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/plugin.xml 2011-05-04 01:43:10 UTC (rev 31057)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/plugin.xml 2011-05-04 02:24:51 UTC (rev 31058)
@@ -145,6 +145,32 @@
</hyperlinkPartitioner>
<hyperlinkPartitioner
+ class="org.jboss.tools.common.text.ext.hyperlink.xml.XMLElementAttributeNameHyperlinkPartitioner"
+ id="org.jboss.tools.common.text.ext.hyperlink.xml.XMLElementAttributeNameHyperlinkPartitioner">
+ <contentType id="org.eclipse.jst.jsf.facesconfig.facesConfigFile">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ELEMENT" />
+ </contentType>
+ <contentType id="org.eclipse.jst.jsp.core.tldsource">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ELEMENT" />
+ </contentType>
+ <contentType id="org.eclipse.wst.xml.core.xmlsource">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ELEMENT" />
+ </contentType>
+ <contentType id="org.eclipse.core.runtime.xml">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ELEMENT" />
+ </contentType>
+ <contentType id="org.eclipse.jst.j2ee.webDD">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ELEMENT" />
+ </contentType>
+ <contentType id="org.eclipse.jst.jee.ee5webDD">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ROOT"/>
+ </contentType>
+ <contentType id="org.jboss.tools.common.model.ui.xml">
+ <partitionType id="org.jboss.tools.common.text.ext.xml.XML_ELEMENT" />
+ </contentType>
+ </hyperlinkPartitioner>
+
+ <hyperlinkPartitioner
class="org.jboss.tools.common.text.ext.hyperlink.xml.XMLElementAttributeValueHyperlinkPartitioner"
id="org.jboss.tools.common.text.ext.hyperlink.xml.XMLElementAttributeValueHyperlinkPartitioner">
<contentType id="org.eclipse.jst.jsf.facesconfig.facesConfigFile">
Added: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLElementAttributeNameHyperlinkPartitioner.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLElementAttributeNameHyperlinkPartitioner.java (rev 0)
+++ trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLElementAttributeNameHyperlinkPartitioner.java 2011-05-04 02:24:51 UTC (rev 31058)
@@ -0,0 +1,97 @@
+/*******************************************************************************
+ * Copyright (c) 2007 Exadel, Inc. and Red Hat, Inc.
+ * Distributed under license by Red Hat, Inc. All rights reserved.
+ * This program is made available under the terms of the
+ * Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Exadel, Inc. and Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+package org.jboss.tools.common.text.ext.hyperlink.xml;
+
+import org.eclipse.jface.text.IDocument;
+import org.eclipse.wst.xml.core.internal.provisional.document.IDOMAttr;
+import org.jboss.tools.common.text.ext.hyperlink.AbstractHyperlinkPartitioner;
+import org.jboss.tools.common.text.ext.hyperlink.HyperlinkRegion;
+import org.jboss.tools.common.text.ext.hyperlink.IExclusiblePartitionerRecognition;
+import org.jboss.tools.common.text.ext.hyperlink.IHyperlinkPartitionRecognizer;
+import org.jboss.tools.common.text.ext.hyperlink.IHyperlinkRegion;
+import org.jboss.tools.common.text.ext.util.StructuredModelWrapper;
+import org.jboss.tools.common.text.ext.util.Utils;
+import org.w3c.dom.Attr;
+import org.w3c.dom.Document;
+import org.w3c.dom.Node;
+
+
+/**
+ * @author Jeremy
+ */
+public class XMLElementAttributeNameHyperlinkPartitioner extends AbstractHyperlinkPartitioner implements IHyperlinkPartitionRecognizer, IExclusiblePartitionerRecognition {
+ public static final String XML_ATTRIBUTE_NAME_PARTITION = "org.jboss.tools.common.text.ext.xml.XML_ATTRIBUTE_NAME"; //$NON-NLS-1$
+
+ protected String getPartitionType() {
+ return XML_ATTRIBUTE_NAME_PARTITION;
+ }
+
+ /**
+ * @see com.ibm.sse.editor.hyperlink.AbstractHyperlinkPartitioner#parse(org.eclipse.jface.text.IDocument, com.ibm.sse.editor.extensions.hyperlink.IHyperlinkRegion)
+ */
+ protected IHyperlinkRegion parse(IDocument document, IHyperlinkRegion superRegion) {
+ StructuredModelWrapper smw = new StructuredModelWrapper();
+ try {
+ smw.init(document);
+ Document xmlDocument = smw.getDocument();
+ if (xmlDocument == null) return null;
+
+ Node n = Utils.findNodeForOffset(xmlDocument, superRegion.getOffset());
+ if (n == null || !(n instanceof Attr)) return null;
+ int start = (n instanceof IDOMAttr) ? ((IDOMAttr)n).getNameRegionStartOffset() : -1;
+ int end = (n instanceof IDOMAttr) ? ((IDOMAttr)n).getNameRegionEndOffset() : -1;
+
+ String axis = getAxis(document, superRegion);
+ String contentType = superRegion.getContentType();
+ String type = getPartitionType();
+ int length = end - start - (superRegion.getOffset() - start);
+ int offset = superRegion.getOffset();
+
+ IHyperlinkRegion region = new HyperlinkRegion(offset, length, axis, contentType, type);
+ return region;
+ } finally {
+ smw.dispose();
+ }
+ }
+
+ /**
+ * @see com.ibm.sse.editor.extensions.hyperlink.IHyperlinkPartitionRecognizer#recognize(org.eclipse.jface.text.IDocument, com.ibm.sse.editor.extensions.hyperlink.IHyperlinkRegion)
+ */
+ public boolean recognize(IDocument document, IHyperlinkRegion region) {
+ StructuredModelWrapper smw = new StructuredModelWrapper();
+ try {
+ smw.init(document);
+ Document xmlDocument = smw.getDocument();
+ if (xmlDocument == null) return false;
+
+ Node n = Utils.findNodeForOffset(xmlDocument, region.getOffset());
+ if (!(n instanceof Attr)) return false;
+ int start = (n instanceof IDOMAttr) ? ((IDOMAttr)n).getNameRegionStartOffset() : -1;
+ int end = (n instanceof IDOMAttr) ? ((IDOMAttr)n).getNameRegionEndOffset() : -1;
+ if (start < 0 || start > region.getOffset() || end < region.getOffset())
+ return false;
+
+ return true;
+ } finally {
+ smw.dispose();
+ }
+ }
+
+ public boolean excludes(String partitionType, IDocument document, IHyperlinkRegion superRegion) {
+ return false;
+ }
+
+ public String getExclusionPartitionType() {
+ return getPartitionType();
+ }
+
+
+}
\ No newline at end of file
Property changes on: trunk/common/plugins/org.jboss.tools.common.text.ext/src/org/jboss/tools/common/text/ext/hyperlink/xml/XMLElementAttributeNameHyperlinkPartitioner.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
13 years, 2 months
JBoss Tools SVN: r31057 - in trunk/as/plugins: org.jboss.ide.eclipse.as.management.as7 and 1 other directories.
by jbosstools-commits@lists.jboss.org
Author: rob.stryker(a)jboss.com
Date: 2011-05-03 21:43:10 -0400 (Tue, 03 May 2011)
New Revision: 31057
Added:
trunk/as/plugins/org.jboss.ide.eclipse.as.management.as7/pom.xml
Modified:
trunk/as/plugins/org.jboss.ide.eclipse.as.management.as7/META-INF/MANIFEST.MF
trunk/as/plugins/pom.xml
Log:
JBIDE-8844
Modified: trunk/as/plugins/org.jboss.ide.eclipse.as.management.as7/META-INF/MANIFEST.MF
===================================================================
--- trunk/as/plugins/org.jboss.ide.eclipse.as.management.as7/META-INF/MANIFEST.MF 2011-05-04 01:01:26 UTC (rev 31056)
+++ trunk/as/plugins/org.jboss.ide.eclipse.as.management.as7/META-INF/MANIFEST.MF 2011-05-04 01:43:10 UTC (rev 31057)
@@ -2,7 +2,7 @@
Bundle-ManifestVersion: 2
Bundle-Name: As7
Bundle-SymbolicName: org.jboss.ide.eclipse.as.management.as7
-Bundle-Version: 1.0.0.qualifier
+Bundle-Version: 0.2.0.qualifier
Bundle-Activator: org.jboss.ide.eclipse.as.management.as7.Activator
Require-Bundle: org.eclipse.ui,
org.eclipse.core.runtime,
Added: trunk/as/plugins/org.jboss.ide.eclipse.as.management.as7/pom.xml
===================================================================
--- trunk/as/plugins/org.jboss.ide.eclipse.as.management.as7/pom.xml (rev 0)
+++ trunk/as/plugins/org.jboss.ide.eclipse.as.management.as7/pom.xml 2011-05-04 01:43:10 UTC (rev 31057)
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <parent>
+ <groupId>org.jboss.tools</groupId>
+ <artifactId>org.jboss.tools.parent.pom</artifactId>
+ <version>0.0.2-SNAPSHOT</version>
+ </parent>
+ <groupId>org.jboss.tools.as.plugins</groupId>
+ <artifactId>org.jboss.ide.eclipse.as.management.as7</artifactId>
+ <version>0.2.0-SNAPSHOT</version>
+ <packaging>eclipse-plugin</packaging>
+</project>
Modified: trunk/as/plugins/pom.xml
===================================================================
--- trunk/as/plugins/pom.xml 2011-05-04 01:01:26 UTC (rev 31056)
+++ trunk/as/plugins/pom.xml 2011-05-04 01:43:10 UTC (rev 31057)
@@ -18,7 +18,8 @@
<module>org.jboss.ide.eclipse.as.wtp.ui</module>
<module>org.jboss.ide.eclipse.as.rse.core</module>
<module>org.jboss.ide.eclipse.as.rse.ui</module>
- <module>org.jboss.ide.eclipse.as.jmx.integration</module>
+ <module>org.jboss.ide.eclipse.as.jmx.integration</module>
+ <module>org.jboss.ide.eclipse.as.management.as7</module>
</modules>
</project>
13 years, 2 months
JBoss Tools SVN: r31056 - trunk/as/tests/org.jboss.ide.eclipse.as.archives.integration.test/src/org/jboss/ide/eclipse/as/archives/integration/test.
by jbosstools-commits@lists.jboss.org
Author: rob.stryker(a)jboss.com
Date: 2011-05-03 21:01:26 -0400 (Tue, 03 May 2011)
New Revision: 31056
Modified:
trunk/as/tests/org.jboss.ide.eclipse.as.archives.integration.test/src/org/jboss/ide/eclipse/as/archives/integration/test/SingleFileZippedDeploymentIntegrationTest.java
Log:
JBIDE-8816 - missed test commit
Modified: trunk/as/tests/org.jboss.ide.eclipse.as.archives.integration.test/src/org/jboss/ide/eclipse/as/archives/integration/test/SingleFileZippedDeploymentIntegrationTest.java
===================================================================
--- trunk/as/tests/org.jboss.ide.eclipse.as.archives.integration.test/src/org/jboss/ide/eclipse/as/archives/integration/test/SingleFileZippedDeploymentIntegrationTest.java 2011-05-04 00:15:25 UTC (rev 31055)
+++ trunk/as/tests/org.jboss.ide.eclipse.as.archives.integration.test/src/org/jboss/ide/eclipse/as/archives/integration/test/SingleFileZippedDeploymentIntegrationTest.java 2011-05-04 01:01:26 UTC (rev 31056)
@@ -122,8 +122,6 @@
assertTrue(!publishLog.exists());
IJBossServerPublisher publisher = ExtensionManager.getDefault().getPublisher(server, mods, "local");
assertNotNull(publisher);
- assertTrue(publisher.getClass().getName() + " not equal to WTPZippedPublisher",
- publisher.getClass().equals(WTPZippedPublisher.class));
ServerRuntimeUtils.publish(server);
assertTrue(publishLog.exists());
System.out.println(IOUtil.getContents(publishLog));
13 years, 2 months
JBoss Tools SVN: r31055 - in trunk/cdi/tests/org.jboss.tools.cdi.seam.text.ext.test: src/org/jboss/tools/cdi/seam/text/ext/test and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2011-05-03 20:15:25 -0400 (Tue, 03 May 2011)
New Revision: 31055
Added:
trunk/cdi/tests/org.jboss.tools.cdi.seam.text.ext.test/src/org/jboss/tools/cdi/seam/text/ext/test/SeamConfigTagNameHyperlinkTest.java
Modified:
trunk/cdi/tests/org.jboss.tools.cdi.seam.text.ext.test/META-INF/MANIFEST.MF
trunk/cdi/tests/org.jboss.tools.cdi.seam.text.ext.test/src/org/jboss/tools/cdi/seam/text/ext/test/CdiSeamTextExtAllTests.java
Log:
JBIDE-8841
https://issues.jboss.org/browse/JBIDE-8841
Modified: trunk/cdi/tests/org.jboss.tools.cdi.seam.text.ext.test/META-INF/MANIFEST.MF
===================================================================
--- trunk/cdi/tests/org.jboss.tools.cdi.seam.text.ext.test/META-INF/MANIFEST.MF 2011-05-04 00:14:18 UTC (rev 31054)
+++ trunk/cdi/tests/org.jboss.tools.cdi.seam.text.ext.test/META-INF/MANIFEST.MF 2011-05-04 00:15:25 UTC (rev 31055)
@@ -4,13 +4,20 @@
Bundle-SymbolicName: org.jboss.tools.cdi.seam.text.ext.test
Bundle-Version: 1.0.0.qualifier
Require-Bundle: org.junit,
+ org.eclipse.ui,
org.eclipse.core.resources,
org.eclipse.jface.text,
org.jboss.tools.common.text.ext,
org.jboss.tools.cdi.text.ext.test,
org.jboss.tools.cdi.seam.text.ext,
org.jboss.tools.common,
+ org.jboss.tools.common.el.core,
+ org.jboss.tools.common.model.ui,
+ org.jboss.tools.cdi.core,
org.jboss.tools.cdi.core.test,
+ org.jboss.tools.cdi.seam.config.core,
+ org.jboss.tools.cdi.seam.config.core.test,
+ org.jboss.tools.tests,
org.eclipse.core.runtime,
org.eclipse.jdt.core
Bundle-ActivationPolicy: lazy
Modified: trunk/cdi/tests/org.jboss.tools.cdi.seam.text.ext.test/src/org/jboss/tools/cdi/seam/text/ext/test/CdiSeamTextExtAllTests.java
===================================================================
--- trunk/cdi/tests/org.jboss.tools.cdi.seam.text.ext.test/src/org/jboss/tools/cdi/seam/text/ext/test/CdiSeamTextExtAllTests.java 2011-05-04 00:14:18 UTC (rev 31054)
+++ trunk/cdi/tests/org.jboss.tools.cdi.seam.text.ext.test/src/org/jboss/tools/cdi/seam/text/ext/test/CdiSeamTextExtAllTests.java 2011-05-04 00:15:25 UTC (rev 31055)
@@ -12,6 +12,7 @@
import org.eclipse.jdt.internal.core.JavaModelManager;
import org.jboss.tools.cdi.core.test.CDICoreTestSetup;
+import org.jboss.tools.cdi.seam.config.core.test.SeamConfigTestSetup;
import junit.framework.Test;
import junit.framework.TestSuite;
@@ -27,7 +28,12 @@
suite.addTestSuite(CDISeamResourceLoadingHyperlinkDetectorTest.class);
suiteAll.addTest(new CDICoreTestSetup(suite));
+
+ TestSuite suiteConfig = new TestSuite("CDI Seam Config Tests");
+ suiteConfig.addTestSuite(SeamConfigTagNameHyperlinkTest.class);
+ suiteAll.addTest(new SeamConfigTestSetup(suiteConfig));
+
return suiteAll;
}
}
\ No newline at end of file
Added: trunk/cdi/tests/org.jboss.tools.cdi.seam.text.ext.test/src/org/jboss/tools/cdi/seam/text/ext/test/SeamConfigTagNameHyperlinkTest.java
===================================================================
--- trunk/cdi/tests/org.jboss.tools.cdi.seam.text.ext.test/src/org/jboss/tools/cdi/seam/text/ext/test/SeamConfigTagNameHyperlinkTest.java (rev 0)
+++ trunk/cdi/tests/org.jboss.tools.cdi.seam.text.ext.test/src/org/jboss/tools/cdi/seam/text/ext/test/SeamConfigTagNameHyperlinkTest.java 2011-05-04 00:15:25 UTC (rev 31055)
@@ -0,0 +1,40 @@
+/*******************************************************************************
+ * Copyright (c) 2011 Red Hat, Inc.
+ * Distributed under license by Red Hat, Inc. All rights reserved.
+ * This program is made available under the terms of the
+ * Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+package org.jboss.tools.cdi.seam.text.ext.test;
+
+import org.eclipse.core.resources.IFile;
+import org.eclipse.jface.text.hyperlink.IHyperlink;
+import org.eclipse.ui.IEditorPart;
+import org.eclipse.ui.IFileEditorInput;
+import org.jboss.tools.cdi.seam.config.core.test.SeamConfigTest;
+import org.jboss.tools.cdi.seam.text.ext.CDISeamExtPlugin;
+import org.jboss.tools.cdi.text.ext.test.HyperlinkDetectorTest;
+
+/**
+ *
+ * @author Viacheslav Kabanovich
+ *
+ */
+public class SeamConfigTagNameHyperlinkTest extends SeamConfigTest {
+ public SeamConfigTagNameHyperlinkTest() {}
+
+ public void testSeamConfigTagNameHyperlink() throws Exception {
+ IHyperlink hyperlink = HyperlinkDetectorTest.checkHyperLinkInXml("src/META-INF/beans.xml", project, 802, "org.jboss.tools.cdi.seam.text.ext.hyperlink.SeamConfigTagNameHyperlink");
+ hyperlink.open();
+
+ IEditorPart editor = CDISeamExtPlugin.getDefault().getWorkbench().getActiveWorkbenchWindow().getActivePage().getActiveEditor();
+ IFileEditorInput input = (IFileEditorInput)editor.getEditorInput();
+ IFile f = input.getFile();
+ assertEquals("Report.java", f.getName());
+
+ }
+
+}
Property changes on: trunk/cdi/tests/org.jboss.tools.cdi.seam.text.ext.test/src/org/jboss/tools/cdi/seam/text/ext/test/SeamConfigTagNameHyperlinkTest.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
13 years, 2 months
JBoss Tools SVN: r31054 - in trunk/cdi/tests/org.jboss.tools.cdi.text.ext.test: src/org/jboss/tools/cdi/text/ext/test and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2011-05-03 20:14:18 -0400 (Tue, 03 May 2011)
New Revision: 31054
Modified:
trunk/cdi/tests/org.jboss.tools.cdi.text.ext.test/META-INF/MANIFEST.MF
trunk/cdi/tests/org.jboss.tools.cdi.text.ext.test/src/org/jboss/tools/cdi/text/ext/test/HyperlinkDetectorTest.java
Log:
JBIDE-8841
https://issues.jboss.org/browse/JBIDE-8841
Modified: trunk/cdi/tests/org.jboss.tools.cdi.text.ext.test/META-INF/MANIFEST.MF
===================================================================
--- trunk/cdi/tests/org.jboss.tools.cdi.text.ext.test/META-INF/MANIFEST.MF 2011-05-04 00:11:24 UTC (rev 31053)
+++ trunk/cdi/tests/org.jboss.tools.cdi.text.ext.test/META-INF/MANIFEST.MF 2011-05-04 00:14:18 UTC (rev 31054)
@@ -8,6 +8,7 @@
org.eclipse.jface.text;bundle-version="3.5.0",
org.eclipse.ui.ide;bundle-version="3.5.0",
org.jboss.tools.common.text.ext;bundle-version="2.0.0",
+ org.jboss.tools.common.model.ui,
org.eclipse.core.runtime;bundle-version="3.5.0",
org.jboss.tools.cdi.text.ext;bundle-version="1.0.0",
org.eclipse.jdt.ui;bundle-version="3.5.0",
Modified: trunk/cdi/tests/org.jboss.tools.cdi.text.ext.test/src/org/jboss/tools/cdi/text/ext/test/HyperlinkDetectorTest.java
===================================================================
--- trunk/cdi/tests/org.jboss.tools.cdi.text.ext.test/src/org/jboss/tools/cdi/text/ext/test/HyperlinkDetectorTest.java 2011-05-04 00:11:24 UTC (rev 31053)
+++ trunk/cdi/tests/org.jboss.tools.cdi.text.ext.test/src/org/jboss/tools/cdi/text/ext/test/HyperlinkDetectorTest.java 2011-05-04 00:14:18 UTC (rev 31054)
@@ -3,6 +3,7 @@
import java.util.List;
import org.eclipse.core.resources.IFile;
+import org.eclipse.core.resources.IProject;
import org.eclipse.core.runtime.IAdaptable;
import org.eclipse.jdt.internal.ui.javaeditor.JavaEditor;
import org.eclipse.jdt.internal.ui.text.JavaWordFinder;
@@ -27,6 +28,8 @@
import org.eclipse.wst.sse.ui.StructuredTextEditor;
import org.eclipse.wst.xml.ui.internal.tabletree.XMLMultiPageEditorPart;
import org.jboss.tools.cdi.core.test.tck.TCKTest;
+import org.jboss.tools.common.editor.ObjectMultiPageEditor;
+import org.jboss.tools.common.model.ui.editor.EditorPartWrapper;
import org.jboss.tools.common.text.ext.hyperlink.HyperlinkDetector;
import org.jboss.tools.common.text.ext.hyperlink.IHyperlinkRegion;
import org.jboss.tools.common.text.ext.util.AxisUtil;
@@ -101,8 +104,12 @@
}
protected void checkHyperLinkInXml(String fileName, int offset, String hyperlinkClassName) throws Exception {
+ checkHyperLinkInXml(fileName, tckProject, offset, hyperlinkClassName);
+ }
+
+ public static IHyperlink checkHyperLinkInXml(String fileName, IProject project, int offset, String hyperlinkClassName) throws Exception {
Region region = new Region(offset, 0);
- IFile file = tckProject.getFile(fileName);
+ IFile file = project.getFile(fileName);
assertNotNull("The file \"" + fileName + "\" is not found", file);
assertTrue("The file \"" + fileName + "\" is not found", file.isAccessible());
@@ -110,23 +117,29 @@
FileEditorInput editorInput = new FileEditorInput(file);
IEditorPart part = openFileInEditor(file);
+ if(part instanceof EditorPartWrapper) part = ((EditorPartWrapper)part).getEditor();
ISourceViewer viewer = null;
if (part instanceof XMLMultiPageEditorPart) {
IEditorPart[] parts = ((XMLMultiPageEditorPart)part).findEditors(editorInput);
if(parts.length>0) {
viewer = ((StructuredTextEditor)parts[0]).getTextViewer();
}
+ } else if(part instanceof ObjectMultiPageEditor) {
+ viewer = ((ObjectMultiPageEditor)part).getSourceEditor().getTextViewer();
+ } else if(part instanceof StructuredTextEditor) {
+ viewer = ((StructuredTextEditor)part).getTextViewer();
}
IHyperlink[] links = HyperlinkDetector.getInstance().detectHyperlinks(viewer, region, true);
if(links!=null) {
for (IHyperlink hyperlink : links) {
if(hyperlink.getClass().getName().equals(hyperlinkClassName)) {
- return;
+ return hyperlink;
}
}
}
fail("Can't find HyperLink");
+ return null;
}
protected boolean findOffsetInRegions(int offset, List<Region> regionList){
@@ -137,11 +150,11 @@
return false;
}
- protected IEditorPart openFileInEditor(IFile input) {
+ public static IEditorPart openFileInEditor(IFile input) {
return openFileInEditor(input, null);
}
- protected IEditorPart openFileInEditor(IFile input, String id) {
+ public static IEditorPart openFileInEditor(IFile input, String id) {
if (input != null && input.exists()) {
try {
if(id==null) {
13 years, 2 months
JBoss Tools SVN: r31053 - trunk/cdi/plugins/org.jboss.tools.cdi.seam.text.ext/src/org/jboss/tools/cdi/seam/text/ext/hyperlink.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2011-05-03 20:11:24 -0400 (Tue, 03 May 2011)
New Revision: 31053
Modified:
trunk/cdi/plugins/org.jboss.tools.cdi.seam.text.ext/src/org/jboss/tools/cdi/seam/text/ext/hyperlink/SeamConfigTagNameHyperlink.java
Log:
JBIDE-8841
https://issues.jboss.org/browse/JBIDE-8841
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.seam.text.ext/src/org/jboss/tools/cdi/seam/text/ext/hyperlink/SeamConfigTagNameHyperlink.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.seam.text.ext/src/org/jboss/tools/cdi/seam/text/ext/hyperlink/SeamConfigTagNameHyperlink.java 2011-05-03 23:44:56 UTC (rev 31052)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.seam.text.ext/src/org/jboss/tools/cdi/seam/text/ext/hyperlink/SeamConfigTagNameHyperlink.java 2011-05-04 00:11:24 UTC (rev 31053)
@@ -35,7 +35,6 @@
import org.jboss.tools.jst.text.ext.hyperlink.jsp.JSPRootHyperlinkPartitioner;
import org.jboss.tools.common.text.ext.util.StructuredModelWrapper;
import org.jboss.tools.common.text.ext.util.Utils;
-import org.jboss.tools.common.util.EclipseJavaUtil;
import org.w3c.dom.Attr;
import org.w3c.dom.Document;
import org.w3c.dom.Element;
13 years, 2 months
JBoss Tools SVN: r31052 - trunk/build/parent.
by jbosstools-commits@lists.jboss.org
Author: dgolovin
Date: 2011-05-03 19:44:56 -0400 (Tue, 03 May 2011)
New Revision: 31052
Modified:
trunk/build/parent/pom.xml
Log:
fix for errors in plugins without sources
Modified: trunk/build/parent/pom.xml
===================================================================
--- trunk/build/parent/pom.xml 2011-05-03 22:46:54 UTC (rev 31051)
+++ trunk/build/parent/pom.xml 2011-05-03 23:44:56 UTC (rev 31052)
@@ -201,9 +201,9 @@
</plugin>
<!-- these two plugins copied in from Chris Aniszczyk's Minerva parent
pom; also need org.sonatype.tycho:maven-osgi-compiler-plugin, above -->
- <plugin>
- <!-- TODO remove workaround when https://issues.sonatype.org/browse/TYCHO-473
+ <!-- TODO remove workaround when https://issues.sonatype.org/browse/TYCHO-473
is fixed -->
+ <!--plugin>
<groupId>org.sonatype.tycho</groupId>
<artifactId>maven-osgi-source-plugin</artifactId>
<version>${tychoVersion}</version>
@@ -216,7 +216,7 @@
</goals>
</execution>
</executions>
- </plugin>
+ </plugin-->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-resources-plugin</artifactId>
13 years, 2 months