forked from qt-creator/qt-creator
Make the public interface of QtVersionManager smaller
Move 3 functions to private, declare 2 which don't need any instance to staic methods.
This commit is contained in:
@@ -126,34 +126,39 @@ private:
|
|||||||
class PROJECTEXPLORER_EXPORT QtVersionManager : public QObject
|
class PROJECTEXPLORER_EXPORT QtVersionManager : public QObject
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
// for getUniqueId();
|
||||||
|
friend class QtVersion;
|
||||||
|
friend class QtOptionsPage;
|
||||||
public:
|
public:
|
||||||
static QtVersionManager *instance();
|
static QtVersionManager *instance();
|
||||||
QtVersionManager();
|
QtVersionManager();
|
||||||
~QtVersionManager();
|
~QtVersionManager();
|
||||||
void writeVersionsIntoSettings();
|
|
||||||
|
|
||||||
QList<QtVersion *> versions() const;
|
QList<QtVersion *> versions() const;
|
||||||
|
|
||||||
QtVersion * version(int id) const;
|
QtVersion *version(int id) const;
|
||||||
QtVersion * currentQtVersion() const;
|
QtVersion *currentQtVersion() const;
|
||||||
// internal
|
|
||||||
int getUniqueId();
|
|
||||||
|
|
||||||
QtVersion::QmakeBuildConfig scanMakefileForQmakeConfig(const QString &directory, QtVersion::QmakeBuildConfig defaultBuildConfig);
|
|
||||||
QString findQtVersionFromMakefile(const QString &directory);
|
|
||||||
QtVersion *qtVersionForDirectory(const QString &directory);
|
QtVersion *qtVersionForDirectory(const QString &directory);
|
||||||
// Used by the projectloadwizard
|
// Used by the projectloadwizard
|
||||||
void addVersion(QtVersion *version);
|
void addVersion(QtVersion *version);
|
||||||
|
|
||||||
|
// Static Methods
|
||||||
// returns something like qmake4, qmake, qmake-qt4 or whatever distributions have chosen (used by QtVersion)
|
// returns something like qmake4, qmake, qmake-qt4 or whatever distributions have chosen (used by QtVersion)
|
||||||
static QStringList possibleQMakeCommands();
|
static QStringList possibleQMakeCommands();
|
||||||
// return true if the qmake at qmakePath is qt4 (used by QtVersion)
|
// return true if the qmake at qmakePath is qt4 (used by QtVersion)
|
||||||
static QString qtVersionForQMake(const QString &qmakePath);
|
static QString qtVersionForQMake(const QString &qmakePath);
|
||||||
void setNewQtVersions(QList<QtVersion *> newVersions, int newDefaultVersion);
|
static QtVersion::QmakeBuildConfig scanMakefileForQmakeConfig(const QString &directory, QtVersion::QmakeBuildConfig defaultBuildConfig);
|
||||||
|
static QString findQtVersionFromMakefile(const QString &directory);
|
||||||
signals:
|
signals:
|
||||||
void defaultQtVersionChanged();
|
void defaultQtVersionChanged();
|
||||||
void qtVersionsChanged();
|
void qtVersionsChanged();
|
||||||
private:
|
private:
|
||||||
|
// Used by QtOptionsPage
|
||||||
|
void setNewQtVersions(QList<QtVersion *> newVersions, int newDefaultVersion);
|
||||||
|
// Used by QtVersion
|
||||||
|
int getUniqueId();
|
||||||
|
void writeVersionsIntoSettings();
|
||||||
void addNewVersionsFromInstaller();
|
void addNewVersionsFromInstaller();
|
||||||
void updateSystemVersion();
|
void updateSystemVersion();
|
||||||
void updateDocumentation();
|
void updateDocumentation();
|
||||||
|
Reference in New Issue
Block a user