diff options
author | hjk <qthjk@ovi.com> | 2012-09-07 15:13:10 +0200 |
---|---|---|
committer | hjk <qthjk@ovi.com> | 2012-09-07 15:26:06 +0200 |
commit | 15ea29533a00dfbf1c8fb42c147a59631d3e0dea (patch) | |
tree | 9307ee08a50059b97747c00914d9f27e4b39a5db | |
parent | 61291e942174e1f64b119709cf164dcb060fbcfc (diff) |
debugger: use DeviceProcessesDialog directly for attaching
Change-Id: I916c42bc141f5bfbf5dd163b3d9dfeed3703ed94
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
-rw-r--r-- | src/plugins/debugger/debuggerplugin.cpp | 14 | ||||
-rw-r--r-- | src/plugins/projectexplorer/devicesupport/deviceprocessesdialog.h | 2 |
2 files changed, 2 insertions, 14 deletions
diff --git a/src/plugins/debugger/debuggerplugin.cpp b/src/plugins/debugger/debuggerplugin.cpp index ec1700bcdb..dda14a769f 100644 --- a/src/plugins/debugger/debuggerplugin.cpp +++ b/src/plugins/debugger/debuggerplugin.cpp @@ -1670,21 +1670,12 @@ void DebuggerPluginPrivate::attachToRunningApplication() attachToProcess(false); } -class DebuggerProcessesDialog : public ProjectExplorer::DeviceProcessesDialog { -public: - DebuggerProcessesDialog(DebuggerKitChooser::Mode m, QWidget *parent) : - ProjectExplorer::DeviceProcessesDialog(new DebuggerKitChooser(m), parent) - { - addAcceptButton(DeviceProcessesDialog::tr("&Attach to Process")); - } -}; - void DebuggerPluginPrivate::attachToProcess(bool startServerOnly) { - const DebuggerKitChooser::Mode mode = startServerOnly ? DebuggerKitChooser::RemoteDebugging : DebuggerKitChooser::LocalDebugging; - DeviceProcessesDialog *dlg = new DebuggerProcessesDialog(mode, mainWindow()); + DebuggerKitChooser *kitChooser = new DebuggerKitChooser(mode); + DeviceProcessesDialog *dlg = new DeviceProcessesDialog(kitChooser, mainWindow()); dlg->addAcceptButton(DeviceProcessesDialog::tr("&Attach to Process")); dlg->showAllDevices(); if (dlg->exec() == QDialog::Rejected) { @@ -1693,7 +1684,6 @@ void DebuggerPluginPrivate::attachToProcess(bool startServerOnly) } dlg->setAttribute(Qt::WA_DeleteOnClose); - KitChooser *kitChooser = dlg->kitChooser(); Kit *kit = kitChooser->currentKit(); QTC_ASSERT(kit, return); IDevice::ConstPtr device = DeviceKitInformation::device(kit); diff --git a/src/plugins/projectexplorer/devicesupport/deviceprocessesdialog.h b/src/plugins/projectexplorer/devicesupport/deviceprocessesdialog.h index 6687a82f1f..c40de73117 100644 --- a/src/plugins/projectexplorer/devicesupport/deviceprocessesdialog.h +++ b/src/plugins/projectexplorer/devicesupport/deviceprocessesdialog.h @@ -59,8 +59,6 @@ public: DeviceProcess currentProcess() const; KitChooser *kitChooser() const; void logMessage(const QString &line); - -protected: DeviceProcessesDialog(KitChooser *chooser, QWidget *parent); private: |