Author: adietish
Date: 2011-03-14 05:34:39 -0400 (Mon, 14 Mar 2011)
New Revision: 29745
Modified:
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/EditCloudConnectionWizard.java
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/FindImageWizard.java
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/ImageFilterWizard.java
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/InstanceFilterWizard.java
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/ManageKeysWizard.java
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/NewCloudConnectionWizard.java
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/NewInstancePage.java
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/NewInstanceWizard.java
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/WizardMessages.properties
Log:
[JBIDE-8090] set window titles to wizards
Modified:
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/EditCloudConnectionWizard.java
===================================================================
---
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/EditCloudConnectionWizard.java 2011-03-14
09:28:15 UTC (rev 29744)
+++
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/EditCloudConnectionWizard.java 2011-03-14
09:34:39 UTC (rev 29745)
@@ -12,6 +12,8 @@
import java.text.MessageFormat;
+import org.eclipse.jface.viewers.IStructuredSelection;
+import org.eclipse.ui.IWorkbench;
import org.jboss.tools.deltacloud.core.DeltaCloud;
import org.jboss.tools.deltacloud.core.Driver;
import org.jboss.tools.deltacloud.ui.ErrorUtils;
@@ -29,6 +31,11 @@
}
@Override
+ public void init(IWorkbench workbench, IStructuredSelection selection) {
+ setWindowTitle(WizardMessages.getString(MAINPAGE_NAME));
+ }
+
+ @Override
public boolean performFinish() {
String name = mainPage.getModel().getName();
String url = mainPage.getModel().getUrl();
Modified:
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/FindImageWizard.java
===================================================================
---
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/FindImageWizard.java 2011-03-14
09:28:15 UTC (rev 29744)
+++
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/FindImageWizard.java 2011-03-14
09:34:39 UTC (rev 29745)
@@ -32,6 +32,7 @@
@Override
public void addPages() {
+ setWindowTitle(WizardMessages.getString("FindImage.title"));
mainPage = new FindImagePage(cloud);
addPage(mainPage);
}
Modified:
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/ImageFilterWizard.java
===================================================================
---
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/ImageFilterWizard.java 2011-03-14
09:28:15 UTC (rev 29744)
+++
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/ImageFilterWizard.java 2011-03-14
09:34:39 UTC (rev 29745)
@@ -28,7 +28,7 @@
@Override
public void addPages() {
- // TODO Auto-generated method stub
+ setWindowTitle(WizardMessages.getString("ImageFilter.title"));
mainPage = new ImageFilterPage(cloud);
addPage(mainPage);
}
Modified:
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/InstanceFilterWizard.java
===================================================================
---
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/InstanceFilterWizard.java 2011-03-14
09:28:15 UTC (rev 29744)
+++
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/InstanceFilterWizard.java 2011-03-14
09:34:39 UTC (rev 29745)
@@ -29,6 +29,7 @@
@Override
public void addPages() {
+ setWindowTitle(WizardMessages.getString("InstanceFilter.title"));
mainPage = new InstanceFilterPage(cloud);
addPage(mainPage);
}
Modified:
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/ManageKeysWizard.java
===================================================================
---
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/ManageKeysWizard.java 2011-03-14
09:28:15 UTC (rev 29744)
+++
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/ManageKeysWizard.java 2011-03-14
09:34:39 UTC (rev 29745)
@@ -34,6 +34,7 @@
@Override
public void addPages() {
+ setWindowTitle(WizardMessages.getString("ManageKeys.title"));
mainPage = new ManageKeysPage(cloud);
addPage(mainPage);
}
Modified:
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/NewCloudConnectionWizard.java
===================================================================
---
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/NewCloudConnectionWizard.java 2011-03-14
09:28:15 UTC (rev 29744)
+++
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/NewCloudConnectionWizard.java 2011-03-14
09:34:39 UTC (rev 29745)
@@ -66,6 +66,7 @@
@Override
public void init(IWorkbench workbench, IStructuredSelection selection) {
+ setWindowTitle(WizardMessages.getString("NewCloudConnection.name"));
}
@Override
Modified:
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/NewInstancePage.java
===================================================================
---
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/NewInstancePage.java 2011-03-14
09:28:15 UTC (rev 29744)
+++
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/NewInstancePage.java 2011-03-14
09:34:39 UTC (rev 29745)
@@ -44,6 +44,7 @@
import org.eclipse.jface.dialogs.IDialogConstants;
import org.eclipse.jface.layout.GridDataFactory;
import org.eclipse.jface.layout.GridLayoutFactory;
+import org.eclipse.jface.preference.PreferenceDialog;
import org.eclipse.jface.wizard.WizardDialog;
import org.eclipse.jface.wizard.WizardPage;
import org.eclipse.swt.SWT;
@@ -54,10 +55,14 @@
import org.eclipse.swt.widgets.Button;
import org.eclipse.swt.widgets.Combo;
import org.eclipse.swt.widgets.Composite;
+import org.eclipse.swt.widgets.Event;
import org.eclipse.swt.widgets.Group;
import org.eclipse.swt.widgets.Label;
+import org.eclipse.swt.widgets.Link;
+import org.eclipse.swt.widgets.Listener;
import org.eclipse.swt.widgets.Shell;
import org.eclipse.swt.widgets.Text;
+import org.eclipse.ui.dialogs.PreferencesUtil;
import org.jboss.tools.common.log.StatusFactory;
import org.jboss.tools.deltacloud.core.DeltaCloud;
import org.jboss.tools.deltacloud.core.DeltaCloudException;
@@ -79,6 +84,8 @@
*/
public class NewInstancePage extends WizardPage {
+ private static final String SSH_PREFERENCE_PAGE_ID =
"org.eclipse.jsch.ui.SSHPreferences";
+
private static final int IMAGE_CHECK_DELAY = 500;
private static final int KEY_CHECK_DELAY = 500;
@@ -100,6 +107,7 @@
private static final String MUST_ENTER_IMAGE_ID =
"ErrorMustProvideImageId.text"; //$NON-NLS-1$
private static final String LOADING_VALUE = "Loading.value"; //$NON-NLS-1$
private static final String IMAGE_ID_NOT_FOUND = "ErrorImageIdNotFound.text";
//$NON-NLS-1$
+ private static final String SSH2_PREF_KEYS = "ShowSSH2Preferences.label";
//$NON-NLS-1$
private Composite container;
private NewInstancePageModel model;
@@ -211,6 +219,23 @@
keyManageButton.addSelectionListener(manageListener);
GridDataFactory.fillDefaults().align(SWT.FILL, SWT.CENTER).applyTo(keyManageButton);
+ Label dummyLabel = new Label(container, SWT.NULL);
+ dummyLabel.setVisible(false);
+ GridDataFactory.fillDefaults().align(SWT.LEFT, SWT.CENTER).applyTo(dummyLabel);
+
+ Link sshPrefsLink = new Link(container, SWT.NULL);
+ sshPrefsLink.setText(WizardMessages.getString(SSH2_PREF_KEYS));
+ sshPrefsLink.addListener(SWT.Selection, new Listener() {
+
+ @Override
+ public void handleEvent(Event event) {
+ PreferenceDialog dialog = PreferencesUtil.createPreferenceDialogOn(
+ event.display.getActiveShell(), SSH_PREFERENCE_PAGE_ID, null, null);
+ dialog.open();
+ }
+ });
+ GridDataFactory.fillDefaults().align(SWT.FILL, SWT.CENTER).span(2,
1).applyTo(sshPrefsLink);
+
Label hardwareLabel = new Label(container, SWT.NULL);
hardwareLabel.setText(WizardMessages.getString(HARDWARE_LABEL));
GridDataFactory.fillDefaults().align(SWT.LEFT, SWT.CENTER).applyTo(hardwareLabel);
Modified:
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/NewInstanceWizard.java
===================================================================
---
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/NewInstanceWizard.java 2011-03-14
09:28:15 UTC (rev 29744)
+++
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/NewInstanceWizard.java 2011-03-14
09:34:39 UTC (rev 29745)
@@ -66,6 +66,7 @@
@Override
public void addPages() {
+ setWindowTitle(WizardMessages.getString("NewInstance.title"));
mainPage = new NewInstancePage(cloud, image);
addPage(mainPage);
additionalPages =
DeltacloudUIExtensionManager.getDefault().loadNewInstanceWizardPages();
@@ -128,7 +129,7 @@
private void scheduleJobs() {
ChainedJob first =
new InstanceStateJob(
- WizardMessages.getFormattedString(STARTING_INSTANCE_TITLE, instance.getName()),
+ WizardMessages.getFormattedString(STARTING_INSTANCE_TITLE, instance.getAlias()),
instance,
DeltaCloudInstance.State.RUNNING);
first.setUser(true);
Modified:
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/WizardMessages.properties
===================================================================
---
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/WizardMessages.properties 2011-03-14
09:28:15 UTC (rev 29744)
+++
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/internal/deltacloud/ui/wizards/WizardMessages.properties 2011-03-14
09:34:39 UTC (rev 29745)
@@ -15,6 +15,7 @@
CloudConnectionTestFailure.msg=Connection Test failed
CloudConnectionTestingCredentials.msg=Testing credentials...
CloudConnectionInvalidCredentials.msg=Invalid credentials
+NewCloudConnection.name=New Cloud Connection
EditCloudConnection.name=Edit Cloud Connection
EditCloudConnectionError.title=Error Editing Cloud Connection
@@ -83,6 +84,7 @@
ErrorMustProvideName.text=A name must be specified
ErrorMustProvideKeyName.text=A key name must be specified
ErrorMustProvideImageId.text=An image id must be specified
+ShowSSH2Preferences.label=<a>Show Private Keys in preferences</a>
NewInstance.desc=Specify details for a new instance you wish to launch based on an image
NewInstance.title=Launch Instance
@@ -120,6 +122,6 @@
ConfirmKeyDelete.title=Confirm Key Delete
ConfirmKeyDelete.msg=Confirm deletion of key: {0}
-StartingInstance.title=Starting Instance
+StartingInstance.title=Starting Instance {0}
StartingInstance.msg=Starting Instance: {0}
ConnectingRSE.msg=Connecting instance as: {0}