debuggercdi/com.nokia.cdt.debug.launch/src/com/nokia/cdt/internal/debug/launch/newwizard/ConnectToDeviceDialog.java
author dadubrow
Wed, 20 Oct 2010 09:35:54 -0500
changeset 2163 f0a9f2d04d4a
parent 2038 dd457404f42f
permissions -rw-r--r--
Refactor data model for new launch wizard
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
     1
/*
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
     2
* Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
     3
* All rights reserved.
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
     4
* This component and the accompanying materials are made available
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
     5
* under the terms of the License "Eclipse Public License v1.0"
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
     6
* which accompanies this distribution, and is available
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
     7
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
     8
*
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
     9
* Initial Contributors:
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    10
* Nokia Corporation - initial contribution.
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    11
*
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    12
* Contributors:
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    13
*
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    14
* Description: 
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    15
*
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    16
*/
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    17
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    18
package com.nokia.cdt.internal.debug.launch.newwizard;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    19
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    20
import java.text.MessageFormat;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    21
import java.util.ArrayList;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    22
import java.util.Collection;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    23
import java.util.HashSet;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    24
import java.util.List;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    25
import java.util.Set;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    26
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    27
import org.eclipse.core.runtime.IStatus;
964
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
    28
import org.eclipse.jface.dialogs.Dialog;
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
    29
import org.eclipse.jface.dialogs.IDialogConstants;
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    30
import org.eclipse.jface.layout.GridDataFactory;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    31
import org.eclipse.jface.layout.GridLayoutFactory;
964
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
    32
import org.eclipse.jface.resource.JFaceResources;
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    33
import org.eclipse.jface.viewers.ArrayContentProvider;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    34
import org.eclipse.jface.viewers.ComboViewer;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    35
import org.eclipse.jface.viewers.ISelection;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    36
import org.eclipse.jface.viewers.ISelectionChangedListener;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    37
import org.eclipse.jface.viewers.IStructuredSelection;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    38
import org.eclipse.jface.viewers.LabelProvider;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    39
import org.eclipse.jface.viewers.SelectionChangedEvent;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    40
import org.eclipse.jface.viewers.StructuredSelection;
2038
dd457404f42f remove hypertext from other UIs
dadubrow
parents: 1265
diff changeset
    41
import org.eclipse.jface.viewers.StyledString;
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    42
import org.eclipse.swt.SWT;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    43
import org.eclipse.swt.events.ControlAdapter;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    44
import org.eclipse.swt.events.ControlEvent;
1184
745221c781a3 Fix issues not disposing listeners in PNP launch wizard
Ed Swartz <ed.swartz@nokia.com>
parents: 1061
diff changeset
    45
import org.eclipse.swt.events.DisposeEvent;
745221c781a3 Fix issues not disposing listeners in PNP launch wizard
Ed Swartz <ed.swartz@nokia.com>
parents: 1061
diff changeset
    46
import org.eclipse.swt.events.DisposeListener;
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    47
import org.eclipse.swt.events.SelectionAdapter;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    48
import org.eclipse.swt.events.SelectionEvent;
964
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
    49
import org.eclipse.swt.graphics.FontMetrics;
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
    50
import org.eclipse.swt.graphics.GC;
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
    51
import org.eclipse.swt.graphics.Point;
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    52
import org.eclipse.swt.widgets.Button;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    53
import org.eclipse.swt.widgets.Combo;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    54
import org.eclipse.swt.widgets.Composite;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    55
import org.eclipse.swt.widgets.Control;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    56
import org.eclipse.swt.widgets.Display;
964
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
    57
import org.eclipse.swt.widgets.Group;
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    58
import org.eclipse.swt.widgets.Label;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    59
import org.eclipse.swt.widgets.Shell;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    60
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    61
import com.nokia.carbide.remoteconnections.RemoteConnectionsActivator;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    62
import com.nokia.carbide.remoteconnections.interfaces.IConnectedService;
2038
dd457404f42f remove hypertext from other UIs
dadubrow
parents: 1265
diff changeset
    63
