forked from qt-creator/qt-creator
Fix id of diff editor according to change b772001c
Task-number: QTCREATORBUG-9960 Change-Id: I233b697254e863b7c4389c0041104b82e97bd340 Reviewed-by: hjk <hjk121@nokiamail.com> Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
This commit is contained in:
@@ -39,19 +39,11 @@ namespace DiffEditor {
|
|||||||
namespace Internal {
|
namespace Internal {
|
||||||
|
|
||||||
DiffEditorFactory::DiffEditorFactory(QObject *parent)
|
DiffEditorFactory::DiffEditorFactory(QObject *parent)
|
||||||
: IEditorFactory(parent),
|
: IEditorFactory(parent)
|
||||||
m_mimeTypes(QLatin1String(Constants::DIFF_EDITOR_MIMETYPE))
|
|
||||||
{
|
{
|
||||||
}
|
setId(Constants::DIFF_EDITOR_ID);
|
||||||
|
setDisplayName(qApp->translate("DiffEditorFactory", Constants::DIFF_EDITOR_DISPLAY_NAME));
|
||||||
Core::Id DiffEditorFactory::id() const
|
addMimeType(QLatin1String(Constants::DIFF_EDITOR_MIMETYPE));
|
||||||
{
|
|
||||||
return Constants::DIFF_EDITOR_ID;
|
|
||||||
}
|
|
||||||
|
|
||||||
QString DiffEditorFactory::displayName() const
|
|
||||||
{
|
|
||||||
return qApp->translate("DiffEditorFactory", Constants::DIFF_EDITOR_DISPLAY_NAME);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Core::IEditor *DiffEditorFactory::createEditor(QWidget *parent)
|
Core::IEditor *DiffEditorFactory::createEditor(QWidget *parent)
|
||||||
@@ -61,10 +53,5 @@ Core::IEditor *DiffEditorFactory::createEditor(QWidget *parent)
|
|||||||
return editor;
|
return editor;
|
||||||
}
|
}
|
||||||
|
|
||||||
QStringList DiffEditorFactory::mimeTypes() const
|
|
||||||
{
|
|
||||||
return m_mimeTypes;
|
|
||||||
}
|
|
||||||
|
|
||||||
} // namespace Internal
|
} // namespace Internal
|
||||||
} // namespace DiffEditor
|
} // namespace DiffEditor
|
||||||
|
@@ -47,13 +47,7 @@ class DiffEditorFactory : public Core::IEditorFactory
|
|||||||
public:
|
public:
|
||||||
explicit DiffEditorFactory(QObject *parent);
|
explicit DiffEditorFactory(QObject *parent);
|
||||||
|
|
||||||
QStringList mimeTypes() const;
|
|
||||||
Core::IEditor *createEditor(QWidget *parent);
|
Core::IEditor *createEditor(QWidget *parent);
|
||||||
Core::Id id() const;
|
|
||||||
QString displayName() const;
|
|
||||||
|
|
||||||
private:
|
|
||||||
const QStringList m_mimeTypes;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace Internal
|
} // namespace Internal
|
||||||
|
@@ -39,19 +39,11 @@ namespace DiffEditor {
|
|||||||
namespace Internal {
|
namespace Internal {
|
||||||
|
|
||||||
DiffShowEditorFactory::DiffShowEditorFactory(QObject *parent)
|
DiffShowEditorFactory::DiffShowEditorFactory(QObject *parent)
|
||||||
: IEditorFactory(parent),
|
: IEditorFactory(parent)
|
||||||
m_mimeTypes(QLatin1String(Constants::DIFF_EDITOR_MIMETYPE))
|
|
||||||
{
|
{
|
||||||
}
|
setId(Constants::DIFF_SHOW_EDITOR_ID);
|
||||||
|
setDisplayName(qApp->translate("DiffEditorFactory", Constants::DIFF_SHOW_EDITOR_DISPLAY_NAME));
|
||||||
Core::Id DiffShowEditorFactory::id() const
|
setMimeTypes(QStringList() << QLatin1String(Constants::DIFF_EDITOR_MIMETYPE));
|
||||||
{
|
|
||||||
return Constants::DIFF_SHOW_EDITOR_ID;
|
|
||||||
}
|
|
||||||
|
|
||||||
QString DiffShowEditorFactory::displayName() const
|
|
||||||
{
|
|
||||||
return qApp->translate("DiffEditorFactory", Constants::DIFF_SHOW_EDITOR_DISPLAY_NAME);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Core::IEditor *DiffShowEditorFactory::createEditor(QWidget *parent)
|
Core::IEditor *DiffShowEditorFactory::createEditor(QWidget *parent)
|
||||||
@@ -61,10 +53,5 @@ Core::IEditor *DiffShowEditorFactory::createEditor(QWidget *parent)
|
|||||||
return editor;
|
return editor;
|
||||||
}
|
}
|
||||||
|
|
||||||
QStringList DiffShowEditorFactory::mimeTypes() const
|
|
||||||
{
|
|
||||||
return m_mimeTypes;
|
|
||||||
}
|
|
||||||
|
|
||||||
} // namespace Internal
|
} // namespace Internal
|
||||||
} // namespace DiffEditor
|
} // namespace DiffEditor
|
||||||
|
@@ -47,13 +47,7 @@ class DiffShowEditorFactory : public Core::IEditorFactory
|
|||||||
public:
|
public:
|
||||||
explicit DiffShowEditorFactory(QObject *parent);
|
explicit DiffShowEditorFactory(QObject *parent);
|
||||||
|
|
||||||
QStringList mimeTypes() const;
|
|
||||||
Core::IEditor *createEditor(QWidget *parent);
|
Core::IEditor *createEditor(QWidget *parent);
|
||||||
Core::Id id() const;
|
|
||||||
QString displayName() const;
|
|
||||||
|
|
||||||
private:
|
|
||||||
const QStringList m_mimeTypes;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace Internal
|
} // namespace Internal
|
||||||
|
Reference in New Issue
Block a user