diff options
author | Eike Ziller <[email protected]> | 2012-05-24 13:49:06 +0200 |
---|---|---|
committer | hjk <[email protected]> | 2012-05-25 10:08:24 +0200 |
commit | 3934347fe9ed7e1567c3ff377f857928e8b03304 (patch) | |
tree | 09f1ccaf1af2d8032bb12ea0a5a05b4b4185d431 /src/plugins/valgrind/callgrindtool.cpp | |
parent | 7c7ccdc764629042729ceede4ca3e47b464aee42 (diff) |
ActionManager API cleanup.
d-pointer instead of inheritance
static methods
Change-Id: I7b2f0c8b05ad3951e1ff26a7d4e08e195d2dd258
Reviewed-by: hjk <[email protected]>
Diffstat (limited to 'src/plugins/valgrind/callgrindtool.cpp')
-rw-r--r-- | src/plugins/valgrind/callgrindtool.cpp | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/plugins/valgrind/callgrindtool.cpp b/src/plugins/valgrind/callgrindtool.cpp index ca84ccf347d..1899acdd9f8 100644 --- a/src/plugins/valgrind/callgrindtool.cpp +++ b/src/plugins/valgrind/callgrindtool.cpp @@ -538,26 +538,24 @@ IAnalyzerTool::ToolMode CallgrindTool::toolMode() const void CallgrindTool::extensionsInitialized() { - Core::ActionManager *actionManager = Core::ICore::actionManager(); - Core::Context analyzerContext = Core::Context(Analyzer::Constants::C_ANALYZEMODE); // check if there is a CppEditor context menu, if true, add our own context menu actions if (Core::ActionContainer *editorContextMenu = - actionManager->actionContainer(CppEditor::Constants::M_CONTEXT)) { + Core::ActionManager::actionContainer(CppEditor::Constants::M_CONTEXT)) { QAction *action = 0; Core::Command *cmd = 0; action = new QAction(this); action->setSeparator(true); - cmd = actionManager->registerAction(action, "Analyzer.Callgrind.ContextMenu.Sep", + cmd = Core::ActionManager::registerAction(action, "Analyzer.Callgrind.ContextMenu.Sep", analyzerContext); editorContextMenu->addAction(cmd); action = new QAction(tr("Profile Costs of this Function and its Callees"), this); action->setIcon(QIcon(Analyzer::Constants::ANALYZER_CONTROL_START_ICON)); connect(action, SIGNAL(triggered()), d, SLOT(handleShowCostsOfFunction())); - cmd = actionManager->registerAction(action, "Analyzer.Callgrind.ShowCostsOfFunction", + cmd = Core::ActionManager::registerAction(action, "Analyzer.Callgrind.ShowCostsOfFunction", analyzerContext); editorContextMenu->addAction(cmd); cmd->setAttribute(Core::Command::CA_Hide); |