import com.nokia.carbide.remoteconnections.interfaces.IConnectedService.IStatusChangedListener;
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    64
import com.nokia.carbide.remoteconnections.interfaces.IConnection;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    65
import com.nokia.carbide.remoteconnections.interfaces.IConnectionType;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    66
import com.nokia.carbide.remoteconnections.interfaces.IConnectionTypeProvider;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    67
import com.nokia.carbide.remoteconnections.interfaces.IConnectionsManager;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    68
import com.nokia.carbide.remoteconnections.interfaces.IConnectionsManager.IConnectionListener;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    69
import com.nokia.carbide.remoteconnections.settings.ui.SettingsWizard;
2038
dd457404f42f remove hypertext from other UIs
dadubrow
parents: 1265
diff changeset
    70
import com.nokia.cpp.internal.api.utils.ui.LinkParser;
dd457404f42f remove hypertext from other UIs
dadubrow
parents: 1265
diff changeset
    71
import com.nokia.cpp.internal.api.utils.ui.LinkParser.Element;
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    72
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    73
/**
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    74
 *	This dialog allows in-depth configuration of the connection settings.
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    75
 */
1061
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
    76
public class ConnectToDeviceDialog extends AbstractLaunchSettingsDialog implements IConnectionListener, IStatusChangedListener {
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    77
	private IConnectionsManager manager;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    78
	private IConnectionTypeProvider typeProvider;
964
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
    79
	private FontMetrics fm;
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    80
	private ComboViewer viewer;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    81
	private Button editButton;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    82
	private Label descriptionLabel;
964
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
    83
	private Button newButton;
1061
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
    84
	private IConnectedService currentServiceListener;
2163
f0a9f2d04d4a Refactor data model for new launch wizard
dadubrow
parents: 2038
diff changeset
    85
	private IConnectionWizardData connectionData;
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    86
2163
f0a9f2d04d4a Refactor data model for new launch wizard
dadubrow
parents: 2038
diff changeset
    87
	protected ConnectToDeviceDialog(Shell shell, IWizardData data) {
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    88
		super(shell, data);
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    89
		manager = RemoteConnectionsActivator.getConnectionsManager();
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    90
		typeProvider = RemoteConnectionsActivator.getConnectionTypeProvider();
2163
f0a9f2d04d4a Refactor data model for new launch wizard
dadubrow
parents: 2038
diff changeset
    91
		connectionData = (IConnectionWizardData) data;
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    92
	}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    93
	
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    94
	@Override
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    95
	protected Control createDialogArea(Composite parent) {
964
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
    96
		initializeDialogUnits(parent);
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    97
		final Composite composite = initDialogArea(parent, 
969
b0dd389735fb externalize strings
dadubrow
parents: 964
diff changeset
    98
				Messages.getString("ConnectToDeviceDialog.Title"), //$NON-NLS-1$
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
    99
				LaunchWizardHelpIds.WIZARD_DIALOG_CHANGE_CONNECTION);
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   100
		
964
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   101
		Group viewerGroup = new Group(composite, SWT.NONE);
969
b0dd389735fb externalize strings
dadubrow
parents: 964
diff changeset
   102
		viewerGroup.setText(Messages.getString("ConnectToDeviceDialog.GroupLabel")); //$NON-NLS-1$
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   103
		GridDataFactory.fillDefaults().applyTo(viewerGroup);
964
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   104
		GridLayoutFactory.swtDefaults().applyTo(viewerGroup);
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   105
		
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   106
		viewer = new ComboViewer(viewerGroup, SWT.READ_ONLY);
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   107
		viewer.setLabelProvider(new LabelProvider() {
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   108
			@Override
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   109
			public String getText(Object element) {
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   110
				if (element instanceof IConnection)
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   111
					return ((IConnection) element).getDisplayName();
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   112
				
969
b0dd389735fb externalize strings
dadubrow
parents: 964
diff changeset
   113
				return Messages.getString("ConnectToDeviceDialog.NoCurrentItem"); //$NON-NLS-1$
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   114
			}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   115
		});
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   116
		viewer.setContentProvider(new ArrayContentProvider());
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   117
		Combo combo = viewer.getCombo();
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   118
		GridDataFactory.defaultsFor(combo).grab(true, false).applyTo(combo);
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   119
		viewer.getControl().setData(UID, "combo_viewer"); //$NON-NLS-1$
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   120
		viewer.addSelectionChangedListener(new ISelectionChangedListener() {
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   121
			public void selectionChanged(SelectionChangedEvent event) {
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   122
				if (getDialogArea() != null)
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   123
					connectionSelected(getConnectionFromSelection(event.getSelection()));
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   124
			}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   125
		});
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   126
		manager.addConnectionListener(this);
1184
745221c781a3 Fix issues not disposing listeners in PNP launch wizard
Ed Swartz <ed.swartz@nokia.com>
parents: 1061
diff changeset
   127
745221c781a3 Fix issues not disposing listeners in PNP launch wizard
Ed Swartz <ed.swartz@nokia.com>
parents: 1061
diff changeset
   128
		parent.addDisposeListener(new DisposeListener() {
745221c781a3 Fix issues not disposing listeners in PNP launch wizard
Ed Swartz <ed.swartz@nokia.com>
parents: 1061
diff changeset
   129
			public void widgetDisposed(DisposeEvent e) {
745221c781a3 Fix issues not disposing listeners in PNP launch wizard
Ed Swartz <ed.swartz@nokia.com>
parents: 1061
diff changeset
   130
				manager.removeConnectionListener(ConnectToDeviceDialog.this);
745221c781a3 Fix issues not disposing listeners in PNP launch wizard
Ed Swartz <ed.swartz@nokia.com>
parents: 1061
diff changeset
   131
				
745221c781a3 Fix issues not disposing listeners in PNP launch wizard
Ed Swartz <ed.swartz@nokia.com>
parents: 1061
diff changeset
   132
				if (currentServiceListener != null)
745221c781a3 Fix issues not disposing listeners in PNP launch wizard
Ed Swartz <ed.swartz@nokia.com>
parents: 1061
diff changeset
   133
					currentServiceListener.removeStatusChangedListener(ConnectToDeviceDialog.this);
745221c781a3 Fix issues not disposing listeners in PNP launch wizard
Ed Swartz <ed.swartz@nokia.com>
parents: 1061
diff changeset
   134
			}
745221c781a3 Fix issues not disposing listeners in PNP launch wizard
Ed Swartz <ed.swartz@nokia.com>
parents: 1061
diff changeset
   135
		});
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   136
		
964
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   137
		final Composite buttonGroup = new Composite(viewerGroup, SWT.NONE);
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   138
		int w = Dialog.convertHorizontalDLUsToPixels(fm, IDialogConstants.HORIZONTAL_MARGIN);
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   139
		int h = Dialog.convertVerticalDLUsToPixels(fm, IDialogConstants.VERTICAL_MARGIN);
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   140
		int hs = Dialog.convertHorizontalDLUsToPixels(fm, IDialogConstants.HORIZONTAL_SPACING);
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   141
		int vs = Dialog.convertVerticalDLUsToPixels(fm, IDialogConstants.VERTICAL_SPACING);
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   142
		GridLayoutFactory.swtDefaults().numColumns(2).equalWidth(true).
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   143
			margins(w, h).spacing(hs, vs).applyTo(buttonGroup);
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   144
		GridDataFactory.swtDefaults().align(SWT.END, SWT.CENTER).applyTo(buttonGroup);
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   145
		buttonGroup.setFont(parent.getFont());
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   146
		
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   147
		newButton = new Button(buttonGroup, SWT.PUSH);
969
b0dd389735fb externalize strings
dadubrow
parents: 964
diff changeset
   148
		newButton.setText(Messages.getString("ConnectToDeviceDialog.NewLabel")); //$NON-NLS-1$
964
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   149
		newButton.setFont(JFaceResources.getDialogFont());
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   150
		int widthHint = Dialog.convertHorizontalDLUsToPixels(fm, IDialogConstants.BUTTON_WIDTH);
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   151
		Point minSize = newButton.computeSize(SWT.DEFAULT, SWT.DEFAULT, true);
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   152
		widthHint = Math.max(widthHint, minSize.x);
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   153
		GridDataFactory.swtDefaults().align(SWT.FILL, SWT.TOP).hint(widthHint, SWT.DEFAULT).applyTo(newButton);
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   154
		newButton.setData(UID, "newButton"); //$NON-NLS-1$
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   155
		newButton.addSelectionListener(new SelectionAdapter() {
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   156
			@Override
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   157
			public void widgetSelected(SelectionEvent e) {
2163
f0a9f2d04d4a Refactor data model for new launch wizard
dadubrow
parents: 2038
diff changeset
   158
				SettingsWizard wizard = new SettingsWizard(null, connectionData.getService());
964
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   159
				wizard.open(composite.getShell());
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   160
				IConnection connection = wizard.getConnectionToEdit();
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   161
				setViewerInput(connection);
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   162
			}
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   163
		});
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   164
		
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   165
		editButton = new Button(buttonGroup, SWT.PUSH);
969
b0dd389735fb externalize strings
dadubrow
parents: 964
diff changeset
   166
		editButton.setText(Messages.getString("ConnectToDeviceDialog.EditLabel")); //$NON-NLS-1$
964
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   167
		editButton.setFont(JFaceResources.getDialogFont());
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   168
		widthHint = Dialog.convertHorizontalDLUsToPixels(fm, IDialogConstants.BUTTON_WIDTH);
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   169
		minSize = editButton.computeSize(SWT.DEFAULT, SWT.DEFAULT, true);
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   170
		widthHint = Math.max(widthHint, minSize.x);
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   171
		GridDataFactory.swtDefaults().align(SWT.FILL, SWT.CENTER).hint(widthHint, SWT.DEFAULT).applyTo(editButton);
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   172
		editButton.setData(UID, "editButton"); //$NON-NLS-1$
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   173
		editButton.addSelectionListener(new SelectionAdapter() {
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   174
			@Override
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   175
			public void widgetSelected(SelectionEvent e) {
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   176
				IConnection connection = getConnectionFromSelection(viewer.getSelection()); 
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   177
				if (connection != null) {
2163
f0a9f2d04d4a Refactor data model for new launch wizard
dadubrow
parents: 2038
diff changeset
   178
					SettingsWizard wizard = new SettingsWizard(connection, connectionData.getService());
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   179
					wizard.open(composite.getShell());
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   180
				}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   181
			}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   182
		});
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   183
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   184
		descriptionLabel = new Label(composite, SWT.WRAP);
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   185
		GridDataFactory.defaultsFor(descriptionLabel).grab(false, true).applyTo(descriptionLabel);
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   186
		composite.addControlListener(new ControlAdapter() {
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   187
			@Override
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   188
			public void controlResized(ControlEvent e) {
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   189
				descriptionLabel.pack();
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   190
			}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   191
		});
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   192
		
2163
f0a9f2d04d4a Refactor data model for new launch wizard
dadubrow
parents: 2038
diff changeset
   193
		setViewerInput(connectionData.getConnection());
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   194
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   195
		return composite;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   196
	}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   197
	
964
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   198
	private void initializeDialogUnits(Composite parent) {
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   199
		GC gc = new GC(parent);
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   200
		gc.setFont(JFaceResources.getDialogFont());
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   201
		fm = gc.getFontMetrics();
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   202
		gc.dispose();
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   203
	}
b0c1a1239188 add new button to new launch wizard connection dialog
dadubrow
parents: 956
diff changeset
   204
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   205
	protected void validate() {
2163
f0a9f2d04d4a Refactor data model for new launch wizard
dadubrow
parents: 2038
diff changeset
   206
		IStatus status = ConnectToDeviceSection.revalidate(connectionData);
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   207
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   208
		if (status.isOK()) {
2163
f0a9f2d04d4a Refactor data model for new launch wizard
dadubrow
parents: 2038
diff changeset
   209
			IConnection connection = connectionData.getConnection();
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   210
			if (connection != null) {
1061
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
   211
				IConnectedService connectedService = findConnectedServiceFromConnection(connection);
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   212
				
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   213
				if (connectedService == null) {
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   214
					status = error(MessageFormat.format(
969
b0dd389735fb externalize strings
dadubrow
parents: 964
diff changeset
   215
							Messages.getString("ConnectToDeviceDialog.ServiceNotSupportedError"), //$NON-NLS-1$
2163
f0a9f2d04d4a Refactor data model for new launch wizard
dadubrow
parents: 2038
diff changeset
   216
							connectionData.getService().getDisplayName()));
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   217
				}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   218
				else {
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   219
					com.nokia.carbide.remoteconnections.interfaces.IConnectedService.IStatus serviceStatus = 
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   220
						connectedService.getStatus();
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   221
					if (!serviceStatus.getEStatus().equals(
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   222
							com.nokia.carbide.remoteconnections.interfaces.IConnectedService.IStatus.EStatus.UP)) {
1061
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
   223
						String description  = serviceStatus.getLongDescription();
2038
dd457404f42f remove hypertext from other UIs
dadubrow
parents: 1265
diff changeset
   224
						if (description != null) {
dd457404f42f remove hypertext from other UIs
dadubrow
parents: 1265
diff changeset
   225
							List<Element> elements = LinkParser.parseText(description);
dd457404f42f remove hypertext from other UIs
dadubrow
parents: 1265
diff changeset
   226
							StyledString styledString = LinkParser.getStyledString(elements);
dd457404f42f remove hypertext from other UIs
dadubrow
parents: 1265
diff changeset
   227
							description = styledString.getString();
dd457404f42f remove hypertext from other UIs
dadubrow
parents: 1265
diff changeset
   228
						}
969
b0dd389735fb externalize strings
dadubrow
parents: 964
diff changeset
   229
						status = warning(Messages.getString("ConnectToDeviceDialog.ServiceNotAvailWarning"),  //$NON-NLS-1$
1061
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
   230
								description == null ? "" : description); //$NON-NLS-1$
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   231
					}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   232
				}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   233
			}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   234
		}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   235
		updateStatus(status);
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   236
	}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   237
1061
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
   238
	private IConnectedService findConnectedServiceFromConnection(IConnection connection) {
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
   239
		Collection<IConnectedService> services = manager.getConnectedServices(connection);
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
   240
		for (IConnectedService connectedService : services) {
2163
f0a9f2d04d4a Refactor data model for new launch wizard
dadubrow
parents: 2038
diff changeset
   241
			if (connectedService != null && connectedService.getService().getIdentifier().equals(connectionData.getService().getIdentifier())) {
1061
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
   242
				return connectedService;
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
   243
			}
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
   244
		}
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
   245
		return null;
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
   246
	}
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
   247
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   248
	/**
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   249
	 *	Update for a change in the connection.  We will attempt to connect to the
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   250
	 *  device (once) to detect what TRK it is running.
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   251
	 */
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   252
	private void updateConnection(IConnection connection) {
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   253
		String standardPNPMessage = ConnectToDeviceSection.getStandardPNPMessage();
2163
f0a9f2d04d4a Refactor data model for new launch wizard
dadubrow
parents: 2038
diff changeset
   254
		connectionData.setConnection(connection);
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   255
		if (connection != null) {
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   256
			descriptionLabel.setText(standardPNPMessage);
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   257
		} else {
969
b0dd389735fb externalize strings
dadubrow
parents: 964
diff changeset
   258
			descriptionLabel.setText(Messages.getString("ConnectToDeviceDialog.NoConnectionsText") + standardPNPMessage); //$NON-NLS-1$
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   259
		}
1061
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
   260
		if (currentServiceListener != null)
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
   261
			currentServiceListener.removeStatusChangedListener(this);
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
   262
		currentServiceListener = findConnectedServiceFromConnection(connection);
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
   263
		if (currentServiceListener != null)
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
   264
			currentServiceListener.addStatusChangedListener(this);
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   265
	}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   266
1061
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
   267
	protected void connectionSelected(IConnection connection) {
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   268
		updateConnection(connection);
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   269
		validate();
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   270
	}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   271
	
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   272
	public void connectionAdded(IConnection connection) {
983
8b4ee73c530c New launch wizard UI tweaks based on demo feedback
dadubrow
parents: 981
diff changeset
   273
		refreshUI(null);
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   274
	}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   275
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   276
	public void connectionRemoved(IConnection connection) {
983
8b4ee73c530c New launch wizard UI tweaks based on demo feedback
dadubrow
parents: 981
diff changeset
   277
		refreshUI(null);		
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   278
	}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   279
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   280
	public void currentConnectionSet(IConnection connection) {
1061
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
   281
//		refreshUI(connection);
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   282
	}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   283
1061
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
   284
	public void statusChanged(com.nokia.carbide.remoteconnections.interfaces.IConnectedService.IStatus status) {
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
   285
		validate();
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
   286
	}
ceac11190019 bug 10815 - connection dialog listen to service status change and update status
dadubrow
parents: 983
diff changeset
   287
	
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   288
	private Set<IConnectionType> getCompatibleConnectionTypes() {
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   289
		HashSet<IConnectionType> types = new HashSet<IConnectionType>();
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   290
		Collection<String> compatibleTypeIds =
2163
f0a9f2d04d4a Refactor data model for new launch wizard
dadubrow
parents: 2038
diff changeset
   291
			typeProvider.getCompatibleConnectionTypeIds(connectionData.getService());
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   292
		for (String typeId : compatibleTypeIds) {
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   293
			types.add(typeProvider.getConnectionType(typeId));
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   294
		}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   295
		return types;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   296
	}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   297
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   298
	private List<IConnection> getCompatibleConnections() {
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   299
		Set<IConnectionType> types = getCompatibleConnectionTypes();
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   300
		
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   301
		List<IConnection> compatibleConnections = new ArrayList<IConnection>();
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   302
		for (IConnection connection : manager.getConnections()) {
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   303
			if (types.contains(connection.getConnectionType()))
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   304
				compatibleConnections.add(connection);
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   305
		}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   306
		return compatibleConnections;
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   307
	}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   308
	
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   309
	private void setViewerInput(IConnection connection) {
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   310
		List<IConnection> connections = getCompatibleConnections();
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   311
		viewer.setInput(connections);
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   312
		
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   313
		if (connections.isEmpty())
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   314
			viewer.getCombo().setEnabled(false);
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   315
		else {
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   316
			viewer.getCombo().setEnabled(true);
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   317
			if (connection == null) {
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   318
				viewer.getCombo().select(0);
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   319
				ISelection selection = viewer.getSelection();
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   320
				connection = getConnectionFromSelection(selection);
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   321
				viewer.setSelection(selection);
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   322
			}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   323
			else
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   324
				viewer.setSelection(new StructuredSelection(connection));
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   325
		}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   326
		editButton.setEnabled(!viewer.getSelection().isEmpty());
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   327
		
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   328
		// fire listener in case we selected anew or the current connection changed
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   329
		connectionSelected(connection);
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   330
	}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   331
	
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   332
	private IConnection getConnectionFromSelection(ISelection selection) {
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   333
		return (IConnection) ((IStructuredSelection) selection).getFirstElement();
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   334
	}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   335
983
8b4ee73c530c New launch wizard UI tweaks based on demo feedback
dadubrow
parents: 981
diff changeset
   336
	private void refreshUI(final IConnection connection) {
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   337
		Display.getDefault().syncExec(new Runnable() {
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   338
			public void run() {
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   339
				if (viewer != null && viewer.getContentProvider() != null) {
983
8b4ee73c530c New launch wizard UI tweaks based on demo feedback
dadubrow
parents: 981
diff changeset
   340
					IConnection connectionToSet = connection == null ? getConnectionFromSelection(viewer.getSelection()) : connection;
8b4ee73c530c New launch wizard UI tweaks based on demo feedback
dadubrow
parents: 981
diff changeset
   341
					setViewerInput(connectionToSet);
956
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   342
				}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   343
			}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   344
		});
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   345
	}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   346
}
d1e221a2875f new launch wizard implementation
dadubrow
parents:
diff changeset
   347