forked from qt-creator/qt-creator
TextEditor: Split the global QuickFixFactory list
It's only ever used in the filtered Cpp/QmlJs variants. Splitting the class simplifies the code and avoids re-doing filtering over and over again. Also inline QuickFixFactory::matchingOperations() into callers Change-Id: I730756315f2e0321649259ef229631233b12fbdd Reviewed-by: David Schulz <david.schulz@qt.io>
This commit is contained in:
@@ -55,21 +55,3 @@ void QuickFixOperation::setDescription(const QString &description)
|
||||
{
|
||||
_description = description;
|
||||
}
|
||||
|
||||
static QList<QuickFixFactory *> g_quickFixFactories;
|
||||
|
||||
QuickFixFactory::QuickFixFactory(QObject *parent)
|
||||
: QObject(parent)
|
||||
{
|
||||
g_quickFixFactories.append(this);
|
||||
}
|
||||
|
||||
QuickFixFactory::~QuickFixFactory()
|
||||
{
|
||||
g_quickFixFactories.removeOne(this);
|
||||
}
|
||||
|
||||
const QList<QuickFixFactory *> QuickFixFactory::allQuickFixFactories()
|
||||
{
|
||||
return g_quickFixFactories;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user