forked from qt-creator/qt-creator
TextEditor: static-ify plugin class
Change-Id: Id795b711f08c89b6066c5269c482fea5e99dd52f Reviewed-by: David Schulz <david.schulz@digia.com> Reviewed-by: Eike Ziller <eike.ziller@digia.com>
This commit is contained in:
@@ -66,7 +66,7 @@ static const char kCurrentDocumentRowCount[] = "CurrentDocument:RowCount";
|
||||
static const char kCurrentDocumentColumnCount[] = "CurrentDocument:ColumnCount";
|
||||
static const char kCurrentDocumentFontSize[] = "CurrentDocument:FontSize";
|
||||
|
||||
TextEditorPlugin *TextEditorPlugin::m_instance = 0;
|
||||
static TextEditorPlugin *m_instance = 0;
|
||||
|
||||
TextEditorPlugin::TextEditorPlugin()
|
||||
: m_settings(0),
|
||||
@@ -83,11 +83,6 @@ TextEditorPlugin::~TextEditorPlugin()
|
||||
m_instance = 0;
|
||||
}
|
||||
|
||||
TextEditorPlugin *TextEditorPlugin::instance()
|
||||
{
|
||||
return m_instance;
|
||||
}
|
||||
|
||||
static const char wizardCategoryC[] = "U.General";
|
||||
|
||||
static inline QString wizardDisplayCategory()
|
||||
@@ -266,6 +261,21 @@ void TextEditorPlugin::extensionsInitialized()
|
||||
this, SLOT(updateCurrentSelection(QString)));
|
||||
}
|
||||
|
||||
PlainTextEditorFactory *TextEditorPlugin::editorFactory()
|
||||
{
|
||||
return m_instance->m_editorFactory;
|
||||
}
|
||||
|
||||
LineNumberFilter *TextEditorPlugin::lineNumberFilter()
|
||||
{
|
||||
return m_instance->m_lineNumberFilter;
|
||||
}
|
||||
|
||||
BaseTextMarkRegistry *TextEditorPlugin::baseTextMarkRegistry()
|
||||
{
|
||||
return m_instance->m_baseTextMarkRegistry;
|
||||
}
|
||||
|
||||
void TextEditorPlugin::invokeCompletion()
|
||||
{
|
||||
Core::IEditor *iface = Core::EditorManager::currentEditor();
|
||||
|
||||
Reference in New Issue
Block a user