Commit 52ee9e22 authored by Pekka Vuorela's avatar Pekka Vuorela

Run astyle for Qt coding conventions

Parameters from
https://wiki.qt.io/Qt_Coding_Style#Artistic_Style
except line length to 120
parent a470b9b0
...@@ -19,9 +19,9 @@ public: ...@@ -19,9 +19,9 @@ public:
* A list of types ssu provides shiny values suitable for displaying * A list of types ssu provides shiny values suitable for displaying
*/ */
enum DisplayType { enum DisplayType {
DeviceManufacturer = Ssu::DeviceManufacturer, ///< Manufacturer, like ACME Corp. Board mappings key "deviceManufacturer" DeviceManufacturer = Ssu::DeviceManufacturer, ///< Manufacturer, like ACME Corp. Board mappings key "deviceManufacturer"
DeviceModel = Ssu::DeviceModel, ///< Marketed device name, like Pogoblaster 3000. Board mappings key "prettyModel" DeviceModel = Ssu::DeviceModel, ///< Marketed device name, like Pogoblaster 3000. Board mappings key "prettyModel"
DeviceDesignation = Ssu::DeviceDesignation, ///< Type designation, like NCC-1701. Beard mappings key "deviceDesignation" DeviceDesignation = Ssu::DeviceDesignation, ///< Type designation, like NCC-1701. Beard mappings key "deviceDesignation"
}; };
DeclarativeSsuDeviceInfo(); DeclarativeSsuDeviceInfo();
...@@ -37,7 +37,7 @@ public: ...@@ -37,7 +37,7 @@ public:
* If the device is not a variant it will return an empty string. If * If the device is not a variant it will return an empty string. If
* fallback is set to true it return the device model in this case. * fallback is set to true it return the device model in this case.
*/ */
Q_INVOKABLE QString deviceVariant(bool fallback=false); Q_INVOKABLE QString deviceVariant(bool fallback = false);
/** /**
* Try to find out ond what kind of system this is running * Try to find out ond what kind of system this is running
*/ */
......
This diff is collapsed.
...@@ -18,20 +18,21 @@ ...@@ -18,20 +18,21 @@
getenv("SSU_TESTS_DATA_PATH") : \ getenv("SSU_TESTS_DATA_PATH") : \
TESTS_DATA_PATH) TESTS_DATA_PATH)
class Sandbox { class Sandbox
public: {
public:
enum Usage { enum Usage {
UseDirectly, UseDirectly,
UseAsSkeleton, UseAsSkeleton,
}; };
enum Scope { enum Scope {
ThisProcess = 0x01, ThisProcess = 0x01,
ChildProcesses = 0x02, ChildProcesses = 0x02,
}; };
Q_DECLARE_FLAGS(Scopes, Scope) Q_DECLARE_FLAGS(Scopes, Scope)
public: public:
Sandbox(); Sandbox();
Sandbox(const QString &sandboxPath, Usage usage, Scopes scopes); Sandbox(const QString &sandboxPath, Usage usage, Scopes scopes);
~Sandbox(); ~Sandbox();
...@@ -45,15 +46,15 @@ class Sandbox { ...@@ -45,15 +46,15 @@ class Sandbox {
static QString map(const QString &pathName, const QString &fileName); static QString map(const QString &pathName, const QString &fileName);
bool addWorldFiles(const QString &directory, QDir::Filters filters = QDir::NoFilter, bool addWorldFiles(const QString &directory, QDir::Filters filters = QDir::NoFilter,
const QStringList &filterNames = QStringList(), bool recurse = true); const QStringList &filterNames = QStringList(), bool recurse = true);
bool addWorldFile(const QString &file); bool addWorldFile(const QString &file);
private: private:
bool prepare(); bool prepare();
static QString createTmpDir(const QString &nameTemplate); static QString createTmpDir(const QString &nameTemplate);
static bool copyDir(const QString &directory, const QString &newName); static bool copyDir(const QString &directory, const QString &newName);
private: private:
static Sandbox *s_activeInstance; static Sandbox *s_activeInstance;
const bool m_defaultConstructed; const bool m_defaultConstructed;
const Usage m_usage; const Usage m_usage;
......
This diff is collapsed.
...@@ -16,20 +16,21 @@ class QNetworkAccessManager; ...@@ -16,20 +16,21 @@ class QNetworkAccessManager;
class QNetworkReply; class QNetworkReply;
class QDomDocument; class QDomDocument;
class Ssu: public QObject { class Ssu: public QObject
{
Q_OBJECT Q_OBJECT
friend class UrlResolverTest; friend class UrlResolverTest;
public: public:
/** /**
* Filters to control the output of the repository lookup methods * Filters to control the output of the repository lookup methods
*/ */
enum RepoFilter { enum RepoFilter {
NoFilter, ///< All repositories (global + user) NoFilter, ///< All repositories (global + user)
UserFilter, ///< Only user configured repositories UserFilter, ///< Only user configured repositories
BoardFilter, ///< Only global repositories, with user blacklist ignored BoardFilter, ///< Only global repositories, with user blacklist ignored
BoardFilterUserBlacklist, ///< Only global repositories, with user blacklist applied BoardFilterUserBlacklist, ///< Only global repositories, with user blacklist applied
}; };
/** /**
...@@ -43,12 +44,12 @@ class Ssu: public QObject { ...@@ -43,12 +44,12 @@ class Ssu: public QObject {
* like in AppInstallMode. * like in AppInstallMode.
*/ */
enum DeviceMode { enum DeviceMode {
DisableRepoManager = 0x1, ///< Disable automagic repository management DisableRepoManager = 0x1, ///< Disable automagic repository management
RndMode = 0x2, ///< Enable RnD mode for device RndMode = 0x2, ///< Enable RnD mode for device
ReleaseMode = 0x4, ///< Enable Release mode ReleaseMode = 0x4, ///< Enable Release mode
LenientMode = 0x8, ///< Disable strict mode (i.e., keep unmanaged repositories) LenientMode = 0x8, ///< Disable strict mode (i.e., keep unmanaged repositories)
UpdateMode = 0x10, ///< Do repo isolation and similar bits important for updating devices UpdateMode = 0x10, ///< Do repo isolation and similar bits important for updating devices
AppInstallMode = 0x20 ///< Do repo isolation, but keep store repository enabled AppInstallMode = 0x20 ///< Do repo isolation, but keep store repository enabled
}; };
Q_DECLARE_FLAGS(DeviceModeFlags, DeviceMode) Q_DECLARE_FLAGS(DeviceModeFlags, DeviceMode)
...@@ -57,26 +58,26 @@ class Ssu: public QObject { ...@@ -57,26 +58,26 @@ class Ssu: public QObject {
* A list of types ssu provides shiny values suitable for displaying * A list of types ssu provides shiny values suitable for displaying
*/ */
enum DisplayType { enum DisplayType {
DeviceManufacturer = 0, ///< Manufacturer, like ACME Corp. Board mappings key "deviceManufacturer" DeviceManufacturer = 0, ///< Manufacturer, like ACME Corp. Board mappings key "deviceManufacturer"
DeviceModel, ///< Marketed device name, like Pogoblaster 3000. Board mappings key "prettyModel" DeviceModel, ///< Marketed device name, like Pogoblaster 3000. Board mappings key "prettyModel"
DeviceDesignation, ///< Type designation, like NCC-1701. Beard mappings key "deviceDesignation" DeviceDesignation, ///< Type designation, like NCC-1701. Beard mappings key "deviceDesignation"
}; };
/** /**
* Edit modes for variables containing bitmasks * Edit modes for variables containing bitmasks
*/ */
enum EditMode { enum EditMode {
Replace = 0x1, ///< Replace the old value with the new one Replace = 0x1, ///< Replace the old value with the new one
Add = 0x2, ///< Make sure the given value is set in the bitmask Add = 0x2, ///< Make sure the given value is set in the bitmask
Remove = 0x4, ///< Make sure the given value is not set in the bitmask Remove = 0x4, ///< Make sure the given value is not set in the bitmask
}; };
/** /**
* Return codes to signal success or error conditions * Return codes to signal success or error conditions
*/ */
enum ReturnValue { enum ReturnValue {
Success = 0, Success = 0,
ErrUpdateMode = -10, ErrUpdateMode = -10,
}; };
Ssu(); Ssu();
...@@ -94,7 +95,7 @@ class Ssu: public QObject { ...@@ -94,7 +95,7 @@ class Ssu: public QObject {
* *
* @return a string containing the scope; it can be used to look up login credentials using credentials() * @return a string containing the scope; it can be used to look up login credentials using credentials()
*/ */
QString credentialsScope(QString repoName, bool rndRepo=false); QString credentialsScope(QString repoName, bool rndRepo = false);
/** /**
* Return the URL for which credentials scope is valid * Return the URL for which credentials scope is valid
*/ */
...@@ -115,9 +116,9 @@ class Ssu: public QObject { ...@@ -115,9 +116,9 @@ class Ssu: public QObject {
* Resolve a repository url * Resolve a repository url
* @return the repository URL on success, an empty string on error * @return the repository URL on success, an empty string on error
*/ */
QString repoUrl(QString repoName, bool rndRepo=false, QString repoUrl(QString repoName, bool rndRepo = false,
QHash<QString, QString> repoParameters=QHash<QString, QString>(), QHash<QString, QString> repoParameters = QHash<QString, QString>(),
QHash<QString, QString> parametersOverride=QHash<QString, QString>()); QHash<QString, QString> parametersOverride = QHash<QString, QString>());
/** /**
* Unregister a device. This will clean all registration data from a device, * Unregister a device. This will clean all registration data from a device,
* though will not touch the information on ssu server; the information there * though will not touch the information on ssu server; the information there
...@@ -141,19 +142,19 @@ class Ssu: public QObject { ...@@ -141,19 +142,19 @@ class Ssu: public QObject {
/// See SsuCoreConfig::lastCredentialsUpdate /// See SsuCoreConfig::lastCredentialsUpdate
Q_INVOKABLE QDateTime lastCredentialsUpdate(); Q_INVOKABLE QDateTime lastCredentialsUpdate();
/// See SsuCoreConfig::release /// See SsuCoreConfig::release
Q_INVOKABLE QString release(bool rnd=false); Q_INVOKABLE QString release(bool rnd = false);
/// See SsuCoreConfig::setDeviceMode /// See SsuCoreConfig::setDeviceMode
Q_INVOKABLE void setDeviceMode(DeviceModeFlags mode, enum EditMode editMode=Replace); Q_INVOKABLE void setDeviceMode(DeviceModeFlags mode, enum EditMode editMode = Replace);
/// See SsuCoreConfig::setFlavour /// See SsuCoreConfig::setFlavour
Q_INVOKABLE void setFlavour(QString flavour); Q_INVOKABLE void setFlavour(QString flavour);
/// See SsuCoreConfig::setRelease /// See SsuCoreConfig::setRelease
Q_INVOKABLE void setRelease(QString release, bool rnd=false); Q_INVOKABLE void setRelease(QString release, bool rnd = false);
/// See SsuCoreConfig::setDomain /// See SsuCoreConfig::setDomain
Q_INVOKABLE void setDomain(QString domain); Q_INVOKABLE void setDomain(QString domain);
/// See SsuCoreConfig::useSslVerify /// See SsuCoreConfig::useSslVerify
Q_INVOKABLE bool useSslVerify(); Q_INVOKABLE bool useSslVerify();
private: private:
QString errorString; QString errorString;
bool errorFlag; bool errorFlag;
QNetworkAccessManager *manager; QNetworkAccessManager *manager;
...@@ -163,7 +164,7 @@ class Ssu: public QObject { ...@@ -163,7 +164,7 @@ class Ssu: public QObject {
bool verifyResponse(QDomDocument *response); bool verifyResponse(QDomDocument *response);
void storeAuthorizedKeys(QByteArray data); void storeAuthorizedKeys(QByteArray data);
private slots: private slots:
void requestFinished(QNetworkReply *reply); void requestFinished(QNetworkReply *reply);
/** /**
* Set errorString returned by lastError to errorMessage, set * Set errorString returned by lastError to errorMessage, set
...@@ -171,7 +172,7 @@ class Ssu: public QObject { ...@@ -171,7 +172,7 @@ class Ssu: public QObject {
*/ */
void setError(QString errorMessage); void setError(QString errorMessage);
public slots: public slots:
/** /**
* Attempt RND device registration, using @a username and @a password supplied * Attempt RND device registration, using @a username and @a password supplied
* @param username Jolla username * @param username Jolla username
...@@ -193,13 +194,13 @@ class Ssu: public QObject { ...@@ -193,13 +194,13 @@ class Ssu: public QObject {
* error() to check if an error occured, and use lastError() to retrieve the last * error() to check if an error occured, and use lastError() to retrieve the last
* error message. * error message.
*/ */
void updateCredentials(bool force=false); void updateCredentials(bool force = false);
/** /**
* Try to update credentials for (Jolla) store * Try to update credentials for (Jolla) store
*/ */
void updateStoreCredentials(); void updateStoreCredentials();
signals: signals:
/** /**
* Emitted after an asynchronous operation finished * Emitted after an asynchronous operation finished
*/ */
......
...@@ -17,141 +17,157 @@ ...@@ -17,141 +17,157 @@
SsuCoreConfig *SsuCoreConfig::ssuCoreConfig = 0; SsuCoreConfig *SsuCoreConfig::ssuCoreConfig = 0;
SsuCoreConfig *SsuCoreConfig::instance(){ SsuCoreConfig *SsuCoreConfig::instance()
if (!ssuCoreConfig) {
ssuCoreConfig = new SsuCoreConfig(); if (!ssuCoreConfig)
ssuCoreConfig = new SsuCoreConfig();
return ssuCoreConfig; return ssuCoreConfig;
} }
QPair<QString, QString> SsuCoreConfig::credentials(QString scope){ QPair<QString, QString> SsuCoreConfig::credentials(QString scope)
QPair<QString, QString> ret; {
beginGroup("credentials-" + scope); QPair<QString, QString> ret;
ret.first = value("username").toString(); beginGroup("credentials-" + scope);
ret.second = value("password").toString(); ret.first = value("username").toString();
endGroup(); ret.second = value("password").toString();
return ret; endGroup();
return ret;
} }
QString SsuCoreConfig::credentialsScope(QString repoName, bool rndRepo){ QString SsuCoreConfig::credentialsScope(QString repoName, bool rndRepo)
if (contains("credentials-scope")) {
return value("credentials-scope").toString(); if (contains("credentials-scope"))
else return value("credentials-scope").toString();
return "your-configuration-is-broken-and-does-not-contain-credentials-scope"; else
} return "your-configuration-is-broken-and-does-not-contain-credentials-scope";
QString SsuCoreConfig::credentialsUrl(QString scope){
if (contains("credentials-url-" + scope))
return value("credentials-url-" + scope).toString();
else
return "your-configuration-is-broken-and-does-not-contain-credentials-url-for-" + scope;
} }
QString SsuCoreConfig::flavour(){ QString SsuCoreConfig::credentialsUrl(QString scope)
if (contains("flavour")) {
return value("flavour").toString(); if (contains("credentials-url-" + scope))
else return value("credentials-url-" + scope).toString();
return "release"; else
return "your-configuration-is-broken-and-does-not-contain-credentials-url-for-" + scope;
} }
Ssu::DeviceModeFlags SsuCoreConfig::deviceMode(){ QString SsuCoreConfig::flavour()
if (!contains("deviceMode")) {
return Ssu::ReleaseMode; if (contains("flavour"))
else return value("flavour").toString();
return Ssu::DeviceModeFlags(value("deviceMode").toInt()); else
return "release";
} }
QString SsuCoreConfig::domain(bool pretty){ Ssu::DeviceModeFlags SsuCoreConfig::deviceMode()
if (contains("domain")){ {
if (pretty) if (!contains("deviceMode"))
return value("domain").toString().replace(":", "-"); return Ssu::ReleaseMode;
else else
return value("domain").toString(); return Ssu::DeviceModeFlags(value("deviceMode").toInt());
} else
return "";
} }
bool SsuCoreConfig::isRegistered(){ QString SsuCoreConfig::domain(bool pretty)
if (!contains("privateKey")) {
return false; if (contains("domain")) {
if (!contains("certificate")) if (pretty)
return false; return value("domain").toString().replace(":", "-");
return value("registered").toBool(); else
return value("domain").toString();
} else
return "";
} }
QDateTime SsuCoreConfig::lastCredentialsUpdate(){ bool SsuCoreConfig::isRegistered()
return value("lastCredentialsUpdate").toDateTime(); {
if (!contains("privateKey"))
return false;
if (!contains("certificate"))
return false;
return value("registered").toBool();
} }
QString SsuCoreConfig::release(bool rnd){ QDateTime SsuCoreConfig::lastCredentialsUpdate()
if (rnd) {
return value("rndRelease").toString(); return value("lastCredentialsUpdate").toDateTime();
else
return value("release").toString();
} }
void SsuCoreConfig::setDeviceMode(Ssu::DeviceModeFlags mode, enum Ssu::EditMode editMode){ QString SsuCoreConfig::release(bool rnd)
int oldMode = value("deviceMode").toInt(); {
if (rnd)
return value("rndRelease").toString();
else
return value("release").toString();
}
if ((editMode & Ssu::Add) == Ssu::Add){ void SsuCoreConfig::setDeviceMode(Ssu::DeviceModeFlags mode, enum Ssu::EditMode editMode)
oldMode |= mode; {
} else if ((editMode & Ssu::Remove) == Ssu::Remove){ int oldMode = value("deviceMode").toInt();
oldMode &= ~mode;
} else
oldMode = mode;
setValue("deviceMode", oldMode); if ((editMode & Ssu::Add) == Ssu::Add) {
sync(); oldMode |= mode;
} } else if ((editMode & Ssu::Remove) == Ssu::Remove) {
oldMode &= ~mode;
} else
oldMode = mode;
void SsuCoreConfig::setFlavour(QString flavour){ setValue("deviceMode", oldMode);
setValue("flavour", flavour); sync();
// flavour is RnD only, so enable RnD mode
setDeviceMode(Ssu::RndMode, Ssu::Add);
sync();
} }
void SsuCoreConfig::setRelease(QString release, bool rnd){ void SsuCoreConfig::setFlavour(QString flavour)
if (rnd) { {
setValue("rndRelease", release); setValue("flavour", flavour);
// switch rndMode on/off when setting releases // flavour is RnD only, so enable RnD mode
setDeviceMode(Ssu::RndMode, Ssu::Add); setDeviceMode(Ssu::RndMode, Ssu::Add);
} else { sync();
setValue("release", release); }
setDeviceMode(Ssu::RndMode, Ssu::Remove);
} void SsuCoreConfig::setRelease(QString release, bool rnd)
sync(); {
} if (rnd) {
setValue("rndRelease", release);
void SsuCoreConfig::setDomain(QString domain){ // switch rndMode on/off when setting releases
// - in domain messes with default section autodetection, setDeviceMode(Ssu::RndMode, Ssu::Add);
// so change it to : } else {
setValue("domain", domain.replace("-", ":")); setValue("release", release);
sync(); setDeviceMode(Ssu::RndMode, Ssu::Remove);
} }
sync();
bool SsuCoreConfig::useSslVerify(){ }
if (contains("ssl-verify"))
return value("ssl-verify").toBool(); void SsuCoreConfig::setDomain(QString domain)
else {
return true; // - in domain messes with default section autodetection,
} // so change it to :
setValue("domain", domain.replace("-", ":"));
QDBusConnection SsuCoreConfig::userSessionBus(){ sync();
int uid_min = getdef_num("UID_MIN", -1); }
// For calls from valid UID we assume that they are properly logged in users. bool SsuCoreConfig::useSslVerify()
// If they are not the call will fail, but it's their fault. {
if (getuid() >= uid_min){ if (contains("ssl-verify"))
return QDBusConnection::sessionBus(); return value("ssl-verify").toBool();
} else { else
// DBus security policy will prevent this beeing used by callers other return true;
// than root at the moment. Still do it generic in case DBus policy will }
// be extended later, and just use the usual 'DBus: THOU SHALL NOT PASS!'
// @TODO the uid to be used should be determined using the logind API from QDBusConnection SsuCoreConfig::userSessionBus()
// systemd package to support multiuser systems in the future {
QString sessionBusAddress=QString("unix:path=/run/user/%1/dbus/user_bus_socket") int uid_min = getdef_num("UID_MIN", -1);
.arg(uid_min);
return QDBusConnection::connectToBus(sessionBusAddress, "userSessionBus"); // For calls from valid UID we assume that they are properly logged in users.
} // If they are not the call will fail, but it's their fault.
if (getuid() >= uid_min) {
return QDBusConnection::sessionBus();
} else {
// DBus security policy will prevent this beeing used by callers other
// than root at the moment. Still do it generic in case DBus policy will
// be extended later, and just use the usual 'DBus: THOU SHALL NOT PASS!'
// @TODO the uid to be used should be determined using the logind API from
// systemd package to support multiuser systems in the future
QString sessionBusAddress = QString("unix:path=/run/user/%1/dbus/user_bus_socket")
.arg(uid_min);
return QDBusConnection::connectToBus(sessionBusAddress, "userSessionBus");
}
} }
...@@ -24,10 +24,11 @@ ...@@ -24,10 +24,11 @@
class QDBusConnection; class QDBusConnection;
class SsuCoreConfig: public SsuSettings { class SsuCoreConfig: public SsuSettings
{
Q_OBJECT Q_OBJECT
public: public:
static SsuCoreConfig *instance(); static SsuCoreConfig *instance();
/** /**
* Find a username/password pair for the given scope * Find a username/password pair for the given scope
...@@ -43,7 +44,7 @@ class SsuCoreConfig: public SsuSettings { ...@@ -43,7 +44,7 @@ class SsuCoreConfig: public SsuSettings {
* *
* @return a string containing the scope; it can be used to look up login credentials using credentials() * @return a string containing the scope; it can be used to look up login credentials using credentials()
*/ */
QString credentialsScope(QString repoName, bool rndRepo=false); QString credentialsScope(QString repoName, bool rndRepo = false);
/** /**
* Return the URL for which credentials scope is valid * Return the URL for which credentials scope is valid
*/ */
...@@ -63,7 +64,7 @@ class SsuCoreConfig: public SsuSettings { ...@@ -63,7 +64,7 @@ class SsuCoreConfig: public SsuSettings {
* to print the domain name set pretty to true * to print the domain name set pretty to true
* @return domain, or "" if not set * @return domain, or "" if not set
*/ */
Q_INVOKABLE QString domain(bool pretty=false); Q_INVOKABLE QString domain(bool pretty = false);
/** /**
* Return devices RND registration status * Return devices RND registration status
* @retval true device is registered * @retval true device is registered
...@@ -78,11 +79,11 @@ class SsuCoreConfig: public SsuSettings { ...@@ -78,11 +79,11 @@ class SsuCoreConfig: public SsuSettings {
/** /**
* Return the release version string for either a release, or a RnD snapshot * Return the release version string for either a release, or a RnD snapshot
*/ */
Q_INVOKABLE QString release(bool rnd=false); Q_INVOKABLE QString release(bool rnd = false);
/** /**
* Set mode bits for the device * Set mode bits for the device
*/ */
Q_INVOKABLE void setDeviceMode(Ssu::DeviceModeFlags mode, enum Ssu::EditMode editMode=Ssu::Replace); Q_INVOKABLE void setDeviceMode(Ssu::DeviceModeFlags mode, enum Ssu::EditMode editMode = Ssu::Replace);
/** /**
* Set the flavour used when resolving RND repositories * Set the flavour used when resolving RND repositories
*/ */
...@@ -90,7 +91,7 @@ class SsuCoreConfig: public SsuSettings { ...@@ -90,7 +91,7 @@ class SsuCoreConfig: public SsuSettings {
/** /**
* Set the release version string for either a release, or a RnD snapshot * Set the release version string for either a release, or a RnD snapshot
*/ */
Q_INVOKABLE void setRelease(QString release, bool rnd=false); Q_INVOKABLE void setRelease(QString release, bool rnd = false);
/** /**
* Set the domain string (usually something like nemo, jolla, ..) * Set the domain string (usually something like nemo, jolla, ..)
*/ */
...@@ -107,7 +108,7 @@ class SsuCoreConfig: public SsuSettings { ...@@ -107,7 +108,7 @@ class SsuCoreConfig: public SsuSettings {
static QDBusConnection userSessionBus(); static QDBusConnection userSessionBus();
private: private:
SsuCoreConfig(): SsuSettings(SSU_CONFIGURATION, QSettings::IniFormat, SSU_DEFAULT_CONFIGURATION) {}; SsuCoreConfig(): SsuSettings(SSU_CONFIGURATION, QSettings::IniFormat, SSU_DEFAULT_CONFIGURATION) {};
SsuCoreConfig(const SsuCoreConfig &); // hide copy constructor SsuCoreConfig(const SsuCoreConfig &); // hide copy constructor
......
This diff is collapsed.
...@@ -14,14 +14,15 @@ ...@@ -14,14 +14,15 @@
class SsuSettings; class SsuSettings;
class SsuDeviceInfo: public QObject { class SsuDeviceInfo: public QObject
{
Q_OBJECT Q_OBJECT
public: public:
/** /**
* Initialize with device to override autodetection * Initialize with device to override autodetection
*/ */
SsuDeviceInfo(QString model=""); SsuDeviceInfo(QString model = "");
/** /**
* Return the list of adaptations used for the set model * Return the list of adaptations used for the set model
*/ */
...@@ -36,7 +37,7 @@ class SsuDeviceInfo: public QObject { ...@@ -36,7 +37,7 @@ class SsuDeviceInfo: public QObject {
* or as variant. If no model is provided as argument the autodetected or previously * or as variant. If no model is provided as argument the autodetected or previously
* set model is used. * set model is used.
*/ */