forked from qt-creator/qt-creator
Add more thread safety to ModelManagerInterface
Add ModelManagerInterface *ModelManagerInterface::instanceForFuture() method. If the returned instance is not null, it's guaranteed that it will be valid at least as long as the passed QFuture object isn't finished. Use instanceForFuture() in Link c'tor, as it's called from non-gui thread. Change-Id: I7e5ee6ad27e8f71cc0cef7fd9a91b710e2f8f662 Reviewed-by: Fawzi Mohamed <fawzi.mohamed@qt.io>
This commit is contained in:
@@ -126,6 +126,7 @@ public:
|
||||
static Dialect guessLanguageOfFile(const QString &fileName);
|
||||
static QStringList globPatternsForLanguages(const QList<Dialect> &languages);
|
||||
static ModelManagerInterface *instance();
|
||||
static ModelManagerInterface *instanceForFuture(const QFuture<void> &future);
|
||||
static void writeWarning(const QString &msg);
|
||||
static WorkingCopy workingCopy();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user