bineditor: some s/QString/Core::Id/

Change-Id: I97b4222d4482d59fa875b016eb3bf248969bbadc
Reviewed-by: hjk <qthjk@ovi.com>
This commit is contained in:
hjk
2012-06-28 16:07:07 +02:00
parent 0b12ed143e
commit c4da217c3e
2 changed files with 9 additions and 15 deletions

View File

@@ -461,14 +461,14 @@ BinEditorPlugin::~BinEditorPlugin()
{ {
} }
QAction *BinEditorPlugin::registerNewAction(const QString &id, const QString &title) QAction *BinEditorPlugin::registerNewAction(Core::Id id, const QString &title)
{ {
QAction *result = new QAction(title, this); QAction *result = new QAction(title, this);
Core::ActionManager::registerAction(result, Core::Id(id), m_context); Core::ActionManager::registerAction(result, id, m_context);
return result; return result;
} }
QAction *BinEditorPlugin::registerNewAction(const QString &id, QAction *BinEditorPlugin::registerNewAction(Core::Id id,
QObject *receiver, QObject *receiver,
const char *slot, const char *slot,
const QString &title) const QString &title)
@@ -489,16 +489,10 @@ void BinEditorPlugin::initializeEditor(BinEditor *editor)
m_context.add(Constants::C_BINEDITOR); m_context.add(Constants::C_BINEDITOR);
if (!m_undoAction) { if (!m_undoAction) {
m_undoAction = registerNewAction(QLatin1String(Core::Constants::UNDO), m_undoAction = registerNewAction(Core::Constants::UNDO, this, SLOT(undoAction()), tr("&Undo"));
this, SLOT(undoAction()), m_redoAction = registerNewAction(Core::Constants::REDO, this, SLOT(redoAction()), tr("&Redo"));
tr("&Undo")); m_copyAction = registerNewAction(Core::Constants::COPY, this, SLOT(copyAction()));
m_redoAction = registerNewAction(QLatin1String(Core::Constants::REDO), m_selectAllAction = registerNewAction(Core::Constants::SELECTALL, this, SLOT(selectAllAction()));
this, SLOT(redoAction()),
tr("&Redo"));
m_copyAction = registerNewAction(QLatin1String(Core::Constants::COPY),
this, SLOT(copyAction()));
m_selectAllAction = registerNewAction(QLatin1String(Core::Constants::SELECTALL),
this, SLOT(selectAllAction()));
} }
// Font settings // Font settings

View File

@@ -83,8 +83,8 @@ private slots:
private: private:
Core::Context m_context; Core::Context m_context;
QAction *registerNewAction(const QString &id, const QString &title = QString()); QAction *registerNewAction(Core::Id id, const QString &title = QString());
QAction *registerNewAction(const QString &id, QObject *receiver, const char *slot, QAction *registerNewAction(Core::Id id, QObject *receiver, const char *slot,
const QString &title = QString()); const QString &title = QString());
QAction *m_undoAction; QAction *m_undoAction;
QAction *m_redoAction; QAction *m_redoAction;