Author: rob.stryker(a)jboss.com
Date: 2009-06-08 06:42:26 -0400 (Mon, 08 Jun 2009)
New Revision: 15769
Modified:
trunk/archives/plugins/org.jboss.ide.eclipse.archives.core/src/eclipse/org/jboss/ide/eclipse/archives/core/model/other/internal/WorkspacePreferenceManager.java
trunk/archives/plugins/org.jboss.ide.eclipse.archives.ui/src/main/org/jboss/ide/eclipse/archives/ui/PrefsInitializer.java
trunk/archives/plugins/org.jboss.ide.eclipse.archives.ui/src/main/org/jboss/ide/eclipse/archives/ui/preferences/MainPreferencePage.java
trunk/archives/plugins/org.jboss.ide.eclipse.archives.ui/src/main/org/jboss/ide/eclipse/archives/ui/wizards/pages/FilesetInfoWizardPage.java
Log:
JBIDE-2095 - fixing the default excludes
Modified:
trunk/archives/plugins/org.jboss.ide.eclipse.archives.core/src/eclipse/org/jboss/ide/eclipse/archives/core/model/other/internal/WorkspacePreferenceManager.java
===================================================================
---
trunk/archives/plugins/org.jboss.ide.eclipse.archives.core/src/eclipse/org/jboss/ide/eclipse/archives/core/model/other/internal/WorkspacePreferenceManager.java 2009-06-08
10:16:08 UTC (rev 15768)
+++
trunk/archives/plugins/org.jboss.ide.eclipse.archives.core/src/eclipse/org/jboss/ide/eclipse/archives/core/model/other/internal/WorkspacePreferenceManager.java 2009-06-08
10:42:26 UTC (rev 15769)
@@ -40,7 +40,7 @@
public static final String PROJECT_SPECIFIC_PREFS =
"org.jboss.ide.eclipse.archives.core.projectSpecificPreferencesEnabled";
//$NON-NLS-1$
private static IWorkspaceRoot workspaceRoot = ResourcesPlugin.getWorkspace().getRoot();
- private static IResource getResource(IPath path) {
+ public static IResource getResource(IPath path) {
if( path != null ) {
IProject[] projects = workspaceRoot.getProjects();
if( projects != null ) {
Modified:
trunk/archives/plugins/org.jboss.ide.eclipse.archives.ui/src/main/org/jboss/ide/eclipse/archives/ui/PrefsInitializer.java
===================================================================
---
trunk/archives/plugins/org.jboss.ide.eclipse.archives.ui/src/main/org/jboss/ide/eclipse/archives/ui/PrefsInitializer.java 2009-06-08
10:16:08 UTC (rev 15768)
+++
trunk/archives/plugins/org.jboss.ide.eclipse.archives.ui/src/main/org/jboss/ide/eclipse/archives/ui/PrefsInitializer.java 2009-06-08
10:42:26 UTC (rev 15769)
@@ -94,7 +94,7 @@
if( adaptable != null ) {
IResource project = (IResource)adaptable.getAdapter(IResource.class);
try {
- if( project != null && project.getPersistentProperty(name) != null) {
+ if( project != null ) {// && project.getPersistentProperty(name) != null) {
project.setPersistentProperty(name, val);
return;
}
Modified:
trunk/archives/plugins/org.jboss.ide.eclipse.archives.ui/src/main/org/jboss/ide/eclipse/archives/ui/preferences/MainPreferencePage.java
===================================================================
---
trunk/archives/plugins/org.jboss.ide.eclipse.archives.ui/src/main/org/jboss/ide/eclipse/archives/ui/preferences/MainPreferencePage.java 2009-06-08
10:16:08 UTC (rev 15768)
+++
trunk/archives/plugins/org.jboss.ide.eclipse.archives.ui/src/main/org/jboss/ide/eclipse/archives/ui/preferences/MainPreferencePage.java 2009-06-08
10:42:26 UTC (rev 15769)
@@ -134,6 +134,8 @@
showAllProjects.setEnabled(val);
automaticBuilder.setEnabled(val);
showErrorDialog.setEnabled(val);
+ enableDefaultExcludes.setEnabled(val);
+ defaultExcludes.setEnabled(val);
}
protected void createCorePrefs(Composite main) {
@@ -166,7 +168,7 @@
enableDefaultExcludes = new Button(filesetGroup, SWT.CHECK);
enableDefaultExcludes.setText(ArchivesUIMessages.EnableDefaultExcludes);
- defaultExcludes = new Text(filesetGroup, SWT.DEFAULT);
+ defaultExcludes = new Text(filesetGroup, SWT.SINGLE | SWT.BORDER);
FormData fd = new FormData();
fd.top = new FormAttachment(0,5);
fd.left = new FormAttachment(0,5);
Modified:
trunk/archives/plugins/org.jboss.ide.eclipse.archives.ui/src/main/org/jboss/ide/eclipse/archives/ui/wizards/pages/FilesetInfoWizardPage.java
===================================================================
---
trunk/archives/plugins/org.jboss.ide.eclipse.archives.ui/src/main/org/jboss/ide/eclipse/archives/ui/wizards/pages/FilesetInfoWizardPage.java 2009-06-08
10:16:08 UTC (rev 15768)
+++
trunk/archives/plugins/org.jboss.ide.eclipse.archives.ui/src/main/org/jboss/ide/eclipse/archives/ui/wizards/pages/FilesetInfoWizardPage.java 2009-06-08
10:42:26 UTC (rev 15769)
@@ -38,10 +38,11 @@
import org.eclipse.swt.widgets.Text;
import org.jboss.ide.eclipse.archives.core.ArchivesCore;
import org.jboss.ide.eclipse.archives.core.model.DirectoryScannerFactory;
+import org.jboss.ide.eclipse.archives.core.model.IArchiveNode;
import org.jboss.ide.eclipse.archives.core.model.IArchiveStandardFileSet;
-import org.jboss.ide.eclipse.archives.core.model.IArchiveNode;
import
org.jboss.ide.eclipse.archives.core.model.DirectoryScannerFactory.DirectoryScannerExtension;
import
org.jboss.ide.eclipse.archives.core.model.DirectoryScannerFactory.DirectoryScannerExtension.FileWrapper;
+import
org.jboss.ide.eclipse.archives.core.model.other.internal.WorkspacePreferenceManager;
import org.jboss.ide.eclipse.archives.ui.ArchivesSharedImages;
import org.jboss.ide.eclipse.archives.ui.ArchivesUIMessages;
import org.jboss.ide.eclipse.archives.ui.PrefsInitializer;
@@ -333,8 +334,13 @@
includes = "**"; //$NON-NLS-1$
includesText.setText(includes);
boolean useDefaultExcludes =
PrefsInitializer.getBoolean(PrefsInitializer.PREF_USE_DEFAULT_EXCLUDES);
- if( useDefaultExcludes)
- excludesText.setText(PrefsInitializer.getString(PrefsInitializer.PREF_DEFAULT_EXCLUDE_LIST));
+ if( useDefaultExcludes && parentNode != null)
+ excludesText.setText(
+ PrefsInitializer.getString(
+ PrefsInitializer.PREF_DEFAULT_EXCLUDE_LIST,
+ WorkspacePreferenceManager.getResource(
+ parentNode.getProjectPath()),
+ true));
}
}
Show replies by date