Author: dazarov
Date: 2009-11-08 04:05:05 -0500 (Sun, 08 Nov 2009)
New Revision: 18479
Removed:
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/Messages.java
Modified:
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/ModelUIMessages.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/CommandBar.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/MutableMultipleChoiceFieldEditor.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/editor/HiddenPaletteTabsWizardView.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/AbstractQueryWizardView.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/list/HiddenFileSystemsWizardView.java
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/BundleLanguagesEditor.java
Log:
https://jira.jboss.org/jira/browse/JBIDE-5169
Deleted:
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/Messages.java
===================================================================
---
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/Messages.java 2009-11-07
22:22:49 UTC (rev 18478)
+++
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/Messages.java 2009-11-08
09:05:05 UTC (rev 18479)
@@ -1,33 +0,0 @@
-package org.jboss.tools.common.model.ui;
-
-import org.eclipse.osgi.util.NLS;
-
-public class Messages extends NLS {
- private static final String BUNDLE_NAME =
"org.jboss.tools.common.model.ui.messages"; //$NON-NLS-1$
- public static String AbstractQueryWizardView_Cancel;
- public static String AbstractQueryWizardView_Close;
- public static String AbstractQueryWizardView_Help;
- public static String AbstractQueryWizardView_OK;
- public static String BundleLanguagesEditor_Add;
- public static String BundleLanguagesEditor_Delete;
- public static String BundleLanguagesEditor_LanguageCountry;
- public static String CommandBar_Finish;
- public static String CommandBar_Next;
- public static String CommandBar_NextArrow;
- public static String CommandBar_OK;
- public static String CommandBar_Run;
- public static String HiddenFileSystemsWizardView_HideAllJars;
- public static String HiddenFileSystemsWizardView_ShowAllJars;
- public static String HiddenPaletteTabsWizardView_HideAll;
- public static String HiddenPaletteTabsWizardView_ShowAll;
- public static String MutableMultipleChoiceFieldEditor_DeselectAll;
- public static String MutableMultipleChoiceFieldEditor_New;
- public static String MutableMultipleChoiceFieldEditor_SelectAll;
- static {
- // initialize resource bundle
- NLS.initializeMessages(BUNDLE_NAME, Messages.class);
- }
-
- private Messages() {
- }
-}
Modified:
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/ModelUIMessages.java
===================================================================
---
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/ModelUIMessages.java 2009-11-07
22:22:49 UTC (rev 18478)
+++
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/ModelUIMessages.java 2009-11-08
09:05:05 UTC (rev 18479)
@@ -50,7 +50,29 @@
public static String Editor_Delete_description;
public static String MainPreferencePage_Description;
public static String Form_CANNOT_LOAD_ATTRIBUTE;
+
+ public static String AbstractQueryWizardView_Cancel;
+ public static String AbstractQueryWizardView_Close;
+ public static String AbstractQueryWizardView_Help;
+ public static String AbstractQueryWizardView_OK;
+ public static String BundleLanguagesEditor_Add;
+ public static String BundleLanguagesEditor_Delete;
+ public static String BundleLanguagesEditor_LanguageCountry;
+ public static String CommandBar_Finish;
+ public static String CommandBar_Next;
+ public static String CommandBar_NextArrow;
+ public static String CommandBar_OK;
+ public static String CommandBar_Run;
+ public static String HiddenFileSystemsWizardView_HideAllJars;
+ public static String HiddenFileSystemsWizardView_ShowAllJars;
+ public static String HiddenPaletteTabsWizardView_HideAll;
+ public static String HiddenPaletteTabsWizardView_ShowAll;
+ public static String MutableMultipleChoiceFieldEditor_DeselectAll;
+ public static String MutableMultipleChoiceFieldEditor_New;
+ public static String MutableMultipleChoiceFieldEditor_SelectAll;
+
+
static {
NLS.initializeMessages(BUNDLE_NAME, ModelUIMessages.class);
}
Modified:
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/CommandBar.java
===================================================================
---
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/CommandBar.java 2009-11-07
22:22:49 UTC (rev 18478)
+++
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/action/CommandBar.java 2009-11-08
09:05:05 UTC (rev 18479)
@@ -10,14 +10,22 @@
******************************************************************************/
package org.jboss.tools.common.model.ui.action;
-import java.util.*;
-import org.eclipse.swt.*;
-import org.eclipse.swt.events.*;
-import org.eclipse.swt.widgets.*;
-import org.eclipse.swt.graphics.*;
+import java.util.ArrayList;
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.events.SelectionEvent;
+import org.eclipse.swt.events.SelectionListener;
+import org.eclipse.swt.graphics.Color;
+import org.eclipse.swt.graphics.Font;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.swt.widgets.Button;
+import org.eclipse.swt.widgets.Composite;
+import org.eclipse.swt.widgets.Control;
+import org.eclipse.swt.widgets.ToolBar;
+import org.eclipse.swt.widgets.ToolItem;
+import org.eclipse.swt.widgets.Widget;
import org.jboss.tools.common.model.XModelException;
-import org.jboss.tools.common.model.ui.Messages;
+import org.jboss.tools.common.model.ui.ModelUIMessages;
import org.jboss.tools.common.model.ui.ModelUIPlugin;
import org.jboss.tools.common.model.ui.widgets.IWidgetSettings;
@@ -90,11 +98,11 @@
}
d.command = commands[i];
// bugfix:Issue # 6167. Try find default button by name
- if (Messages.CommandBar_OK.equalsIgnoreCase(commands[i]) ||
- Messages.CommandBar_Finish.equalsIgnoreCase(commands[i]) ||
- Messages.CommandBar_Next.equalsIgnoreCase(commands[i])||
- Messages.CommandBar_NextArrow.equalsIgnoreCase(commands[i]) ||
- Messages.CommandBar_Run.equalsIgnoreCase(commands[i])) {
+ if (ModelUIMessages.CommandBar_OK.equalsIgnoreCase(commands[i]) ||
+ ModelUIMessages.CommandBar_Finish.equalsIgnoreCase(commands[i]) ||
+ ModelUIMessages.CommandBar_Next.equalsIgnoreCase(commands[i])||
+ ModelUIMessages.CommandBar_NextArrow.equalsIgnoreCase(commands[i]) ||
+ ModelUIMessages.CommandBar_Run.equalsIgnoreCase(commands[i])) {
this.defaultCommand = commands[i];
}
}
Modified:
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/MutableMultipleChoiceFieldEditor.java
===================================================================
---
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/MutableMultipleChoiceFieldEditor.java 2009-11-07
22:22:49 UTC (rev 18478)
+++
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/MutableMultipleChoiceFieldEditor.java 2009-11-08
09:05:05 UTC (rev 18479)
@@ -12,8 +12,6 @@
import java.util.Properties;
-import org.jboss.tools.common.model.ui.Messages;
-import org.jboss.tools.common.model.ui.action.*;
import org.eclipse.swt.SWT;
import org.eclipse.swt.layout.GridData;
import org.eclipse.swt.layout.GridLayout;
@@ -21,12 +19,15 @@
import org.eclipse.swt.widgets.Control;
import org.eclipse.swt.widgets.Label;
import org.jboss.tools.common.meta.action.SpecialWizard;
+import org.jboss.tools.common.model.ui.ModelUIMessages;
+import org.jboss.tools.common.model.ui.action.CommandBar;
+import org.jboss.tools.common.model.ui.action.CommandBarListener;
import org.jboss.tools.common.model.ui.widgets.IWidgetSettings;
public class MutableMultipleChoiceFieldEditor extends MultipleChoiceFieldEditor
implements CommandBarListener, IMutableFieldEditor {
- static String NEW = Messages.MutableMultipleChoiceFieldEditor_New;
- static String SELECT_ALL = Messages.MutableMultipleChoiceFieldEditor_SelectAll;
- static String DESELECT_ALL = Messages.MutableMultipleChoiceFieldEditor_DeselectAll;
+ static String NEW = ModelUIMessages.MutableMultipleChoiceFieldEditor_New;
+ static String SELECT_ALL = ModelUIMessages.MutableMultipleChoiceFieldEditor_SelectAll;
+ static String DESELECT_ALL =
ModelUIMessages.MutableMultipleChoiceFieldEditor_DeselectAll;
CommandBar bar = new CommandBar();
String[] commands = {NEW, SELECT_ALL, DESELECT_ALL};
Modified:
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/editor/HiddenPaletteTabsWizardView.java
===================================================================
---
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/editor/HiddenPaletteTabsWizardView.java 2009-11-07
22:22:49 UTC (rev 18478)
+++
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/views/palette/editor/HiddenPaletteTabsWizardView.java 2009-11-08
09:05:05 UTC (rev 18479)
@@ -10,7 +10,7 @@
******************************************************************************/
package org.jboss.tools.common.model.ui.views.palette.editor;
-import org.jboss.tools.common.model.ui.Messages;
+import org.jboss.tools.common.model.ui.ModelUIMessages;
import org.jboss.tools.common.model.ui.wizards.query.list.AbstractTreeWizardView;
public class HiddenPaletteTabsWizardView extends AbstractTreeWizardView {
@@ -19,13 +19,13 @@
}
protected String[] getActions() {
- return new String[]{Messages.HiddenPaletteTabsWizardView_ShowAll,
Messages.HiddenPaletteTabsWizardView_HideAll};
+ return new String[]{ModelUIMessages.HiddenPaletteTabsWizardView_ShowAll,
ModelUIMessages.HiddenPaletteTabsWizardView_HideAll};
}
protected void internalAction(String command) {
- if(Messages.HiddenPaletteTabsWizardView_HideAll.equals(command)) {
+ if(ModelUIMessages.HiddenPaletteTabsWizardView_HideAll.equals(command)) {
disableAll();
- } else if(Messages.HiddenPaletteTabsWizardView_ShowAll.equals(command)) {
+ } else if(ModelUIMessages.HiddenPaletteTabsWizardView_ShowAll.equals(command)) {
enableAll();
}
}
Modified:
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/AbstractQueryWizardView.java
===================================================================
---
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/AbstractQueryWizardView.java 2009-11-07
22:22:49 UTC (rev 18478)
+++
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/AbstractQueryWizardView.java 2009-11-08
09:05:05 UTC (rev 18479)
@@ -24,10 +24,10 @@
import org.jboss.tools.common.model.ui.*;
public abstract class AbstractQueryWizardView implements CommandBarListener {
- public static String CANCEL = Messages.AbstractQueryWizardView_Cancel;
- public static String CLOSE = Messages.AbstractQueryWizardView_Close;
- public static String OK = Messages.AbstractQueryWizardView_OK;
- public static String HELP = Messages.AbstractQueryWizardView_Help;
+ public static String CANCEL = ModelUIMessages.AbstractQueryWizardView_Cancel;
+ public static String CLOSE = ModelUIMessages.AbstractQueryWizardView_Close;
+ public static String OK = ModelUIMessages.AbstractQueryWizardView_OK;
+ public static String HELP = ModelUIMessages.AbstractQueryWizardView_Help;
private String helpkey = null;
private Dialog dialog;
private TitleAreaDialog titleDialog = null;
Modified:
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/list/HiddenFileSystemsWizardView.java
===================================================================
---
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/list/HiddenFileSystemsWizardView.java 2009-11-07
22:22:49 UTC (rev 18478)
+++
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/wizards/query/list/HiddenFileSystemsWizardView.java 2009-11-08
09:05:05 UTC (rev 18479)
@@ -11,7 +11,7 @@
package org.jboss.tools.common.model.ui.wizards.query.list;
import org.jboss.tools.common.meta.key.WizardKeys;
-import org.jboss.tools.common.model.ui.Messages;
+import org.jboss.tools.common.model.ui.ModelUIMessages;
public class HiddenFileSystemsWizardView extends AbstractListWizardView {
public HiddenFileSystemsWizardView() {
@@ -22,17 +22,17 @@
}
protected String[] getActions() {
- return new String[]{Messages.HiddenFileSystemsWizardView_HideAllJars,
Messages.HiddenFileSystemsWizardView_ShowAllJars};
+ return new String[]{ModelUIMessages.HiddenFileSystemsWizardView_HideAllJars,
ModelUIMessages.HiddenFileSystemsWizardView_ShowAllJars};
}
protected void internalAction(String command) {
- if(Messages.HiddenFileSystemsWizardView_HideAllJars.equals(command)) {
+ if(ModelUIMessages.HiddenFileSystemsWizardView_HideAllJars.equals(command)) {
for (int i = 0; i < boxes.length; i++)
if("true".equals(vs[i][2])) { //$NON-NLS-1$
boxes[i].setSelection(false);
apply(i);
}
- } else if(Messages.HiddenFileSystemsWizardView_ShowAllJars.equals(command)) {
+ } else if(ModelUIMessages.HiddenFileSystemsWizardView_ShowAllJars.equals(command)) {
for (int i = 0; i < boxes.length; i++)
if("true".equals(vs[i][2])) { //$NON-NLS-1$
boxes[i].setSelection(true);
Modified:
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/BundleLanguagesEditor.java
===================================================================
---
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/BundleLanguagesEditor.java 2009-11-07
22:22:49 UTC (rev 18478)
+++
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/propertieseditor/BundleLanguagesEditor.java 2009-11-08
09:05:05 UTC (rev 18479)
@@ -10,24 +10,30 @@
******************************************************************************/
package org.jboss.tools.common.propertieseditor;
-import java.util.*;
+import java.util.ArrayList;
+
import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.*;
+import org.eclipse.swt.events.SelectionEvent;
+import org.eclipse.swt.events.SelectionListener;
import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.*;
-import org.eclipse.swt.widgets.*;
-import org.jboss.tools.common.propertieseditor.bundlemodel.*;
-import org.jboss.tools.common.model.ui.Messages;
-import org.jboss.tools.common.model.ui.action.*;
-
+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.eclipse.swt.widgets.Label;
import org.jboss.tools.common.meta.action.XActionInvoker;
import org.jboss.tools.common.model.XModelObject;
import org.jboss.tools.common.model.impl.bundle.CountriesHelper;
+import org.jboss.tools.common.model.ui.ModelUIMessages;
+import org.jboss.tools.common.model.ui.action.CommandBar;
+import org.jboss.tools.common.model.ui.action.CommandBarLayout;
+import org.jboss.tools.common.model.ui.action.CommandBarListener;
import org.jboss.tools.common.model.util.EclipseResourceUtil;
+import org.jboss.tools.common.propertieseditor.bundlemodel.BundleModel;
public class BundleLanguagesEditor implements CommandBarListener, SelectionListener {
- static String CREATE = Messages.BundleLanguagesEditor_Add;
- static String DELETE = Messages.BundleLanguagesEditor_Delete;
+ static String CREATE = ModelUIMessages.BundleLanguagesEditor_Add;
+ static String DELETE = ModelUIMessages.BundleLanguagesEditor_Delete;
public Image IMAGE_DELETE =
EclipseResourceUtil.getImage("images/actions/delete.gif"); //$NON-NLS-1$
public Image IMAGE_EDIT =
EclipseResourceUtil.getImage("images/actions/edit.gif"); //$NON-NLS-1$
public Image IMAGE_CREATE =
EclipseResourceUtil.getImage("images/actions/new.gif"); //$NON-NLS-1$
@@ -66,7 +72,7 @@
Composite control = new Composite(parent, SWT.NONE);
control.setLayout(new GridLayout(2, false));
Label label = new Label(control, SWT.NONE);
- label.setText(Messages.BundleLanguagesEditor_LanguageCountry);
+ label.setText(ModelUIMessages.BundleLanguagesEditor_LanguageCountry);
combo = new Combo(control, SWT.DROP_DOWN | SWT.READ_ONLY);
combomodel.setCombo(combo);
update();