diff options
author | Petya Sabeva | 2012-11-07 15:50:59 +0000 |
---|---|---|
committer | Petya Sabeva | 2012-11-07 15:50:59 +0000 |
commit | 92ce02c502941b8471c3dbfdcf75c8d9801cd0a0 (patch) | |
tree | d98544767da77afa01250bb911c0479979ba362d | |
parent | 09c0193c841b867238ce1c9ec9d5dbb2a005aa3f (diff) | |
parent | 503fb0d6ba1ee1730030a5febc18b69a1beeb38d (diff) | |
download | webtools.dali-92ce02c502941b8471c3dbfdcf75c8d9801cd0a0.tar.gz webtools.dali-92ce02c502941b8471c3dbfdcf75c8d9801cd0a0.tar.xz webtools.dali-92ce02c502941b8471c3dbfdcf75c8d9801cd0a0.zip |
Merge branch 'master' of ssh://psabeva@proxy.eclipse.org:443/gitroot/dali/webtools.dali.git
5 files changed, 40 insertions, 42 deletions
diff --git a/common/plugins/org.eclipse.jpt.common.core/src/org/eclipse/jpt/common/core/internal/utility/jdt/ASTTools.java b/common/plugins/org.eclipse.jpt.common.core/src/org/eclipse/jpt/common/core/internal/utility/jdt/ASTTools.java index 79757d335d..49f562909b 100644 --- a/common/plugins/org.eclipse.jpt.common.core/src/org/eclipse/jpt/common/core/internal/utility/jdt/ASTTools.java +++ b/common/plugins/org.eclipse.jpt.common.core/src/org/eclipse/jpt/common/core/internal/utility/jdt/ASTTools.java @@ -65,7 +65,7 @@ public class ASTTools { } private static ASTParser astParser() { - ASTParser parser = ASTParser.newParser(AST.JLS3); + ASTParser parser = ASTParser.newParser(AST.JLS4); parser.setIgnoreMethodBodies(true); // we don't need method bodies parser.setResolveBindings(true); parser.setBindingsRecovery(true); // see bugs 196200, 222735 diff --git a/jaxb/plugins/org.eclipse.jpt.jaxb.core/src/org/eclipse/jpt/jaxb/core/JaxbPreferences.java b/jaxb/plugins/org.eclipse.jpt.jaxb.core/src/org/eclipse/jpt/jaxb/core/JaxbPreferences.java index 74fa591eb3..e9e18c4447 100644 --- a/jaxb/plugins/org.eclipse.jpt.jaxb.core/src/org/eclipse/jpt/jaxb/core/JaxbPreferences.java +++ b/jaxb/plugins/org.eclipse.jpt.jaxb.core/src/org/eclipse/jpt/jaxb/core/JaxbPreferences.java @@ -14,14 +14,8 @@ import java.util.Collections; import java.util.List; import org.eclipse.core.resources.IProject; import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Status; -import org.eclipse.core.runtime.jobs.Job; -import org.eclipse.jpt.common.core.internal.JptCommonCoreMessages; import org.eclipse.jpt.common.utility.internal.StringTools; import org.eclipse.jpt.jaxb.core.internal.plugin.JptJaxbCorePlugin; -import org.eclipse.osgi.util.NLS; import org.eclipse.wst.common.project.facet.core.IFacetedProject; import org.eclipse.wst.common.project.facet.core.ProjectFacetsManager; import org.osgi.service.prefs.BackingStoreException; @@ -179,27 +173,10 @@ public class JaxbPreferences { // ********** flush preferences ********** private static void flushPreferences(Preferences prefs) { - new FlushPreferencesJob(prefs).schedule(); - } - - /* CU private */ static class FlushPreferencesJob - extends Job - { - private final Preferences prefs; - - FlushPreferencesJob(Preferences prefs) { - super(NLS.bind(JptCommonCoreMessages.PREFERENCES_FLUSH_JOB_NAME, prefs.absolutePath())); - this.prefs = prefs; - } - - @Override - protected IStatus run(IProgressMonitor monitor) { - try { - this.prefs.flush(); - } catch(BackingStoreException ex) { - return JptJaxbCorePlugin.instance().logError(ex); - } - return Status.OK_STATUS; + try { + prefs.flush(); + } catch (BackingStoreException ex) { + JptJaxbCorePlugin.instance().logError(ex); } } diff --git a/jaxb/plugins/org.eclipse.jpt.jaxb.eclipselink.core/src/org/eclipse/jpt/jaxb/eclipselink/core/resource/oxm/EXmlBindings.java b/jaxb/plugins/org.eclipse.jpt.jaxb.eclipselink.core/src/org/eclipse/jpt/jaxb/eclipselink/core/resource/oxm/EXmlBindings.java index 672660fb8b..bce390926d 100644 --- a/jaxb/plugins/org.eclipse.jpt.jaxb.eclipselink.core/src/org/eclipse/jpt/jaxb/eclipselink/core/resource/oxm/EXmlBindings.java +++ b/jaxb/plugins/org.eclipse.jpt.jaxb.eclipselink.core/src/org/eclipse/jpt/jaxb/eclipselink/core/resource/oxm/EXmlBindings.java @@ -74,14 +74,10 @@ public class EXmlBindings extends ERootObjectImpl /**
- * The default value of the '{@link #getXmlAccessorOrder() <em>Xml Accessor Order</em>}' attribute.
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
- * @see #getXmlAccessorOrder()
- * @generated
- * @ordered
+ * changed this to null and removed the generated flag so emf won't generate over it
+ * we don't want a default for enums, just null if the tag does not exist
*/
- protected static final EXmlAccessOrder XML_ACCESSOR_ORDER_EDEFAULT = EXmlAccessOrder.ALPHABETICAL;
+ protected static final EXmlAccessOrder XML_ACCESSOR_ORDER_EDEFAULT = null;
/**
diff --git a/jaxb/plugins/org.eclipse.jpt.jaxb.ui/src/org/eclipse/jpt/jaxb/ui/internal/wizards/classesgen/ClassesGeneratorWizard.java b/jaxb/plugins/org.eclipse.jpt.jaxb.ui/src/org/eclipse/jpt/jaxb/ui/internal/wizards/classesgen/ClassesGeneratorWizard.java index 46d770fb9a..6bfdc368ab 100644 --- a/jaxb/plugins/org.eclipse.jpt.jaxb.ui/src/org/eclipse/jpt/jaxb/ui/internal/wizards/classesgen/ClassesGeneratorWizard.java +++ b/jaxb/plugins/org.eclipse.jpt.jaxb.ui/src/org/eclipse/jpt/jaxb/ui/internal/wizards/classesgen/ClassesGeneratorWizard.java @@ -42,8 +42,8 @@ import org.eclipse.jpt.jaxb.ui.internal.plugin.JptJaxbUiPlugin; import org.eclipse.osgi.util.NLS; import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Shell; +import org.eclipse.ui.INewWizard; import org.eclipse.ui.IWorkbench; -import org.eclipse.ui.IWorkbenchWizard; import org.eclipse.wst.xsd.contentmodel.internal.XSDImpl; import org.eclipse.xsd.XSDSchema; @@ -52,8 +52,8 @@ import org.eclipse.xsd.XSDSchema; */ public class ClassesGeneratorWizard extends Wizard - implements IWorkbenchWizard { - + implements INewWizard { + private IJavaProject javaProject; private IFile preselectedXsdFile; protected IStructuredSelection selection; diff --git a/jpa/plugins/org.eclipse.jpt.jpa.ui/plugin.xml b/jpa/plugins/org.eclipse.jpt.jpa.ui/plugin.xml index df929c68d9..deb6c8ef1c 100644 --- a/jpa/plugins/org.eclipse.jpt.jpa.ui/plugin.xml +++ b/jpa/plugins/org.eclipse.jpt.jpa.ui/plugin.xml @@ -272,12 +272,13 @@ <command id="org.eclipse.jpt.jpa.ui.convertJavaProjectToJpa" name="%convertJavaProjectToJpaCommandName" - categoryId="org.eclipse.ui.category.file" - defaultHandler="org.eclipse.jpt.jpa.ui.internal.commands.ConvertJavaProjectToJpaCommandHandler"/> - + categoryId="org.eclipse.ui.category.file"> + </command> + <command id="org.eclipse.jpt.jpa.ui.xmlFileUpgradeToLatestVersion" - name="%upgradeToLatestVersion"/> + name="%upgradeToLatestVersion"> + </command> <category id="org.eclipse.jpt.jpa.ui.jpaStructureViewCommands" @@ -514,6 +515,30 @@ class="org.eclipse.jpt.jpa.ui.internal.commands.JavaQueryConversionHandler" commandId="org.eclipse.jpt.jpa.ui.convertJavaQueries"/> + <handler + commandId="org.eclipse.jpt.jpa.ui.convertJavaProjectToJpa" + class="org.eclipse.jpt.jpa.ui.internal.commands.ConvertJavaProjectToJpaCommandHandler"> + <activeWhen> + <and> + <count value="1"/> + <iterate ifEmpty="false" operator="and"> + <adapt type="org.eclipse.core.resources.IProject"> + <and> + <test + property="org.eclipse.core.resources.projectNature" + value="org.eclipse.jdt.core.javanature"/> + <not> + <test + property="org.eclipse.core.resources.projectNature" + value="org.eclipse.wst.common.project.facet.core.nature"/> + </not> + </and> + </adapt> + </iterate> + </and> + </activeWhen> + </handler> + </extension> |