Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorcanderson2010-08-24 15:28:34 +0000
committercanderson2010-08-24 15:28:34 +0000
commitb5b06dcf96f3c7bf21fd3d7b64e8d5e209d08f8b (patch)
tree16f00ec7a0c77d852014c630d367a2e3c966a560 /plugins/org.eclipse.jst.servlet.ui/servlet_ui/org/eclipse/jst/servlet/ui
parent6b9dba70f25f3c8d625cc2f711fc08131f037dbb (diff)
downloadwebtools.javaee-b5b06dcf96f3c7bf21fd3d7b64e8d5e209d08f8b.tar.gz
webtools.javaee-b5b06dcf96f3c7bf21fd3d7b64e8d5e209d08f8b.tar.xz
webtools.javaee-b5b06dcf96f3c7bf21fd3d7b64e8d5e209d08f8b.zip
[323186] Allow creation of Filters and Listeners in Web Fragments
Diffstat (limited to 'plugins/org.eclipse.jst.servlet.ui/servlet_ui/org/eclipse/jst/servlet/ui')
-rw-r--r--plugins/org.eclipse.jst.servlet.ui/servlet_ui/org/eclipse/jst/servlet/ui/internal/wizard/NewFilterClassWizardPage.java3
-rw-r--r--plugins/org.eclipse.jst.servlet.ui/servlet_ui/org/eclipse/jst/servlet/ui/internal/wizard/NewListenerClassWizardPage.java3
2 files changed, 6 insertions, 0 deletions
diff --git a/plugins/org.eclipse.jst.servlet.ui/servlet_ui/org/eclipse/jst/servlet/ui/internal/wizard/NewFilterClassWizardPage.java b/plugins/org.eclipse.jst.servlet.ui/servlet_ui/org/eclipse/jst/servlet/ui/internal/wizard/NewFilterClassWizardPage.java
index 1f6e59198..2ad1bd1d1 100644
--- a/plugins/org.eclipse.jst.servlet.ui/servlet_ui/org/eclipse/jst/servlet/ui/internal/wizard/NewFilterClassWizardPage.java
+++ b/plugins/org.eclipse.jst.servlet.ui/servlet_ui/org/eclipse/jst/servlet/ui/internal/wizard/NewFilterClassWizardPage.java
@@ -156,6 +156,9 @@ public class NewFilterClassWizardPage extends NewWebClassWizardPage {
boolean result = super.isProjectValid(project);
if (!result)
return false;
+
+ if (JavaEEProjectUtilities.isWebFragmentProject(project))
+ return true;
// get the version of the web facet
IProjectFacetVersion facetVersion = JavaEEProjectUtilities.getProjectFacetVersion(project, IJ2EEFacetConstants.DYNAMIC_WEB);
diff --git a/plugins/org.eclipse.jst.servlet.ui/servlet_ui/org/eclipse/jst/servlet/ui/internal/wizard/NewListenerClassWizardPage.java b/plugins/org.eclipse.jst.servlet.ui/servlet_ui/org/eclipse/jst/servlet/ui/internal/wizard/NewListenerClassWizardPage.java
index 54e29399a..031ed181f 100644
--- a/plugins/org.eclipse.jst.servlet.ui/servlet_ui/org/eclipse/jst/servlet/ui/internal/wizard/NewListenerClassWizardPage.java
+++ b/plugins/org.eclipse.jst.servlet.ui/servlet_ui/org/eclipse/jst/servlet/ui/internal/wizard/NewListenerClassWizardPage.java
@@ -76,6 +76,9 @@ public class NewListenerClassWizardPage extends NewWebClassWizardPage {
boolean result = super.isProjectValid(project);
if (!result)
return false;
+
+ if (JavaEEProjectUtilities.isWebFragmentProject(project))
+ return true;
// get the version of the web facet
IProjectFacetVersion facetVersion = JavaEEProjectUtilities.getProjectFacetVersion(project, IJ2EEFacetConstants.DYNAMIC_WEB);

Back to the top