JBoss Tools SVN: r6020 - trunk/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/packages.
by jbosstools-commits@lists.jboss.org
Author: rob.stryker(a)jboss.com
Date: 2008-01-29 17:48:06 -0500 (Tue, 29 Jan 2008)
New Revision: 6020
Modified:
trunk/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/packages/PublishAction.java
Log:
JBIDE-1404 - current publish action does not save its properties when it should.
Modified: trunk/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/packages/PublishAction.java
===================================================================
--- trunk/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/packages/PublishAction.java 2008-01-29 22:23:42 UTC (rev 6019)
+++ trunk/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/packages/PublishAction.java 2008-01-29 22:48:06 UTC (rev 6020)
@@ -21,6 +21,7 @@
*/
package org.jboss.ide.eclipse.as.ui.packages;
+import org.eclipse.core.runtime.IPath;
import org.eclipse.jface.viewers.ArrayContentProvider;
import org.eclipse.jface.viewers.ISelection;
import org.eclipse.jface.viewers.ISelectionChangedListener;
@@ -28,6 +29,7 @@
import org.eclipse.jface.viewers.LabelProvider;
import org.eclipse.jface.viewers.ListViewer;
import org.eclipse.jface.viewers.SelectionChangedEvent;
+import org.eclipse.jface.window.Window;
import org.eclipse.jface.wizard.Wizard;
import org.eclipse.jface.wizard.WizardDialog;
import org.eclipse.jface.wizard.WizardPage;
@@ -44,6 +46,7 @@
import org.eclipse.swt.widgets.Shell;
import org.eclipse.wst.server.core.IServer;
import org.eclipse.wst.server.core.ServerCore;
+import org.jboss.ide.eclipse.archives.core.model.ArchivesModel;
import org.jboss.ide.eclipse.archives.core.model.IArchive;
import org.jboss.ide.eclipse.archives.core.model.IArchiveNode;
import org.jboss.ide.eclipse.archives.ui.actions.INodeActionDelegate;
@@ -58,15 +61,16 @@
}
public void run (IArchiveNode node) {
- if (node.getNodeType() == IArchiveNode.TYPE_ARCHIVE)
- {
+ if (node.getNodeType() == IArchiveNode.TYPE_ARCHIVE
+ && ((IArchive)node).isTopLevel()) {
IArchive pkg = (IArchive)node;
String servers = node.getProperty(ArchivesBuildListener.DEPLOY_SERVERS);
if( !new Boolean(pkg.getProperty(ArchivesBuildListener.DEPLOY_AFTER_BUILD)).booleanValue() ||
servers == null || "".equals(servers) || anyServerDoesntExist(servers)){
servers = showSelectServersDialog(pkg);
}
- ArchivesBuildListener.publish(pkg, servers, IServer.PUBLISH_FULL);
+ if( servers != null )
+ ArchivesBuildListener.publish(pkg, servers, IServer.PUBLISH_FULL);
}
}
@@ -89,8 +93,11 @@
protected String showSelectServersDialog(IArchive node) {
SelectServerWizard wiz = new SelectServerWizard(node);
- new WizardDialog(new Shell(), wiz).open();
- return wiz.getServers();
+ int result = new WizardDialog(new Shell(), wiz).open();
+ if( result == Window.OK) {
+ return wiz.getServers();
+ }
+ return null;
}
@@ -103,6 +110,8 @@
public boolean performFinish() {
pack.setProperty(ArchivesBuildListener.DEPLOY_SERVERS, getServers());
pack.setProperty(ArchivesBuildListener.DEPLOY_AFTER_BUILD, getAutoDeploy());
+ IPath p = pack.getProjectPath();
+ ArchivesModel.instance().saveModel(p, null);
return true;
}
public void addPages() {
16 years, 11 months
JBoss Tools SVN: r6019 - trunk/core/plugins/org.jboss.ide.eclipse.archives.ui/src/main/org/jboss/ide/eclipse/archives/ui.
by jbosstools-commits@lists.jboss.org
Author: rob.stryker(a)jboss.com
Date: 2008-01-29 17:23:42 -0500 (Tue, 29 Jan 2008)
New Revision: 6019
Modified:
trunk/core/plugins/org.jboss.ide.eclipse.archives.ui/src/main/org/jboss/ide/eclipse/archives/ui/NodeContribution.java
Log:
JBIDE-1404 - wrapper did not account for nulls in extension point.
Modified: trunk/core/plugins/org.jboss.ide.eclipse.archives.ui/src/main/org/jboss/ide/eclipse/archives/ui/NodeContribution.java
===================================================================
--- trunk/core/plugins/org.jboss.ide.eclipse.archives.ui/src/main/org/jboss/ide/eclipse/archives/ui/NodeContribution.java 2008-01-29 20:10:47 UTC (rev 6018)
+++ trunk/core/plugins/org.jboss.ide.eclipse.archives.ui/src/main/org/jboss/ide/eclipse/archives/ui/NodeContribution.java 2008-01-29 22:23:42 UTC (rev 6019)
@@ -31,13 +31,13 @@
String iconPath = element.getAttribute("icon");
String pluginId = element.getDeclaringExtension().getNamespaceIdentifier();
Bundle bundle = Platform.getBundle(pluginId);
- URL iconURL = FileLocator.find(bundle, new Path(iconPath), null);
- if (iconURL == null) {
+ URL iconURL = iconPath == null ? null : FileLocator.find(bundle, new Path(iconPath), null);
+ if (iconURL != null) {
iconURL = bundle.getEntry(iconPath);
+ icon = ImageDescriptor.createFromURL(iconURL);
}
- icon = ImageDescriptor.createFromURL(iconURL);
-
- weight = Integer.parseInt(element.getAttribute("weight"));
+ String weightString = element.getAttribute("weight");
+ weight = Integer.parseInt(weightString == null ? "100" : weightString);
}
public int compareTo(Object o) {
16 years, 11 months
JBoss Tools SVN: r6018 - trunk/as/plugins/org.jboss.ide.eclipse.as.core.
by jbosstools-commits@lists.jboss.org
Author: dgolovin
Date: 2008-01-29 15:10:47 -0500 (Tue, 29 Jan 2008)
New Revision: 6018
Modified:
trunk/as/plugins/org.jboss.ide.eclipse.as.core/plugin.xml
Log:
http://jira.jboss.com/jira/browse/JBIDE-1647
default version 5.0 for jst.java faced added for JBoss 4.2 Runtime
Modified: trunk/as/plugins/org.jboss.ide.eclipse.as.core/plugin.xml
===================================================================
--- trunk/as/plugins/org.jboss.ide.eclipse.as.core/plugin.xml 2008-01-29 18:41:29 UTC (rev 6017)
+++ trunk/as/plugins/org.jboss.ide.eclipse.as.core/plugin.xml 2008-01-29 20:10:47 UTC (rev 6018)
@@ -451,4 +451,17 @@
containerID="org.jboss.ide.eclipse.as.classpath.core.javaee-5.0">
</filteredClasspathContainer>
</extension>
+ <extension
+ point="org.eclipse.wst.common.project.facet.core.defaultFacets">
+ <default-facets>
+ <runtime-component
+ id="org.jboss.ide.eclipse.as.runtime.component"
+ version="4.2">
+ </runtime-component>
+ <facet
+ id="jst.java"
+ version="5.0">
+ </facet>
+ </default-facets>
+ </extension>
</plugin>
16 years, 11 months
JBoss Tools SVN: r6017 - trunk/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor.
by jbosstools-commits@lists.jboss.org
Author: mareshkau
Date: 2008-01-29 13:41:29 -0500 (Tue, 29 Jan 2008)
New Revision: 6017
Modified:
trunk/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeSourceDomBuilder.java
Log:
code adjustment
Modified: trunk/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeSourceDomBuilder.java
===================================================================
--- trunk/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeSourceDomBuilder.java 2008-01-29 17:50:00 UTC (rev 6016)
+++ trunk/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeSourceDomBuilder.java 2008-01-29 18:41:29 UTC (rev 6017)
@@ -315,7 +315,7 @@
// info.setSourceCommentValue(pageContext, (Comment)sourceParent);
// }
//Added by Max Areshkau in scope of bug JBIDE-1209
- } else if (sourceParent instanceof TextImplForJSP) {
+ } else {
try{
IndexedRegion region = (IndexedRegion)sourceParent;
String text = sourceParent.getNodeValue();
16 years, 11 months
JBoss Tools SVN: r6016 - in trunk/common/plugins/org.jboss.tools.common.model: src/org/jboss/tools/common/model/files/handlers and 1 other directories.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2008-01-29 12:50:00 -0500 (Tue, 29 Jan 2008)
New Revision: 6016
Modified:
trunk/common/plugins/org.jboss.tools.common.model/resources/meta/filesystems.meta
trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/files/handlers/CreateFolderSupport.java
trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/util/EclipseResourceUtil.java
Log:
JBIDE-1705
Modified: trunk/common/plugins/org.jboss.tools.common.model/resources/meta/filesystems.meta
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model/resources/meta/filesystems.meta 2008-01-29 17:10:22 UTC (rev 6015)
+++ trunk/common/plugins/org.jboss.tools.common.model/resources/meta/filesystems.meta 2008-01-29 17:50:00 UTC (rev 6016)
@@ -265,7 +265,7 @@
kind="list" name="CreateActions">
<XActionItem HandlerClassName="%SpecialWizard%"
ICON="action.new.file.folder"
- PROPERTIES="validator.add=true;support=org.jboss.tools.common.model.files.handlers.CreateFolderSupport"
+ PROPERTIES="validator.add=true;support=org.jboss.tools.common.model.files.handlers.CreateFolderSupport;entity=FileFolder"
displayName="Folder..." kind="action" name="CreateFolder">
<EntityData EntityName="NewFileWizard">
<AttributeData AttributeName="folder"/>
@@ -401,7 +401,7 @@
kind="list" name="CreateActions">
<XActionItem HandlerClassName="%SpecialWizard%"
ICON="action.new.file.folder"
- PROPERTIES="validator.add=true;support=org.jboss.tools.common.model.files.handlers.CreateFolderSupport"
+ PROPERTIES="validator.add=true;support=org.jboss.tools.common.model.files.handlers.CreateFolderSupport;entity=FileFolder"
displayName="Folder..." kind="action" name="CreateFolder">
<EntityData EntityName="NewFileWizard">
<AttributeData AttributeName="folder"/>
Modified: trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/files/handlers/CreateFolderSupport.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/files/handlers/CreateFolderSupport.java 2008-01-29 17:10:22 UTC (rev 6015)
+++ trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/files/handlers/CreateFolderSupport.java 2008-01-29 17:50:00 UTC (rev 6016)
@@ -135,6 +135,10 @@
String folder = data.getProperty("folder");
targetHolder.revalidate(folder);
message = null;
+ if(targetHolder.target == null) {
+ message = "Cannot create folder in specified folder.";
+ return;
+ }
validateFolderName();
if(message != null) return;
validateChildName(data);
Modified: trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/util/EclipseResourceUtil.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/util/EclipseResourceUtil.java 2008-01-29 17:10:22 UTC (rev 6015)
+++ trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/util/EclipseResourceUtil.java 2008-01-29 17:50:00 UTC (rev 6016)
@@ -206,7 +206,7 @@
if(n == null) return null;
n = testNature(n);
if(n == null) {
- ModelPlugin.getPluginLog().logWarning("Project " + p + " has corrupted nuture: " + natures[i]);
+ ModelPlugin.getPluginLog().logWarning("Project " + p + " has corrupted nature: " + natures[i]);
removeNatureFromProject(p, natures[i]);
}
return n;
@@ -235,7 +235,7 @@
if(n == null) return null;
n = testNature(n);
if(n == null) {
- ModelPlugin.getPluginLog().logWarning("Project " + p + " has corrupted nuture: " + id);
+ ModelPlugin.getPluginLog().logWarning("Project " + p + " has corrupted nature: " + id);
removeNatureFromProject(p, id);
}
return n;
16 years, 11 months
JBoss Tools SVN: r6015 - trunk/jsf/docs/userguide/en/modules.
by jbosstools-commits@lists.jboss.org
Author: afedosik
Date: 2008-01-29 12:10:22 -0500 (Tue, 29 Jan 2008)
New Revision: 6015
Modified:
trunk/jsf/docs/userguide/en/modules/editors.xml
Log:
http://jira.jboss.com/jira/browse/JBDS-162 Editors chapter updated.
Modified: trunk/jsf/docs/userguide/en/modules/editors.xml
===================================================================
--- trunk/jsf/docs/userguide/en/modules/editors.xml 2008-01-29 16:33:45 UTC (rev 6014)
+++ trunk/jsf/docs/userguide/en/modules/editors.xml 2008-01-29 17:10:22 UTC (rev 6015)
@@ -11,14 +11,22 @@
<title>Editors</title>
- <para>JBDS is supplied with a huge range of various editors for different file types.</para>
+ <para>In previous chapters you had possibility to read about Graphical Editor for
+ <link linkend="GraphicalEditorAndViewingForJSFConfigurationFiles76331">JSF</link> and
+ <link linkend="GraphicalEditorForStrutsConfigurationFiles564">Struts</link> configuration files,
+ <link linkend="GraphicalEditorForTilesFiles132">Graphical Editor for Tiles Files</link>,
+ <link linkend="GraphicalEditorForStrutsValidationFiles86">Graphical Editor for Struts Validation Files</link>.
+ All these editors have <link linkend="OpenOnSelection4Hyperlinknavigation"><property>OpenOn</property></link> and
+ <link linkend="CodeAssistAndDynamicCodeAssist42BasedOnProjectData"><property>Content Assist</property></link> features,
+ they are described more detail in this chapter. In addition you get to know a <link linkend="visual_page">Visual Page Editor</link> for combined visual and source editing
+ of Web pages and many <link linkend="more_editors">other editors</link> for different types of files.</para>
<section id="editors_features">
<title>Editors Features</title>
<para>JBoss Developer Studio has powerful editor features that help you easily navigate
within your application and make use of content and code assist no matter what project
- file (jsp, xhtml, xml, css, etc.) you are working on.</para>
+ file (jsp, xhtml, xml, css, etc...) you are working on.</para>
<section id="OpenOnSelection4Hyperlinknavigation">
@@ -112,7 +120,7 @@
</figure>
<para>Open managed beans:</para>
<figure>
- <title>OpenOn With Maneaged Beans</title>
+ <title>OpenOn With Managed Beans</title>
<mediaobject>
<imageobject>
<imagedata fileref="images/editors_features/editors_features_7.png"/>
@@ -135,30 +143,32 @@
<section id="CodeAssistAndDynamicCodeAssist42BasedOnProjectData">
- <title>Code Assist and Dynamic Code Assist (based on project data)</title>
- <section id="ContentAssistFeatures321">
-
- <title>Content Assist Features</title>
- <section id="ContentAssist374">
-
+
<title>Content Assist</title>
<para><property>Content assist</property> is available when working with</para>
-
+
<itemizedlist>
<listitem>
- <para>Seam project files</para>
+ <para>
+ <ulink url="../../../seam/en/html_single/index.html#ContentAssist">Seam project files</ulink>
+ </para>
+
</listitem>
<listitem>
- <para>JSF project files</para>
+ <para><link linkend="JSFProjectFiles3087">JSF project files</link></para>
</listitem>
<listitem>
- <para>Struts project files</para>
+ <para><link linkend="StrutsProjectFile46s3">Struts project files</link></para>
</listitem>
<listitem>
- <para>JSP files</para>
+ <para><link linkend="JSPPages434">JSP files</link></para>
</listitem>
+ <listitem>
+ <para><link linkend="ContentAssistForRF">RichFaces components</link></para>
+ </listitem>
</itemizedlist>
- </section>
+
+
<section id="JSFProjectFiles3087">
<title>JSF Project Files</title>
@@ -513,7 +523,7 @@
</section>
<section id="ContentAssistForRF">
- <title>Content Assist for Rich Faces components</title>
+ <title>Rich Faces components</title>
<para>JBDS indeed provides code completion for Rich Faces framework components.
All you have to do is to install Rich Faces libraries into your project. See
<ulink
@@ -567,7 +577,7 @@
</mediaobject>
</figure>
</section>
- </section>
+
<section id="AddingDynamicCodeAssistToCustomComponents8745">
@@ -1099,8 +1109,8 @@
<section id="more_editors">
<title>More Editors</title>
- <para>Besides Visual Page Editor JBDS provides editors for editing project files of any
- types: properties, TLD, web.xml, tiles, and so on.</para>
+
+ <para>Besides Visual Page Editor JBDS is supplied with a huge range of various editors for different file types: properties, TLD, web.xml, tiles, and so on.</para>
<section id="GraphicalPropertiesEditor">
<title>Graphical Properties Editor</title>
16 years, 11 months
JBoss Tools SVN: r6014 - trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/util.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2008-01-29 11:33:45 -0500 (Tue, 29 Jan 2008)
New Revision: 6014
Modified:
trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/util/EclipseResourceUtil.java
Log:
JBIDE-1655
Modified: trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/util/EclipseResourceUtil.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/util/EclipseResourceUtil.java 2008-01-29 14:56:13 UTC (rev 6013)
+++ trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/util/EclipseResourceUtil.java 2008-01-29 16:33:45 UTC (rev 6014)
@@ -13,7 +13,6 @@
import java.io.File;
import java.io.IOException;
import java.net.URL;
-import java.net.URLClassLoader;
import java.util.*;
import org.eclipse.core.resources.*;
@@ -204,7 +203,13 @@
try {
if(p.hasNature(natures[i])) {
IModelNature n = (IModelNature)p.getNature(natures[i]);
- return n == null || n.getModel() == null ? null : n;
+ if(n == null) return null;
+ n = testNature(n);
+ if(n == null) {
+ ModelPlugin.getPluginLog().logWarning("Project " + p + " has corrupted nuture: " + natures[i]);
+ removeNatureFromProject(p, natures[i]);
+ }
+ return n;
}
} catch (CoreException e) {
ModelPlugin.getPluginLog().logError(e);
@@ -212,11 +217,29 @@
}
return null;
}
+
+ private static IModelNature testNature(IModelNature n) {
+ if(n == null || n.getModel() == null) return null;
+ XModel model = n.getModel();
+ XModelObject object = model.getRoot();
+ if(object == null) return null;
+ if(!"Root".equals(object.getModelEntity().getName())) return null;
+ return n;
+ }
public static IModelNature getModelNature(IProject p, String id) {
if(p == null || !p.isOpen()) return null;
try {
- if(p.hasNature(id)) return (IModelNature)p.getNature(id);
+ if(p.hasNature(id)) {
+ IModelNature n = (IModelNature)p.getNature(id);
+ if(n == null) return null;
+ n = testNature(n);
+ if(n == null) {
+ ModelPlugin.getPluginLog().logWarning("Project " + p + " has corrupted nuture: " + id);
+ removeNatureFromProject(p, id);
+ }
+ return n;
+ }
} catch (CoreException e) {
ModelPlugin.getPluginLog().logError(e);
}
16 years, 11 months
JBoss Tools SVN: r6013 - in trunk/seam/tests/org.jboss.tools.seam.core.test: src/org/jboss/tools/seam/core/test and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2008-01-29 09:56:13 -0500 (Tue, 29 Jan 2008)
New Revision: 6013
Added:
trunk/seam/tests/org.jboss.tools.seam.core.test/projects/SeamWebWarTestProject/src/action/org/domain/SeamWebWarTestProject/session/BaseComponent.java
trunk/seam/tests/org.jboss.tools.seam.core.test/projects/SeamWebWarTestProject/src/action/org/domain/SeamWebWarTestProject/session/InheritedComponent.java
Modified:
trunk/seam/tests/org.jboss.tools.seam.core.test/src/org/jboss/tools/seam/core/test/SeamValidatorsTest.java
Log:
JBIDE-1691
Added: trunk/seam/tests/org.jboss.tools.seam.core.test/projects/SeamWebWarTestProject/src/action/org/domain/SeamWebWarTestProject/session/BaseComponent.java
===================================================================
--- trunk/seam/tests/org.jboss.tools.seam.core.test/projects/SeamWebWarTestProject/src/action/org/domain/SeamWebWarTestProject/session/BaseComponent.java (rev 0)
+++ trunk/seam/tests/org.jboss.tools.seam.core.test/projects/SeamWebWarTestProject/src/action/org/domain/SeamWebWarTestProject/session/BaseComponent.java 2008-01-29 14:56:13 UTC (rev 6013)
@@ -0,0 +1,11 @@
+package org.domain.SeamWebWarTestProject.session;
+
+import javax.ejb.Remove;
+import org.jboss.seam.annotations.Destroy;
+
+public abstract class BaseComponent {
+
+ @Remove @Destroy
+ public void destroy() {}
+
+}
Added: trunk/seam/tests/org.jboss.tools.seam.core.test/projects/SeamWebWarTestProject/src/action/org/domain/SeamWebWarTestProject/session/InheritedComponent.java
===================================================================
--- trunk/seam/tests/org.jboss.tools.seam.core.test/projects/SeamWebWarTestProject/src/action/org/domain/SeamWebWarTestProject/session/InheritedComponent.java (rev 0)
+++ trunk/seam/tests/org.jboss.tools.seam.core.test/projects/SeamWebWarTestProject/src/action/org/domain/SeamWebWarTestProject/session/InheritedComponent.java 2008-01-29 14:56:13 UTC (rev 6013)
@@ -0,0 +1,13 @@
+package org.domain.SeamWebWarTestProject.session;
+
+import javax.ejb.Stateful;
+import javax.persistence.Entity;
+
+import org.jboss.seam.annotations.Name;
+
+@Name("inheritedComponent")
+@Entity
+@Stateful
+public class InheritedComponent extends BaseComponent {
+
+}
Modified: trunk/seam/tests/org.jboss.tools.seam.core.test/src/org/jboss/tools/seam/core/test/SeamValidatorsTest.java
===================================================================
--- trunk/seam/tests/org.jboss.tools.seam.core.test/src/org/jboss/tools/seam/core/test/SeamValidatorsTest.java 2008-01-29 14:44:34 UTC (rev 6012)
+++ trunk/seam/tests/org.jboss.tools.seam.core.test/src/org/jboss/tools/seam/core/test/SeamValidatorsTest.java 2008-01-29 14:56:13 UTC (rev 6013)
@@ -11,6 +11,7 @@
package org.jboss.tools.seam.core.test;
import java.io.IOException;
+import java.util.Set;
import junit.framework.TestCase;
@@ -24,7 +25,10 @@
import org.eclipse.core.runtime.NullProgressMonitor;
import org.eclipse.jface.preference.IPersistentPreferenceStore;
import org.eclipse.jface.preference.IPreferenceStore;
+import org.jboss.tools.seam.core.ISeamComponent;
+import org.jboss.tools.seam.core.ISeamComponentMethod;
import org.jboss.tools.seam.core.ISeamProject;
+import org.jboss.tools.seam.core.SeamComponentMethodType;
import org.jboss.tools.seam.core.SeamCorePlugin;
import org.jboss.tools.seam.core.SeamPreferences;
import org.jboss.tools.seam.internal.core.SeamProject;
@@ -839,7 +843,24 @@
assertTrue(errorMessage, lineNumbers[0] == 16);
assertTrue(errorMessage, lineNumbers[1] == 16);
}
+
+ public void testInheritedMethods() {
+ ISeamProject seamProject = getSeamProject(project);
+ ISeamComponent c = seamProject.getComponent("inheritedComponent");
+ assertTrue("Component inheritedComponent is not found", c != null);
+
+ Set<ISeamComponentMethod> ms = c.getMethodsByType(SeamComponentMethodType.DESTROY);
+ assertTrue("Seam tools does not see @Destroy-annotated method declared in super class", ms.size() > 0);
+
+ ms = c.getMethodsByType(SeamComponentMethodType.REMOVE);
+ assertTrue("Seam tools does not see @Remove-annotated method declared in super class", ms.size() > 0);
+
+ IFile f = project.getFile("src/action/org/domain/SeamWebWarTestProject/session/InheritedComponent.java");
+ int errorsCount = getMarkersNumber(f);
+ assertTrue("Seam tools validator does not see annotated methods declared in super class", errorsCount == 0);
+ }
+
private void modifyPreferences(){
IPreferenceStore store = SeamCorePlugin.getDefault().getPreferenceStore();
store.putValue(SeamPreferences.UNKNOWN_EL_VARIABLE_NAME, SeamPreferences.ERROR);
16 years, 11 months
JBoss Tools SVN: r6011 - trunk/jst/plugins/org.jboss.tools.jst.web/resources/help.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2008-01-29 08:05:47 -0500 (Tue, 29 Jan 2008)
New Revision: 6011
Modified:
trunk/jst/plugins/org.jboss.tools.jst.web/resources/help/keys-web.properties
Log:
JBIDE-1701
Modified: trunk/jst/plugins/org.jboss.tools.jst.web/resources/help/keys-web.properties
===================================================================
--- trunk/jst/plugins/org.jboss.tools.jst.web/resources/help/keys-web.properties 2008-01-29 13:01:36 UTC (rev 6010)
+++ trunk/jst/plugins/org.jboss.tools.jst.web/resources/help/keys-web.properties 2008-01-29 13:05:47 UTC (rev 6011)
@@ -725,4 +725,9 @@
FileSystems_Add_0.Title=Module
WebAppLocaleEncodingMappingList_CreateLocaleEncodingMapping.WindowTitle=Add Locale Encoding Mapping
-WebAppLocaleEncodingMappingList_CreateLocaleEncodingMapping.Title=Locale Encoding Mapping
\ No newline at end of file
+WebAppLocaleEncodingMappingList_CreateLocaleEncodingMapping.Title=Locale Encoding Mapping
+
+OptionRoot_CreatePageTemplate_0.WindowTitle=Add Page Template
+OptionRoot_CreatePageTemplate_0.Title=Template
+OptionRoot_CreatePageTemplate.WindowTitle=Add Page Template
+OptionRoot_CreatePageTemplate.Title=Template
16 years, 11 months
JBoss Tools SVN: r6010 - trunk/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/hqleditor.
by jbosstools-commits@lists.jboss.org
Author: dgeraskov
Date: 2008-01-29 08:01:36 -0500 (Tue, 29 Jan 2008)
New Revision: 6010
Added:
trunk/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/hqleditor/LoadConsoleCFGCompletionProposal.java
Modified:
trunk/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/hqleditor/HQLCompletionProcessor.java
Log:
http://jira.jboss.com/jira/browse/JBIDE-1500
Added completion proposal to load console configuration when it was not loaded
Modified: trunk/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/hqleditor/HQLCompletionProcessor.java
===================================================================
--- trunk/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/hqleditor/HQLCompletionProcessor.java 2008-01-29 12:32:17 UTC (rev 6009)
+++ trunk/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/hqleditor/HQLCompletionProcessor.java 2008-01-29 13:01:36 UTC (rev 6010)
@@ -101,9 +101,8 @@
startWord = getWord( doc, startOffset, wordLength );
if(startWord!=null) {
- char[] cs = new char[0];
try {
- cs = doc.get(0,doc.getLength()).toCharArray();
+ doc.get(0,doc.getLength()).toCharArray();
}
catch (BadLocationException e) {
errorMessage = "Could not get document contents";
@@ -111,7 +110,10 @@
}
Configuration configuration = consoleConfiguration!=null?consoleConfiguration.getConfiguration():null;
-
+ if(configuration == null && consoleConfiguration!=null) {
+ errorMessage = "Configuration not opened";
+ return new ICompletionProposal[]{ new LoadConsoleCFGCompletionProposal(consoleConfiguration) };
+ }
IHQLCodeAssist hqlEval = new HQLCodeAssist(configuration);
EclipseHQLCompletionRequestor eclipseHQLCompletionCollector = new EclipseHQLCompletionRequestor();
hqlEval.codeComplete(doc.get(), currentOffset, eclipseHQLCompletionCollector);
Added: trunk/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/hqleditor/LoadConsoleCFGCompletionProposal.java
===================================================================
--- trunk/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/hqleditor/LoadConsoleCFGCompletionProposal.java (rev 0)
+++ trunk/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/hqleditor/LoadConsoleCFGCompletionProposal.java 2008-01-29 13:01:36 UTC (rev 6010)
@@ -0,0 +1,79 @@
+/*******************************************************************************
+ * Copyright (c) 2007-2008 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
+ *
+ * Contributor:
+ * Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+package org.hibernate.eclipse.hqleditor;
+
+import org.eclipse.jface.text.IDocument;
+import org.eclipse.jface.text.contentassist.ICompletionProposal;
+import org.eclipse.jface.text.contentassist.IContextInformation;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.swt.graphics.Point;
+import org.hibernate.console.ConsoleConfiguration;
+import org.hibernate.console.ImageConstants;
+import org.hibernate.eclipse.console.utils.EclipseImages;
+
+/**
+ * @author Dmitry Geraskov
+ *
+ */
+public class LoadConsoleCFGCompletionProposal implements ICompletionProposal {
+
+ private ConsoleConfiguration consoleConfiguration;
+
+ public LoadConsoleCFGCompletionProposal(ConsoleConfiguration consoleConfiguration){
+ this.consoleConfiguration = consoleConfiguration;
+ }
+
+ /* (non-Javadoc)
+ * @see org.eclipse.jface.text.contentassist.ICompletionProposal#apply(org.eclipse.jface.text.IDocument)
+ */
+ public void apply(IDocument document) {
+ //load console configuration
+ if(consoleConfiguration.getConfiguration()==null) {
+ consoleConfiguration.build();
+ }
+ }
+
+ /* (non-Javadoc)
+ * @see org.eclipse.jface.text.contentassist.ICompletionProposal#getAdditionalProposalInfo()
+ */
+ public String getAdditionalProposalInfo() {
+ return "Additional Info";
+ }
+
+ /* (non-Javadoc)
+ * @see org.eclipse.jface.text.contentassist.ICompletionProposal#getContextInformation()
+ */
+ public IContextInformation getContextInformation() {
+ return null;
+ }
+
+ /* (non-Javadoc)
+ * @see org.eclipse.jface.text.contentassist.ICompletionProposal#getDisplayString()
+ */
+ public String getDisplayString() {
+ return "Load Console Configuration";
+ }
+
+ /* (non-Javadoc)
+ * @see org.eclipse.jface.text.contentassist.ICompletionProposal#getImage()
+ */
+ public Image getImage() {
+ return EclipseImages.getImage( ImageConstants.CONFIGURATION );
+ }
+
+ /* (non-Javadoc)
+ * @see org.eclipse.jface.text.contentassist.ICompletionProposal#getSelection(org.eclipse.jface.text.IDocument)
+ */
+ public Point getSelection(IDocument document) {
+ return null;
+ }
+
+}
Property changes on: trunk/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/hqleditor/LoadConsoleCFGCompletionProposal.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Name: svn:keywords
+ Author Id Revision Date
Name: svn:eol-style
+ native
16 years, 11 months