diff options
Diffstat (limited to 'src')
42 files changed, 167 insertions, 177 deletions
diff --git a/src/libs/installer/addqtcreatorarrayvalueoperation.h b/src/libs/installer/addqtcreatorarrayvalueoperation.h index 6792b8e88..670dccff8 100644 --- a/src/libs/installer/addqtcreatorarrayvalueoperation.h +++ b/src/libs/installer/addqtcreatorarrayvalueoperation.h @@ -39,8 +39,8 @@ ** **************************************************************************/ -#ifndef ADDQTCREATORVALUEOPERATION_H -#define ADDQTCREATORVALUEOPERATION_H +#ifndef ADDQTCREATORARRAYVALUEOPERATION_H +#define ADDQTCREATORARRAYVALUEOPERATION_H #include "qinstallerglobal.h" @@ -60,4 +60,4 @@ public: } // namespace QInstaller -#endif // ADDQTCREATORVALUEOPERATION_H +#endif // ADDQTCREATORARRAYVALUEOPERATION_H diff --git a/src/libs/installer/adminauthorization_win.cpp b/src/libs/installer/adminauthorization_win.cpp index 20420cef0..151fef953 100644 --- a/src/libs/installer/adminauthorization_win.cpp +++ b/src/libs/installer/adminauthorization_win.cpp @@ -91,9 +91,9 @@ bool AdminAuthorization::hasAdminRights() &adminGroup)) return false; - BOOL isInAdminGroup = FALSE; - if (!CheckTokenMembership(0, adminGroup, &isInAdminGroup)) - isInAdminGroup = FALSE; + bool isInAdminGroup = false; + if (!CheckTokenMembership(0, adminGroup, (int*)&isInAdminGroup)) + isInAdminGroup = false; FreeSid(adminGroup); return isInAdminGroup; diff --git a/src/libs/installer/adminauthorization_x11.cpp b/src/libs/installer/adminauthorization_x11.cpp index 71a66cd83..6d5a52357 100644 --- a/src/libs/installer/adminauthorization_x11.cpp +++ b/src/libs/installer/adminauthorization_x11.cpp @@ -194,7 +194,7 @@ bool AdminAuthorization::execute(QWidget *parent, const QString &program, const const QString line = QString::fromLatin1(buf, bytes); if (re.indexIn(line) != -1) { const QString password = getPassword(parent); - if (password == QString()) { + if (password.isEmpty()) { QByteArray pwd = password.toLatin1(); for (int i = 0; i < 3; ++i) { ::write(masterFD, pwd.data(), pwd.length()); diff --git a/src/libs/installer/binaryformat.h b/src/libs/installer/binaryformat.h index 49be60a06..d255ea8a9 100644 --- a/src/libs/installer/binaryformat.h +++ b/src/libs/installer/binaryformat.h @@ -203,7 +203,7 @@ class INSTALLER_EXPORT BinaryContentPrivate : public QSharedData { public: BinaryContentPrivate(); - BinaryContentPrivate(const QString &path); + explicit BinaryContentPrivate(const QString &path); BinaryContentPrivate(const BinaryContentPrivate &other); ~BinaryContentPrivate(); diff --git a/src/libs/installer/component.cpp b/src/libs/installer/component.cpp index f9e809565..fb554155f 100644 --- a/src/libs/installer/component.cpp +++ b/src/libs/installer/component.cpp @@ -45,7 +45,6 @@ #include "fsengineclient.h" #include "lib7z_facade.h" #include "packagemanagercore.h" -#include "qinstallerglobal.h" #include "messageboxhandler.h" #include <kdupdaterupdatesourcesinfo.h> @@ -308,23 +307,22 @@ void Component::removeComponent(Component *component) } /*! - Returns a list of child components. If \a recursive is set to true, the returned list - contains not only the direct children, but all ancestors. Note: The returned list does include ALL - children, non virtual components as well as virtual components. + Returns a list of child components. If \a kind is set to DirectChildrenOnly, the returned list contains + only the direct children, if set to Descendants it will also include all descendants of the components + children. Note: The returned list does include ALL children, non virtual components as well as virtual + components. */ -QList<Component*> Component::childComponents(bool recursive, RunMode runMode) const +QList<Component *> Component::childComponents(Kind kind) const { - QList<Component*> result; - if (runMode == UpdaterMode) - return result; + if (d->m_core->isUpdater()) + return QList<Component*>(); - if (!recursive) - return d->m_allChildComponents; + QList<Component *> result = d->m_allChildComponents; + if (kind == DirectChildrenOnly) + return result; - foreach (Component *component, d->m_allChildComponents) { - result.append(component); - result += component->childComponents(true, runMode); - } + foreach (Component *component, d->m_allChildComponents) + result += component->childComponents(kind); return result; } diff --git a/src/libs/installer/component.h b/src/libs/installer/component.h index 1c8712145..343e1a3af 100644 --- a/src/libs/installer/component.h +++ b/src/libs/installer/component.h @@ -85,6 +85,12 @@ class INSTALLER_EXPORT Component : public QObject, public QScriptable, public Co Q_PROPERTY(bool enabled READ isEnabled WRITE setEnabled) public: + enum Kind + { + Descendants = 0x1000, // all descendants of the current component (children, grandchildren, etc.) + DirectChildrenOnly = 0x2000 // all child components of the current component + }; + explicit Component(PackageManagerCore *core); ~Component(); @@ -117,7 +123,7 @@ public: Component *parentComponent() const; void appendComponent(Component *component); void removeComponent(Component *component); - QList<Component*> childComponents(bool recursive, RunMode runMode) const; + QList<Component*> childComponents(Component::Kind kind) const; void loadComponentScript(); diff --git a/src/libs/installer/component_p.cpp b/src/libs/installer/component_p.cpp index 162b62c54..51455c27f 100644 --- a/src/libs/installer/component_p.cpp +++ b/src/libs/installer/component_p.cpp @@ -218,8 +218,10 @@ int ComponentModelHelper::childCount() const int ComponentModelHelper::indexInParent() const { int index = 0; - if (Component *parent = m_componentPrivate->m_parentComponent->parentComponent()) - index = parent->childComponents(false, AllMode).indexOf(m_componentPrivate->m_parentComponent); + if (Component *parent = m_componentPrivate->m_parentComponent->parentComponent()) { + index = parent->childComponents(Component::DirectChildrenOnly) + .indexOf(m_componentPrivate->m_parentComponent); + } return (index >= 0 ? index : 0); } diff --git a/src/libs/installer/componentmodel.cpp b/src/libs/installer/componentmodel.cpp index a87f59c00..264f69650 100644 --- a/src/libs/installer/componentmodel.cpp +++ b/src/libs/installer/componentmodel.cpp @@ -373,7 +373,7 @@ void ComponentModel::appendRootComponents(QList<QInstaller::Component*> rootComp void ComponentModel::slotModelReset() { QList<QInstaller::Component*> components = m_rootComponentList; - if (m_core->runMode() == QInstaller::AllMode) { + if (!m_core->isUpdater()) { for (int i = m_rootIndex; i < m_rootComponentList.count(); ++i) components.append(m_rootComponentList.at(i)->childs()); } @@ -384,7 +384,7 @@ void ComponentModel::slotModelReset() } m_currentCheckedSet += m_initialCheckedSet; - if (m_core->runMode() == QInstaller::AllMode) + if (!m_core->isUpdater()) select(Qt::Unchecked); foreach (const QString &name, m_currentCheckedSet) diff --git a/src/libs/installer/constants.h b/src/libs/installer/constants.h index 3929681a7..7ea73bbb9 100644 --- a/src/libs/installer/constants.h +++ b/src/libs/installer/constants.h @@ -80,6 +80,7 @@ static const QLatin1String scSortingPriority("SortingPriority"); static const QLatin1String scTitle("Title"); static const QLatin1String scPublisher("Publisher"); static const QLatin1String scRunProgram("RunProgram"); +static const QLatin1String scRunProgramArguments("RunProgramArguments"); static const QLatin1String scStartMenuDir("StartMenuDir"); static const QLatin1String scRemoveTargetDir("RemoveTargetDir"); static const QLatin1String scRunProgramDescription("RunProgramDescription"); diff --git a/src/libs/installer/createshortcutoperation.cpp b/src/libs/installer/createshortcutoperation.cpp index 62f7cfa82..2f2696fcd 100644 --- a/src/libs/installer/createshortcutoperation.cpp +++ b/src/libs/installer/createshortcutoperation.cpp @@ -107,8 +107,9 @@ static QString takeWorkingDirArgument(QStringList &args) static bool createLink(const QString &fileName, const QString &linkName, QString workingDir, QString arguments = QString()) { - bool success = QFile::link(fileName, linkName); #ifdef Q_OS_WIN + bool success = QFile::link(fileName, linkName); + if (!success) return success; @@ -131,7 +132,7 @@ static bool createLink(const QString &fileName, const QString &linkName, QString IPersistFile *ppf = NULL; if (SUCCEEDED(psl->QueryInterface(IID_IPersistFile, (void **)&ppf))) { - ppf->Save((wchar_t*)QDir::toNativeSeparators(linkName).utf16(), TRUE); + ppf->Save((wchar_t*)QDir::toNativeSeparators(linkName).utf16(), true); ppf->Release(); } psl->Release(); @@ -145,11 +146,16 @@ static bool createLink(const QString &fileName, const QString &linkName, QString SHChangeNotify(SHCNE_UPDATEDIR, SHCNF_IDLIST, pidl, 0); CoTaskMemFree(pidl); } + + return success; #else Q_UNUSED(arguments) Q_UNUSED(workingDir) + Q_UNUSED(fileName) + Q_UNUSED(linkName) + + return true; #endif - return success; } diff --git a/src/libs/installer/fsengineclient.cpp b/src/libs/installer/fsengineclient.cpp index c9aff560f..7822ed65b 100644 --- a/src/libs/installer/fsengineclient.cpp +++ b/src/libs/installer/fsengineclient.cpp @@ -753,7 +753,7 @@ void FSEngineClientHandler::setActive(bool active) } /*! - Returns, wheter this FSEngineClientHandler is active or not. + Returns true when this FSEngineClientHandler is active. */ bool FSEngineClientHandler::isActive() const { diff --git a/src/libs/installer/fsengineserver.cpp b/src/libs/installer/fsengineserver.cpp index 991681b95..76992c241 100644 --- a/src/libs/installer/fsengineserver.cpp +++ b/src/libs/installer/fsengineserver.cpp @@ -75,7 +75,7 @@ bool startDetached(const QString &program, const QStringList &args, const QStrin const QString arguments = QInstaller::createCommandline(program, args); const bool success = CreateProcess(0, (wchar_t*)arguments.utf16(), - 0, 0, FALSE, CREATE_UNICODE_ENVIRONMENT | CREATE_NEW_CONSOLE, + 0, 0, false, CREATE_UNICODE_ENVIRONMENT | CREATE_NEW_CONSOLE, 0, (wchar_t*)workingDirectory.utf16(), &startupInfo, &pinfo); diff --git a/src/libs/installer/getrepositoriesmetainfojob.cpp b/src/libs/installer/getrepositoriesmetainfojob.cpp index 996bf4692..7604bcf06 100644 --- a/src/libs/installer/getrepositoriesmetainfojob.cpp +++ b/src/libs/installer/getrepositoriesmetainfojob.cpp @@ -43,7 +43,6 @@ #include "getrepositorymetainfojob.h" #include "packagemanagercore_p.h" -#include "qinstallerglobal.h" #include <QtCore/QDebug> diff --git a/src/libs/installer/getrepositorymetainfojob.cpp b/src/libs/installer/getrepositorymetainfojob.cpp index 6fa21e32c..34441b02b 100644 --- a/src/libs/installer/getrepositorymetainfojob.cpp +++ b/src/libs/installer/getrepositorymetainfojob.cpp @@ -44,22 +44,13 @@ #include "lib7z_facade.h" #include "messageboxhandler.h" #include "packagemanagercore_p.h" -#include "qinstallerglobal.h" #include "utils.h" #include "kdupdaterfiledownloader.h" #include "kdupdaterfiledownloaderfactory.h" -#include <QtCore/QFile> -#include <QtCore/QTimer> -#include <QtCore/QUrl> +#include <QTimer> -#include <QMessageBox> - -#include <QtNetwork/QAuthenticator> - -#include <QtXml/QDomDocument> -#include <QtXml/QDomElement> using namespace KDUpdater; using namespace QInstaller; diff --git a/src/libs/installer/init.cpp b/src/libs/installer/init.cpp index e0c51a2f3..579446ebf 100644 --- a/src/libs/installer/init.cpp +++ b/src/libs/installer/init.cpp @@ -67,7 +67,7 @@ #include "setpluginpathonqtcoreoperation.h" #include "setimportspathonqtcoreoperation.h" #include "setpathonqtcoreoperation.h" -#include "registerqtvqnxoperation.h" +#include "registerqtincreatorqnxoperation.h" #include "setqtcreatorvalueoperation.h" #include "addqtcreatorarrayvalueoperation.h" #include "registertoolchainoperation.h" diff --git a/src/libs/installer/installer.pro b/src/libs/installer/installer.pro index 3308876fb..3b0b10813 100644 --- a/src/libs/installer/installer.pro +++ b/src/libs/installer/installer.pro @@ -24,15 +24,10 @@ DLLDESTDIR = $$IFW_APP_PATH DEFINES += BUILD_LIB_INSTALLER -QT += \ - script \ +QT += script \ network \ xml -isEqual(QT_MAJOR_VERSION, 5) { - QT += concurrent widgets core-private -} - HEADERS += packagemanagercore.h \ packagemanagercore_p.h \ packagemanagergui.h \ @@ -58,7 +53,6 @@ HEADERS += packagemanagercore.h \ replaceoperation.h \ linereplaceoperation.h \ registertoolchainoperation.h \ - registerqtvqnxoperation.h \ setqtcreatorvalueoperation.h \ addqtcreatorarrayvalueoperation.h \ copydirectoryoperation.h \ @@ -104,6 +98,7 @@ HEADERS += packagemanagercore.h \ link.h \ createlinkoperation.h \ packagemanagercoredata.h \ + registerqtincreatorqnxoperation.h \ applyproductkeyoperation.h SOURCES += packagemanagercore.cpp \ @@ -129,7 +124,6 @@ HEADERS += packagemanagercore.h \ replaceoperation.cpp \ linereplaceoperation.cpp \ registertoolchainoperation.cpp \ - registerqtvqnxoperation.cpp \ setqtcreatorvalueoperation.cpp \ addqtcreatorarrayvalueoperation.cpp \ copydirectoryoperation.cpp \ @@ -173,6 +167,7 @@ HEADERS += packagemanagercore.h \ link.cpp \ createlinkoperation.cpp \ packagemanagercoredata.cpp \ + registerqtincreatorqnxoperation.cpp \ applyproductkeyoperation.cpp RESOURCES += resources/patch_file_lists.qrc \ diff --git a/src/libs/installer/lib7z_facade.cpp b/src/libs/installer/lib7z_facade.cpp index 0c02890e2..fbec5e644 100644 --- a/src/libs/installer/lib7z_facade.cpp +++ b/src/libs/installer/lib7z_facade.cpp @@ -17,12 +17,12 @@ #include "Windows/PropVariant.h" #include "Windows/PropVariantConversions.h" -#include <QtCore/QDir> -#include <QtCore/QFileInfo> -#include <QtCore/QIODevice> +#include <QDir> +#include <QFileInfo> +#include <QIODevice> #include <QtCore/QMutexLocker> -#include <QtCore/QPointer> -#include <QtCore/QTemporaryFile> +#include <QPointer> +#include <QTemporaryFile> #ifdef _MSC_VER #pragma warning(disable:4297) diff --git a/src/libs/installer/lib7z_facade.h b/src/libs/installer/lib7z_facade.h index e61cce6ac..88185375e 100644 --- a/src/libs/installer/lib7z_facade.h +++ b/src/libs/installer/lib7z_facade.h @@ -3,14 +3,14 @@ #include "installer_global.h" +#include <QCoreApplication> #include <QDateTime> -#include <QtCore/QCoreApplication> -#include <QtCore/QFile> -#include <QtCore/QPoint> -#include <QtCore/QRunnable> -#include <QtCore/QString> -#include <QtCore/QVector> -#include <QtCore/QVariant> +#include <QFile> +#include <QPoint> +#include <QRunnable> +#include <QString> +#include <QVariant> +#include <QVector> #include "Common/MyWindows.h" diff --git a/src/libs/installer/link.h b/src/libs/installer/link.h index fc8d8fee3..e359c8f91 100644 --- a/src/libs/installer/link.h +++ b/src/libs/installer/link.h @@ -47,7 +47,7 @@ class Link { public: - Link(const QString &path); + explicit Link(const QString &path); static Link create(const QString &link, const QString &targetPath); QString targetPath() const; bool targetExists(); diff --git a/src/libs/installer/macreplaceinstallnamesoperation.h b/src/libs/installer/macreplaceinstallnamesoperation.h index 635f60054..f4b76de6d 100644 --- a/src/libs/installer/macreplaceinstallnamesoperation.h +++ b/src/libs/installer/macreplaceinstallnamesoperation.h @@ -39,8 +39,8 @@ ** **************************************************************************/ -#ifndef MACREPLACEINSTALLNAMEOPERATION_H -#define MACREPLACEINSTALLNAMEOPERATION_H +#ifndef MACREPLACEINSTALLNAMESOPERATION_H +#define MACREPLACEINSTALLNAMESOPERATION_H #include "qinstallerglobal.h" @@ -85,4 +85,4 @@ private: } // namespace QInstaller -#endif // MACREPLACEINSTALLNAMEOPERATION_H +#endif // MACREPLACEINSTALLNAMESOPERATION_H diff --git a/src/libs/installer/messageboxhandler.cpp b/src/libs/installer/messageboxhandler.cpp index cb9a845ff..219bc8057 100644 --- a/src/libs/installer/messageboxhandler.cpp +++ b/src/libs/installer/messageboxhandler.cpp @@ -47,8 +47,8 @@ #include <QDialogButtonBox> #include <QPushButton> -#include <QtScript/QScriptEngine> -#include <QtScript/QScriptValue> +#include <QScriptEngine> +#include <QScriptValue> QScriptValue QInstaller::registerMessageBox(QScriptEngine *scriptEngine) { diff --git a/src/libs/installer/packagemanagercore.cpp b/src/libs/installer/packagemanagercore.cpp index cb957f9aa..5b75aa0fb 100644 --- a/src/libs/installer/packagemanagercore.cpp +++ b/src/libs/installer/packagemanagercore.cpp @@ -39,6 +39,7 @@ ** **************************************************************************/ #include "packagemanagercore.h" +#include "packagemanagercore_p.h" #include "adminauthorization.h" #include "binaryformat.h" @@ -49,10 +50,8 @@ #include "fsengineclient.h" #include "getrepositoriesmetainfojob.h" #include "messageboxhandler.h" -#include "packagemanagercore_p.h" #include "packagemanagerproxyfactory.h" #include "progresscoordinator.h" -#include "qinstallerglobal.h" #include "qprocesswrapper.h" #include "qsettingswrapper.h" #include "settings.h" @@ -131,12 +130,12 @@ Component *PackageManagerCore::subComponentByName(const QInstaller::PackageManag if (check != 0 && componentMatches(check, name, version)) return check; - if (installer->runMode() == AllMode) { + if (!installer->isUpdater()) { QList<Component*> rootComponents; if (check == 0) rootComponents = installer->rootComponents(); else - rootComponents = check->childComponents(false, AllMode); + rootComponents = check->childComponents(Component::DirectChildrenOnly); foreach (QInstaller::Component *component, rootComponents) { Component *const result = subComponentByName(installer, name, version, component); @@ -487,7 +486,7 @@ void PackageManagerCore::rollBackInstallation() if (!componentName.isEmpty()) { Component *component = componentByName(componentName); if (!component) - component = d->componentsToReplace(runMode()).value(componentName).second; + component = d->componentsToReplace().value(componentName).second; if (component) { component->setUninstalled(); packages.removePackage(component->name()); @@ -606,11 +605,6 @@ void PackageManagerCore::setCreateLocalRepositoryFromBinary(bool create) sCreateLocalRepositoryFromBinary = create; } -RunMode PackageManagerCore::runMode() const -{ - return isUpdater() ? UpdaterMode : AllMode; -} - bool PackageManagerCore::fetchLocalPackagesTree() { d->setStatus(Running); @@ -725,7 +719,7 @@ bool PackageManagerCore::fetchRemotePackagesTree() return false; bool success = false; - if (runMode() == AllMode) + if (!isUpdater()) success = fetchAllPackages(packages, installedPackages); else { success = fetchUpdaterPackages(packages, installedPackages); @@ -934,7 +928,7 @@ QList<Component*> PackageManagerCore::availableComponents() const QList<Component*> result = d->m_rootComponents; foreach (QInstaller::Component *component, d->m_rootComponents) - result += component->childComponents(true, AllMode); + result += component->childComponents(Component::Descendants); return result + d->m_rootDependencyReplacements; } @@ -968,21 +962,23 @@ bool PackageManagerCore::calculateComponentsToInstall() const if (!d->m_componentsToInstallCalculated) { d->clearComponentsToInstall(); QList<Component*> components; - if (runMode() == UpdaterMode) { + if (isUpdater()) { foreach (Component *component, updaterComponents()) { if (component->updateRequested()) components.append(component); } - } else if (runMode() == AllMode) { + } else if (!isUpdater()) { // relevant means all components which are not replaced QList<Component*> relevantComponents = rootComponents(); foreach (QInstaller::Component *component, rootComponents()) - relevantComponents += component->childComponents(true, AllMode); + relevantComponents += component->childComponents(Component::Descendants); foreach (Component *component, relevantComponents) { // ask for all components which will be installed to get all dependencies - // even dependencies wich are changed without an increased version - if (component->installationRequested() || (component->isInstalled() && !component->uninstallationRequested())) - components.append(component); + // even dependencies which are changed without an increased version + if (component->installationRequested() || (component->isInstalled() + && !component->uninstallationRequested())) { + components.append(component); + } } } @@ -1005,10 +1001,10 @@ QList<Component*> PackageManagerCore::orderedComponentsToInstall() const */ bool PackageManagerCore::calculateComponentsToUninstall() const { - if (runMode() == UpdaterMode) + if (isUpdater()) return true; - // hack to avoid removeing needed dependencies + // hack to avoid removing needed dependencies QSet<Component*> componentsToInstall = d->m_orderedComponentsToInstall.toSet(); QList<Component*> components; @@ -1046,7 +1042,7 @@ QString PackageManagerCore::installReason(Component *component) const } /*! - Returns a list of components that dependend on \a component. The list can be empty. Note: Auto + Returns a list of components that depend on \a component. The list can be empty. Note: Auto installed dependencies are not resolved. */ QList<Component*> PackageManagerCore::dependees(const Component *_component) const @@ -1263,12 +1259,13 @@ bool PackageManagerCore::executeDetached(const QString &program, const QStringLi */ QString PackageManagerCore::environmentVariable(const QString &name) const { + if (name.isEmpty()) + return QString(); + #ifdef Q_OS_WIN - const LPCWSTR n = (LPCWSTR) name.utf16(); - LPTSTR buff = (LPTSTR) malloc(4096 * sizeof(TCHAR)); - DWORD getenvret = GetEnvironmentVariable(n, buff, 4096); - QString value = getenvret != 0 ? QString::fromUtf16((const unsigned short *) buff) : QString(); - free(buff); + static TCHAR buffer[32767]; + DWORD size = GetEnvironmentVariable(LPCWSTR(name.utf16()), buffer, 32767); + QString value = QString::fromUtf16((const unsigned short *) buffer, size); if (value.isEmpty()) { static QLatin1String userEnvironmentRegistryPath("HKEY_CURRENT_USER\\Environment"); @@ -1281,8 +1278,7 @@ QString PackageManagerCore::environmentVariable(const QString &name) const } return value; #else - const char *pPath = name.isEmpty() ? 0 : getenv(name.toLatin1()); - return pPath ? QLatin1String(pPath) : QString(); + return QString::fromUtf8(qgetenv(name.toLatin1())); #endif } @@ -1711,14 +1707,14 @@ void PackageManagerCore::storeReplacedComponents(QHash<QString, Component *> &co qWarning() << componentName << "- Does not exist in the repositories anymore."; continue; } - if (!component && !d->componentsToReplace(data.runMode).contains(componentName)) { + if (!component && !d->componentsToReplace().contains(componentName)) { component = new Component(this); component->setValue(scName, componentName); } else { component->loadComponentScript(); - d->replacementDependencyComponents(data.runMode).append(component); + d->replacementDependencyComponents().append(component); } - d->componentsToReplace(data.runMode).insert(componentName, qMakePair(it.key(), component)); + d->componentsToReplace().insert(componentName, qMakePair(it.key(), component)); } } } @@ -1731,7 +1727,6 @@ bool PackageManagerCore::fetchAllPackages(const PackagesList &remotes, const Loc QHash<QString, QInstaller::Component*> components; Data data; - data.runMode = AllMode; data.components = &components; data.installedPackages = &locals; @@ -1775,7 +1770,6 @@ bool PackageManagerCore::fetchUpdaterPackages(const PackagesList &remotes, const QHash<QString, QInstaller::Component *> components; Data data; - data.runMode = UpdaterMode; data.components = &components; data.installedPackages = &locals; diff --git a/src/libs/installer/packagemanagercore.h b/src/libs/installer/packagemanagercore.h index 50eb63184..df77cd115 100644 --- a/src/libs/installer/packagemanagercore.h +++ b/src/libs/installer/packagemanagercore.h @@ -121,7 +121,6 @@ public: bool fetchRemotePackagesTree(); bool run(); - RunMode runMode() const; void reset(const QHash<QString, QString> ¶ms); Q_INVOKABLE void setDependsOnLocalInstallerBinary(); @@ -297,7 +296,6 @@ Q_SIGNALS: private: struct Data { - RunMode runMode; Package *package; QHash<QString, Component*> *components; const LocalPackagesHash *installedPackages; diff --git a/src/libs/installer/packagemanagercore_p.cpp b/src/libs/installer/packagemanagercore_p.cpp index c0c1c78b4..9b25728d6 100644 --- a/src/libs/installer/packagemanagercore_p.cpp +++ b/src/libs/installer/packagemanagercore_p.cpp @@ -422,14 +422,14 @@ void PackageManagerCorePrivate::clearUpdaterComponentLists() m_componentsToInstallCalculated = false; } -QList<Component *> &PackageManagerCorePrivate::replacementDependencyComponents(RunMode mode) +QList<Component *> &PackageManagerCorePrivate::replacementDependencyComponents() { - return mode == AllMode ? m_rootDependencyReplacements : m_updaterDependencyReplacements; + return (!isUpdater()) ? m_rootDependencyReplacements : m_updaterDependencyReplacements; } -QHash<QString, QPair<Component*, Component*> > &PackageManagerCorePrivate::componentsToReplace(RunMode mode) +QHash<QString, QPair<Component*, Component*> > &PackageManagerCorePrivate::componentsToReplace() { - return mode == AllMode ? m_componentsToReplaceAllMode : m_componentsToReplaceUpdaterMode; + return (!isUpdater()) ? m_componentsToReplaceAllMode : m_componentsToReplaceUpdaterMode; } void PackageManagerCorePrivate::clearComponentsToInstall() @@ -453,7 +453,7 @@ bool PackageManagerCorePrivate::appendComponentsToInstall(const QList<Component relevantComponentForAutoDependOn = m_updaterComponents + m_updaterComponentsDeps; else { foreach (QInstaller::Component *component, m_rootComponents) - relevantComponentForAutoDependOn += component->childComponents(true, AllMode); + relevantComponentForAutoDependOn += component->childComponents(Component::Descendants); } QList<Component*> notAppendedComponents; // for example components with unresolved dependencies @@ -773,7 +773,7 @@ void PackageManagerCorePrivate::writeMaintenanceConfigFiles() QVariantHash variables; QSettingsWrapper cfg(iniPath, QSettingsWrapper::IniFormat); foreach (const QString &key, m_data.keys()) { - if (key != scRunProgramDescription && key != scRunProgram) + if (key != scRunProgramDescription && key != scRunProgram && key != scRunProgramArguments) variables.insert(key, m_data.value(key)); } cfg.setValue(QLatin1String("Variables"), variables); @@ -2006,7 +2006,7 @@ void PackageManagerCorePrivate::runUndoOperations(const OperationList &undoOpera if (!componentName.isEmpty()) { Component *component = m_core->componentByName(componentName); if (!component) - component = componentsToReplace(m_core->runMode()).value(componentName).second; + component = componentsToReplace().value(componentName).second; if (component) { component->setUninstalled(); packages.removePackage(component->name()); diff --git a/src/libs/installer/packagemanagercore_p.h b/src/libs/installer/packagemanagercore_p.h index 9d4a6abab..e77bff18f 100644 --- a/src/libs/installer/packagemanagercore_p.h +++ b/src/libs/installer/packagemanagercore_p.h @@ -43,18 +43,15 @@ #define PACKAGEMANAGERCORE_P_H #include "getrepositoriesmetainfojob.h" -#include "settings.h" #include "packagemanagercore.h" #include "packagemanagercoredata.h" +#include "qinstallerglobal.h" -#include <kdsysinfo.h> -#include <kdupdaterapplication.h> -#include <kdupdaterupdatefinder.h> +#include "kdsysinfo.h" +#include "kdupdaterapplication.h" +#include "kdupdaterfiledownloaderfactory.h" -#include <QtCore/QHash> -#include <QtCore/QObject> -#include <QtCore/QPair> -#include <QtCore/QPointer> +#include <QObject> class FSEngineClientHandler; class KDJob; @@ -117,8 +114,8 @@ public: void clearAllComponentLists(); void clearUpdaterComponentLists(); - QList<Component*> &replacementDependencyComponents(RunMode mode); - QHash<QString, QPair<Component*, Component*> > &componentsToReplace(RunMode mode); + QList<Component*> &replacementDependencyComponents(); + QHash<QString, QPair<Component*, Component*> > &componentsToReplace(); void clearComponentsToInstall(); bool appendComponentsToInstall(const QList<Component*> &components); diff --git a/src/libs/installer/packagemanagercoredata.cpp b/src/libs/installer/packagemanagercoredata.cpp index 4c848f13e..b15b2796c 100644 --- a/src/libs/installer/packagemanagercoredata.cpp +++ b/src/libs/installer/packagemanagercoredata.cpp @@ -99,6 +99,7 @@ PackageManagerCoreData::PackageManagerCoreData(const QHash<QString, QString> &va m_variables.insert(scTargetDir, replaceVariables(m_settings.targetDir())); m_variables.insert(scRunProgram, replaceVariables(m_settings.runProgram())); + m_variables.insert(scRunProgramArguments, replaceVariables(m_settings.runProgramArguments())); m_variables.insert(scRemoveTargetDir, replaceVariables(m_settings.removeTargetDir())); } diff --git a/src/libs/installer/packagemanagergui.cpp b/src/libs/installer/packagemanagergui.cpp index 1e01e69ff..c68891145 100644 --- a/src/libs/installer/packagemanagergui.cpp +++ b/src/libs/installer/packagemanagergui.cpp @@ -46,7 +46,6 @@ #include "fileutils.h" #include "messageboxhandler.h" #include "packagemanagercore.h" -#include "qinstallerglobal.h" #include "progresscoordinator.h" #include "performinstallationform.h" #include "settings.h" @@ -2012,11 +2011,13 @@ void FinishedPage::leaving() void FinishedPage::handleFinishClicked() { const QString program = packageManagerCore()->replaceVariables(packageManagerCore()->value(scRunProgram)); + const QStringList args = packageManagerCore()->replaceVariables( + packageManagerCore()->value(scRunProgramArguments)).split(QLatin1Char(' ')); if (!m_runItCheckBox->isChecked() || program.isEmpty()) return; - qDebug() << "starting" << program; - QProcess::startDetached(program); + qDebug() << "starting" << program << args; + QProcess::startDetached(program, args); } diff --git a/src/libs/installer/packagemanagerproxyfactory.h b/src/libs/installer/packagemanagerproxyfactory.h index 2ddfe7a18..a50605232 100644 --- a/src/libs/installer/packagemanagerproxyfactory.h +++ b/src/libs/installer/packagemanagerproxyfactory.h @@ -51,7 +51,7 @@ class PackageManagerCore; class PackageManagerProxyFactory : public KDUpdater::FileDownloaderProxyFactory { public: - PackageManagerProxyFactory(const PackageManagerCore *const core); + explicit PackageManagerProxyFactory(const PackageManagerCore *const core); PackageManagerProxyFactory *clone() const; QList<QNetworkProxy> queryProxy(const QNetworkProxyQuery &query = QNetworkProxyQuery()); diff --git a/src/libs/installer/performinstallationform.h b/src/libs/installer/performinstallationform.h index f3471ebe2..209afc42d 100644 --- a/src/libs/installer/performinstallationform.h +++ b/src/libs/installer/performinstallationform.h @@ -61,7 +61,7 @@ class PerformInstallationForm : public QObject Q_OBJECT public: - PerformInstallationForm(QObject *parent); + explicit PerformInstallationForm(QObject *parent); void setupUi(QWidget *widget); void setDetailsWidgetVisible(bool visible); diff --git a/src/libs/installer/progresscoordinator.h b/src/libs/installer/progresscoordinator.h index b1fa0ab67..263b25695 100644 --- a/src/libs/installer/progresscoordinator.h +++ b/src/libs/installer/progresscoordinator.h @@ -39,8 +39,8 @@ ** **************************************************************************/ -#ifndef PROGRESSCOORDNINATOR_H -#define PROGRESSCOORDNINATOR_H +#ifndef PROGRESSCOORDINATOR_H +#define PROGRESSCOORDINATOR_H #include <QtCore/QHash> #include <QtCore/QObject> @@ -102,4 +102,4 @@ private: } //namespace QInstaller -#endif //PROGRESSCOORDNINATOR_H +#endif //PROGRESSCOORDINATOR_H diff --git a/src/libs/installer/qinstallerglobal.h b/src/libs/installer/qinstallerglobal.h index b7d5d3f3d..81635830b 100644 --- a/src/libs/installer/qinstallerglobal.h +++ b/src/libs/installer/qinstallerglobal.h @@ -59,12 +59,6 @@ namespace QInstaller { static QRegExp scCommaRegExp(QLatin1String("\\b(,|, )\\b")); -enum INSTALLER_EXPORT RunMode -{ - AllMode, - UpdaterMode -}; - enum INSTALLER_EXPORT JobError { InvalidUrl = 0x24B04, diff --git a/src/libs/installer/registerqtvqnxoperation.cpp b/src/libs/installer/registerqtincreatorqnxoperation.cpp index b52558145..be99de4c7 100644 --- a/src/libs/installer/registerqtvqnxoperation.cpp +++ b/src/libs/installer/registerqtincreatorqnxoperation.cpp @@ -39,7 +39,7 @@ ** **************************************************************************/ -#include "registerqtvqnxoperation.h" +#include "registerqtincreatorqnxoperation.h" #include "packagemanagercore.h" #include "qtcreator_constants.h" diff --git a/src/libs/installer/registerqtvqnxoperation.h b/src/libs/installer/registerqtincreatorqnxoperation.h index a5e49656a..5b6a3c9b1 100644 --- a/src/libs/installer/registerqtvqnxoperation.h +++ b/src/libs/installer/registerqtincreatorqnxoperation.h @@ -39,8 +39,8 @@ ** **************************************************************************/ -#ifndef REGISTERQTINCREATORVQNXOPERATION_H -#define REGISTERQTINCREATORVQNXOPERATION_H +#ifndef REGISTERQTINCREATORQNXOPERATION_H +#define REGISTERQTINCREATORQNXOPERATION_H #include "qinstallerglobal.h" @@ -60,4 +60,4 @@ public: } // namespace QInstaller -#endif // REGISTERQTINCREATORVQNXOPERATION_H +#endif // REGISTERQTINCREATORQNXOPERATION_H diff --git a/src/libs/installer/settings.cpp b/src/libs/installer/settings.cpp index a01836253..6503b8778 100644 --- a/src/libs/installer/settings.cpp +++ b/src/libs/installer/settings.cpp @@ -41,7 +41,6 @@ #include "settings.h" #include "errors.h" -#include "qinstallerglobal.h" #include "repository.h" #include <QtCore/QFileInfo> @@ -218,7 +217,7 @@ Settings Settings::fromFileAndPrefix(const QString &path, const QString &prefix) << scTargetDir << scAdminTargetDir << scIcon << scLogo << scLogoSmall << scWatermark << scBackground << scStartMenuDir << scUninstallerName << scUninstallerIniFile << scRemoveTargetDir - << scRunProgram << scRunProgramDescription + << scRunProgram << scRunProgramArguments << scRunProgramDescription << scDependsOnLocalInstallerBinary << scAllowSpaceInPath << scAllowNonAsciiCharacters << scRepositorySettingsPageVisible << scTargetConfigurationFile @@ -361,6 +360,11 @@ QString Settings::runProgram() const return d->m_data.value(scRunProgram).toString(); } +QString Settings::runProgramArguments() const +{ + return d->m_data.value(scRunProgramArguments).toString(); +} + QString Settings::runProgramDescription() const { return d->m_data.value(scRunProgramDescription).toString(); diff --git a/src/libs/installer/settings.h b/src/libs/installer/settings.h index 51355d038..db7212b1e 100644 --- a/src/libs/installer/settings.h +++ b/src/libs/installer/settings.h @@ -95,6 +95,7 @@ public: QString applicationVersion() const; QString runProgram() const; + QString runProgramArguments() const; QString runProgramDescription() const; QString startMenuDir() const; QString targetDir() const; diff --git a/src/libs/installer/utils.h b/src/libs/installer/utils.h index 0d21adbee..e6aca456d 100644 --- a/src/libs/installer/utils.h +++ b/src/libs/installer/utils.h @@ -81,7 +81,7 @@ namespace QInstaller { { Q_OBJECT public: - VerboseWriter(QObject *parent = 0); + explicit VerboseWriter(QObject *parent = 0); ~VerboseWriter(); static VerboseWriter *instance(); diff --git a/src/libs/kdtools/kdsysinfo_win.cpp b/src/libs/kdtools/kdsysinfo_win.cpp index 10666c8e0..0fa605ef9 100644 --- a/src/libs/kdtools/kdsysinfo_win.cpp +++ b/src/libs/kdtools/kdsysinfo_win.cpp @@ -247,7 +247,7 @@ bool killProcess(const ProcessInfo &process, int msecs) // If we can't open the process with PROCESS_TERMINATE rights, // then we give up immediately. - HANDLE hProc = OpenProcess(SYNCHRONIZE | PROCESS_TERMINATE, FALSE, process.id); + HANDLE hProc = OpenProcess(SYNCHRONIZE | PROCESS_TERMINATE, false, process.id); if (hProc == 0) return false; diff --git a/src/libs/kdtools/kdupdaterupdateoperation.cpp b/src/libs/kdtools/kdupdaterupdateoperation.cpp index 40d2e5ada..6f09bc825 100644 --- a/src/libs/kdtools/kdupdaterupdateoperation.cpp +++ b/src/libs/kdtools/kdupdaterupdateoperation.cpp @@ -38,7 +38,7 @@ update operations. Concrete implementations of this class must perform a single update operation like copy, move, delete etc. - \note Two seperate threads cannot be using a single instance of KDUpdater::UpdateOperation + \note Two separate threads cannot be using a single instance of KDUpdater::UpdateOperation at the same time. */ diff --git a/src/libs/kdtools/kdupdaterupdateoperations.cpp b/src/libs/kdtools/kdupdaterupdateoperations.cpp index 8270bba03..51fcaf7b1 100644 --- a/src/libs/kdtools/kdupdaterupdateoperations.cpp +++ b/src/libs/kdtools/kdupdaterupdateoperations.cpp @@ -886,7 +886,7 @@ bool ExecuteOperation::performOperation() 0, 0, 0, STARTF_USESHOWWINDOW, SW_HIDE, 0, 0, 0, 0, 0 }; success = CreateProcess(0, (wchar_t*)arguments.utf16(), - 0, 0, FALSE, CREATE_UNICODE_ENVIRONMENT | CREATE_NEW_CONSOLE, 0, + 0, 0, false, CREATE_UNICODE_ENVIRONMENT | CREATE_NEW_CONSOLE, 0, 0, &startupInfo, &pinfo); diff --git a/src/sdk/installerbase_p.h b/src/sdk/installerbase_p.h index bea4c862f..cd6ed0142 100644 --- a/src/sdk/installerbase_p.h +++ b/src/sdk/installerbase_p.h @@ -66,7 +66,7 @@ class InstallerBase : public QObject Q_OBJECT public: - InstallerBase(QObject *parent = 0); + explicit InstallerBase(QObject *parent = 0); ~InstallerBase(); int replaceMaintenanceToolBinary(QStringList arguments); diff --git a/src/sdk/settingsdialog.cpp b/src/sdk/settingsdialog.cpp index 5773d65c5..b9bfba617 100644 --- a/src/sdk/settingsdialog.cpp +++ b/src/sdk/settingsdialog.cpp @@ -54,6 +54,8 @@ #include <QtXml/QDomDocument> +using namespace QInstaller; + // -- TestRepositoryJob @@ -72,12 +74,12 @@ TestRepository::~TestRepository() m_downloader->deleteLater(); } -QInstaller::Repository TestRepository::repository() const +Repository TestRepository::repository() const { return m_repository; } -void TestRepository::setRepository(const QInstaller::Repository &repository) +void TestRepository::setRepository(const Repository &repository) { cancel(); @@ -93,13 +95,13 @@ void TestRepository::doStart() const QUrl url = m_repository.url(); if (url.isEmpty()) { - emitFinishedWithError(QInstaller::InvalidUrl, tr("Empty repository URL.")); + emitFinishedWithError(InvalidUrl, tr("Empty repository URL.")); return; } m_downloader = KDUpdater::FileDownloaderFactory::instance().create(url.scheme(), this); if (!m_downloader) { - emitFinishedWithError(QInstaller::InvalidUrl, tr("URL scheme not supported: %1 (%2).") + emitFinishedWithError(InvalidUrl, tr("URL scheme not supported: %1 (%2).") .arg(url.scheme(), url.toString())); return; } @@ -132,7 +134,7 @@ void TestRepository::doCancel() void TestRepository::downloadCompleted() { QString errorMsg; - int error = QInstaller::DownloadError; + int error = DownloadError; if (m_downloader->isDownloaded()) { QFile file(m_downloader->downloadedFileName()); @@ -140,7 +142,7 @@ void TestRepository::downloadCompleted() QDomDocument doc; QString errorMsg; if (!doc.setContent(&file, &errorMsg)) { - error = QInstaller::InvalidUpdatesXml; + error = InvalidUpdatesXml; errorMsg = tr("Could not parse Updates.xml! Error: %1."); } else { error = NoError; @@ -163,7 +165,7 @@ void TestRepository::downloadCompleted() void TestRepository::downloadAborted(const QString &reason) { - emitFinishedWithError(QInstaller::DownloadError, reason); + emitFinishedWithError(DownloadError, reason); } void TestRepository::onAuthenticatorChanged(const QAuthenticator &authenticator) @@ -214,7 +216,7 @@ RepositoryItem::RepositoryItem(const QString &label) m_repo = QInstaller::Repository(QUrl(), true); } -RepositoryItem::RepositoryItem(const QInstaller::Repository &repo) +RepositoryItem::RepositoryItem(const Repository &repo) : QTreeWidgetItem(QTreeWidgetItem::UserType) , m_repo(repo) { @@ -302,9 +304,9 @@ void RepositoryItem::setData(int column, int role, const QVariant &value) QTreeWidgetItem::setData(column, role, value); } -QSet<QInstaller::Repository> RepositoryItem::repositories() const +QSet<Repository> RepositoryItem::repositories() const { - QSet<QInstaller::Repository> set; + QSet<Repository> set; for (int i = 0; i < childCount(); ++i) { if (QTreeWidgetItem *item = child(i)) { if (item->type() == QTreeWidgetItem::UserType) { @@ -319,7 +321,7 @@ QSet<QInstaller::Repository> RepositoryItem::repositories() const // -- SettingsDialog -SettingsDialog::SettingsDialog(QInstaller::PackageManagerCore *core, QWidget *parent) +SettingsDialog::SettingsDialog(PackageManagerCore *core, QWidget *parent) : QDialog(parent) , m_ui(new Ui::SettingsDialog) , m_core(core) @@ -328,15 +330,15 @@ SettingsDialog::SettingsDialog(QInstaller::PackageManagerCore *core, QWidget *pa m_ui->setupUi(this); setupRepositoriesTreeWidget(); - const QInstaller::Settings &settings = m_core->settings(); + const Settings &settings = m_core->settings(); switch (settings.proxyType()) { - case QInstaller::Settings::NoProxy: + case Settings::NoProxy: m_ui->m_noProxySettings->setChecked(true); break; - case QInstaller::Settings::SystemProxy: + case Settings::SystemProxy: m_ui->m_systemProxySettings->setChecked(true); break; - case QInstaller::Settings::UserDefinedProxy: + case Settings::UserDefinedProxy: m_ui->m_manualProxySettings->setChecked(true); break; default: @@ -381,8 +383,8 @@ SettingsDialog::SettingsDialog(QInstaller::PackageManagerCore *core, QWidget *pa void SettingsDialog::accept() { bool settingsChanged = false; - QInstaller::Settings newSettings; - const QInstaller::Settings &settings = m_core->settings(); + Settings newSettings; + const Settings &settings = m_core->settings(); // set possible updated default repositories newSettings.setDefaultRepositories((dynamic_cast<RepositoryItem*> (m_rootItems.at(0)))->repositories()); @@ -399,14 +401,14 @@ void SettingsDialog::accept() settingsChanged |= (settings.userRepositories() != newSettings.userRepositories()); // update proxy type - newSettings.setProxyType(QInstaller::Settings::NoProxy); + newSettings.setProxyType(Settings::NoProxy); if (m_ui->m_systemProxySettings->isChecked()) - newSettings.setProxyType(QInstaller::Settings::SystemProxy); + newSettings.setProxyType(Settings::SystemProxy); else if (m_ui->m_manualProxySettings->isChecked()) - newSettings.setProxyType(QInstaller::Settings::UserDefinedProxy); + newSettings.setProxyType(Settings::UserDefinedProxy); settingsChanged |= settings.proxyType() != newSettings.proxyType(); - if (newSettings.proxyType() == QInstaller::Settings::UserDefinedProxy) { + if (newSettings.proxyType() == Settings::UserDefinedProxy) { // update ftp proxy settings newSettings.setFtpProxy(QNetworkProxy(QNetworkProxy::HttpProxy, m_ui->m_ftpProxy->text(), m_ui->m_ftpProxyPort->value(), m_ui->m_ftpProxyUser->text(), m_ui->m_ftpProxyPass->text())); @@ -436,7 +438,7 @@ void SettingsDialog::addRepository() } if (parent) { - QInstaller::Repository repository; + Repository repository; repository.setEnabled(true); RepositoryItem *item = new RepositoryItem(repository); parent->insertChild(index, item); @@ -537,7 +539,7 @@ void SettingsDialog::setupRepositoriesTreeWidget() m_rootItems.append(new RepositoryItem(tr("User defined repositories"))); treeWidget->addTopLevelItems(m_rootItems); - const QInstaller::Settings &settings = m_core->settings(); + const Settings &settings = m_core->settings(); insertRepositories(settings.userRepositories(), m_rootItems.at(2)); insertRepositories(settings.defaultRepositories(), m_rootItems.at(0)); insertRepositories(settings.temporaryRepositories(), m_rootItems.at(1)); @@ -562,9 +564,9 @@ void SettingsDialog::setupRepositoriesTreeWidget() m_delegate->disableEditing(false); } -void SettingsDialog::insertRepositories(const QSet<QInstaller::Repository> repos, QTreeWidgetItem *rootItem) +void SettingsDialog::insertRepositories(const QSet<Repository> repos, QTreeWidgetItem *rootItem) { rootItem->setFirstColumnSpanned(true); - foreach (const QInstaller::Repository &repo, repos) + foreach (const Repository &repo, repos) rootItem->addChild(new RepositoryItem(repo)); } diff --git a/src/sdk/settingsdialog.h b/src/sdk/settingsdialog.h index f0d068a78..1a6633c67 100644 --- a/src/sdk/settingsdialog.h +++ b/src/sdk/settingsdialog.h @@ -77,7 +77,7 @@ class TestRepository : public KDJob public: - TestRepository(QObject *parent = 0); + explicit TestRepository(QObject *parent = 0); ~TestRepository(); QInstaller::Repository repository() const; @@ -105,7 +105,7 @@ class PasswordDelegate : public QStyledItemDelegate Q_OBJECT public: - PasswordDelegate(QWidget *parent = 0) + explicit PasswordDelegate(QWidget *parent = 0) : QStyledItemDelegate(parent) , m_showPasswords(true) , m_disabledEditor(true) @@ -129,8 +129,8 @@ private: class RepositoryItem : public QTreeWidgetItem { public: - RepositoryItem(const QString &label); - RepositoryItem(const QInstaller::Repository &repo); + explicit RepositoryItem(const QString &label); + explicit RepositoryItem(const QInstaller::Repository &repo); QVariant data(int column, int role) const; void setData(int column, int role, const QVariant &value); @@ -151,7 +151,7 @@ class SettingsDialog : public QDialog Q_OBJECT public: - SettingsDialog(QInstaller::PackageManagerCore *core, QWidget *parent = 0); + explicit SettingsDialog(QInstaller::PackageManagerCore *core, QWidget *parent = 0); public slots: void accept(); |