aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/debugger/debuggerdialogs.h
diff options
context:
space:
mode:
authorFriedemann Kleint <Friedemann.Kleint@nokia.com>2012-09-05 10:55:05 +0200
committerFriedemann Kleint <Friedemann.Kleint@nokia.com>2012-09-05 15:49:20 +0200
commitc3f50e3192cc36a0ddc938565ef5af0c00788146 (patch)
treee11d43378316515cb79cd2ab9f8ec6d025727315 /src/plugins/debugger/debuggerdialogs.h
parentaf6bbc442ecb60d2ddcb37752215f6a2e3e5bea4 (diff)
KitChooser: Introduce virtual methods for Debugger.
Introduce virtual methods such that it is possible to write derived classes for specific KitInformation classes, allowing for filtering and setting text and tooltip. Remove debugging-specific code of KitChooser from the ProjectExplorer. Move populate() away from the constructor as not to call virtuals from it. Implement DebuggerKitChooser. It should no longer be possible to to choose an invalid kit for debugging from the debugger starter dialogs. Add a protected constructor to DeviceProcessesDialog allowing to pass a KitChooser. Change-Id: I8c683a2da7d69bfbccdc08213cb47d69a0df8b3e Reviewed-by: Tobias Hunger <tobias.hunger@nokia.com>
Diffstat (limited to 'src/plugins/debugger/debuggerdialogs.h')
-rw-r--r--src/plugins/debugger/debuggerdialogs.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/plugins/debugger/debuggerdialogs.h b/src/plugins/debugger/debuggerdialogs.h
index a8d8274c60..a0e5c251e9 100644
--- a/src/plugins/debugger/debuggerdialogs.h
+++ b/src/plugins/debugger/debuggerdialogs.h
@@ -31,6 +31,9 @@
#ifndef DEBUGGER_DIALOGS_H
#define DEBUGGER_DIALOGS_H
+#include <projectexplorer/kitchooser.h>
+#include <projectexplorer/abi.h>
+
#include <QDialog>
#include <QHash>
#include <QStringList>
@@ -58,6 +61,22 @@ class StartApplicationParameters;
class StartApplicationDialogPrivate;
class StartRemoteEngineDialogPrivate;
+class DebuggerKitChooser : public ProjectExplorer::KitChooser {
+ Q_OBJECT
+public:
+ enum Mode { RemoteDebugging, LocalDebugging };
+
+ explicit DebuggerKitChooser(Mode mode = RemoteDebugging, QWidget *parent = 0);
+
+protected:
+ bool kitMatches(const ProjectExplorer::Kit *k) const;
+ QString kitToolTip(ProjectExplorer::Kit *k) const;
+
+private:
+ const ProjectExplorer::Abi m_hostAbi;
+ const Mode m_mode;
+};
+
class StartApplicationDialog : public QDialog
{
Q_OBJECT