forked from qt-creator/qt-creator
ActionManager API cleanup.
d-pointer instead of inheritance static methods Change-Id: I7b2f0c8b05ad3951e1ff26a7d4e08e195d2dd258 Reviewed-by: hjk <qthjk@ovi.com>
This commit is contained in:
@@ -108,11 +108,9 @@ void ImageViewerActionHandler::registerNewAction(int actionId, const Core::Id &i
|
||||
const QString &title, const QKeySequence &key)
|
||||
{
|
||||
Core::Context context(Constants::IMAGEVIEWER_ID);
|
||||
Core::ActionManager *actionManager = Core::ICore::actionManager();
|
||||
QAction *action = new QAction(title, this);
|
||||
Core::Command *command = actionManager->registerAction(action, id, context);
|
||||
if (command)
|
||||
command->setDefaultKeySequence(key);
|
||||
Core::Command *command = Core::ActionManager::registerAction(action, id, context);
|
||||
command->setDefaultKeySequence(key);
|
||||
connect(action, SIGNAL(triggered()), m_signalMapper, SLOT(map()));
|
||||
m_signalMapper->setMapping(action, actionId);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user