diff --git a/applets/weather/plugin/locationlistmodel.cpp b/applets/weather/plugin/locationlistmodel.cpp index 5248512f76fe74c759a0b846b83a4b0aede77744..0cf9b97eb1006e6fbb2e9b36e4a7f1b6f33ef730 100644 --- a/applets/weather/plugin/locationlistmodel.cpp +++ b/applets/weather/plugin/locationlistmodel.cpp @@ -120,9 +120,9 @@ void LocationListModel::searchLocations(const QString &searchString, const QStri //qDebug() << "ion: " << pluginInfo[0] << pluginInfo[1]; //d->ions.insert(pluginInfo[1], pluginInfo[0]); - WeatherValidator *validator = new WeatherValidator(this); - connect(validator, &WeatherValidator::error, this, &LocationListModel::validatorError); - connect(validator, &WeatherValidator::finished, this, &LocationListModel::addSources); + auto* validator = new Plasma::WeatherValidator(this); + connect(validator, &Plasma::WeatherValidator::error, this, &LocationListModel::validatorError); + connect(validator, &Plasma::WeatherValidator::finished, this, &LocationListModel::addSources); validator->setDataEngine(dataengine); validator->setIon(ionId); @@ -130,7 +130,7 @@ void LocationListModel::searchLocations(const QString &searchString, const QStri } } - for (WeatherValidator* validator : qAsConst(m_validators)) { + for (auto* validator : qAsConst(m_validators)) { validator->validate(m_searchString, true); } } diff --git a/applets/weather/plugin/locationlistmodel.h b/applets/weather/plugin/locationlistmodel.h index 9bbedcc4cea7bed3379fd2993091a269934813d4..b02885df42e47881b01a7e854a38ab637d47519d 100644 --- a/applets/weather/plugin/locationlistmodel.h +++ b/applets/weather/plugin/locationlistmodel.h @@ -24,8 +24,9 @@ #include #include +namespace Plasma { class WeatherValidator; - +} class LocationItem { @@ -81,7 +82,7 @@ private: bool m_validatingInput; QString m_searchString; int m_checkedInCount; - QVector m_validators; + QVector m_validators; }; #endif // LOCATIONLISTMODEL_H diff --git a/applets/weather/weatherapplet.cpp b/applets/weather/weatherapplet.cpp index 0dfe87e451907c9e012ef64fd43b968d3b55c8ce..bed4ccdc387b9879576531daf7f549dec6901ac7 100644 --- a/applets/weather/weatherapplet.cpp +++ b/applets/weather/weatherapplet.cpp @@ -75,7 +75,7 @@ QString existingWeatherIconName(const QString &iconName) WeatherApplet::WeatherApplet(QObject *parent, const QVariantList &args) - : WeatherPopupApplet(parent, args) + : Plasma::WeatherPopupApplet(parent, args) { } @@ -83,7 +83,7 @@ void WeatherApplet::init() { resetPanelModel(); - WeatherPopupApplet::init(); + Plasma::WeatherPopupApplet::init(); } WeatherApplet::~WeatherApplet() diff --git a/applets/weather/weatherapplet.h b/applets/weather/weatherapplet.h index 6523c57c225d61ea3a970208bd146f61e569ba1a..4f7696fc9045fb4e8439002b7a298f971c106426 100644 --- a/applets/weather/weatherapplet.h +++ b/applets/weather/weatherapplet.h @@ -23,7 +23,7 @@ #include -class WeatherApplet : public WeatherPopupApplet +class WeatherApplet : public Plasma::WeatherPopupApplet { Q_OBJECT Q_PROPERTY(QVariantMap panelModel READ panelModel NOTIFY modelUpdated) diff --git a/libs/plasmaweather/weatherlocation.cpp b/libs/plasmaweather/weatherlocation.cpp index 1c6cb2b27ae1daff1b5c72b09ee5f04e5d5d3308..51fcf320be98006e022548f2d2226e27fe007645 100644 --- a/libs/plasmaweather/weatherlocation.cpp +++ b/libs/plasmaweather/weatherlocation.cpp @@ -21,6 +21,8 @@ #include "weathervalidator.h" +namespace Plasma { + class WeatherLocationPrivate { public: @@ -90,3 +92,5 @@ void WeatherLocation::dataUpdated(const QString &source, const Plasma::DataEngin emit finished(QString()); } + +} diff --git a/libs/plasmaweather/weatherlocation.h b/libs/plasmaweather/weatherlocation.h index 173105084ad58e81b660c2b970339959f8564333..5b257511c46cb26986674edd4ba901129a481953 100644 --- a/libs/plasmaweather/weatherlocation.h +++ b/libs/plasmaweather/weatherlocation.h @@ -22,6 +22,8 @@ #include +namespace Plasma { + /** * @class WeatherLocation * @@ -60,4 +62,6 @@ private: const QScopedPointer d; }; +} + #endif diff --git a/libs/plasmaweather/weatherpopupapplet.cpp b/libs/plasmaweather/weatherpopupapplet.cpp index 7022c51ec3ef9432801cf2b66f93c94b4564d006..959b8ae5b3d38199a835ec1fe375978627ea0f1f 100644 --- a/libs/plasmaweather/weatherpopupapplet.cpp +++ b/libs/plasmaweather/weatherpopupapplet.cpp @@ -53,6 +53,8 @@ inline QString weather() { return QStringLiteral("weather"); } } } +namespace Plasma { + class WeatherPopupAppletPrivate { public: @@ -442,3 +444,5 @@ QString WeatherPopupApplet::conditionIcon() } return d->conditionIcon; } + +} diff --git a/libs/plasmaweather/weatherpopupapplet.h b/libs/plasmaweather/weatherpopupapplet.h index 24bf259f807503cecd14a3c1bd3040199d92d775..dcdcb8a0e491cc82b420aafb5c6bd48705fe2ead 100644 --- a/libs/plasmaweather/weatherpopupapplet.h +++ b/libs/plasmaweather/weatherpopupapplet.h @@ -28,6 +28,7 @@ #include "plasmaweather_export.h" +namespace Plasma { /** * @class WeatherPopupApplet @@ -115,4 +116,6 @@ class PLASMAWEATHER_EXPORT WeatherPopupApplet : public Plasma::Applet, public Pl friend class WeatherPopupAppletPrivate; }; +} + #endif diff --git a/libs/plasmaweather/weathervalidator.cpp b/libs/plasmaweather/weathervalidator.cpp index f24237716bc364d1e19f6926ef1229e633273562..bf4144cadc17ff54f49643357f7166217be1ec72 100644 --- a/libs/plasmaweather/weathervalidator.cpp +++ b/libs/plasmaweather/weathervalidator.cpp @@ -22,6 +22,8 @@ #include #include +namespace Plasma { + class WeatherValidatorPrivate { public: @@ -136,3 +138,4 @@ void WeatherValidator::dataUpdated(const QString &source, const Plasma::DataEngi emit finished(locations); } +} diff --git a/libs/plasmaweather/weathervalidator.h b/libs/plasmaweather/weathervalidator.h index a64bce5435a48cd4792361d65d558024c6032785..517751060396d62a2074878481a428139eb9504e 100644 --- a/libs/plasmaweather/weathervalidator.h +++ b/libs/plasmaweather/weathervalidator.h @@ -24,6 +24,8 @@ #include "plasmaweather_export.h" +namespace Plasma { + /** * @class WeatherValidator * @@ -90,4 +92,6 @@ private: const QScopedPointer d; }; +} + #endif