debuggercdi/com.nokia.cdt.debug.launch/src/com/nokia/cdt/internal/debug/launch/wizard/MainExecutableSelectionWizardPage.java
equal
deleted
inserted
replaced
15 * |
15 * |
16 */ |
16 */ |
17 package com.nokia.cdt.internal.debug.launch.wizard; |
17 package com.nokia.cdt.internal.debug.launch.wizard; |
18 |
18 |
19 import com.nokia.cpp.internal.api.utils.core.*; |
19 import com.nokia.cpp.internal.api.utils.core.*; |
|
20 import com.nokia.cpp.internal.api.utils.ui.BrowseDialogUtils; |
20 |
21 |
21 import org.eclipse.core.runtime.IPath; |
22 import org.eclipse.core.runtime.IPath; |
22 import org.eclipse.core.runtime.Path; |
23 import org.eclipse.core.runtime.Path; |
23 import org.eclipse.jface.dialogs.Dialog; |
24 import org.eclipse.jface.dialogs.Dialog; |
24 import org.eclipse.jface.viewers.*; |
25 import org.eclipse.jface.viewers.*; |
235 IStructuredSelection selection = (IStructuredSelection) event.getSelection(); |
236 IStructuredSelection selection = (IStructuredSelection) event.getSelection(); |
236 String item = (String) selection.getFirstElement(); |
237 String item = (String) selection.getFirstElement(); |
237 if (item.equals(BROWSE_ITEM)) { |
238 if (item.equals(BROWSE_ITEM)) { |
238 FileDialog fileDialog = new FileDialog(getShell(), SWT.OPEN); |
239 FileDialog fileDialog = new FileDialog(getShell(), SWT.OPEN); |
239 fileDialog.setText(Messages.getString("MainExecutableSelectionWizardPage.SelectExectuableTitle")); //$NON-NLS-1$ |
240 fileDialog.setText(Messages.getString("MainExecutableSelectionWizardPage.SelectExectuableTitle")); //$NON-NLS-1$ |
240 fileDialog.setFilterPath(emulatorPath.removeLastSegments(1).toOSString()); |
241 BrowseDialogUtils.initializeFrom(fileDialog, emulatorPath); |
241 fileDialog.setFilterExtensions(FILTER_EXTS); |
242 fileDialog.setFilterExtensions(FILTER_EXTS); |
242 fileDialog.setFilterNames(FILTER_EXT_NAMES); |
243 fileDialog.setFilterNames(FILTER_EXT_NAMES); |
243 String pathstr = fileDialog.open(); |
244 String pathstr = fileDialog.open(); |
244 if (pathstr != null) { |
245 if (pathstr != null) { |
245 IPath path = new Path(pathstr); |
246 IPath path = new Path(pathstr); |