summaryrefslogtreecommitdiff
path: root/src/plugins/analyzerbase
diff options
context:
space:
mode:
authorhjk <qtc-committer@nokia.com>2011-04-13 13:00:30 +0200
committerhjk <qtc-committer@nokia.com>2011-04-14 11:15:07 +0200
commit70d392d23515e9fc4c5a64897fd4c295d3f17817 (patch)
tree228cf7522e5cd695295b810d6fe5daf53afc9488 /src/plugins/analyzerbase
parentcbfaea1ed342102cdfa848698d96cb7c010dae48 (diff)
downloadqt-creator-70d392d23515e9fc4c5a64897fd4c295d3f17817.tar.gz
core: make context and widget IContext data members
Diffstat (limited to 'src/plugins/analyzerbase')
-rw-r--r--src/plugins/analyzerbase/analyzermanager.cpp18
1 files changed, 6 insertions, 12 deletions
diff --git a/src/plugins/analyzerbase/analyzermanager.cpp b/src/plugins/analyzerbase/analyzermanager.cpp
index 7d1d89fe7b..81aaecfc33 100644
--- a/src/plugins/analyzerbase/analyzermanager.cpp
+++ b/src/plugins/analyzerbase/analyzermanager.cpp
@@ -143,8 +143,12 @@ class AnalyzerMode : public Core::IMode
public:
AnalyzerMode(QObject *parent = 0)
: Core::IMode(parent)
- , m_widget(0)
- {}
+ {
+ setContext(Core::Context(
+ Core::Constants::C_EDITORMANAGER,
+ Constants::C_ANALYZEMODE,
+ Core::Constants::C_NAVIGATION_PANE));
+ }
~AnalyzerMode()
{
@@ -159,19 +163,9 @@ public:
QString displayName() const { return tr("Analyze"); }
QIcon icon() const { return QIcon(":/images/analyzer_mode.png"); }
int priority() const { return Constants::P_MODE_ANALYZE; }
- QWidget *widget() { return m_widget; }
QString id() const { return QLatin1String(Constants::MODE_ANALYZE); }
QString type() const { return Core::Constants::MODE_EDIT_TYPE; }
- Core::Context context() const
- {
- return Core::Context(Core::Constants::C_EDITORMANAGER, Constants::C_ANALYZEMODE,
- Core::Constants::C_NAVIGATION_PANE);
- }
QString contextHelpId() const { return QString(); }
- void setWidget(QWidget *widget) { m_widget = widget; }
-
-private:
- QWidget *m_widget;
};
} // namespace Internal