JBoss Tools SVN: r4133 - in branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test: META-INF and 5 other directories.
by jbosstools-commits@lists.jboss.org
Author: dsakovich
Date: 2007-10-12 05:09:59 -0400 (Fri, 12 Oct 2007)
New Revision: 4133
Added:
branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/xulrunner/
branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/xulrunner/tests/
branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/xulrunner/view/
Removed:
branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/mozilla/tests/
branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/mozilla/view/
Modified:
branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/.project
branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/META-INF/MANIFEST.MF
branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/plugin.xml
branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/xulrunner/tests/DOMCreatingTest.java
branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/xulrunner/tests/MozillaBrowserTest.java
branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/xulrunner/tests/VpeMozillaAllTests.java
branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/xulrunner/view/MozillaView.java
Log:
Add XulRunnerTest
Modified: branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/.project
===================================================================
--- branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/.project 2007-10-12 08:48:02 UTC (rev 4132)
+++ branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/.project 2007-10-12 09:09:59 UTC (rev 4133)
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
- <name>org.jboss.tools.vpe.mozilla.test</name>
+ <name>org.jboss.tools.vpe.xulrunner.test</name>
<comment></comment>
<projects>
</projects>
Modified: branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/META-INF/MANIFEST.MF
===================================================================
--- branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/META-INF/MANIFEST.MF 2007-10-12 08:48:02 UTC (rev 4132)
+++ branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/META-INF/MANIFEST.MF 2007-10-12 09:09:59 UTC (rev 4133)
@@ -1,15 +1,15 @@
Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: Mozilla Tests Plug-in
-Bundle-SymbolicName: org.jboss.tools.vpe.mozilla.test;singleton:=true
+Bundle-SymbolicName: org.jboss.tools.vpe.xulrunner.test;singleton:=true
Bundle-Version: 2.0.0
Bundle-Vendor: Red Hat, Inc.
Require-Bundle: org.eclipse.ui,
org.eclipse.core.runtime,
org.junit,
org.jboss.tools.common,
- org.jboss.tools.vpe.mozilla
+ org.jboss.tools.vpe.xulrunner
Eclipse-LazyStart: true
-Export-Package: org.jboss.tools.vpe.mozilla.tests,
- org.jboss.tools.vpe.mozilla.view
+Export-Package: org.jboss.tools.vpe.xulrunner.tests,
+ org.jboss.tools.vpe.xulrunner.view
Bundle-ClassPath: vpe-mozilla-tests.jar
Modified: branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/plugin.xml
===================================================================
--- branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/plugin.xml 2007-10-12 08:48:02 UTC (rev 4132)
+++ branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/plugin.xml 2007-10-12 09:09:59 UTC (rev 4133)
@@ -8,7 +8,7 @@
name="VPE Tests"/>
<view
category="org.jboss.tools.vpe.mozilla.view"
- class="org.jboss.tools.vpe.mozilla.view.MozillaView"
+ class="org.jboss.tools.vpe.xulrunner.view.MozillaView"
id="org.jboss.tools.vpe.mozilla.view.MozillaView"
name="Mozilla View"/>
</extension>
Copied: branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/xulrunner/tests (from rev 4131, branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/mozilla/tests)
Modified: branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/xulrunner/tests/DOMCreatingTest.java
===================================================================
--- branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/mozilla/tests/DOMCreatingTest.java 2007-10-12 08:07:11 UTC (rev 4131)
+++ branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/xulrunner/tests/DOMCreatingTest.java 2007-10-12 09:09:59 UTC (rev 4133)
@@ -8,12 +8,12 @@
* Contributors:
* Exadel, Inc. and Red Hat, Inc. - initial API and implementation
******************************************************************************/
-package org.jboss.tools.vpe.mozilla.tests;
+package org.jboss.tools.vpe.xulrunner.tests;
import org.eclipse.ui.PlatformUI;
import org.jboss.tools.vpe.mozilla.internal.swt.xpl.nsIDOMDocument;
import org.jboss.tools.vpe.mozilla.browser.MozillaBrowser;
-import org.jboss.tools.vpe.mozilla.view.MozillaView;
+import org.jboss.tools.vpe.xulrunner.view.MozillaView;
import org.w3c.dom.Attr;
import org.w3c.dom.Element;
import org.w3c.dom.Node;
@@ -26,7 +26,7 @@
* @author Max Areshkau
*
*/
-public class DOMCreatingTest extends MozillaBrowserTest {
+public class DOMCreatingTest extends XulRunnerBrowserTest {
/**
* Contains brouser instamce
Modified: branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/xulrunner/tests/MozillaBrowserTest.java
===================================================================
--- branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/mozilla/tests/MozillaBrowserTest.java 2007-10-12 08:07:11 UTC (rev 4131)
+++ branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/xulrunner/tests/MozillaBrowserTest.java 2007-10-12 09:09:59 UTC (rev 4133)
@@ -8,7 +8,7 @@
* Contributors:
* Exadel, Inc. and Red Hat, Inc. - initial API and implementation
******************************************************************************/
-package org.jboss.tools.vpe.mozilla.tests;
+package org.jboss.tools.vpe.xulrunner.tests;
import junit.framework.TestCase;
@@ -16,7 +16,7 @@
import org.eclipse.swt.widgets.Display;
import org.eclipse.ui.PartInitException;
import org.eclipse.ui.PlatformUI;
-import org.jboss.tools.vpe.mozilla.view.MozillaView;
+import org.jboss.tools.vpe.xulrunner.view.MozillaView;
public class MozillaBrowserTest extends TestCase {
public static final String VIEW_ID
Modified: branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/xulrunner/tests/VpeMozillaAllTests.java
===================================================================
--- branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/mozilla/tests/VpeMozillaAllTests.java 2007-10-12 08:07:11 UTC (rev 4131)
+++ branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/xulrunner/tests/VpeMozillaAllTests.java 2007-10-12 09:09:59 UTC (rev 4133)
@@ -8,7 +8,7 @@
* Contributors:
* Exadel, Inc. and Red Hat, Inc. - initial API and implementation
******************************************************************************/
-package org.jboss.tools.vpe.mozilla.tests;
+package org.jboss.tools.vpe.xulrunner.tests;
import junit.framework.Test;
import junit.framework.TestSuite;
Copied: branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/xulrunner/view (from rev 4131, branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/mozilla/view)
Modified: branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/xulrunner/view/MozillaView.java
===================================================================
--- branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/mozilla/view/MozillaView.java 2007-10-12 08:07:11 UTC (rev 4131)
+++ branches/jbosstools_xulrunner/vpe/tests/org.jboss.tools.vpe.mozilla.test/src/org/jboss/tools/vpe/xulrunner/view/MozillaView.java 2007-10-12 09:09:59 UTC (rev 4133)
@@ -8,17 +8,18 @@
* Contributors:
* Exadel, Inc. and Red Hat, Inc. - initial API and implementation
******************************************************************************/
-package org.jboss.tools.vpe.mozilla.view;
+package org.jboss.tools.vpe.xulrunner.view;
import org.eclipse.swt.SWT;
import org.eclipse.swt.layout.GridData;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.ui.part.ViewPart;
+import org.jboss.tools.vpe.xulrunner.browser.XulRunnerBrowser;
-import org.jboss.tools.vpe.mozilla.browser.MozillaBrowser;
+
/**
* This class wes developed for test corectly starting of Mozilla.
* Mozilla is used as part of Visual Pade Editor.
@@ -26,7 +27,7 @@
public class MozillaView extends ViewPart {
private static final String INIT_URL = "about:buildconfig";
- private MozillaBrowser browser;
+ private XulRunnerBrowser browser;
/**
* The constructor.
17 years, 3 months
JBoss Tools SVN: r4132 - trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/operation.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2007-10-12 04:48:02 -0400 (Fri, 12 Oct 2007)
New Revision: 4132
Modified:
trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/operation/WebNatureOperation.java
Log:
JBIDE-544
Modified: trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/operation/WebNatureOperation.java
===================================================================
--- trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/operation/WebNatureOperation.java 2007-10-12 08:07:11 UTC (rev 4131)
+++ trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/operation/WebNatureOperation.java 2007-10-12 08:48:02 UTC (rev 4132)
@@ -365,7 +365,10 @@
}
for (int i = 0; i < servers.length; i++) {
ComponentUtilities.setServerContextRoot(getProject(), registry.getApplicationName());
- if(monitor != null) monitor.worked(step);
+ if(monitor != null) {
+ monitor.worked(step);
+ monitor.subTask(servers[i].getName());
+ }
RegistrationHelper.register(getProject(), servers[i]);
if(monitor != null) monitor.worked(step);
}
17 years, 3 months
JBoss Tools SVN: r4131 - trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/operation.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2007-10-12 04:07:11 -0400 (Fri, 12 Oct 2007)
New Revision: 4131
Modified:
trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/operation/WebNatureOperation.java
Log:
JBIDE-544
Modified: trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/operation/WebNatureOperation.java
===================================================================
--- trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/operation/WebNatureOperation.java 2007-10-12 07:07:06 UTC (rev 4130)
+++ trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/operation/WebNatureOperation.java 2007-10-12 08:07:11 UTC (rev 4131)
@@ -316,7 +316,7 @@
long counter = 100;
public RegisterTomcatJob() {
- super("Register Tomcat");
+ super("Register in Server");
}
protected IStatus run(IProgressMonitor monitor) {
17 years, 3 months
JBoss Tools SVN: r4130 - trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/xmleditor.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2007-10-12 03:07:06 -0400 (Fri, 12 Oct 2007)
New Revision: 4130
Modified:
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/xmleditor/XMLTextEditor.java
Log:
JBIDE-737
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/xmleditor/XMLTextEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/xmleditor/XMLTextEditor.java 2007-10-12 04:56:51 UTC (rev 4129)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/texteditors/xmleditor/XMLTextEditor.java 2007-10-12 07:07:06 UTC (rev 4130)
@@ -51,9 +51,11 @@
import org.eclipse.wst.sse.core.internal.provisional.IndexedRegion;
import org.eclipse.wst.sse.core.internal.provisional.text.ITextRegion;
import org.eclipse.wst.sse.ui.StructuredTextEditor;
+import org.eclipse.wst.sse.ui.StructuredTextViewerConfiguration;
import org.eclipse.wst.sse.ui.internal.StructuredTextViewer;
import org.eclipse.wst.xml.core.internal.document.AttrImpl;
import org.eclipse.wst.xml.core.internal.document.ElementImpl;
+import org.eclipse.wst.xml.ui.StructuredTextViewerConfigurationXML;
import org.eclipse.wst.xml.ui.internal.XMLUIPlugin;
import org.w3c.dom.DocumentType;
import org.w3c.dom.NamedNodeMap;
@@ -96,7 +98,11 @@
}
protected void setSourceViewerConfiguration(SourceViewerConfiguration config) {
- if(!(config instanceof RedHatStructuredTextViewerConfigurationXML)) {
+ if(!(config instanceof RedHatStructuredTextViewerConfigurationXML)
+ && (config instanceof StructuredTextViewerConfigurationXML
+ || !(config instanceof StructuredTextViewerConfiguration)
+ )
+ ) {
RedHatStructuredTextViewerConfigurationXML r = new RedHatStructuredTextViewerConfigurationXML();
r.setInitialConfiguration(config);
config = r;
17 years, 3 months
JBoss Tools SVN: r4129 - trunk/as/plugins/org.jboss.ide.eclipse.as.core.
by jbosstools-commits@lists.jboss.org
Author: rob.stryker(a)jboss.com
Date: 2007-10-12 00:56:51 -0400 (Fri, 12 Oct 2007)
New Revision: 4129
Modified:
trunk/as/plugins/org.jboss.ide.eclipse.as.core/plugin.xml
Log:
JBIDE-249
Modified: trunk/as/plugins/org.jboss.ide.eclipse.as.core/plugin.xml
===================================================================
--- trunk/as/plugins/org.jboss.ide.eclipse.as.core/plugin.xml 2007-10-12 01:30:51 UTC (rev 4128)
+++ trunk/as/plugins/org.jboss.ide.eclipse.as.core/plugin.xml 2007-10-12 04:56:51 UTC (rev 4129)
@@ -14,7 +14,7 @@
id="org.jboss.ide.eclipse.as.32"
initialState="stopped"
launchConfigId="org.jboss.ide.eclipse.as.core.server.startupConfiguration"
- launchModes="run,debug"
+ launchModes="run,debug,profile"
name="%jboss.version.32.name"
runtime="true"
runtimeTypeId="org.jboss.ide.eclipse.as.runtime.32"
@@ -31,7 +31,7 @@
id="org.jboss.ide.eclipse.as.40"
initialState="stopped"
launchConfigId="org.jboss.ide.eclipse.as.core.server.startupConfiguration"
- launchModes="run,debug"
+ launchModes="run,debug,profile"
name="%jboss.version.40.name"
runtime="true"
runtimeTypeId="org.jboss.ide.eclipse.as.runtime.40"
@@ -48,7 +48,7 @@
id="org.jboss.ide.eclipse.as.42"
initialState="stopped"
launchConfigId="org.jboss.ide.eclipse.as.core.server.startupConfiguration"
- launchModes="run,debug"
+ launchModes="run,debug,profile"
name="%jboss.version.42.name"
runtime="true"
runtimeTypeId="org.jboss.ide.eclipse.as.runtime.42"
17 years, 3 months
JBoss Tools SVN: r4128 - trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/wizard.
by jbosstools-commits@lists.jboss.org
Author: dgolovin
Date: 2007-10-11 21:30:51 -0400 (Thu, 11 Oct 2007)
New Revision: 4128
Modified:
trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/wizard/SeamActionNewWizardTest.java
trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/wizard/SeamFormNewWizardTest.java
trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/wizard/SeamProjectNewWizardTest.java
Log:
http://jira.jboss.com/jira/browse/JBIDE-985
seam runtime validation added to Seam Wizards
some code clean up was done
Modified: trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/wizard/SeamActionNewWizardTest.java
===================================================================
--- trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/wizard/SeamActionNewWizardTest.java 2007-10-12 01:30:44 UTC (rev 4127)
+++ trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/wizard/SeamActionNewWizardTest.java 2007-10-12 01:30:51 UTC (rev 4128)
@@ -16,8 +16,8 @@
import org.eclipse.jface.wizard.IWizardPage;
import org.eclipse.jface.wizard.WizardDialog;
import org.eclipse.ui.PlatformUI;
+import org.jboss.tools.common.util.WorkbenchUtils;
import org.jboss.tools.seam.ui.ISeamUiConstants;
-import org.jboss.tools.test.util.WorkbenchUtils;
/**
* @author eskimo
Modified: trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/wizard/SeamFormNewWizardTest.java
===================================================================
--- trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/wizard/SeamFormNewWizardTest.java 2007-10-12 01:30:44 UTC (rev 4127)
+++ trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/wizard/SeamFormNewWizardTest.java 2007-10-12 01:30:51 UTC (rev 4128)
@@ -16,8 +16,8 @@
import org.eclipse.jface.wizard.IWizardPage;
import org.eclipse.jface.wizard.WizardDialog;
import org.eclipse.ui.PlatformUI;
+import org.jboss.tools.common.util.WorkbenchUtils;
import org.jboss.tools.seam.ui.ISeamUiConstants;
-import org.jboss.tools.test.util.WorkbenchUtils;
/**
* @author eskimo
Modified: trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/wizard/SeamProjectNewWizardTest.java
===================================================================
--- trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/wizard/SeamProjectNewWizardTest.java 2007-10-12 01:30:44 UTC (rev 4127)
+++ trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/wizard/SeamProjectNewWizardTest.java 2007-10-12 01:30:51 UTC (rev 4128)
@@ -16,8 +16,8 @@
import org.eclipse.jface.wizard.IWizardPage;
import org.eclipse.jface.wizard.WizardDialog;
import org.eclipse.ui.PlatformUI;
+import org.jboss.tools.common.util.WorkbenchUtils;
import org.jboss.tools.seam.ui.ISeamUiConstants;
-import org.jboss.tools.test.util.WorkbenchUtils;
/**
* @author eskimo
17 years, 3 months
JBoss Tools SVN: r4127 - in trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui: actions and 9 other directories.
by jbosstools-commits@lists.jboss.org
Author: dgolovin
Date: 2007-10-11 21:30:44 -0400 (Thu, 11 Oct 2007)
New Revision: 4127
Removed:
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamProjectWizardPage1.java
Modified:
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/SeamGuiPlugin.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/SeamUiImages.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/actions/CreateProjectAction.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/internal/project/facet/IValidator.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/internal/project/facet/SeamInstallWizardPage.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/internal/project/facet/ValidatorFactory.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/preferences/SeamPreferencePage.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/preferences/SeamSettingsPreferencePage.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/preferences/SeamValidatorPreferencePage.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/text/java/SeamELProposalProcessor.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/AbstractSeamContentProvider.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/RootContentProvider.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/SeamLabelProvider.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/actions/ScopePresentationActionProvider.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/actions/SeamActionProvider.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/actions/SeamOpenAction.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/actions/SeamViewLayoutActionGroup.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/properties/SeamComponentProperties.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/BaseFieldEditor.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/ButtonFieldEditor.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/CheckBoxFieldEditor.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/CompositeEditor.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/LabelFieldEditor.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/SeamRuntimeListFieldEditor.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/SwtFieldEditorFactory.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/TextFieldEditor.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/field/TextField.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/CreateSeamWebProjectAction.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/IParameter.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamActionWizardPage1.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamBaseWizardPage.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamConversationWizard.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamConversationWizardPage1.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamEntityWizard.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamEntityWizardPage1.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamFormWizard.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamFormWizardPage1.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamGenerateEnitiesWizard.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamProjectSelectionDialog.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamWizardFactory.java
Log:
http://jira.jboss.com/jira/browse/JBIDE-985
seam runtime validation added to Seam Wizards
some code clean up was done
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/SeamGuiPlugin.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/SeamGuiPlugin.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/SeamGuiPlugin.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -10,25 +10,9 @@
******************************************************************************/
package org.jboss.tools.seam.ui;
-import java.util.Properties;
-
-import org.eclipse.core.runtime.IConfigurationElement;
-import org.eclipse.datatools.connectivity.ConnectionProfileConstants;
-import org.eclipse.datatools.connectivity.ProfileManager;
-import org.eclipse.datatools.connectivity.db.generic.IDBConnectionProfileConstants;
-import org.eclipse.datatools.connectivity.db.generic.IDBDriverDefinitionConstants;
-import org.eclipse.datatools.connectivity.drivers.DriverInstance;
-import org.eclipse.datatools.connectivity.drivers.DriverManager;
-import org.eclipse.datatools.connectivity.drivers.IDriverMgmtConstants;
-import org.eclipse.datatools.connectivity.drivers.IPropertySet;
-import org.eclipse.datatools.connectivity.drivers.PropertySetImpl;
-import org.eclipse.datatools.connectivity.drivers.models.OverrideTemplateDescriptor;
-import org.eclipse.datatools.connectivity.drivers.models.TemplateDescriptor;
import org.eclipse.jface.resource.ImageDescriptor;
import org.jboss.tools.common.log.BaseUIPlugin;
import org.jboss.tools.common.log.IPluginLog;
-import org.jboss.tools.seam.core.SeamPreferences;
-import org.jboss.tools.seam.core.project.facet.SeamFacetPreference;
import org.osgi.framework.BundleContext;
/**
@@ -53,6 +37,7 @@
* (non-Javadoc)
* @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext)
*/
+ @Override
public void stop(BundleContext context) throws Exception {
plugin = null;
super.stop(context);
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/SeamUiImages.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/SeamUiImages.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/SeamUiImages.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -30,13 +30,13 @@
}
}
- public static Image SCOPE_IMAGE = getImage("view/scope.gif"); //$NON-NLS-1$
- public static Image PROJECT_IMAGE = getImage("view/seam_project.gif"); //$NON-NLS-1$
- public static Image COMPONENT_IMAGE = getImage("view/component.gif"); //$NON-NLS-1$
- public static Image ROLE_IMAGE = getImage("view/role.gif"); //$NON-NLS-1$
- public static Image JAVA_IMAGE = getImage("view/java.gif"); //$NON-NLS-1$
- public static Image JAVA_BINARY_IMAGE = getImage("view/java_binary.gif"); //$NON-NLS-1$
- public static Image PACKAGE_IMAGE = getImage("view/package.gif"); //$NON-NLS-1$
+ public static final Image SCOPE_IMAGE = getImage("view/scope.gif"); //$NON-NLS-1$
+ public static final Image PROJECT_IMAGE = getImage("view/seam_project.gif"); //$NON-NLS-1$
+ public static final Image COMPONENT_IMAGE = getImage("view/component.gif"); //$NON-NLS-1$
+ public static final Image ROLE_IMAGE = getImage("view/role.gif"); //$NON-NLS-1$
+ public static final Image JAVA_IMAGE = getImage("view/java.gif"); //$NON-NLS-1$
+ public static final Image JAVA_BINARY_IMAGE = getImage("view/java_binary.gif"); //$NON-NLS-1$
+ public static final Image PACKAGE_IMAGE = getImage("view/package.gif"); //$NON-NLS-1$
public static String SEAM_CREATE_PROJECT_ACTION = "view/seam_project_new.gif"; //$NON-NLS-1$
@@ -62,7 +62,7 @@
protected SeamUiImages(URL registryUrl, SeamUiImages parent){
- if(registryUrl == null) throw new NullPointerException(SeamUIMessages.SEAM_UI_IMAGESBASE_URL_FOR_IMAGE_REGISTRY_CANNOT_BE_NULL);
+ if(registryUrl == null) throw new IllegalArgumentException(SeamUIMessages.SEAM_UI_IMAGESBASE_URL_FOR_IMAGE_REGISTRY_CANNOT_BE_NULL);
baseUrl = registryUrl;
parentRegistry = parent;
}
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/actions/CreateProjectAction.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/actions/CreateProjectAction.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/actions/CreateProjectAction.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -51,6 +51,7 @@
.getImageDescriptor(SeamUiImages.SEAM_CREATE_PROJECT_ACTION));
}
+ @Override
public void run() {
INewWizard wizard = ExtensionPointUtils.findNewWizardsItem(
SeamGuiPlugin.PLUGIN_ID, SEAM_CREATE_PROJECT_WIZARD_ID);
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/internal/project/facet/IValidator.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/internal/project/facet/IValidator.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/internal/project/facet/IValidator.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -12,8 +12,6 @@
import java.util.Map;
-import org.eclipse.core.runtime.IAdaptable;
-
/**
* Simple validator interface
* @author eskimo
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/internal/project/facet/SeamInstallWizardPage.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/internal/project/facet/SeamInstallWizardPage.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/internal/project/facet/SeamInstallWizardPage.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -346,7 +346,7 @@
validatorDelegate = new DataModelValidatorDelegate(this.model, this);
validatorDelegate.addValidatorForProperty(jBossSeamHomeEditor
.getName(),
- ValidatorFactory.JBOSS_SEAM_HOME_IS_NOT_SELECTED);
+ ValidatorFactory.SEAM_RUNTIME_NAME_VALIDATOR);
validatorDelegate.addValidatorForProperty(connProfileSelEditor
.getName(),
ValidatorFactory.CONNECTION_PROFILE_VALIDATOR);
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/internal/project/facet/ValidatorFactory.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/internal/project/facet/ValidatorFactory.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/internal/project/facet/ValidatorFactory.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -11,23 +11,15 @@
package org.jboss.tools.seam.ui.internal.project.facet;
import java.io.File;
-import java.io.IOException;
-import java.io.InputStream;
-import java.text.MessageFormat;
import java.util.Collections;
import java.util.HashMap;
import java.util.Map;
import java.util.Properties;
-import java.util.zip.ZipEntry;
-import java.util.zip.ZipException;
-import java.util.zip.ZipFile;
-
import org.eclipse.core.resources.IProject;
import org.eclipse.core.resources.IResource;
import org.eclipse.core.resources.ResourcesPlugin;
import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Path;
import org.eclipse.datatools.connectivity.IConnectionProfile;
import org.eclipse.datatools.connectivity.ProfileManager;
import org.eclipse.jdt.core.IJavaProject;
@@ -38,15 +30,15 @@
import org.eclipse.jdt.core.dom.ASTParser;
import org.eclipse.jdt.core.dom.CompilationUnit;
import org.eclipse.jdt.internal.corext.util.Messages;
-import org.eclipse.ui.wizards.datatransfer.ZipFileStructureProvider;
import org.eclipse.wst.common.project.facet.core.IFacetedProject;
import org.eclipse.wst.common.project.facet.core.ProjectFacetsManager;
import org.jboss.tools.seam.core.ISeamProject;
import org.jboss.tools.seam.core.SeamCorePlugin;
+import org.jboss.tools.seam.core.project.facet.SeamRuntime;
+import org.jboss.tools.seam.core.project.facet.SeamRuntimeManager;
import org.jboss.tools.seam.internal.core.SeamProject;
import org.jboss.tools.seam.internal.core.project.facet.ISeamFacetDataModelProperties;
import org.jboss.tools.seam.ui.SeamUIMessages;
-import org.jboss.tools.seam.ui.wizard.IParameter;
/**
*
@@ -217,6 +209,7 @@
return ValidatorFactory.NO_ERRORS;
};
};
+
/**
*
* @author eskimo
@@ -225,12 +218,14 @@
public static IValidator SEAM_COMPONENT_NAME_VALIDATOR = new IValidator() {
public Map<String, String> validate(Object value, Object context) {
- IStatus status = JavaConventions.validateClassFileName(value.toString()+".class", "5.0", "5.0"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
- if (!status.isOK()) {
- return createErrormessage(SeamUIMessages.VALIDATOR_FACTORY_NAME_IS_NOT_VALID);
+ IStatus status = JavaConventions.validateClassFileName(
+ value.toString()+".class", "5.0", "5.0"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ if (status.isOK()) {
+ return NO_ERRORS;
+ } else {
+ return createErrormessage(
+ SeamUIMessages.VALIDATOR_FACTORY_NAME_IS_NOT_VALID);
}
-
- return NO_ERRORS;
}
};
@@ -242,13 +237,14 @@
public static IValidator SEAM_JAVA_INTEFACE_NAME_CONVENTION_VALIDATOR = new IValidator() {
public Map<String, String> validate(Object value, Object context) {
- String targetName = null;
- IProject project = null;
- if (context instanceof Object[]) {
- Object[] contextArray = ((Object[]) context);
- targetName = contextArray[0].toString();
- project = (IProject) contextArray[1];
+ if(!(context instanceof Object[])) {
+ throw new IllegalArgumentException(
+ "Context parameter should be instance of Object[]");
}
+
+ Object[] contextArray = ((Object[]) context);
+ IProject project = (IProject) contextArray[1];
+
IJavaProject jProject = JavaCore.create(project);
String sourceLevel = jProject.getOption(JavaCore.COMPILER_SOURCE,
@@ -268,15 +264,15 @@
public static IValidator SEAM_METHOD_NAME_VALIDATOR = new IValidator() {
public Map<String, String> validate(Object value, Object context) {
- String targetName = null;
- IProject project = null;
-
- if (context instanceof Object[]) {
- Object[] contextArray = ((Object[]) context);
- targetName = contextArray[0].toString();
- project = (IProject) contextArray[1];
+ if(!(context instanceof Object[])) {
+ throw new IllegalArgumentException(
+ "Context parameter should be instance of Object[]");
}
+ Object[] contextArray = ((Object[]) context);
+ String targetName = contextArray[0].toString();
+ IProject project = (IProject) contextArray[1];
+
CompilationUnit compilationUnit = createCompilationUnit(
"class ClassName {public void " //$NON-NLS-1$
+ value.toString() + "() {}}",project); //$NON-NLS-1$
@@ -294,14 +290,15 @@
public static IValidator FILE_NAME_VALIDATOR = new IValidator() {
public Map<String, String> validate(Object value, Object context) {
- String targetName = null;
- IProject project = null;
+ if(!(context instanceof Object[])) {
+ throw new IllegalArgumentException(
+ "Context parameter should be instance of Object[]");
+ }
- if (context instanceof Object[]) {
- Object[] contextArray = ((Object[]) context);
- targetName = contextArray[0].toString();
- project = (IProject) contextArray[1];
- }
+ Object[] contextArray = ((Object[]) context);
+ String targetName = contextArray[0].toString();
+ IProject project = (IProject) contextArray[1];
+
if ("".equals(value) //$NON-NLS-1$
|| !project.getLocation().isValidSegment(value.toString()))
return createErrormessage(targetName + SeamUIMessages.VALIDATOR_FACTORY_NAME_IS_NOT_VALID2);
@@ -319,11 +316,11 @@
if (project == null || !(project instanceof IProject)
|| !project.exists()) {
return createErrormessage(
- SeamUIMessages.VALIDATOR_FACTORY_PROJECT + value + SeamUIMessages.VALIDATOR_FACTORY_DOES_NOT_EXIST);
+ SeamUIMessages.VALIDATOR_FACTORY_PROJECT + value + SeamUIMessages.VALIDATOR_FACTORY_DOES_NOT_EXIST);
} else {
IProject selection = (IProject)project;
try {
- if (!selection.hasNature(SeamProject.NATURE_ID)
+ if (!selection.hasNature(ISeamProject.NATURE_ID)
|| SeamCorePlugin.getSeamPreferences(selection)==null
|| selection.getAdapter(IFacetedProject.class)==null
|| !((IFacetedProject)selection.getAdapter(IFacetedProject.class)).hasProjectFacet(ProjectFacetsManager.getProjectFacet("jst.web"))) { //$NON-NLS-1$
@@ -363,7 +360,7 @@
}
};
- public static IValidator JBOSS_SEAM_HOME_IS_NOT_SELECTED = new IValidator() {
+ public static IValidator SEAM_RUNTIME_NAME_VALIDATOR = new IValidator() {
public Map<String, String> validate(Object value, Object context) {
if (value == null || "".equals(value.toString().trim())) { //$NON-NLS-1$
return createErrormessage(
@@ -374,6 +371,41 @@
}
};
+ public static IValidator SEAM_RUNTIME_VALIDATOR = new IValidator() {
+ public java.util.Map<String, String> validate(Object value,
+ Object context) {
+ Map<String,String> errors = NO_ERRORS;
+ String rtName = value.toString();
+
+ if(value==null || "".equals(value)) {
+ errors = createErrormessage("Seam Runtime is not configured for selected Seam Web Project");
+ } else {
+ SeamRuntime rt = SeamRuntimeManager.getInstance()
+ .findRuntimeByName(value.toString());
+ if (rt == null) {
+ errors = createErrormessage("Cannot find '" + value
+ + "' Seam Runtime for selected Seam Web Project");
+ } else if (!new File(rt.getHomeDir()).exists()) {
+ errors = createErrormessage(
+ "Seam Runtime '" + value + "' home directory doesn't exist for selected Seam Web Project");
+ } else if (!new File(rt.getSeamGenDir()).exists()) {
+ errors = createErrormessage(
+ "Seam Runtime '" + value + "' templates directory doesn't exist for selected Seam Web Project");
+ } else if (!new File(rt.getSrcTemplatesDir()).exists()) {
+ errors = createErrormessage(
+ "Seam Runtime '" + value + "' source templates directory doesn't exist for selected Seam Web Project");
+ } else if (!new File(rt.getViewTemplatesDir()).exists()) {
+ errors = createErrormessage(
+ "Seam Runtime '" + value + "' view templates directory doesn't exist for selected Seam Web Project");
+ } else if(!new File(rt.getResourceTemplatesDir()).exists()) {
+ errors = createErrormessage(
+ "Seam Runtime '" + value + "' resources templates directory doesn't exist for selected Seam Web Project");
+ }
+ }
+ return errors;
+ }
+ };
+
public static CompilationUnit createCompilationUnit(String classDecl,
IProject project) {
ASTParser parser = ASTParser.newParser(AST.JLS3);
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/preferences/SeamPreferencePage.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/preferences/SeamPreferencePage.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/preferences/SeamPreferencePage.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -15,9 +15,6 @@
import java.beans.PropertyChangeListener;
import java.util.ArrayList;
import java.util.Arrays;
-import java.util.Map;
-
-import org.eclipse.jface.dialogs.IMessageProvider;
import org.eclipse.jface.preference.PreferencePage;
import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.swt.SWT;
@@ -26,14 +23,9 @@
import org.eclipse.swt.widgets.Control;
import org.eclipse.ui.IWorkbench;
import org.eclipse.ui.IWorkbenchPreferencePage;
-import org.jboss.tools.seam.core.SeamCorePlugin;
-import org.jboss.tools.seam.core.project.facet.SeamFacetPreference;
import org.jboss.tools.seam.core.project.facet.SeamRuntime;
import org.jboss.tools.seam.core.project.facet.SeamRuntimeManager;
-import org.jboss.tools.seam.ui.internal.project.facet.ValidatorFactory;
-import org.jboss.tools.seam.ui.widget.editor.IFieldEditor;
import org.jboss.tools.seam.ui.widget.editor.SeamRuntimeListFieldEditor;
-import org.jboss.tools.seam.ui.widget.editor.SwtFieldEditorFactory;
/**
* @author eskimo
@@ -74,6 +66,7 @@
/**
*
*/
+ @Override
protected Control createContents(Composite parent) {
Composite root = new Composite(parent, SWT.NONE);
GridLayout gl = new GridLayout(3,false);
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/preferences/SeamSettingsPreferencePage.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/preferences/SeamSettingsPreferencePage.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/preferences/SeamSettingsPreferencePage.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -37,6 +37,7 @@
import org.jboss.tools.seam.ui.widget.editor.ButtonFieldEditor;
import org.jboss.tools.seam.ui.widget.editor.CompositeEditor;
import org.jboss.tools.seam.ui.widget.editor.IFieldEditor;
+import org.jboss.tools.seam.ui.widget.editor.IFieldEditorFactory;
import org.jboss.tools.seam.ui.widget.editor.ITaggedFieldEditor;
import org.jboss.tools.seam.ui.widget.editor.SwtFieldEditorFactory;
import org.jboss.tools.seam.ui.widget.editor.SeamRuntimeListFieldEditor.SeamRuntimeNewWizard;
@@ -53,6 +54,7 @@
public SeamSettingsPreferencePage() {
}
+ @Override
public void setElement(IAdaptable element) {
super.setElement(element);
project = (IProject) getElement().getAdapter(IProject.class);
@@ -63,13 +65,13 @@
ISeamProject seamProject = SeamCorePlugin
.getSeamProject(project, false);
boolean hasSeamSupport = seamProject != null;
- seamEnablement = SwtFieldEditorFactory.INSTANCE.createCheckboxEditor(
+ seamEnablement = IFieldEditorFactory.INSTANCE.createCheckboxEditor(
SeamPreferencesMessages.SEAM_SETTINGS_PREFERENCE_PAGE_SEAM_SUPPORT, SeamPreferencesMessages.SEAM_SETTINGS_PREFERENCE_PAGE_SEAM_SUPPORT, false);
seamEnablement.setValue(hasSeamSupport);
SeamRuntime rs = SeamRuntimeManager.getInstance().getDefaultRuntime();
- runtime = SwtFieldEditorFactory.INSTANCE.createComboWithButton(SeamPreferencesMessages.SEAM_SETTINGS_PREFERENCE_PAGE_RUNTIME,
+ runtime = IFieldEditorFactory.INSTANCE.createComboWithButton(SeamPreferencesMessages.SEAM_SETTINGS_PREFERENCE_PAGE_RUNTIME,
SeamPreferencesMessages.SEAM_SETTINGS_PREFERENCE_PAGE_RUNTIME, SeamRuntimeManager.getInstance().getRuntimeNames(),
rs==null?"":rs.getName(),true,new NewSeamRuntimeAction(),(IValidator)null); //$NON-NLS-1$
@@ -124,6 +126,7 @@
return composite;
}
+ @Override
public boolean performOk() {
if (getSeamSupport()) {
addSeamSupport();
@@ -200,10 +203,11 @@
super(SeamPreferencesMessages.SEAM_SETTINGS_PREFERENCE_PAGE_ADD);
}
+ @Override
public void run() {
List<SeamRuntime> added = new ArrayList<SeamRuntime>();
Wizard wiz = new SeamRuntimeNewWizard(
- (List<SeamRuntime>) new ArrayList<SeamRuntime>(Arrays
+ new ArrayList<SeamRuntime>(Arrays
.asList(SeamRuntimeManager.getInstance()
.getRuntimes())), added);
WizardDialog dialog = new WizardDialog(Display.getCurrent()
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/preferences/SeamValidatorPreferencePage.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/preferences/SeamValidatorPreferencePage.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/preferences/SeamValidatorPreferencePage.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -52,6 +52,7 @@
return fConfigurationBlock.hasProjectSpecificOptions(project);
}
+ @Override
public void createControl(Composite parent) {
IWorkbenchPreferenceContainer container = (IWorkbenchPreferenceContainer) getContainer();
fConfigurationBlock = new SeamValidatorConfigurationBlock(getNewStatusChangedListener(), getProject(), container);
@@ -67,6 +68,7 @@
/*
* @see org.eclipse.jface.dialogs.DialogPage#dispose()
*/
+ @Override
public void dispose() {
if (fConfigurationBlock != null) {
fConfigurationBlock.dispose();
@@ -77,6 +79,7 @@
/*
* @see org.eclipse.jdt.internal.ui.preferences.PropertyAndPreferencePage#enableProjectSpecificSettings(boolean)
*/
+ @Override
protected void enableProjectSpecificSettings(boolean useProjectSpecificSettings) {
super.enableProjectSpecificSettings(useProjectSpecificSettings);
if (fConfigurationBlock != null) {
@@ -87,6 +90,7 @@
/*
* @see org.eclipse.jface.preference.IPreferencePage#performDefaults()
*/
+ @Override
protected void performDefaults() {
super.performDefaults();
if (fConfigurationBlock != null) {
@@ -97,6 +101,7 @@
/*
* @see org.eclipse.jface.preference.IPreferencePage#performOk()
*/
+ @Override
public boolean performOk() {
if (fConfigurationBlock != null && !fConfigurationBlock.performOk()) {
return false;
@@ -107,6 +112,7 @@
/*
* @see org.eclipse.jface.preference.IPreferencePage#performApply()
*/
+ @Override
public void performApply() {
if (fConfigurationBlock != null) {
fConfigurationBlock.performApply();
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/text/java/SeamELProposalProcessor.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/text/java/SeamELProposalProcessor.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/text/java/SeamELProposalProcessor.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -254,7 +254,7 @@
if (result == null || result.size() == 0)
return NO_PROPOSALS;
- ICompletionProposal[] resultArray = (ICompletionProposal[]) result.toArray(new ICompletionProposal[result.size()]);
+ ICompletionProposal[] resultArray = result.toArray(new ICompletionProposal[result.size()]);
Arrays.sort(resultArray, new Comparator<ICompletionProposal>() {
public int compare(ICompletionProposal arg0,
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/AbstractSeamContentProvider.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/AbstractSeamContentProvider.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/AbstractSeamContentProvider.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -47,7 +47,6 @@
import org.jboss.tools.seam.core.event.SeamProjectChangeEvent;
import org.jboss.tools.seam.ui.SeamGuiPlugin;
import org.jboss.tools.seam.ui.SeamUIMessages;
-import org.jboss.tools.seam.ui.views.actions.ScopePresentationActionProvider;
/**
* Basic type for content providers that add seam components
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/RootContentProvider.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/RootContentProvider.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/RootContentProvider.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -75,6 +75,7 @@
}
}
+ @Override
public void dispose() {
super.dispose();
root = null;
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/SeamLabelProvider.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/SeamLabelProvider.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/SeamLabelProvider.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -15,8 +15,6 @@
import org.eclipse.core.resources.IWorkspaceRoot;
import org.eclipse.jdt.core.IMember;
import org.eclipse.jdt.core.IType;
-import org.eclipse.jdt.internal.ui.navigator.IExtensionStateConstants.Values;
-import org.eclipse.jdt.internal.ui.packageview.PackageExplorerContentProvider;
import org.eclipse.jdt.internal.ui.viewsupport.JavaElementImageProvider;
import org.eclipse.jface.util.IPropertyChangeListener;
import org.eclipse.jface.util.PropertyChangeEvent;
@@ -38,7 +36,6 @@
import org.jboss.tools.seam.core.ISeamProject;
import org.jboss.tools.seam.core.ISeamScope;
import org.jboss.tools.seam.ui.SeamUiImages;
-import org.jboss.tools.seam.ui.views.actions.ScopePresentationActionProvider;
/**
* @author Viacheslav Kabanovich
@@ -92,6 +89,7 @@
isScopeLable = b;
}
+ @Override
public String getText(Object element) {
if(element instanceof IWorkspaceRoot) {
return ""; //$NON-NLS-1$
@@ -139,6 +137,7 @@
return element == null ? "" : element.toString();//$NON-NLS-1$
}
+ @Override
public Image getImage(Object obj) {
if (obj instanceof ISeamProject) {
return SeamUiImages.PROJECT_IMAGE;
@@ -179,6 +178,7 @@
return ""; //$NON-NLS-1$
}
+ @Override
public void dispose() {
super.dispose();
fStateModel.removePropertyChangeListener(layoutPropertyListener);
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/actions/ScopePresentationActionProvider.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/actions/ScopePresentationActionProvider.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/actions/ScopePresentationActionProvider.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -80,6 +80,7 @@
public ScopePresentationActionProvider() {}
+ @Override
public void init(ICommonActionExtensionSite site) {
super.init(site);
fExtensionSite = site;
@@ -101,12 +102,14 @@
p.put(SCOPE_PRESENTATION, s ? SCOPE_AS_LABEL : SCOPE_AS_NODE);
}
- public void fillActionBars(IActionBars actionBars) {
+ @Override
+ public void fillActionBars(IActionBars actionBars) {
fActionBars = actionBars;
actionGroup.fillActionBars(actionBars);
}
- public void dispose() {
+ @Override
+ public void dispose() {
super.dispose();
fExtensionSite.getContentService().getActivationService().removeExtensionActivationListener(fMenuUpdater);
}
@@ -127,6 +130,7 @@
);
}
+ @Override
public void restoreState(IMemento memento) {
boolean isCurrentLayoutFlat = true;
String state = null;
@@ -156,6 +160,7 @@
}
+ @Override
public void saveState(IMemento aMemento) {
super.saveState(aMemento);
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/actions/SeamActionProvider.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/actions/SeamActionProvider.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/actions/SeamActionProvider.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -28,7 +28,8 @@
public SeamActionProvider() {}
- public void fillContextMenu(IMenuManager menu) {
+ @Override
+ public void fillContextMenu(IMenuManager menu) {
ActionContext c = getContext();
ISelection s = c.getSelection();
if(s == null || s.isEmpty() || !(s instanceof IStructuredSelection)) return;
@@ -44,7 +45,8 @@
}
}
- public void fillActionBars(IActionBars actionBars) {
+ @Override
+ public void fillActionBars(IActionBars actionBars) {
ActionContext c = getContext();
ISelection s = c.getSelection();
if(s == null || s.isEmpty() || !(s instanceof IStructuredSelection)) return;
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/actions/SeamOpenAction.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/actions/SeamOpenAction.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/actions/SeamOpenAction.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -25,6 +25,7 @@
this.element = element;
}
+ @Override
public void run() {
if(element != null) {
element.open();
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/actions/SeamViewLayoutActionGroup.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/actions/SeamViewLayoutActionGroup.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/actions/SeamViewLayoutActionGroup.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -70,6 +70,7 @@
this.setId(id);
}
+ @Override
public void run() {
if (stateModel.getBooleanProperty(property) != value) {
stateModel.setBooleanProperty(property, value);
@@ -83,6 +84,7 @@
}
}
+ @Override
public void fillActionBars(IActionBars actionBars) {
if (!hasContributedToViewMenu) {
@@ -155,6 +157,7 @@
protected void addLayoutActions(IMenuManager viewMenu) {
viewMenu.add(new SeamContributionItem(flatLayoutAction) {
+ @Override
public void fill(Menu menu, int index) {
int style = SWT.RADIO;
MenuItem mi = new MenuItem(menu, style, index);
@@ -162,6 +165,7 @@
mi.setText(SeamUIMessages.SEAM_VIEW_LAYOUT_ACTION_GROUP_FLAT);
mi.setSelection(isFlatLayout);
mi.addSelectionListener(new SelectionAdapter() {
+ @Override
public void widgetSelected(SelectionEvent e) {
if (isFlatLayout) {
flatLayoutItem.setSelection(true);
@@ -176,12 +180,14 @@
}
});
}
+ @Override
public boolean isDynamic() {
return false;
}
});
viewMenu.add(new SeamContributionItem(hierarchicalLayoutAction) {
+ @Override
public void fill(Menu menu, int index) {
int style = SWT.RADIO;
MenuItem mi = new MenuItem(menu, style, index);
@@ -189,6 +195,7 @@
mi.setText(SeamUIMessages.SEAM_VIEW_LAYOUT_ACTION_GROUP_HIERARCHICAL);
mi.setSelection(!isFlatLayout);
mi.addSelectionListener(new SelectionAdapter() {
+ @Override
public void widgetSelected(SelectionEvent e) {
if (!isFlatLayout) {
hierarchicalLayoutItem.setSelection(true);
@@ -203,6 +210,7 @@
}
});
}
+ @Override
public boolean isDynamic() {
return false;
}
@@ -212,6 +220,7 @@
protected void addScopeActions(IMenuManager viewMenu) {
viewMenu.add(new SeamContributionItem(labelScopeAction) {
+ @Override
public void fill(Menu menu, int index) {
int style = SWT.RADIO;
MenuItem mi = new MenuItem(menu, style, index);
@@ -219,6 +228,7 @@
mi.setText(SeamUIMessages.SEAM_VIEW_LAYOUT_ACTION_GROUP_LABEL);
mi.setSelection(isScopeLable);
mi.addSelectionListener(new SelectionAdapter() {
+ @Override
public void widgetSelected(SelectionEvent e) {
if (isScopeLable) {
labelScopeItem.setSelection(true);
@@ -233,12 +243,14 @@
}
});
}
+ @Override
public boolean isDynamic() {
return false;
}
});
viewMenu.add(new SeamContributionItem(nodeScopeAction) {
+ @Override
public void fill(Menu menu, int index) {
int style = SWT.RADIO;
MenuItem mi = new MenuItem(menu, style, index);
@@ -246,6 +258,7 @@
mi.setText(SeamUIMessages.SEAM_VIEW_LAYOUT_ACTION_GROUP_NODE);
mi.setSelection(!isScopeLable);
mi.addSelectionListener(new SelectionAdapter() {
+ @Override
public void widgetSelected(SelectionEvent e) {
if (!isScopeLable) {
nodeScopeItem.setSelection(true);
@@ -260,6 +273,7 @@
}
});
}
+ @Override
public boolean isDynamic() {
return false;
}
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/properties/SeamComponentProperties.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/properties/SeamComponentProperties.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/properties/SeamComponentProperties.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -54,11 +54,13 @@
this.element = element;
}
+ @Override
public IPropertyDescriptor[] getPropertyDescriptors() {
if(element != null && element.isEntity()) return ENTITY_DESCRIPTORS;
return DESCRIPTORS;
}
+ @Override
public Object getPropertyValue(Object id) {
if(NAME.equals(id)) {
return element.getName();
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/BaseFieldEditor.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/BaseFieldEditor.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/BaseFieldEditor.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -10,13 +10,11 @@
******************************************************************************/
package org.jboss.tools.seam.ui.widget.editor;
-import java.beans.PropertyChangeEvent;
import java.beans.PropertyChangeListener;
import java.beans.PropertyChangeSupport;
import org.eclipse.core.runtime.Assert;
import org.eclipse.swt.SWT;
-import org.eclipse.swt.layout.GridData;
import org.eclipse.swt.layout.GridLayout;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Control;
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/ButtonFieldEditor.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/ButtonFieldEditor.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/ButtonFieldEditor.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -10,16 +10,11 @@
******************************************************************************/
package org.jboss.tools.seam.ui.widget.editor;
-import java.beans.PropertyChangeListener;
-
import org.eclipse.jface.action.Action;
-import org.eclipse.swt.SWT;
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.events.SelectionListener;
-import org.eclipse.swt.widgets.Button;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Event;
import org.jboss.tools.seam.ui.SeamUIMessages;
import org.jboss.tools.seam.ui.widget.field.PushButtonField;
@@ -57,6 +52,7 @@
return null;
}
+ @Override
public boolean isEditable() {
return false;
}
@@ -64,9 +60,11 @@
public void save(Object object) {
}
+ @Override
public void setEditable(boolean ediatble) {
}
+ @Override
public Object[] getEditorControls(Object composite) {
if(button==null && composite!=null) {
button = new PushButtonField((Composite)composite,buttonAction);
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/CheckBoxFieldEditor.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/CheckBoxFieldEditor.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/CheckBoxFieldEditor.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -15,7 +15,6 @@
import java.beans.PropertyChangeListener;
import org.eclipse.core.runtime.Assert;
-import org.eclipse.swt.layout.GridData;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Control;
import org.jboss.tools.seam.ui.widget.field.CheckBoxField;
@@ -76,6 +75,7 @@
/* (non-Javadoc)
* @see org.jboss.tools.seam.ui.internal.project.facet.IFieldEditor#isEditable()
*/
+ @Override
public boolean isEditable() {
// TODO Auto-generated method stub
return false;
@@ -92,6 +92,7 @@
/* (non-Javadoc)
* @see org.jboss.tools.seam.ui.internal.project.facet.IFieldEditor#setEditable(boolean)
*/
+ @Override
public void setEditable(boolean ediatble) {
// TODO Auto-generated method stub
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/CompositeEditor.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/CompositeEditor.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/CompositeEditor.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -17,13 +17,9 @@
import java.util.Collections;
import java.util.List;
-import javax.rmi.CORBA.ValueHandler;
-
import org.eclipse.core.runtime.Assert;
-import org.eclipse.swt.SWT;
import org.eclipse.swt.layout.GridData;
import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Combo;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Control;
import org.jboss.tools.seam.ui.SeamUIMessages;
@@ -66,6 +62,7 @@
}
+ @Override
public Object[] getEditorControls(Object parent) {
for (IFieldEditor editor : editors) {
controls.addAll(Arrays.asList((Control[])editor.getEditorControls(parent)));
@@ -73,10 +70,12 @@
return controls.toArray(new Control[]{});
}
+ @Override
public int getNumberOfControls() {
return editors.size();
}
+ @Override
public boolean isEditable() {
return true;
}
@@ -84,6 +83,7 @@
public void save(Object object) {
}
+ @Override
public void setEditable(boolean ediatble) {
}
@@ -97,6 +97,7 @@
return this;
}
+ @Override
public void setValue(Object newValue) {
for (IFieldEditor editor : editors) {
editor.removePropertyChangeListener(this);
@@ -117,6 +118,7 @@
super.setValue(event.getNewValue());
}
+ @Override
public void setEnabled(boolean set) {
for (IFieldEditor editor : editors) {
editor.setEnabled(set);
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/LabelFieldEditor.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/LabelFieldEditor.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/LabelFieldEditor.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -53,6 +53,7 @@
/* (non-Javadoc)
* @see org.jboss.tools.seam.ui.widget.editor.IFieldEditor#isEditable()
*/
+ @Override
public boolean isEditable() {
// TODO Auto-generated method stub
return false;
@@ -69,11 +70,13 @@
/* (non-Javadoc)
* @see org.jboss.tools.seam.ui.widget.editor.IFieldEditor#setEditable(boolean)
*/
+ @Override
public void setEditable(boolean ediatble) {
// TODO Auto-generated method stub
}
+ @Override
public void setValue(Object value) {
}
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/SeamRuntimeListFieldEditor.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/SeamRuntimeListFieldEditor.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/SeamRuntimeListFieldEditor.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -49,7 +49,6 @@
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Control;
import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Shell;
import org.eclipse.swt.widgets.TableColumn;
import org.eclipse.ui.wizards.datatransfer.ZipFileStructureProvider;
import org.jboss.tools.seam.core.SeamCorePlugin;
@@ -131,7 +130,7 @@
gd.grabExcessHorizontalSpace = true;
root.setLayoutData(gd);
- tableView = CheckboxTableViewer.newCheckList((Composite) root,
+ tableView = CheckboxTableViewer.newCheckList(root,
SWT.V_SCROLL|SWT.BORDER|SWT.FULL_SELECTION|SWT.SINGLE);
gd = new GridData();
@@ -278,6 +277,7 @@
*
* @param parent
*/
+ @Override
public void doFillIntoGrid(Object parent) {
Assert.isTrue(parent instanceof Composite,
SeamUIMessages.SEAM_RUNTIME_LIST_FIELD_EDITOR_PARENT_CONTROL_SHOULD_BE_COMPOSITE);
@@ -299,18 +299,18 @@
List<SeamRuntime> value = null;
- IFieldEditor name = SwtFieldEditorFactory.INSTANCE.createTextEditor(
+ IFieldEditor name = IFieldEditorFactory.INSTANCE.createTextEditor(
"name", SeamUIMessages.SEAM_RUNTIME_LIST_FIELD_EDITOR_NAME2, ""); //$NON-NLS-1$ //$NON-NLS-2$
- IFieldEditor version = SwtFieldEditorFactory.INSTANCE.createComboEditor(
+ IFieldEditor version = IFieldEditorFactory.INSTANCE.createComboEditor(
"version", SeamUIMessages.SEAM_RUNTIME_LIST_FIELD_EDITOR_VERSION2, Arrays.asList( //$NON-NLS-1$
new Object[]{SeamVersion.SEAM_1_2.toString()}),
SeamVersion.SEAM_1_2.toString(), false);
- IFieldEditor homeDir = SwtFieldEditorFactory.INSTANCE.createBrowseFolderEditor(
+ IFieldEditor homeDir = IFieldEditorFactory.INSTANCE.createBrowseFolderEditor(
"homeDir", SeamUIMessages.SEAM_RUNTIME_LIST_FIELD_EDITOR_HOME_FOLDER, ""); //$NON-NLS-1$ //$NON-NLS-2$
- IFieldEditor dflt = SwtFieldEditorFactory.INSTANCE.createCheckboxEditor(
+ IFieldEditor dflt = IFieldEditorFactory.INSTANCE.createCheckboxEditor(
"default", SeamUIMessages.SEAM_RUNTIME_LIST_FIELD_EDITOR_USE_AS_DEFAULT, false); //$NON-NLS-1$
/**
@@ -457,6 +457,7 @@
this.added = added;
}
+ @Override
public boolean performFinish() {
SeamRuntime rt = page1.getRuntime();
added.add(rt);
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/SwtFieldEditorFactory.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/SwtFieldEditorFactory.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/SwtFieldEditorFactory.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -12,22 +12,13 @@
import java.util.List;
-import org.eclipse.datatools.connectivity.ConnectionProfileException;
-import org.eclipse.datatools.connectivity.ProfileManager;
-import org.eclipse.datatools.connectivity.db.generic.IDBConnectionProfileConstants;
-import org.eclipse.datatools.connectivity.db.generic.ui.NewConnectionProfileWizard;
import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.jface.wizard.Wizard;
-import org.eclipse.jface.wizard.WizardDialog;
import org.eclipse.swt.widgets.DirectoryDialog;
import org.eclipse.swt.widgets.Display;
import org.eclipse.swt.widgets.FileDialog;
-import org.jboss.tools.seam.core.SeamCorePlugin;
-import org.jboss.tools.seam.core.project.facet.SeamRuntime;
import org.jboss.tools.seam.ui.SeamUIMessages;
import org.jboss.tools.seam.ui.internal.project.facet.IValidator;
import org.jboss.tools.seam.ui.widget.editor.ButtonFieldEditor.ButtonPressedAction;
-import org.jboss.tools.seam.ui.widget.editor.SeamRuntimeListFieldEditor.SeamRuntimeNewWizard;
/**
*
@@ -57,7 +48,7 @@
*/
public ITaggedFieldEditor createComboEditor(String name, String label,
List values, Object defaultValue) {
- TaggedComboFieldEditor editor = new TaggedComboFieldEditor(name,label,values, defaultValue,true);
+ TaggedComboFieldEditor editor = new TaggedComboFieldEditor(name,label,values, defaultValue,false);
return editor;
}
@@ -65,8 +56,8 @@
*
*/
public ITaggedFieldEditor createComboEditor(String name, String label,
- List values, Object defaultValue, boolean flat) {
- TaggedComboFieldEditor editor = new TaggedComboFieldEditor(name,label,values, defaultValue,flat);
+ List values, Object defaultValue, boolean editable) {
+ TaggedComboFieldEditor editor = new TaggedComboFieldEditor(name,label,values, defaultValue,editable);
return editor;
}
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/TextFieldEditor.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/TextFieldEditor.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/editor/TextFieldEditor.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -17,10 +17,6 @@
import org.eclipse.core.runtime.Assert;
import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.DisposeEvent;
-import org.eclipse.swt.events.DisposeListener;
-import org.eclipse.swt.graphics.GC;
-import org.eclipse.swt.graphics.Point;
import org.eclipse.swt.layout.GridData;
import org.eclipse.swt.layout.GridLayout;
import org.eclipse.swt.widgets.Composite;
@@ -78,6 +74,7 @@
/**
*
*/
+ @Override
public Object[] getEditorControls() {
return new Control[] {getTextControl()};
}
@@ -86,6 +83,7 @@
/**
* @see com.kabira.ide.ex.workbench.ui.feature.IFeatureFieldEditor#doFillIntoGrid(java.lang.Object)
*/
+ @Override
public void doFillIntoGrid(Object aParent) {
Assert.isTrue(aParent instanceof Composite, SeamUIMessages.TEXT_FIELD_EDITOR_PARENT_CONTROL_SHOULD_BE_COMPOSITE);
Assert.isTrue(((Composite)aParent).getLayout() instanceof GridLayout,SeamUIMessages.TEXT_FIELD_EDITOR_EDITOR_SUPPORTS_ONLY_GRID_LAYOUT);
@@ -176,6 +174,7 @@
/**
*
*/
+ @Override
public int getNumberOfControls() {
return 2;
}
@@ -193,7 +192,8 @@
/**
* @see com.kabira.ide.ex.workbench.ui.feature.eitors.BaseFeatureFieldEditor#setFocus()
*/
- public boolean setFocus() {
+ @Override
+ public boolean setFocus() {
boolean setfocus = false;
if(fTextField!=null && !fTextField.getTextControl().isDisposed())
setfocus = fTextField.getTextControl().setFocus();
@@ -218,6 +218,7 @@
/**
*
*/
+ @Override
public void setValue(Object newValue) {
super.setValue(newValue);
if(fTextField!=null){
@@ -230,6 +231,7 @@
/**
*
*/
+ @Override
public void setEditable(boolean aEditable) {
super.setEditable(aEditable);
if(getTextControl()!=null) getTextControl().setEditable(aEditable);
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/field/TextField.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/field/TextField.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/widget/field/TextField.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -10,15 +10,11 @@
******************************************************************************/
package org.jboss.tools.seam.ui.widget.field;
-import java.beans.PropertyChangeListener;
-import java.beans.PropertyChangeSupport;
-
import org.eclipse.swt.events.ModifyEvent;
import org.eclipse.swt.events.ModifyListener;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Control;
import org.eclipse.swt.widgets.Text;
-import org.eclipse.swt.widgets.Widget;
public class TextField extends BaseField implements ModifyListener{
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/CreateSeamWebProjectAction.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/CreateSeamWebProjectAction.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/CreateSeamWebProjectAction.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -30,6 +30,7 @@
ModelUIImages.setImageDescriptors(this, ModelUIImages.ACT_CREATE_PROJECT);
}
+ @Override
public void run() {
INewWizard wizard = ExtensionPointUtils.findNewWizardsItem(
SeamGuiPlugin.PLUGIN_ID,
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/IParameter.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/IParameter.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/IParameter.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -11,8 +11,6 @@
package org.jboss.tools.seam.ui.wizard;
-import org.jboss.tools.seam.ui.SeamUIMessages;
-
/**
* @author eskimo
*
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamActionWizardPage1.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamActionWizardPage1.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamActionWizardPage1.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -10,10 +10,7 @@
******************************************************************************/
package org.jboss.tools.seam.ui.wizard;
-import java.beans.PropertyChangeEvent;
-
import org.jboss.tools.seam.ui.SeamUIMessages;
-import org.jboss.tools.seam.ui.widget.editor.IFieldEditor;
/**
* @author eskimo
@@ -28,11 +25,20 @@
*/
public SeamActionWizardPage1() {
super("seam.new.action.page1", SeamUIMessages.SEAM_ACTION_WIZARD_PAGE1_SEAM_ACTION, null); //$NON-NLS-1$
- setMessage(SeamUIMessages.SEAM_ACTION_WIZARD_PAGE1_SELECT_THE_NAME_OF_THE_SEAM_CONVERSATION +
- SeamUIMessages.SEAM_ACTION_WIZARD_PAGE1_WITH_KEY_SEAM_EJB_ANNOTATIONS_WILL_BE_CREATED);
+ setMessage(getDefaultMessageText());
}
+ @Override
protected void createEditors() {
addEditors(SeamWizardFactory.createBaseFormFieldEditors(SeamWizardUtils.getSelectedProjectName()));
}
+
+ /* (non-Javadoc)
+ * @see org.jboss.tools.seam.ui.wizard.SeamBaseWizardPage#getDefaultMessageText()
+ */
+ @Override
+ public String getDefaultMessageText() {
+ // TODO Auto-generated method stub
+ return "Create a new Seam action";
+ }
}
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamBaseWizardPage.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamBaseWizardPage.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamBaseWizardPage.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -21,17 +21,14 @@
import org.eclipse.core.resources.IProject;
import org.eclipse.core.resources.IResource;
import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.IAdaptable;
import org.eclipse.jface.dialogs.IMessageProvider;
import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.wizard.Wizard;
import org.eclipse.jface.wizard.WizardPage;
import org.eclipse.osgi.util.NLS;
import org.eclipse.swt.SWT;
import org.eclipse.swt.layout.GridLayout;
import org.eclipse.swt.widgets.Composite;
-import org.jboss.tools.seam.core.ISeamProject;
import org.jboss.tools.seam.core.SeamCorePlugin;
import org.jboss.tools.seam.internal.core.project.facet.ISeamFacetDataModelProperties;
import org.jboss.tools.seam.ui.SeamUIMessages;
@@ -80,7 +77,7 @@
*/
public void createControl(Composite parent) {
setControl(new GridLayoutComposite(parent));
-
+
if (!"".equals(editorRegistry.get(IParameter.SEAM_PROJECT_NAME).getValue())){ //$NON-NLS-1$
Map errors = ValidatorFactory.SEAM_PROJECT_NAME_VALIDATOR.validate(
getEditor(IParameter.SEAM_PROJECT_NAME).getValue(), null);
@@ -200,12 +197,11 @@
return;
}
- IResource project = getSelectedProject();
+ IProject project = getSelectedProject();
+ getEditor(IParameter.SEAM_BEAN_NAME).setEnabled(!isWar());
- String type = SeamCorePlugin.getSeamPreferences(project.getProject()).get(ISeamFacetDataModelProperties.JBOSS_AS_DEPLOY_AS,"war"); //$NON-NLS-1$
+ if(!isValidRuntimeConfigured(project)) return;
- getEditor(IParameter.SEAM_BEAN_NAME).setEnabled(!isWar());
-
LabelFieldEditor label = (LabelFieldEditor)((CompositeEditor)getEditor(IParameter.SEAM_LOCAL_INTERFACE_NAME)).getEditors().get(0);
label.getLabelControl().setText(isWar()?SeamUIMessages.SEAM_BASE_WIZARD_PAGE_POJO_CLASS_NAME: SeamUIMessages.SEAM_BASE_WIZARD_PAGE_LOCAL_CLASS_NAME);
@@ -250,7 +246,7 @@
}
errors = ValidatorFactory.FILE_NAME_VALIDATOR.validate(
- editorRegistry.get(IParameter.SEAM_PAGE_NAME).getValue(), (Object)new Object[]{"Page",project}); //$NON-NLS-1$
+ editorRegistry.get(IParameter.SEAM_PAGE_NAME).getValue(), new Object[]{"Page",project}); //$NON-NLS-1$
if(errors.size()>0) {
setErrorMessage(errors.get(IValidator.DEFAULT_ERROR).toString());
@@ -269,11 +265,26 @@
}
setErrorMessage(null);
- setMessage(null);
+ setMessage(getDefaultMessageText());
setPageComplete(true);
}
/**
+ * @param project
+ */
+ protected boolean isValidRuntimeConfigured(IProject project) {
+ Map errors;
+ String seamRt = SeamCorePlugin.getSeamPreferences(project).get(ISeamFacetDataModelProperties.SEAM_RUNTIME_NAME,"war"); //$NON-NLS-1$
+ errors = ValidatorFactory.SEAM_RUNTIME_VALIDATOR.validate(seamRt, null);
+ if(errors.size()>0) {
+ setErrorMessage(errors.get(IValidator.DEFAULT_ERROR).toString());
+ setPageComplete(false);
+ return false;
+ }
+ return true;
+ }
+
+ /**
*
*/
protected void doFillDefaults(PropertyChangeEvent event) {
@@ -299,10 +310,10 @@
/**
* @return
*/
- public IResource getSelectedProject() {
+ public IProject getSelectedProject() {
IResource project = ResourcesPlugin.getWorkspace().getRoot().findMember(
editorRegistry.get(IParameter.SEAM_PROJECT_NAME).getValueAsString());
- return project;
+ return (IProject)project;
}
public boolean isWar() {
@@ -310,4 +321,6 @@
SeamCorePlugin.getSeamPreferences(getSelectedProject().getProject())==null) return true;
return "war".equals(SeamCorePlugin.getSeamPreferences(getSelectedProject().getProject()).get(ISeamFacetDataModelProperties.JBOSS_AS_DEPLOY_AS,"war")); //$NON-NLS-1$ //$NON-NLS-2$
}
+
+ public abstract String getDefaultMessageText();
}
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamConversationWizard.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamConversationWizard.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamConversationWizard.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -10,21 +10,14 @@
******************************************************************************/
package org.jboss.tools.seam.ui.wizard;
-import java.io.File;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
-import org.eclipse.core.commands.ExecutionException;
import org.eclipse.core.commands.operations.IUndoableOperation;
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
import org.eclipse.ui.INewWizard;
import org.jboss.tools.seam.internal.core.project.facet.ISeamFacetDataModelProperties;
import org.jboss.tools.seam.ui.SeamUIMessages;
-import org.jboss.tools.seam.ui.wizard.SeamEntityWizard.SeamEntityCreateOperation;
public class SeamConversationWizard extends SeamBaseWizard implements INewWizard {
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamConversationWizardPage1.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamConversationWizardPage1.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamConversationWizardPage1.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -11,16 +11,12 @@
package org.jboss.tools.seam.ui.wizard;
-import java.beans.PropertyChangeEvent;
import java.util.Map;
import org.eclipse.swt.widgets.Composite;
import org.jboss.tools.seam.ui.SeamUIMessages;
import org.jboss.tools.seam.ui.internal.project.facet.IValidator;
import org.jboss.tools.seam.ui.internal.project.facet.ValidatorFactory;
-import org.jboss.tools.seam.ui.widget.editor.CompositeEditor;
-import org.jboss.tools.seam.ui.widget.editor.LabelFieldEditor;
-import org.jboss.tools.seam.ui.wizard.SeamBaseWizardPage.GridLayoutComposite;
/**
* @author eskimo
@@ -30,13 +26,13 @@
public SeamConversationWizardPage1() {
super("seam.new.conversation.page1",SeamUIMessages.SEAM_CONVERSATION_WIZARD_PAGE1_SEAM_CONVERSATION,null); //$NON-NLS-1$
- setMessage(SeamUIMessages.SEAM_CONVERSATION_WIZARD_PAGE1_SELECT_THE_NAME_OF_THE_NEW_SEAM_CONVERSATION +
- SeamUIMessages.SEAM_CONVERSATION_WIZARD_PAGE1_MANAGING_A_CONVERSATION_WILL_BE_CREATED);
+ setMessage(getDefaultMessageText());
}
/**
* @see org.eclipse.jface.dialogs.IDialogPage#createControl(org.eclipse.swt.widgets.Composite)
*/
+ @Override
public void createControl(Composite parent) {
setControl(new GridLayoutComposite(parent));
@@ -51,4 +47,13 @@
}
setPageComplete(false);
}
+
+ /* (non-Javadoc)
+ * @see org.jboss.tools.seam.ui.wizard.SeamBaseWizardPage#getDefaultMessageText()
+ */
+ @Override
+ public String getDefaultMessageText() {
+ // TODO Auto-generated method stub
+ return "Create a new Seam conversation";
+ }
}
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamEntityWizard.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamEntityWizard.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamEntityWizard.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -10,21 +10,14 @@
******************************************************************************/
package org.jboss.tools.seam.ui.wizard;
-import java.io.File;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
-import org.eclipse.core.commands.ExecutionException;
import org.eclipse.core.commands.operations.IUndoableOperation;
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
import org.eclipse.ui.INewWizard;
import org.jboss.tools.seam.internal.core.project.facet.ISeamFacetDataModelProperties;
import org.jboss.tools.seam.ui.SeamUIMessages;
-import org.jboss.tools.seam.ui.widget.editor.INamedElement;
/**
* @author eskimo
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamEntityWizardPage1.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamEntityWizardPage1.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamEntityWizardPage1.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -14,18 +14,13 @@
import java.beans.PropertyChangeEvent;
import java.util.Map;
+import org.eclipse.core.resources.IProject;
import org.eclipse.core.resources.IResource;
-import org.eclipse.jface.dialogs.IMessageProvider;
import org.eclipse.osgi.util.NLS;
import org.eclipse.swt.widgets.Composite;
-import org.jboss.tools.seam.core.SeamCorePlugin;
-import org.jboss.tools.seam.internal.core.project.facet.ISeamFacetDataModelProperties;
import org.jboss.tools.seam.ui.SeamUIMessages;
import org.jboss.tools.seam.ui.internal.project.facet.IValidator;
import org.jboss.tools.seam.ui.internal.project.facet.ValidatorFactory;
-import org.jboss.tools.seam.ui.widget.editor.CompositeEditor;
-import org.jboss.tools.seam.ui.widget.editor.LabelFieldEditor;
-import org.jboss.tools.seam.ui.wizard.SeamBaseWizardPage.GridLayoutComposite;
/**
* @author eskimo
@@ -38,13 +33,13 @@
*/
public SeamEntityWizardPage1() {
super("seam.new.entity.page1",SeamUIMessages.SEAM_ENTITY_WIZARD_PAGE1_SEAM_ENTITY, null); //$NON-NLS-1$
- setMessage(SeamUIMessages.SEAM_ENTITY_WIZARD_PAGE1_SELECT_THE_NAME_OF_NEW_SEAM_ENTITY +
- SeamUIMessages.SEAM_ENTITY_WIZARD_PAGE1_ANNOTATIONS_AND_EXAMPLES_ATTRIBUTES_WILL_BE_CREATED);
+ setMessage(getDefaultMessageText());
}
/**
*
*/
+ @Override
protected void createEditors() {
addEditor(SeamWizardFactory.createSeamProjectSelectionFieldEditor(SeamWizardUtils.getSelectedProjectName()));
addEditor(SeamWizardFactory.createSeamEntityClasNameFieldEditor());
@@ -52,11 +47,13 @@
addEditor(SeamWizardFactory.createSeamPageNameFieldEditor());
}
+ @Override
public void createControl(Composite parent) {
setControl(new GridLayoutComposite(parent));
setPageComplete(false);
}
+ @Override
public void doFillDefaults(PropertyChangeEvent event) {
if(event.getPropertyName().equals(IParameter.SEAM_ENTITY_CLASS_NAME)) {
if(event.getNewValue()==null||"".equals(event.getNewValue().toString().trim())) { //$NON-NLS-1$
@@ -73,6 +70,7 @@
}
}
+ @Override
protected void doValidate(PropertyChangeEvent event) {
Map errors = ValidatorFactory.SEAM_PROJECT_NAME_VALIDATOR.validate(
editorRegistry.get(IParameter.SEAM_PROJECT_NAME).getValue(), null);
@@ -83,9 +81,10 @@
return;
}
- IResource project = getSelectedProject();
+ IProject project = getSelectedProject();
+
+ if(!isValidRuntimeConfigured(project)) return;
-
errors = ValidatorFactory.SEAM_COMPONENT_NAME_VALIDATOR.validate(
editorRegistry.get(IParameter.SEAM_ENTITY_CLASS_NAME).getValue(), null);
@@ -96,7 +95,7 @@
}
errors = ValidatorFactory.FILE_NAME_VALIDATOR.validate(
- editorRegistry.get(IParameter.SEAM_MASTER_PAGE_NAME).getValue(), (Object)new Object[]{SeamUIMessages.SEAM_ENTITY_WIZARD_PAGE1_ENTITY_MASTER_PAGE,project});
+ editorRegistry.get(IParameter.SEAM_MASTER_PAGE_NAME).getValue(), new Object[]{SeamUIMessages.SEAM_ENTITY_WIZARD_PAGE1_ENTITY_MASTER_PAGE,project});
if(errors.size()>0) {
setErrorMessage(errors.get(IValidator.DEFAULT_ERROR).toString());
@@ -105,7 +104,7 @@
}
errors = ValidatorFactory.FILE_NAME_VALIDATOR.validate(
- editorRegistry.get(IParameter.SEAM_PAGE_NAME).getValue(), (Object)new Object[]{SeamUIMessages.SEAM_ENTITY_WIZARD_PAGE1_PAGE,project});
+ editorRegistry.get(IParameter.SEAM_PAGE_NAME).getValue(), new Object[]{SeamUIMessages.SEAM_ENTITY_WIZARD_PAGE1_PAGE,project});
if(errors.size()>0) {
setErrorMessage(errors.get(IValidator.DEFAULT_ERROR).toString());
@@ -114,7 +113,16 @@
}
setErrorMessage(null);
- setMessage(null);
+ setMessage(getDefaultMessageText());
setPageComplete(true);
}
+
+ /* (non-Javadoc)
+ * @see org.jboss.tools.seam.ui.wizard.SeamBaseWizardPage#getDefaultMessageText()
+ */
+ @Override
+ public String getDefaultMessageText() {
+ // TODO Auto-generated method stub
+ return "Create a new Entity";
+ }
}
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamFormWizard.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamFormWizard.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamFormWizard.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -15,12 +15,7 @@
import java.util.List;
import java.util.Map;
-import org.eclipse.core.commands.ExecutionException;
import org.eclipse.core.commands.operations.IUndoableOperation;
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.ui.INewWizard;
import org.jboss.tools.seam.internal.core.project.facet.ISeamFacetDataModelProperties;
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamFormWizardPage1.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamFormWizardPage1.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamFormWizardPage1.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -10,10 +10,7 @@
******************************************************************************/
package org.jboss.tools.seam.ui.wizard;
-import java.beans.PropertyChangeEvent;
-
import org.jboss.tools.seam.ui.SeamUIMessages;
-import org.jboss.tools.seam.ui.widget.editor.IFieldEditor;
/**
@@ -27,11 +24,22 @@
*/
public SeamFormWizardPage1() {
super("seam.new.form.page1",SeamUIMessages.SEAM_FORM_WIZARD_PAGE1_SEAM_FORM,null); //$NON-NLS-1$
- setMessage(SeamUIMessages.SEAM_FORM_WIZARD_PAGE1_SELECT_THE_NAME_OF_THE_NEW_SEAM_FORM +
- SeamUIMessages.SEAM_FORM_WIZARD_PAGE1_JAVA_INTERFACE_SLSB_AND_KEY_SEAMEJB3_ANNOTATIONS_WILL_BE_CREATED);
+ setMessage(getDefaultMessageText());
}
+ @Override
protected void createEditors() {
addEditors(SeamWizardFactory.createBaseFormFieldEditors(SeamWizardUtils.getSelectedProjectName()));
}
+
+ /* (non-Javadoc)
+ * @see org.jboss.tools.seam.ui.wizard.SeamBaseWizardPage#getDefaultMessageText()
+ */
+ @Override
+ public String getDefaultMessageText() {
+ // TODO Auto-generated method stub
+ return "Create a new Seam form";
+ }
+
+
}
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamGenerateEnitiesWizard.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamGenerateEnitiesWizard.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamGenerateEnitiesWizard.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -17,13 +17,10 @@
import org.eclipse.core.commands.ExecutionException;
import org.eclipse.core.commands.operations.IUndoableOperation;
-import org.eclipse.core.resources.IFolder;
import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
import org.eclipse.core.resources.ResourcesPlugin;
import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.core.runtime.IPath;
import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.Status;
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamProjectSelectionDialog.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamProjectSelectionDialog.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamProjectSelectionDialog.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -26,8 +26,8 @@
import org.eclipse.ui.model.WorkbenchLabelProvider;
import org.eclipse.wst.common.project.facet.core.IFacetedProject;
import org.eclipse.wst.common.project.facet.core.ProjectFacetsManager;
+import org.jboss.tools.seam.core.ISeamProject;
import org.jboss.tools.seam.core.SeamCorePlugin;
-import org.jboss.tools.seam.core.project.facet.SeamFacetPreference;
import org.jboss.tools.seam.internal.core.SeamProject;
import org.jboss.tools.seam.ui.SeamUIMessages;
@@ -51,7 +51,7 @@
ArrayList<IProject> seamProjects = new ArrayList<IProject>();
for (IProject project : ResourcesPlugin.getWorkspace().getRoot().getProjects()) {
try {
- if(project.hasNature(SeamProject.NATURE_ID)
+ if(project.hasNature(ISeamProject.NATURE_ID)
&& SeamCorePlugin.getSeamPreferences(project)!=null
&& project.getAdapter(IFacetedProject.class)!=null
&& ((IFacetedProject)project.getAdapter(IFacetedProject.class)).hasProjectFacet(ProjectFacetsManager.getProjectFacet("jst.web"))) { //$NON-NLS-1$
Deleted: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamProjectWizardPage1.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamProjectWizardPage1.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamProjectWizardPage1.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -1,197 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2007 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.seam.ui.wizard;
-
-import org.eclipse.core.resources.IContainer;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jface.dialogs.IDialogPage;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.wizard.WizardPage;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.ui.dialogs.ContainerSelectionDialog;
-import org.jboss.tools.seam.ui.SeamUIMessages;
-
-/**
- * The "New" wizard page allows setting the container for the new file as well
- * as the file name. The page will only accept file name without the extension
- * OR with the extension that matches the expected one (mpe).
- */
-
-public class SeamProjectWizardPage1 extends WizardPage {
- private Text containerText;
-
- private Text fileText;
-
- private ISelection selection;
-
- /**
- * Constructor for SampleNewWizardPage.
- *
- * @param pageName
- */
- public SeamProjectWizardPage1(ISelection selection) {
- super("wizardPage"); //$NON-NLS-1$
- setTitle(SeamUIMessages.SEAM_PROJECT_WIZARD_PAGE1_MULTIPAGE_EDITOR_FILE);
- setDescription(SeamUIMessages.SEAM_PROJECT_WIZARD_PAGE1_THIS_WIZARD_CREATES_A_NEW_FILE);
- this.selection = selection;
- }
-
- /**
- * @see IDialogPage#createControl(Composite)
- */
- public void createControl(Composite parent) {
- Composite container = new Composite(parent, SWT.NULL);
- GridLayout layout = new GridLayout();
- container.setLayout(layout);
- layout.numColumns = 3;
- layout.verticalSpacing = 9;
- Label label = new Label(container, SWT.NULL);
- label.setText(SeamUIMessages.SEAM_PROJECT_WIZARD_PAGE1_CONTAINER);
-
- containerText = new Text(container, SWT.BORDER | SWT.SINGLE);
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- containerText.setLayoutData(gd);
- containerText.addModifyListener(new ModifyListener() {
- public void modifyText(ModifyEvent e) {
- dialogChanged();
- }
- });
-
- Button button = new Button(container, SWT.PUSH);
- button.setText(SeamUIMessages.SEAM_PROJECT_WIZARD_PAGE1_BROWSE);
- button.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- handleBrowse();
- }
- });
- label = new Label(container, SWT.NULL);
- label.setText(SeamUIMessages.SEAM_PROJECT_WIZARD_PAGE1_FILE_NAME);
-
- fileText = new Text(container, SWT.BORDER | SWT.SINGLE);
- gd = new GridData(GridData.FILL_HORIZONTAL);
- fileText.setLayoutData(gd);
- fileText.addModifyListener(new ModifyListener() {
- public void modifyText(ModifyEvent e) {
- dialogChanged();
- }
- });
- initialize();
- dialogChanged();
- setControl(container);
- }
-
- /**
- * Tests if the current workbench selection is a suitable container to use.
- */
-
- private void initialize() {
- if (selection != null && selection.isEmpty() == false
- && selection instanceof IStructuredSelection) {
- IStructuredSelection ssel = (IStructuredSelection) selection;
- if (ssel.size() > 1)
- return;
- Object obj = ssel.getFirstElement();
- if (obj instanceof IResource) {
- IContainer container;
- if (obj instanceof IContainer)
- container = (IContainer) obj;
- else
- container = ((IResource) obj).getParent();
- containerText.setText(container.getFullPath().toString());
- }
- }
- fileText.setText("new_file.mpe"); //$NON-NLS-1$
- }
-
- /**
- * Uses the standard container selection dialog to choose the new value for
- * the container field.
- */
-
- private void handleBrowse() {
- ContainerSelectionDialog dialog = new ContainerSelectionDialog(
- getShell(), ResourcesPlugin.getWorkspace().getRoot(), false,
- SeamUIMessages.SEAM_PROJECT_WIZARD_PAGE1_SELECT_NEW_FILE_CONTAINER);
- if (dialog.open() == ContainerSelectionDialog.OK) {
- Object[] result = dialog.getResult();
- if (result.length == 1) {
- containerText.setText(((Path) result[0]).toString());
- }
- }
- }
-
- /**
- * Ensures that both text fields are set.
- */
-
- private void dialogChanged() {
- IResource container = ResourcesPlugin.getWorkspace().getRoot()
- .findMember(new Path(getContainerName()));
- String fileName = getFileName();
-
- if (getContainerName().length() == 0) {
- updateStatus(SeamUIMessages.SEAM_PROJECT_WIZARD_PAGE1_FILE_CONTAINER_MUST_BE_SPECIFIED);
- return;
- }
- if (container == null
- || (container.getType() & (IResource.PROJECT | IResource.FOLDER)) == 0) {
- updateStatus(SeamUIMessages.SEAM_PROJECT_WIZARD_PAGE1_FILE_CONTAINER_MUST_EXIST);
- return;
- }
- if (!container.isAccessible()) {
- updateStatus(SeamUIMessages.SEAM_PROJECT_WIZARD_PAGE1_PROJECT_MUST_BE_WRITABLE);
- return;
- }
- if (fileName.length() == 0) {
- updateStatus(SeamUIMessages.SEAM_PROJECT_WIZARD_PAGE1_FILE_NAME_MUST_BE_SPECIFIED);
- return;
- }
- if (fileName.replace('\\', '/').indexOf('/', 1) > 0) {
- updateStatus(SeamUIMessages.SEAM_PROJECT_WIZARD_PAGE1_FILE_NAME_MUST_BE_VALID);
- return;
- }
- int dotLoc = fileName.lastIndexOf('.');
- if (dotLoc != -1) {
- String ext = fileName.substring(dotLoc + 1);
- if (ext.equalsIgnoreCase("mpe") == false) { //$NON-NLS-1$
- updateStatus(SeamUIMessages.SEAM_PROJECT_WIZARD_PAGE1_FILE_EXTENSION_MUST_BE_MPE);
- return;
- }
- }
- updateStatus(null);
- }
-
- private void updateStatus(String message) {
- setErrorMessage(message);
- setPageComplete(message == null);
- }
-
- public String getContainerName() {
- return containerText.getText();
- }
-
- public String getFileName() {
- return fileText.getText();
- }
-}
\ No newline at end of file
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamWizardFactory.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamWizardFactory.java 2007-10-12 01:30:23 UTC (rev 4126)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamWizardFactory.java 2007-10-12 01:30:44 UTC (rev 4127)
@@ -20,6 +20,7 @@
import org.jboss.tools.seam.ui.SeamUIMessages;
import org.jboss.tools.seam.ui.internal.project.facet.ValidatorFactory;
import org.jboss.tools.seam.ui.widget.editor.IFieldEditor;
+import org.jboss.tools.seam.ui.widget.editor.IFieldEditorFactory;
import org.jboss.tools.seam.ui.widget.editor.SwtFieldEditorFactory;
/**
@@ -29,7 +30,7 @@
public class SeamWizardFactory {
public static IFieldEditor createSeamProjectSelectionFieldEditor(
String defaultSelection) {
- return SwtFieldEditorFactory.INSTANCE.createButtonFieldEditor(
+ return IFieldEditorFactory.INSTANCE.createButtonFieldEditor(
IParameter.SEAM_PROJECT_NAME, SeamUIMessages.SEAM_WIZARD_FACTORY_SEAM_PROJECT, defaultSelection,
new SelectSeamProjectAction(), ValidatorFactory.NO_ERRORS_VALIDATOR);
}
@@ -39,7 +40,7 @@
*/
public static IFieldEditor createSeamLocalInterfaceNameFieldEditor() {
// TODO Auto-generated method stub
- return SwtFieldEditorFactory.INSTANCE.createTextEditor(
+ return IFieldEditorFactory.INSTANCE.createTextEditor(
IParameter.SEAM_LOCAL_INTERFACE_NAME, SeamUIMessages.SEAM_WIZARD_FACTORY_LOCAL_INTERFACE_NAME, ""); //$NON-NLS-1$
}
@@ -47,7 +48,7 @@
* @return
*/
public static IFieldEditor createSeamBeanNameFieldEditor() {
- return SwtFieldEditorFactory.INSTANCE.createTextEditor(
+ return IFieldEditorFactory.INSTANCE.createTextEditor(
IParameter.SEAM_BEAN_NAME, SeamUIMessages.SEAM_WIZARD_FACTORY_BEAN_NAME, ""); //$NON-NLS-1$
}
@@ -56,7 +57,7 @@
* @return
*/
public static IFieldEditor createSeamMethodNameFieldEditor() {
- return SwtFieldEditorFactory.INSTANCE.createTextEditor(
+ return IFieldEditorFactory.INSTANCE.createTextEditor(
IParameter.SEAM_METHOD_NAME, SeamUIMessages.SEAM_WIZARD_FACTORY_METHOD_NAME, ""); //$NON-NLS-1$
}
@@ -65,7 +66,7 @@
* @return
*/
public static IFieldEditor createSeamPageNameFieldEditor() {
- return SwtFieldEditorFactory.INSTANCE.createTextEditor(
+ return IFieldEditorFactory.INSTANCE.createTextEditor(
IParameter.SEAM_PAGE_NAME, SeamUIMessages.SEAM_WIZARD_FACTORY_PAGE_NAME, ""); //$NON-NLS-1$
}
@@ -73,7 +74,7 @@
* @return
*/
public static IFieldEditor createSeamMasterPageNameFieldEditor() {
- return SwtFieldEditorFactory.INSTANCE.createTextEditor(
+ return IFieldEditorFactory.INSTANCE.createTextEditor(
IParameter.SEAM_MASTER_PAGE_NAME, SeamUIMessages.SEAM_WIZARD_FACTORY_MASTER_PAGE_NAME, ""); //$NON-NLS-1$
}
@@ -93,7 +94,7 @@
*/
public static IFieldEditor createSeamComponentNameFieldEditor() {
// TODO Auto-generated method stub
- return SwtFieldEditorFactory.INSTANCE.createTextEditor(
+ return IFieldEditorFactory.INSTANCE.createTextEditor(
IParameter.SEAM_COMPONENT_NAME, SeamUIMessages.SEAM_WIZARD_FACTORY_SEAM_COMPONENT_NAME, ""); //$NON-NLS-1$
}
@@ -101,7 +102,7 @@
* @return
*/
public static IFieldEditor createSeamEntityClasNameFieldEditor() {
- return SwtFieldEditorFactory.INSTANCE.createTextEditor(
+ return IFieldEditorFactory.INSTANCE.createTextEditor(
IParameter.SEAM_ENTITY_CLASS_NAME, SeamUIMessages.SEAM_WIZARD_FACTORY_SEAM_ENTITY_CLASS_NAME, ""); //$NON-NLS-1$
}
@@ -123,7 +124,7 @@
defaultSelection = ""; //$NON-NLS-1$
}
}
- IFieldEditor editor = SwtFieldEditorFactory.INSTANCE.createComboEditor(
+ IFieldEditor editor = IFieldEditorFactory.INSTANCE.createComboEditor(
IParameter.HIBERNATE_CONFIGURATION_NAME,
SeamUIMessages.GENERATE_SEAM_ENTITIES_WIZARD_HIBERNATE_CONFIGURATION_LABEL,
configurationNames, defaultSelection);
17 years, 3 months
JBoss Tools SVN: r4126 - trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/core/project/facet.
by jbosstools-commits@lists.jboss.org
Author: dgolovin
Date: 2007-10-11 21:30:23 -0400 (Thu, 11 Oct 2007)
New Revision: 4126
Modified:
trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/core/project/facet/SeamRuntime.java
Log:
http://jira.jboss.com/jira/browse/JBIDE-985
seam runtime validation added to Seam Wizards
some code clean up was done
Modified: trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/core/project/facet/SeamRuntime.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/core/project/facet/SeamRuntime.java 2007-10-12 01:30:20 UTC (rev 4125)
+++ trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/core/project/facet/SeamRuntime.java 2007-10-12 01:30:23 UTC (rev 4126)
@@ -118,9 +118,13 @@
}
public String getResourceTemplatesDir() {
- return getHomeDir()+"/seam-gen/resources"; //$NON-NLS-1$
+ return getSeamGenDir()+"/resources"; //$NON-NLS-1$
}
+ public String getTestTemplatesDir() {
+ return getSeamGenDir()+"/test"; //$NON-NLS-1$
+ }
+
public String getTemplatesDir() {
return getSeamGenDir();
}
17 years, 3 months
JBoss Tools SVN: r4125 - trunk/seam/tests/org.jboss.tools.seam.core.test/src/org/jboss/tools/seam/core/test/project/facet.
by jbosstools-commits@lists.jboss.org
Author: dgolovin
Date: 2007-10-11 21:30:20 -0400 (Thu, 11 Oct 2007)
New Revision: 4125
Modified:
trunk/seam/tests/org.jboss.tools.seam.core.test/src/org/jboss/tools/seam/core/test/project/facet/SeamRuntimeManagerTest.java
Log:
http://jira.jboss.com/jira/browse/JBIDE-985
seam runtime validation added to Seam Wizards
some code clean up was done
Modified: trunk/seam/tests/org.jboss.tools.seam.core.test/src/org/jboss/tools/seam/core/test/project/facet/SeamRuntimeManagerTest.java
===================================================================
--- trunk/seam/tests/org.jboss.tools.seam.core.test/src/org/jboss/tools/seam/core/test/project/facet/SeamRuntimeManagerTest.java 2007-10-11 20:49:05 UTC (rev 4124)
+++ trunk/seam/tests/org.jboss.tools.seam.core.test/src/org/jboss/tools/seam/core/test/project/facet/SeamRuntimeManagerTest.java 2007-10-12 01:30:20 UTC (rev 4125)
@@ -59,7 +59,7 @@
public void testGetRuntimesSeamVersion() {
SeamRuntimeManager manager = SeamRuntimeManager.getInstance();
SeamRuntime[] rtms = manager.getRuntimes(SeamVersion.SEAM_1_2);
- assertTrue("Error in obtaining seam runtimes lis for Seam 1.2", rtms.length==1);
+ assertTrue("Error in obtaining seam runtimes list for Seam 1.2", rtms.length==1);
}
/**
17 years, 3 months
JBoss Tools SVN: r4124 - trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/action/server.
by jbosstools-commits@lists.jboss.org
Author: rob.stryker(a)jboss.com
Date: 2007-10-11 16:49:05 -0400 (Thu, 11 Oct 2007)
New Revision: 4124
Modified:
trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/action/server/StopServerActionDelegate.java
Log:
JBIDE-865
Modified: trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/action/server/StopServerActionDelegate.java
===================================================================
--- trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/action/server/StopServerActionDelegate.java 2007-10-11 17:41:32 UTC (rev 4123)
+++ trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/action/server/StopServerActionDelegate.java 2007-10-11 20:49:05 UTC (rev 4124)
@@ -24,7 +24,7 @@
if(server == null) return;
ServiceDialog d = PreferenceModelUtilities.getPreferenceModel().getService();
try {
- server.stop(true);
+ server.stop(false);
} catch (Exception e) {
d.showDialog(WebUIMessages.ERROR, e.getMessage(), new String[]{WebUIMessages.CLOSE}, null, ServiceDialog.ERROR);
}
17 years, 3 months