Fixes: pluginmanager: fork QPluginLoader and QLibraryPrivate

Details:  saves 20% startup time. patch for Qt 4.6 at
http://codepaster-nokia.troll.no/?id=11918.
This commit is contained in:
hjk
2009-02-19 15:32:50 +01:00
parent 0a0586a2cf
commit 52007d1cc7
3 changed files with 1186 additions and 3 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -39,7 +39,6 @@
#include "iplugin.h" #include "iplugin.h"
#include <QtCore/QMetaProperty> #include <QtCore/QMetaProperty>
#include <QtCore/QPluginLoader>
#include <QtCore/QDir> #include <QtCore/QDir>
#include <QtCore/QTextStream> #include <QtCore/QTextStream>
#include <QtCore/QWriteLocker> #include <QtCore/QWriteLocker>

View File

@@ -42,10 +42,23 @@
#include <QtCore/QFileInfo> #include <QtCore/QFileInfo>
#include <QtCore/QXmlStreamReader> #include <QtCore/QXmlStreamReader>
#include <QtCore/QRegExp> #include <QtCore/QRegExp>
#include <QtCore/QPluginLoader>
#include <QtCore/QCoreApplication> #include <QtCore/QCoreApplication>
#include <QtDebug> #include <QtDebug>
#define USE_UNPATCHED_QPLUGINLOADER 1
#if USE_UNPATCHED_QPLUGINLOADER
#include <QtCore/QPluginLoader>
typedef QT_PREPEND_NAMESPACE(QPluginLoader) PluginLoader;
#else
#include "patchedpluginloader.cpp"
typedef PatchedPluginLoader PluginLoader;
#endif
/*! /*!
\class ExtensionSystem::PluginDependency \class ExtensionSystem::PluginDependency
\brief Struct that contains the name and required compatible version number of a plugin's dependency. \brief Struct that contains the name and required compatible version number of a plugin's dependency.
@@ -770,7 +783,7 @@ bool PluginSpecPrivate::loadLibrary()
#endif #endif
QPluginLoader loader(libName); PluginLoader loader(libName);
if (!loader.load()) { if (!loader.load()) {
hasError = true; hasError = true;
errorString = loader.errorString(); errorString = loader.errorString();