mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-14 08:45:36 +08:00
Made BlackMisc::CStatusMessageList value no slot, no DBus XML signature shall be created.
A second value method tailored for DBus is the one called for DBus transfer and uses QDBusVariant.
This commit is contained in:
@@ -58,16 +58,17 @@ namespace BlackCore
|
||||
return static_cast<CCoreRuntime *>(this->parent());
|
||||
}
|
||||
|
||||
/*!
|
||||
* \copydoc IContextSettings::value()
|
||||
*/
|
||||
virtual BlackMisc::CStatusMessageList value(const QString &path, const QString &command, const QVariant &value);
|
||||
|
||||
public slots:
|
||||
/*!
|
||||
* \copydoc IContextSettings::getNetworkSettings()
|
||||
*/
|
||||
virtual BlackMisc::Settings::CSettingsNetwork getNetworkSettings() const;
|
||||
|
||||
/*!
|
||||
* \copydoc IContextSettings::value()
|
||||
*/
|
||||
virtual BlackMisc::CStatusMessageList value(const QString &path, const QString &command, const QVariant &value);
|
||||
|
||||
private:
|
||||
BlackMisc::Settings::CSettingsNetwork m_settingsNetwork;
|
||||
|
||||
@@ -41,7 +41,7 @@ namespace BlackCore
|
||||
}
|
||||
|
||||
/*
|
||||
* Relay to DBus
|
||||
* Relay to DBus, but make this no slot
|
||||
*/
|
||||
BlackMisc::CStatusMessageList IContextSettings::value(const QString &path, const QString &command, const QVariant &value)
|
||||
{
|
||||
@@ -66,5 +66,4 @@ namespace BlackCore
|
||||
return this->value(path, command, qv);
|
||||
}
|
||||
|
||||
|
||||
} // namespace
|
||||
|
||||
@@ -71,6 +71,19 @@ namespace BlackCore
|
||||
*/
|
||||
~IContextSettings() {}
|
||||
|
||||
|
||||
/*!
|
||||
* \brief Handle value
|
||||
* \param path where value belongs to
|
||||
* \param command what to do with value
|
||||
* \param value
|
||||
* \return messages generated during handling
|
||||
* \remarks Do not make this a slot, no DBus XML signature shall be created. The QVariant
|
||||
* will be send a tailored value method using QDBusVariant
|
||||
* @see value(const QString &, const QString &, QDBusVariant, int)
|
||||
*/
|
||||
virtual BlackMisc::CStatusMessageList value(const QString &path, const QString &command, const QVariant &value);
|
||||
|
||||
private:
|
||||
BlackMisc::CGenericDBusInterface *m_dBusInterface;
|
||||
|
||||
@@ -86,7 +99,7 @@ namespace BlackCore
|
||||
* \brief IContextSettings
|
||||
* \param parent
|
||||
*/
|
||||
IContextSettings(QObject *parent = 0) : QObject(parent), m_dBusInterface(0) {}
|
||||
IContextSettings(QObject *parent = nullptr) : QObject(parent), m_dBusInterface(nullptr) {}
|
||||
|
||||
signals:
|
||||
|
||||
@@ -102,14 +115,6 @@ namespace BlackCore
|
||||
*/
|
||||
virtual BlackMisc::Settings::CSettingsNetwork getNetworkSettings() const;
|
||||
|
||||
/*!
|
||||
* \brief Handle value
|
||||
* \param path where value belongs to
|
||||
* \param command what to do with value
|
||||
* \param value
|
||||
* \return messages generated during handling
|
||||
*/
|
||||
virtual BlackMisc::CStatusMessageList value(const QString &path, const QString &command, const QVariant &value);
|
||||
|
||||
/*!
|
||||
* \brief DBus version of value method.
|
||||
|
||||
Reference in New Issue
Block a user