Optimize BaseTextMark

Instead of each BaseTextMark being a QObject and being connected
to editorOpened, centralize that and distribute the signal
to only the BaseTextMarks that need it.

Change-Id: I3f2783c34a25d78aa335418236850436028bfdf3
Reviewed-by: Eike Ziller <eike.ziller@nokia.com>
This commit is contained in:
Daniel Teske
2012-02-08 17:21:12 +01:00
parent cf4c131541
commit b267027c9e
14 changed files with 106 additions and 90 deletions

View File

@@ -46,6 +46,7 @@
#include "outlinefactory.h"
#include "snippets/plaintextsnippetprovider.h"
#include "codeassist/assistenums.h"
#include "basetextmark.h"
#include <coreplugin/icore.h>
#include <coreplugin/coreconstants.h>
@@ -168,6 +169,8 @@ bool TextEditorPlugin::initialize(const QStringList &arguments, QString *errorMe
// registered in the action manager at plugin initialization time.
m_editorFactory->actionHandler()->initializeActions();
m_baseTextMarkRegistry = new BaseTextMarkRegistry(this);
return true;
}