diff options
12 files changed, 82 insertions, 49 deletions
diff --git a/bundles/org.eclipse.e4.tools.emf.editor3x/src/org/eclipse/e4/tools/emf/editor3x/ModelEditorPreferencePage.java b/bundles/org.eclipse.e4.tools.emf.editor3x/src/org/eclipse/e4/tools/emf/editor3x/ModelEditorPreferencePage.java index acb7735f..b97ffe58 100644 --- a/bundles/org.eclipse.e4.tools.emf.editor3x/src/org/eclipse/e4/tools/emf/editor3x/ModelEditorPreferencePage.java +++ b/bundles/org.eclipse.e4.tools.emf.editor3x/src/org/eclipse/e4/tools/emf/editor3x/ModelEditorPreferencePage.java @@ -1,12 +1,14 @@ /******************************************************************************* * * Contributors: - * Steven Spungin <steven@spungin.tv> - Bug 431735, Bug 437890, Bug 440469 + * Steven Spungin <steven@spungin.tv> - Bug 431735, Bug 437890, Bug 440469 ******************************************************************************/ package org.eclipse.e4.tools.emf.editor3x; import org.eclipse.core.runtime.preferences.InstanceScope; +import org.eclipse.e4.tools.emf.ui.common.ModelEditorPreferences; +import org.eclipse.e4.tools.emf.ui.common.Plugin; import org.eclipse.jface.preference.BooleanFieldEditor; import org.eclipse.jface.preference.ColorFieldEditor; import org.eclipse.jface.preference.PreferencePage; @@ -42,37 +44,42 @@ public class ModelEditorPreferencePage extends PreferencePage implements IWorkbe super(title, image); } + @Override public void init(IWorkbench workbench) { - setPreferenceStore(new ScopedPreferenceStore(InstanceScope.INSTANCE, "org.eclipse.e4.tools.emf.ui")); + setPreferenceStore(new ScopedPreferenceStore(InstanceScope.INSTANCE, Plugin.ID)); } @Override protected Control createContents(Composite parent) { - Composite result = new Composite(parent, SWT.NONE); + final Composite result = new Composite(parent, SWT.NONE); result.setLayout(new GridLayout()); { - Group group = new Group(result, SWT.NONE); + final Group group = new Group(result, SWT.NONE); group.setText("Color"); group.setLayoutData(new GridData(GridData.FILL, GridData.CENTER, false, false, 2, 1)); group.setLayout(new GridLayout(2, false)); { - fColorValueNotRendered = new ColorFieldEditor("notRenderedColor", "Not rendered color", group); + fColorValueNotRendered = new ColorFieldEditor(ModelEditorPreferences.NOT_RENDERED_COLOR, + "Not rendered color", group); fColorValueNotRendered.setPage(this); fColorValueNotRendered.setPreferenceStore(getPreferenceStore()); fColorValueNotRendered.load(); } { - fColorValueNotVisible = new ColorFieldEditor("notVisibleColor", "Not visible color", group); + fColorValueNotVisible = new ColorFieldEditor(ModelEditorPreferences.NOT_VISIBLE_COLOR, + "Not visible color", group); fColorValueNotVisible.setPage(this); fColorValueNotVisible.setPreferenceStore(getPreferenceStore()); fColorValueNotVisible.load(); } { - fColorValueNotVisibleAndRendered = new ColorFieldEditor("notVisibleAndRenderedColor", "Not visible and not rendered color", group); + fColorValueNotVisibleAndRendered = new ColorFieldEditor( + ModelEditorPreferences.NOT_VISIBLE_AND_RENDERED_COLOR, + "Not visible and not rendered color", group); fColorValueNotVisibleAndRendered.setPage(this); fColorValueNotVisibleAndRendered.setPreferenceStore(getPreferenceStore()); fColorValueNotVisibleAndRendered.load(); @@ -80,33 +87,36 @@ public class ModelEditorPreferencePage extends PreferencePage implements IWorkbe } { - Group group = new Group(result, SWT.NONE); + final Group group = new Group(result, SWT.NONE); group.setText("Form Tab"); group.setLayoutData(new GridData(GridData.FILL, GridData.CENTER, false, false, 2, 1)); group.setLayout(new GridLayout(2, false)); { - Composite container = new Composite(group, SWT.NONE); + final Composite container = new Composite(group, SWT.NONE); container.setLayoutData(new GridData(GridData.FILL, GridData.CENTER, false, false, 2, 1)); - fAutoGeneratedId = new BooleanFieldEditor("autoCreateElementId", "Autogenerate Element-Id", container); + fAutoGeneratedId = new BooleanFieldEditor(ModelEditorPreferences.AUTO_CREATE_ELEMENT_ID, + "Autogenerate Element-Id", container); fAutoGeneratedId.setPage(this); fAutoGeneratedId.setPreferenceStore(getPreferenceStore()); fAutoGeneratedId.load(); } { - Composite container = new Composite(group, SWT.NONE); + final Composite container = new Composite(group, SWT.NONE); container.setLayoutData(new GridData(GridData.FILL, GridData.CENTER, false, false, 2, 1)); - fShowXMIId = new BooleanFieldEditor("showXMIId", "Show XMI:ID", container); + fShowXMIId = new BooleanFieldEditor(ModelEditorPreferences.SHOW_XMI_ID, "Show XMI:ID", container); fShowXMIId.setPage(this); fShowXMIId.setPreferenceStore(getPreferenceStore()); fShowXMIId.load(); } { - Composite container = new Composite(group, SWT.NONE); + final Composite container = new Composite(group, SWT.NONE); container.setLayoutData(new GridData(GridData.FILL, GridData.CENTER, false, false, 2, 1)); - fShowSearch = new BooleanFieldEditor("tab-form-search-show", "Searchable tree on form tab\n" + "(forces read only XMI tab)\n" + "(requires reopening model)", container); + fShowSearch = new BooleanFieldEditor(ModelEditorPreferences.TAB_FORM_SEARCH_SHOW, + "Searchable tree on form tab\n" + + "(forces read only XMI tab)\n" + "(requires reopening model)", container); fShowSearch.setPage(this); fShowSearch.setPreferenceStore(getPreferenceStore()); fShowSearch.load(); @@ -115,21 +125,23 @@ public class ModelEditorPreferencePage extends PreferencePage implements IWorkbe } { - Group group = new Group(result, SWT.NONE); + final Group group = new Group(result, SWT.NONE); group.setText("List Tab"); group.setLayoutData(new GridData(GridData.FILL, GridData.CENTER, false, false, 2, 1)); group.setLayout(new GridLayout(2, false)); { - Composite container = new Composite(group, SWT.NONE); + final Composite container = new Composite(group, SWT.NONE); container.setLayoutData(new GridData(GridData.FILL, GridData.CENTER, false, false, 2, 1)); - fRememberColumns = new BooleanFieldEditor("list-tab-remember-columns", "Remember column settings when reopening editor ", container); + fRememberColumns = new BooleanFieldEditor(ModelEditorPreferences.LIST_TAB_REMEMBER_COLUMNS, + "Remember column settings when reopening editor ", container); fRememberColumns.setPage(this); fRememberColumns.setPreferenceStore(getPreferenceStore()); fRememberColumns.load(); - fRememberFilters = new BooleanFieldEditor("list-tab-remember-filters", "Remember filter settings when reopening editor", container); + fRememberFilters = new BooleanFieldEditor(ModelEditorPreferences.LIST_TAB_REMEMBER_FILTERS, + "Remember filter settings when reopening editor", container); fRememberFilters.setPage(this); fRememberFilters.setPreferenceStore(getPreferenceStore()); fRememberFilters.load(); diff --git a/bundles/org.eclipse.e4.tools.emf.ui/META-INF/MANIFEST.MF b/bundles/org.eclipse.e4.tools.emf.ui/META-INF/MANIFEST.MF index c3d09708..207e185a 100644 --- a/bundles/org.eclipse.e4.tools.emf.ui/META-INF/MANIFEST.MF +++ b/bundles/org.eclipse.e4.tools.emf.ui/META-INF/MANIFEST.MF @@ -42,7 +42,7 @@ Import-Package: javax.annotation;version="1.0.0", javax.inject;version="1.0.0", org.eclipse.core.runtime.jobs, org.osgi.framework;version="1.5.0" -Export-Package: org.eclipse.e4.tools.emf.ui.common;x-friends:="org.eclipse.e4.tools.emf.liveeditor", +Export-Package: org.eclipse.e4.tools.emf.ui.common;x-friends:="org.eclipse.e4.tools.emf.liveeditor,org.eclipse.e4.tools.emf.editor3x", org.eclipse.e4.tools.emf.ui.common.component;x-internal:=true, org.eclipse.e4.tools.emf.ui.internal;x-internal:=true, org.eclipse.e4.tools.emf.ui.internal.common;x-internal:=true, diff --git a/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/common/ContributionURIValidator.java b/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/common/ContributionURIValidator.java index 3c7b8375..449f39a9 100644 --- a/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/common/ContributionURIValidator.java +++ b/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/common/ContributionURIValidator.java @@ -14,7 +14,6 @@ import org.eclipse.core.databinding.validation.IValidator; import org.eclipse.core.runtime.IStatus; import org.eclipse.core.runtime.Status; import org.eclipse.e4.tools.emf.ui.internal.Messages; -import org.eclipse.e4.tools.emf.ui.internal.Plugin; import org.eclipse.emf.common.util.URI; public class ContributionURIValidator implements IValidator { diff --git a/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/common/ModelEditorPreferences.java b/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/common/ModelEditorPreferences.java new file mode 100644 index 00000000..74dc1d8e --- /dev/null +++ b/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/common/ModelEditorPreferences.java @@ -0,0 +1,14 @@ +package org.eclipse.e4.tools.emf.ui.common; + +public interface ModelEditorPreferences { + + public static final String LIST_TAB_REMEMBER_COLUMNS = "list-tab-remember-columns"; //$NON-NLS-1$ + public static final String LIST_TAB_REMEMBER_FILTERS = "list-tab-remember-filters"; //$NON-NLS-1$ + public static final String TAB_FORM_SEARCH_SHOW = "tab-form-search-show"; //$NON-NLS-1$ + public static final String AUTO_CREATE_ELEMENT_ID = "autoCreateElementId"; //$NON-NLS-1$ + public static final String NOT_VISIBLE_AND_RENDERED_COLOR = "notVisibleAndRenderedColor"; //$NON-NLS-1$ + public static final String NOT_VISIBLE_COLOR = "notVisibleColor"; //$NON-NLS-1$ + public static final String NOT_RENDERED_COLOR = "notRenderedColor"; //$NON-NLS-1$ + public static final String SHOW_XMI_ID = "showXMIId"; //$NON-NLS-1$ + +} diff --git a/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/Plugin.java b/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/common/Plugin.java index 42a2ee64..bdb46217 100644 --- a/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/Plugin.java +++ b/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/common/Plugin.java @@ -1,4 +1,4 @@ -package org.eclipse.e4.tools.emf.ui.internal; +package org.eclipse.e4.tools.emf.ui.common; public interface Plugin { diff --git a/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/PreferenceInitializer.java b/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/PreferenceInitializer.java index aff3e138..571e523b 100644 --- a/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/PreferenceInitializer.java +++ b/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/PreferenceInitializer.java @@ -9,6 +9,8 @@ package org.eclipse.e4.tools.emf.ui.internal; import org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer; import org.eclipse.core.runtime.preferences.IEclipsePreferences; import org.eclipse.core.runtime.preferences.InstanceScope; +import org.eclipse.e4.tools.emf.ui.common.ModelEditorPreferences; +import org.eclipse.e4.tools.emf.ui.common.Plugin; import org.eclipse.jface.resource.StringConverter; import org.eclipse.swt.graphics.RGB; @@ -18,37 +20,37 @@ public class PreferenceInitializer extends AbstractPreferenceInitializer { public void initializeDefaultPreferences() { IEclipsePreferences pref = InstanceScope.INSTANCE.getNode(Plugin.ID); - if (pref.get("notRenderedColor", null) == null) { //$NON-NLS-1$ + if (pref.get(ModelEditorPreferences.NOT_RENDERED_COLOR, null) == null) { String val = StringConverter.asString(new RGB(200, 200, 200)); - pref.put("notRenderedColor", val); //$NON-NLS-1$ + pref.put(ModelEditorPreferences.NOT_RENDERED_COLOR, val); } - if (pref.get("notVisibleColor", null) == null) { //$NON-NLS-1$ + if (pref.get(ModelEditorPreferences.NOT_VISIBLE_COLOR, null) == null) { String val = StringConverter.asString(new RGB(200, 200, 200)); - pref.put("notVisibleColor", val); //$NON-NLS-1$ + pref.put(ModelEditorPreferences.NOT_VISIBLE_COLOR, val); } - if (pref.get("notVisibleAndRenderedColor", null) == null) { //$NON-NLS-1$ + if (pref.get(ModelEditorPreferences.NOT_VISIBLE_AND_RENDERED_COLOR, null) == null) { String val = StringConverter.asString(new RGB(200, 200, 200)); - pref.put("notVisibleAndRenderedColor", val); //$NON-NLS-1$ + pref.put(ModelEditorPreferences.NOT_VISIBLE_AND_RENDERED_COLOR, val); } - if (pref.get("autoCreateElementId", null) == null) { //$NON-NLS-1$ - pref.putBoolean("autoCreateElementId", true); //$NON-NLS-1$ + if (pref.get(ModelEditorPreferences.AUTO_CREATE_ELEMENT_ID, null) == null) { + pref.putBoolean(ModelEditorPreferences.AUTO_CREATE_ELEMENT_ID, true); } // TODO: After XMI tab is not forced disabled, this should default to // true - if (pref.get("tab-form-search-show", null) == null) { //$NON-NLS-1$ - pref.putBoolean("tab-form-search-show", false); //$NON-NLS-1$ + if (pref.get(ModelEditorPreferences.TAB_FORM_SEARCH_SHOW, null) == null) { + pref.putBoolean(ModelEditorPreferences.TAB_FORM_SEARCH_SHOW, false); } - if (pref.get("list-tab-remember-filters", null) == null) { //$NON-NLS-1$ - pref.putBoolean("list-tab-remember-filters", false); //$NON-NLS-1$ + if (pref.get(ModelEditorPreferences.LIST_TAB_REMEMBER_FILTERS, null) == null) { + pref.putBoolean(ModelEditorPreferences.LIST_TAB_REMEMBER_FILTERS, false); } - if (pref.get("list-tab-remember-columns", null) == null) { //$NON-NLS-1$ - pref.putBoolean("list-tab-remember-columns", false); //$NON-NLS-1$ + if (pref.get(ModelEditorPreferences.LIST_TAB_REMEMBER_COLUMNS, null) == null) { + pref.putBoolean(ModelEditorPreferences.LIST_TAB_REMEMBER_COLUMNS, false); } } diff --git a/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/ModelEditor.java b/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/ModelEditor.java index 7cd44ab4..ea1d5ecb 100644 --- a/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/ModelEditor.java +++ b/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/ModelEditor.java @@ -60,11 +60,12 @@ import org.eclipse.e4.tools.emf.ui.common.IModelExtractor; import org.eclipse.e4.tools.emf.ui.common.IModelResource; import org.eclipse.e4.tools.emf.ui.common.IScriptingSupport; import org.eclipse.e4.tools.emf.ui.common.MemoryTransfer; +import org.eclipse.e4.tools.emf.ui.common.ModelEditorPreferences; +import org.eclipse.e4.tools.emf.ui.common.Plugin; import org.eclipse.e4.tools.emf.ui.common.Util; import org.eclipse.e4.tools.emf.ui.common.component.AbstractComponentEditor; import org.eclipse.e4.tools.emf.ui.internal.Messages; import org.eclipse.e4.tools.emf.ui.internal.PatternFilter; -import org.eclipse.e4.tools.emf.ui.internal.Plugin; import org.eclipse.e4.tools.emf.ui.internal.ResourceProvider; import org.eclipse.e4.tools.emf.ui.internal.common.component.AddonsEditor; import org.eclipse.e4.tools.emf.ui.internal.common.component.ApplicationEditor; @@ -292,11 +293,11 @@ public class ModelEditor implements IGotoObject { private IClipboardService clipboardService; @Inject - @Preference(nodePath = Plugin.ID, value = "autoCreateElementId") + @Preference(nodePath = Plugin.ID, value = ModelEditorPreferences.AUTO_CREATE_ELEMENT_ID) private boolean autoCreateElementId; @Inject - @Preference(nodePath = Plugin.ID, value = "showXMIId") + @Preference(nodePath = Plugin.ID, value = ModelEditorPreferences.SHOW_XMI_ID) private boolean showXMIId; @Inject @@ -1042,7 +1043,7 @@ public class ModelEditor implements IGotoObject { TreeViewer tempViewer = null; String property = System.getProperty(ORG_ECLIPSE_E4_TOOLS_MODELEDITOR_FILTEREDTREE_ENABLED_XMITAB_DISABLED); - if (property != null || preferences.getBoolean("tab-form-search-show", false)) { //$NON-NLS-1$ + if (property != null || preferences.getBoolean(ModelEditorPreferences.TAB_FORM_SEARCH_SHOW, false)) { //$NON-NLS-1$ FilteredTree viewParent = new FilteredTree(treeArea, SWT.MULTI | SWT.FULL_SELECTION | SWT.H_SCROLL | SWT.V_SCROLL, new PatternFilter(), false); tempViewer = viewParent.getViewer(); } else { @@ -1309,7 +1310,7 @@ public class ModelEditor implements IGotoObject { } @Inject - public void setNotVisibleColor(@Preference("notVisibleColor") String color) { + public void setNotVisibleColor(@Preference(ModelEditorPreferences.NOT_VISIBLE_COLOR) String color) { RGB current = JFaceResources.getColorRegistry().getRGB(ComponentLabelProvider.NOT_VISIBLE_KEY); if (current == null || !current.equals(color)) { @@ -1323,7 +1324,7 @@ public class ModelEditor implements IGotoObject { } @Inject - public void setNotRenderedColor(@Preference("notRenderedColor") String color) { + public void setNotRenderedColor(@Preference(ModelEditorPreferences.NOT_RENDERED_COLOR) String color) { RGB current = JFaceResources.getColorRegistry().getRGB(ComponentLabelProvider.NOT_RENDERED_KEY); if (current == null || !current.equals(color)) { @@ -1337,7 +1338,7 @@ public class ModelEditor implements IGotoObject { } @Inject - public void setNotVisibleRenderedColor(@Preference("notVisibleAndRenderedColor") String color) { + public void setNotVisibleRenderedColor(@Preference(ModelEditorPreferences.NOT_VISIBLE_AND_RENDERED_COLOR) String color) { RGB current = JFaceResources.getColorRegistry().getRGB(ComponentLabelProvider.NOT_VISIBLE_AND_RENDERED_KEY); if (current == null || !current.equals(color)) { diff --git a/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/component/KeyBindingEditor.java b/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/component/KeyBindingEditor.java index e20b77db..79c3ec80 100644 --- a/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/component/KeyBindingEditor.java +++ b/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/component/KeyBindingEditor.java @@ -12,6 +12,8 @@ ******************************************************************************/ package org.eclipse.e4.tools.emf.ui.internal.common.component; +import org.eclipse.e4.tools.emf.ui.common.Plugin; + import java.util.ArrayList; import java.util.Arrays; import java.util.List; @@ -28,7 +30,6 @@ import org.eclipse.e4.tools.emf.ui.common.CommandToStringConverter; import org.eclipse.e4.tools.emf.ui.common.IModelResource; import org.eclipse.e4.tools.emf.ui.common.Util; import org.eclipse.e4.tools.emf.ui.common.component.AbstractComponentEditor; -import org.eclipse.e4.tools.emf.ui.internal.Plugin; import org.eclipse.e4.tools.emf.ui.internal.ResourceProvider; import org.eclipse.e4.tools.emf.ui.internal.common.AbstractPickList.PickListFeatures; import org.eclipse.e4.tools.emf.ui.internal.common.E4PickList; diff --git a/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/component/dialogs/SaveDialogBoundsSettingsDialog.java b/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/component/dialogs/SaveDialogBoundsSettingsDialog.java index 37f9dc2e..a0257e2c 100644 --- a/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/component/dialogs/SaveDialogBoundsSettingsDialog.java +++ b/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/component/dialogs/SaveDialogBoundsSettingsDialog.java @@ -11,8 +11,9 @@ *******************************************************************************/ package org.eclipse.e4.tools.emf.ui.internal.common.component.dialogs; +import org.eclipse.e4.tools.emf.ui.common.Plugin; + import org.eclipse.core.runtime.preferences.InstanceScope; -import org.eclipse.e4.tools.emf.ui.internal.Plugin; import org.eclipse.jface.dialogs.DialogSettings; import org.eclipse.jface.dialogs.IDialogSettings; import org.eclipse.jface.dialogs.TitleAreaDialog; diff --git a/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/component/tabs/ListTab.java b/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/component/tabs/ListTab.java index afcf8a86..43b5a992 100644 --- a/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/component/tabs/ListTab.java +++ b/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/component/tabs/ListTab.java @@ -41,8 +41,9 @@ import org.eclipse.core.runtime.preferences.InstanceScope; import org.eclipse.e4.core.contexts.IEclipseContext; import org.eclipse.e4.core.services.nls.Translation; import org.eclipse.e4.tools.emf.ui.common.IModelResource; +import org.eclipse.e4.tools.emf.ui.common.ModelEditorPreferences; +import org.eclipse.e4.tools.emf.ui.common.Plugin; import org.eclipse.e4.tools.emf.ui.internal.Messages; -import org.eclipse.e4.tools.emf.ui.internal.Plugin; import org.eclipse.e4.tools.emf.ui.internal.ResourceProvider; import org.eclipse.e4.tools.emf.ui.internal.common.ModelEditor; import org.eclipse.e4.tools.emf.ui.internal.common.component.dialogs.BundleImageCache; @@ -239,8 +240,8 @@ public class ListTab implements IViewEObjects { private void loadSettings() { IEclipsePreferences pref = InstanceScope.INSTANCE.getNode(Plugin.ID); - boolean restoreColumns = pref.getBoolean("list-tab-remember-columns", false); //$NON-NLS-1$ - boolean restoreFilters = pref.getBoolean("list-tab-remember-filters", false); //$NON-NLS-1$ + boolean restoreColumns = pref.getBoolean(ModelEditorPreferences.LIST_TAB_REMEMBER_COLUMNS, false); + boolean restoreFilters = pref.getBoolean(ModelEditorPreferences.LIST_TAB_REMEMBER_FILTERS, false); if (!restoreColumns && !restoreFilters) { return; } diff --git a/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/resourcelocator/dialogs/NonReferencedActionPage.java b/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/resourcelocator/dialogs/NonReferencedActionPage.java index c2a71fb4..fedab5d7 100644 --- a/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/resourcelocator/dialogs/NonReferencedActionPage.java +++ b/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/resourcelocator/dialogs/NonReferencedActionPage.java @@ -11,6 +11,8 @@ package org.eclipse.e4.tools.emf.ui.internal.common.resourcelocator.dialogs; +import org.eclipse.e4.tools.emf.ui.common.Plugin; + import java.io.BufferedInputStream; import java.io.ByteArrayInputStream; import java.io.ByteArrayOutputStream; @@ -26,7 +28,6 @@ import org.eclipse.core.runtime.IPath; import org.eclipse.core.runtime.Path; import org.eclipse.e4.core.contexts.IEclipseContext; import org.eclipse.e4.tools.emf.ui.common.IClassContributionProvider.ContributionData; -import org.eclipse.e4.tools.emf.ui.internal.Plugin; import org.eclipse.e4.tools.emf.ui.internal.ResourceProvider; import org.eclipse.e4.tools.emf.ui.internal.common.component.dialogs.BundleImageCache; import org.eclipse.e4.tools.emf.ui.internal.common.component.dialogs.ContributionDataFile; diff --git a/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/resourcelocator/dialogs/NonReferencedResourceDialog.java b/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/resourcelocator/dialogs/NonReferencedResourceDialog.java index fde88603..410ed63d 100644 --- a/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/resourcelocator/dialogs/NonReferencedResourceDialog.java +++ b/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/resourcelocator/dialogs/NonReferencedResourceDialog.java @@ -11,6 +11,8 @@ package org.eclipse.e4.tools.emf.ui.internal.common.resourcelocator.dialogs; +import org.eclipse.e4.tools.emf.ui.common.Plugin; + import java.io.BufferedInputStream; import java.io.ByteArrayInputStream; import java.io.ByteArrayOutputStream; @@ -26,7 +28,6 @@ import org.eclipse.core.runtime.IPath; import org.eclipse.core.runtime.Path; import org.eclipse.e4.core.contexts.IEclipseContext; import org.eclipse.e4.tools.emf.ui.common.IClassContributionProvider.ContributionData; -import org.eclipse.e4.tools.emf.ui.internal.Plugin; import org.eclipse.e4.tools.emf.ui.internal.ResourceProvider; import org.eclipse.e4.tools.emf.ui.internal.common.component.dialogs.BundleImageCache; import org.eclipse.e4.tools.emf.ui.internal.common.component.dialogs.ContributionDataFile; |