diff --git a/autotests/coronatest.h b/autotests/coronatest.h index 8d5b3861c..2010b0bbb 100644 --- a/autotests/coronatest.h +++ b/autotests/coronatest.h @@ -39,7 +39,7 @@ class SimpleCorona : public Plasma::Corona Q_OBJECT public: - explicit SimpleCorona(QObject * parent = 0); + explicit SimpleCorona(QObject * parent = nullptr); ~SimpleCorona(); QRect screenGeometry(int) const Q_DECL_OVERRIDE; @@ -51,7 +51,7 @@ class SimpleApplet : public Plasma::Applet Q_OBJECT public: - explicit SimpleApplet(QObject *parent = 0, const QString &serviceId = QString(), uint appletId = 0); + explicit SimpleApplet(QObject *parent = nullptr, const QString &serviceId = QString(), uint appletId = 0); private: QTimer m_timer; }; @@ -61,7 +61,7 @@ class SimpleContainment : public Plasma::Containment Q_OBJECT public: - explicit SimpleContainment(QObject *parent = 0, const QString &serviceId = QString(), uint appletId = 0); + explicit SimpleContainment(QObject *parent = nullptr, const QString &serviceId = QString(), uint appletId = 0); private: QTimer m_timer; }; @@ -71,7 +71,7 @@ class SimpleNoScreenContainment : public Plasma::Containment Q_OBJECT public: - explicit SimpleNoScreenContainment(QObject *parent = 0, const QString &serviceId = QString(), uint appletId = 0); + explicit SimpleNoScreenContainment(QObject *parent = nullptr, const QString &serviceId = QString(), uint appletId = 0); }; class CoronaTest : public QObject diff --git a/autotests/dynamictreemodel.h b/autotests/dynamictreemodel.h index 283d6ed3f..24bba1c62 100644 --- a/autotests/dynamictreemodel.h +++ b/autotests/dynamictreemodel.h @@ -52,7 +52,7 @@ class DynamicTreeModel : public QAbstractItemModel Q_OBJECT public: - DynamicTreeModel(QObject *parent = 0); + DynamicTreeModel(QObject *parent = nullptr); QModelIndex index(int row, int column, const QModelIndex &parent = QModelIndex()) const; QModelIndex parent(const QModelIndex &index) const; @@ -99,7 +99,7 @@ class ModelChangeCommand : public QObject Q_OBJECT public: - explicit ModelChangeCommand(DynamicTreeModel *model, QObject *parent = 0); + explicit ModelChangeCommand(DynamicTreeModel *model, QObject *parent = nullptr); virtual ~ModelChangeCommand() {} @@ -144,7 +144,7 @@ class ModelInsertCommand : public ModelChangeCommand public: - explicit ModelInsertCommand(DynamicTreeModel *model, QObject *parent = 0); + explicit ModelInsertCommand(DynamicTreeModel *model, QObject *parent = nullptr); virtual ~ModelInsertCommand() {} virtual void doCommand(); @@ -186,7 +186,7 @@ class ModelResetCommand : public ModelMoveCommand { Q_OBJECT public: - explicit ModelResetCommand(DynamicTreeModel *model, QObject *parent = 0); + explicit ModelResetCommand(DynamicTreeModel *model, QObject *parent = nullptr); virtual ~ModelResetCommand(); @@ -202,7 +202,7 @@ class ModelResetCommandFixed : public ModelMoveCommand { Q_OBJECT public: - explicit ModelResetCommandFixed(DynamicTreeModel *model, QObject *parent = 0); + explicit ModelResetCommandFixed(DynamicTreeModel *model, QObject *parent = nullptr); virtual ~ModelResetCommandFixed(); diff --git a/autotests/modeltest.h b/autotests/modeltest.h index 9b1eaadc3..c89e3bcce 100644 --- a/autotests/modeltest.h +++ b/autotests/modeltest.h @@ -51,7 +51,7 @@ class ModelTest : public QObject Q_OBJECT public: - explicit ModelTest(QAbstractItemModel *model, QObject *parent = 0); + explicit ModelTest(QAbstractItemModel *model, QObject *parent = nullptr); private Q_SLOTS: void nonDestructiveBasicTest(); diff --git a/examples/dataengines/customDataContainers/httpContainer.h b/examples/dataengines/customDataContainers/httpContainer.h index 1e6e3a206..1fc4fe76d 100644 --- a/examples/dataengines/customDataContainers/httpContainer.h +++ b/examples/dataengines/customDataContainers/httpContainer.h @@ -40,7 +40,7 @@ class HttpContainer : public Plasma::DataContainer Q_OBJECT public: - HttpContainer(const QUrl &url, QObject *parent = 0); + HttpContainer(const QUrl &url, QObject *parent = nullptr); void fetchUrl(bool reload = true); diff --git a/examples/dataengines/dataEngineTracker/dataenginetracker.h b/examples/dataengines/dataEngineTracker/dataenginetracker.h index feeca2a50..ae8b5662f 100644 --- a/examples/dataengines/dataEngineTracker/dataenginetracker.h +++ b/examples/dataengines/dataEngineTracker/dataenginetracker.h @@ -35,7 +35,7 @@ class DataEngineTracker : QObject Q_OBJECT public: - DataEngineTracker(Plasma::DataEngine *engine, QObject *parent = 0); + DataEngineTracker(Plasma::DataEngine *engine, QObject *parent = nullptr); public Q_SLOTS: void dataUpdated(const QString &source, const Plasma::DataEngine::Data &data); diff --git a/examples/shell/customcorona.h b/examples/shell/customcorona.h index 5a11067ea..5c2ea0b45 100644 --- a/examples/shell/customcorona.h +++ b/examples/shell/customcorona.h @@ -29,7 +29,7 @@ class CustomCorona : public Plasma::Corona Q_OBJECT public: - explicit CustomCorona(QObject * parent = 0); + explicit CustomCorona(QObject * parent = nullptr); QRect screenGeometry(int id) const; public Q_SLOTS: diff --git a/src/declarativeimports/calendar/calendar.h b/src/declarativeimports/calendar/calendar.h index b0bbc7e7f..17783a4bc 100644 --- a/src/declarativeimports/calendar/calendar.h +++ b/src/declarativeimports/calendar/calendar.h @@ -137,7 +137,7 @@ public: }; Q_ENUM(DateMatchingPrecision) - explicit Calendar(QObject *parent = 0); + explicit Calendar(QObject *parent = nullptr); // Displayed date QDate displayedDate() const; diff --git a/src/declarativeimports/calendar/calendardata.h b/src/declarativeimports/calendar/calendardata.h index 860d22b16..5b5395c99 100644 --- a/src/declarativeimports/calendar/calendardata.h +++ b/src/declarativeimports/calendar/calendardata.h @@ -47,7 +47,7 @@ public: Q_ENUM(Type) Q_DECLARE_FLAGS(Types, Type) - explicit CalendarData(QObject *parent = 0); + explicit CalendarData(QObject *parent = nullptr); Q_SIGNALS: void startDateChanged(); diff --git a/src/declarativeimports/calendar/daysmodel.h b/src/declarativeimports/calendar/daysmodel.h index c2423a53d..636beb5a8 100644 --- a/src/declarativeimports/calendar/daysmodel.h +++ b/src/declarativeimports/calendar/daysmodel.h @@ -44,7 +44,7 @@ public: yearNumber }; - explicit DaysModel(QObject *parent = 0); + explicit DaysModel(QObject *parent = nullptr); virtual ~DaysModel(); void setSourceData(QList *data); int rowCount(const QModelIndex &parent) const Q_DECL_OVERRIDE; diff --git a/src/declarativeimports/calendar/eventpluginsmanager.h b/src/declarativeimports/calendar/eventpluginsmanager.h index 2b3b213f0..e414e1869 100644 --- a/src/declarativeimports/calendar/eventpluginsmanager.h +++ b/src/declarativeimports/calendar/eventpluginsmanager.h @@ -38,7 +38,7 @@ class EventPluginsManager : public QObject Q_PROPERTY(QStringList enabledPlugins READ enabledPlugins WRITE setEnabledPlugins NOTIFY pluginsChanged) public: - EventPluginsManager(QObject *parent = 0); + explicit EventPluginsManager(QObject *parent = nullptr); ~EventPluginsManager(); QList plugins() const; diff --git a/src/declarativeimports/core/colorscope.h b/src/declarativeimports/core/colorscope.h index 88e6a9762..089a9c1fc 100644 --- a/src/declarativeimports/core/colorscope.h +++ b/src/declarativeimports/core/colorscope.h @@ -87,7 +87,7 @@ class ColorScope : public QQuickItem public: /// @cond INTERNAL_DOCS - ColorScope(QQuickItem *parent = 0, QObject *parentObject = 0); + explicit ColorScope(QQuickItem *parent = nullptr, QObject *parentObject = 0); ~ColorScope(); void setColorGroup(Plasma::Theme::ColorGroup group); diff --git a/src/declarativeimports/core/datamodel.h b/src/declarativeimports/core/datamodel.h index 18886193f..79e7c169e 100644 --- a/src/declarativeimports/core/datamodel.h +++ b/src/declarativeimports/core/datamodel.h @@ -90,7 +90,7 @@ class SortFilterModel : public QSortFilterProxyModel friend class DataModel; public: - SortFilterModel(QObject *parent = 0); + SortFilterModel(QObject *parent = nullptr); ~SortFilterModel(); void setModel(QAbstractItemModel *source); @@ -182,7 +182,7 @@ class DataModel : public QAbstractItemModel Q_PROPERTY(int count READ count NOTIFY countChanged) public: - DataModel(QObject *parent = 0); + DataModel(QObject *parent = nullptr); ~DataModel(); void setDataSource(QObject *source); diff --git a/src/declarativeimports/core/datasource.h b/src/declarativeimports/core/datasource.h index 71e0f445c..f859c5acd 100644 --- a/src/declarativeimports/core/datasource.h +++ b/src/declarativeimports/core/datasource.h @@ -56,7 +56,7 @@ public: typedef QMap Data; - DataSource(QObject *parent = 0); + DataSource(QObject *parent = nullptr); void classBegin() Q_DECL_OVERRIDE; void componentComplete() Q_DECL_OVERRIDE; @@ -124,7 +124,7 @@ public: * All the data fetched by this dataengine. * This is a map of maps. At the first level, there are the source names, at the second, they keys set by the DataEngine */ - Q_PROPERTY(QQmlPropertyMap *data READ data CONSTANT); + Q_PROPERTY(QQmlPropertyMap *data READ data CONSTANT) QQmlPropertyMap *data() const { return m_data; @@ -135,7 +135,7 @@ public: * In order for a model to be present, besides being implemented in the DataEngine, * The user has to be connected to its source, so the source name has to be present in the connectedSources property. */ - Q_PROPERTY(QQmlPropertyMap *models READ models CONSTANT); + Q_PROPERTY(QQmlPropertyMap *models READ models CONSTANT) QQmlPropertyMap *models() const { return m_models; diff --git a/src/declarativeimports/core/framesvgitem.h b/src/declarativeimports/core/framesvgitem.h index 82d91d583..95dcaf817 100644 --- a/src/declarativeimports/core/framesvgitem.h +++ b/src/declarativeimports/core/framesvgitem.h @@ -74,7 +74,7 @@ class FrameSvgItemMargins : public QObject public: - FrameSvgItemMargins(Plasma::FrameSvg *frameSvg, QObject *parent = 0); + FrameSvgItemMargins(Plasma::FrameSvg *frameSvg, QObject *parent = nullptr); qreal left() const; qreal top() const; @@ -192,7 +192,7 @@ public: Q_INVOKABLE bool hasElementPrefix(const QString &prefix) const; /// @cond INTERNAL_DOCS - FrameSvgItem(QQuickItem *parent = 0); + FrameSvgItem(QQuickItem *parent = nullptr); ~FrameSvgItem(); void setImagePath(const QString &path); diff --git a/src/declarativeimports/core/iconitem.h b/src/declarativeimports/core/iconitem.h index e32da0d1d..2488c320c 100644 --- a/src/declarativeimports/core/iconitem.h +++ b/src/declarativeimports/core/iconitem.h @@ -124,7 +124,7 @@ class IconItem : public QQuickItem Q_PROPERTY(int implicitWidth READ implicitWidth WRITE setImplicitWidth2 NOTIFY implicitWidthChanged2) public: - IconItem(QQuickItem *parent = 0); + explicit IconItem(QQuickItem *parent = nullptr); ~IconItem(); void setSource(const QVariant &source); diff --git a/src/declarativeimports/core/quicktheme.h b/src/declarativeimports/core/quicktheme.h index e0263d89b..ec55c6f37 100644 --- a/src/declarativeimports/core/quicktheme.h +++ b/src/declarativeimports/core/quicktheme.h @@ -85,7 +85,7 @@ class QuickTheme : public Plasma::Theme Q_PROPERTY(QColor complementaryNegativeTextColor READ buttonNegativeTextColor NOTIFY themeChangedProxy) public: - explicit QuickTheme(QObject *parent = 0); + explicit QuickTheme(QObject *parent = nullptr); ~QuickTheme(); diff --git a/src/declarativeimports/core/serviceoperationstatus.h b/src/declarativeimports/core/serviceoperationstatus.h index fe6af2e53..628beba3d 100644 --- a/src/declarativeimports/core/serviceoperationstatus.h +++ b/src/declarativeimports/core/serviceoperationstatus.h @@ -53,7 +53,7 @@ class ServiceOperationStatus : public QObject Q_PROPERTY(bool enabled READ isEnabled WRITE setEnabled NOTIFY enabledChanged) public: - ServiceOperationStatus(QObject *parent = 0); + explicit ServiceOperationStatus(QObject *parent = nullptr); ~ServiceOperationStatus(); void setService(Plasma::Service *service); diff --git a/src/declarativeimports/core/svgitem.h b/src/declarativeimports/core/svgitem.h index f33d3501f..2e98b8945 100644 --- a/src/declarativeimports/core/svgitem.h +++ b/src/declarativeimports/core/svgitem.h @@ -68,7 +68,7 @@ class SvgItem : public QQuickItem public: /// @cond INTERNAL_DOCS - SvgItem(QQuickItem *parent = 0); + SvgItem(QQuickItem *parent = nullptr); ~SvgItem(); void setElementId(const QString &elementID); diff --git a/src/declarativeimports/core/tooltip.h b/src/declarativeimports/core/tooltip.h index 2b9a48470..06593ad3d 100644 --- a/src/declarativeimports/core/tooltip.h +++ b/src/declarativeimports/core/tooltip.h @@ -127,7 +127,7 @@ class ToolTip : public QQuickItem public: /// @cond INTERNAL_DOCS - ToolTip(QQuickItem *parent = 0); + ToolTip(QQuickItem *parent = nullptr); ~ToolTip(); QQuickItem *mainItem() const; diff --git a/src/declarativeimports/core/tooltipdialog.h b/src/declarativeimports/core/tooltipdialog.h index d4e0ff0a6..2652fc9ae 100644 --- a/src/declarativeimports/core/tooltipdialog.h +++ b/src/declarativeimports/core/tooltipdialog.h @@ -43,7 +43,7 @@ class ToolTipDialog : public PlasmaQuick::Dialog Q_OBJECT public: - ToolTipDialog(QQuickItem *parent = 0); + ToolTipDialog(QQuickItem *parent = nullptr); ~ToolTipDialog(); QQuickItem *loadDefaultItem(); diff --git a/src/declarativeimports/core/units.h b/src/declarativeimports/core/units.h index 3b8d7f1ce..e93270cc7 100644 --- a/src/declarativeimports/core/units.h +++ b/src/declarativeimports/core/units.h @@ -32,7 +32,7 @@ class SharedAppFilter : public QObject { Q_OBJECT public: - SharedAppFilter(QObject *parent = 0); + SharedAppFilter(QObject *parent = nullptr); ~SharedAppFilter(); Q_SIGNALS: @@ -209,7 +209,7 @@ private Q_SLOTS: void updateSpacing(); private: - Units(QObject *parent = 0); + Units(QObject *parent = nullptr); Units(Units const&) = delete; // Copy construct Units(Units&&) = delete; // Move construct Units& operator=(Units const&) = delete; // Copy assign diff --git a/src/declarativeimports/core/windowthumbnail.h b/src/declarativeimports/core/windowthumbnail.h index 780f1d407..7f2536ff7 100644 --- a/src/declarativeimports/core/windowthumbnail.h +++ b/src/declarativeimports/core/windowthumbnail.h @@ -82,7 +82,7 @@ class WindowThumbnail : public QQuickItem, public QAbstractNativeEventFilter Q_PROPERTY(bool thumbnailAvailable READ thumbnailAvailable NOTIFY thumbnailAvailableChanged) public: - WindowThumbnail(QQuickItem *parent = 0); + WindowThumbnail(QQuickItem *parent = nullptr); virtual ~WindowThumbnail(); bool nativeEventFilter(const QByteArray &eventType, void *message, long int *result) Q_DECL_OVERRIDE; QSGNode *updatePaintNode(QSGNode *oldNode, UpdatePaintNodeData *updatePaintNodeData) Q_DECL_OVERRIDE; diff --git a/src/declarativeimports/plasmacomponents/fullscreensheet.h b/src/declarativeimports/plasmacomponents/fullscreensheet.h index f1450cd28..914cf37c9 100644 --- a/src/declarativeimports/plasmacomponents/fullscreensheet.h +++ b/src/declarativeimports/plasmacomponents/fullscreensheet.h @@ -33,7 +33,7 @@ class FullScreenSheet : public FullScreenWindow Q_PROPERTY(QString rejectButtonText READ rejectButtonText WRITE setRejectButtonText NOTIFY rejectButtonTextChanged) public: - FullScreenSheet(QDeclarativeItem *parent = 0); + FullScreenSheet(QDeclarativeItem *parent = nullptr); ~FullScreenSheet(); QString title() const; diff --git a/src/declarativeimports/plasmacomponents/fullscreenwindow.h b/src/declarativeimports/plasmacomponents/fullscreenwindow.h index 8632acb5a..85920bcd7 100644 --- a/src/declarativeimports/plasmacomponents/fullscreenwindow.h +++ b/src/declarativeimports/plasmacomponents/fullscreenwindow.h @@ -44,7 +44,7 @@ class FullScreenWindow : public QDeclarativeItem Q_PROPERTY(DialogStatus::Status status READ status NOTIFY statusChanged) public: - FullScreenWindow(QDeclarativeItem *parent = 0); + FullScreenWindow(QDeclarativeItem *parent = nullptr); ~FullScreenWindow(); QGraphicsObject *mainItem() const; diff --git a/src/declarativeimports/plasmacomponents/qmenu.h b/src/declarativeimports/plasmacomponents/qmenu.h index 45f894dde..34e20f64f 100644 --- a/src/declarativeimports/plasmacomponents/qmenu.h +++ b/src/declarativeimports/plasmacomponents/qmenu.h @@ -101,7 +101,7 @@ class QMenuProxy : public QObject Q_PROPERTY(int maximumWidth READ maximumWidth WRITE setMaximumWidth RESET resetMaximumWidth NOTIFY maximumWidthChanged) public: - QMenuProxy(QObject *parent = 0); + explicit QMenuProxy(QObject *parent = nullptr); ~QMenuProxy(); QQmlListProperty content(); diff --git a/src/declarativeimports/plasmacomponents/qmenuitem.h b/src/declarativeimports/plasmacomponents/qmenuitem.h index 03a5629e6..c52ca36c2 100644 --- a/src/declarativeimports/plasmacomponents/qmenuitem.h +++ b/src/declarativeimports/plasmacomponents/qmenuitem.h @@ -48,7 +48,7 @@ class QMenuItem : public QQuickItem Q_PROPERTY(bool checked READ checked WRITE setChecked NOTIFY toggled) public: - QMenuItem(QQuickItem *parent = 0); + QMenuItem(QQuickItem *parent = nullptr); QAction *action() const; void setAction(QAction *a); diff --git a/src/declarativeimports/plasmacomponents/qrangemodel.h b/src/declarativeimports/plasmacomponents/qrangemodel.h index 1e34acf0b..1b14d3a8a 100644 --- a/src/declarativeimports/plasmacomponents/qrangemodel.h +++ b/src/declarativeimports/plasmacomponents/qrangemodel.h @@ -62,7 +62,7 @@ class QRangeModel : public QObject Q_PROPERTY(bool inverted READ inverted WRITE setInverted NOTIFY invertedChanged) public: - QRangeModel(QObject *parent = 0); + explicit QRangeModel(QObject *parent = nullptr); virtual ~QRangeModel(); void setRange(qreal min, qreal max); diff --git a/src/declarativeimports/plasmaextracomponents/fallbackcomponent.h b/src/declarativeimports/plasmaextracomponents/fallbackcomponent.h index f8a9f513c..d47813e8a 100644 --- a/src/declarativeimports/plasmaextracomponents/fallbackcomponent.h +++ b/src/declarativeimports/plasmaextracomponents/fallbackcomponent.h @@ -48,7 +48,7 @@ class FallbackComponent : public QObject Q_PROPERTY(QStringList candidates READ candidates WRITE setCandidates NOTIFY candidatesChanged) public: - FallbackComponent(QObject *parent = 0); + FallbackComponent(QObject *parent = nullptr); /** * This method must be called after the the basePath and the candidates property diff --git a/src/declarativeimports/platformcomponents/application.h b/src/declarativeimports/platformcomponents/application.h index 1ec2542eb..482de8b02 100644 --- a/src/declarativeimports/platformcomponents/application.h +++ b/src/declarativeimports/platformcomponents/application.h @@ -52,7 +52,7 @@ class Application: public QObject Q_PROPERTY(bool running READ running WRITE setRunning NOTIFY runningChanged) public: - Application(QObject *parent = nullptr); + explicit Application(QObject *parent = nullptr); ~Application(); QString application() const; diff --git a/src/declarativeimports/platformcomponents/icondialog.h b/src/declarativeimports/platformcomponents/icondialog.h index c3ae8cd57..0ff393e3e 100644 --- a/src/declarativeimports/platformcomponents/icondialog.h +++ b/src/declarativeimports/platformcomponents/icondialog.h @@ -46,7 +46,7 @@ class IconDialog: public QObject Q_OBJECT public: - IconDialog(QObject *parent = nullptr); + explicit IconDialog(QObject *parent = nullptr); ~IconDialog(); Q_INVOKABLE QString openDialog(); diff --git a/src/plasma/applet.h b/src/plasma/applet.h index 89498ea46..31f42298c 100644 --- a/src/plasma/applet.h +++ b/src/plasma/applet.h @@ -84,7 +84,7 @@ public: * @param appletId a unique id used to differentiate between multiple * instances of the same Applet type */ - explicit Applet(QObject *parent = 0, const QString &serviceId = QString(), uint appletId = 0); + explicit Applet(QObject *parent = nullptr, const QString &serviceId = QString(), uint appletId = 0); /** * @param parent the QObject this applet is parented to @@ -95,7 +95,7 @@ public: * * @deprecated prefer using KPluginMetaData */ - PLASMA_DEPRECATED explicit Applet(const KPluginInfo &info, QObject *parent = 0, uint appletId = 0); + PLASMA_DEPRECATED explicit Applet(const KPluginInfo &info, QObject *parent = nullptr, uint appletId = 0); /** * @param parent the QObject this applet is parented to @@ -104,7 +104,7 @@ public: * instances of the same Applet type * @since 5.27 */ - explicit Applet(const KPluginMetaData &metadata, QObject *parent = 0, uint appletId = 0); + explicit Applet(const KPluginMetaData &metadata, QObject *parent = nullptr, uint appletId = 0); ~Applet(); diff --git a/src/plasma/containment.h b/src/plasma/containment.h index 44902d714..6680ece93 100644 --- a/src/plasma/containment.h +++ b/src/plasma/containment.h @@ -69,7 +69,7 @@ public: * @param containmentId a unique id used to differentiate between multiple * instances of the same Applet type */ - explicit Containment(QObject *parent = 0, + explicit Containment(QObject *parent = nullptr, const QString &serviceId = QString(), uint containmentId = 0); diff --git a/src/plasma/containmentactions.h b/src/plasma/containmentactions.h index eab617911..61a4c7b52 100644 --- a/src/plasma/containmentactions.h +++ b/src/plasma/containmentactions.h @@ -59,7 +59,7 @@ public: /** * Default constructor for an empty or null containmentactions */ - explicit ContainmentActions(QObject *parent = 0); + explicit ContainmentActions(QObject *parent = nullptr); ~ContainmentActions(); diff --git a/src/plasma/corona.h b/src/plasma/corona.h index ed8ecaa0e..6a5d004bd 100644 --- a/src/plasma/corona.h +++ b/src/plasma/corona.h @@ -46,7 +46,7 @@ class PLASMA_EXPORT Corona : public QObject Q_PROPERTY(KPackage::Package kPackage READ kPackage NOTIFY kPackageChanged) public: - explicit Corona(QObject *parent = 0); + explicit Corona(QObject *parent = nullptr); ~Corona(); #ifndef PLASMA_NO_DEPRECATED diff --git a/src/plasma/datacontainer.h b/src/plasma/datacontainer.h index fa5807edb..10b61f402 100644 --- a/src/plasma/datacontainer.h +++ b/src/plasma/datacontainer.h @@ -73,7 +73,7 @@ public: * Constructs a default DataContainer that has no name or data * associated with it **/ - explicit DataContainer(QObject *parent = 0); + explicit DataContainer(QObject *parent = nullptr); virtual ~DataContainer(); /** diff --git a/src/plasma/dataengine.h b/src/plasma/dataengine.h index b91adc268..57f862ca9 100644 --- a/src/plasma/dataengine.h +++ b/src/plasma/dataengine.h @@ -73,9 +73,9 @@ public: * @param parent The parent object. * @param plugin plugin info that describes the engine **/ - explicit DataEngine(const KPluginInfo &plugin, QObject *parent = 0); + explicit DataEngine(const KPluginInfo &plugin, QObject *parent = nullptr); - explicit DataEngine(QObject *parent = 0, const QVariantList &args = QVariantList()); + explicit DataEngine(QObject *parent = nullptr, const QVariantList &args = QVariantList()); ~DataEngine(); diff --git a/src/plasma/framesvg.h b/src/plasma/framesvg.h index bc02cc456..4a2d80136 100644 --- a/src/plasma/framesvg.h +++ b/src/plasma/framesvg.h @@ -103,7 +103,7 @@ public: * * @related Plasma::Theme */ - explicit FrameSvg(QObject *parent = 0); + explicit FrameSvg(QObject *parent = nullptr); ~FrameSvg(); /** diff --git a/src/plasma/packagestructure.h b/src/plasma/packagestructure.h index 40feec60b..1afb96067 100644 --- a/src/plasma/packagestructure.h +++ b/src/plasma/packagestructure.h @@ -42,7 +42,7 @@ class PLASMA_EXPORT PackageStructure : public QObject public: - PLASMA_DEPRECATED explicit PackageStructure(QObject *parent = 0, const QVariantList &args = QVariantList()); + PLASMA_DEPRECATED explicit PackageStructure(QObject *parent = nullptr, const QVariantList &args = QVariantList()); ~PackageStructure(); diff --git a/src/plasma/packagestructure/packages_p.h b/src/plasma/packagestructure/packages_p.h index 6863ac5aa..53ed9a44f 100644 --- a/src/plasma/packagestructure/packages_p.h +++ b/src/plasma/packagestructure/packages_p.h @@ -32,7 +32,7 @@ class ChangeableMainScriptPackage : public KPackage::PackageStructure { Q_OBJECT public: - ChangeableMainScriptPackage(QObject *parent = 0, const QVariantList &args = QVariantList()) : KPackage::PackageStructure(parent, args) {} + ChangeableMainScriptPackage(QObject *parent = nullptr, const QVariantList &args = QVariantList()) : KPackage::PackageStructure(parent, args) {} void initPackage(KPackage::Package *package) Q_DECL_OVERRIDE; void pathChanged(KPackage::Package *package) Q_DECL_OVERRIDE; @@ -45,7 +45,7 @@ class GenericPackage : public ChangeableMainScriptPackage { Q_OBJECT public: - GenericPackage(QObject *parent = 0, const QVariantList &args = QVariantList()) : ChangeableMainScriptPackage(parent, args) {} + GenericPackage(QObject *parent = nullptr, const QVariantList &args = QVariantList()) : ChangeableMainScriptPackage(parent, args) {} void initPackage(KPackage::Package *package) Q_DECL_OVERRIDE; }; diff --git a/src/plasma/plasma.h b/src/plasma/plasma.h index 3f235ddb9..5f8936d1d 100644 --- a/src/plasma/plasma.h +++ b/src/plasma/plasma.h @@ -285,7 +285,7 @@ public: Q_ENUM(BackgroundHints) private: - Types(QObject *parent = 0); + Types(QObject *parent = nullptr); }; /** diff --git a/src/plasma/pluginloader.h b/src/plasma/pluginloader.h index 12f7ea8c7..886f70b8a 100644 --- a/src/plasma/pluginloader.h +++ b/src/plasma/pluginloader.h @@ -126,7 +126,7 @@ public: * * @return a Service object, unlike Plasma::Service::loadService, this can return null. **/ - Service *loadService(const QString &name, const QVariantList &args, QObject *parent = 0); + Service *loadService(const QString &name, const QVariantList &args, QObject *parent = nullptr); /** * Load a ContainmentActions plugin. @@ -398,7 +398,7 @@ protected: * * @return a Service object, unlike Plasma::Service::loadService, this can return null. **/ - virtual Service *internalLoadService(const QString &name, const QVariantList &args, QObject *parent = 0); + virtual Service *internalLoadService(const QString &name, const QVariantList &args, QObject *parent = nullptr); /** * A re-implementable method that allows subclasses to override diff --git a/src/plasma/private/actionwidgetinterface_p.h b/src/plasma/private/actionwidgetinterface_p.h index 2b7fe58e4..1ef7fed30 100644 --- a/src/plasma/private/actionwidgetinterface_p.h +++ b/src/plasma/private/actionwidgetinterface_p.h @@ -33,13 +33,13 @@ class ActionWidgetInterface : public ThemedWidgetInterface public: ActionWidgetInterface(T *parent) : ThemedWidgetInterface(parent), - action(0) + action(nullptr) { } virtual ~ActionWidgetInterface() { - setAction(0); + setAction(nullptr); } virtual void changed() @@ -48,7 +48,7 @@ public: void clearAction() { - action = 0; + action = nullptr; syncToAction(); changed(); } @@ -92,7 +92,7 @@ public: } } - QAction *action; + QAction *action = nullptr; }; } // namespace Plasma diff --git a/src/plasma/private/associatedapplicationmanager_p.h b/src/plasma/private/associatedapplicationmanager_p.h index 4ead085dd..16a8565c8 100644 --- a/src/plasma/private/associatedapplicationmanager_p.h +++ b/src/plasma/private/associatedapplicationmanager_p.h @@ -52,7 +52,7 @@ public: bool appletHasValidAssociatedApplication(const Plasma::Applet *applet) const; private: - AssociatedApplicationManager(QObject *parent = 0); + AssociatedApplicationManager(QObject *parent = nullptr); ~AssociatedApplicationManager(); AssociatedApplicationManagerPrivate *const d; diff --git a/src/plasma/private/componentinstaller_p.h b/src/plasma/private/componentinstaller_p.h index 1902bfe16..3e30e2a19 100644 --- a/src/plasma/private/componentinstaller_p.h +++ b/src/plasma/private/componentinstaller_p.h @@ -74,7 +74,7 @@ public: * @param force whether to always prompt, even if recently prompted */ void installMissingComponent(const QString &type, const QString &name, - QWidget *parent = 0, bool force = false); + QWidget *parent = nullptr, bool force = false); private: /** diff --git a/src/plasma/private/containmentactions_p.h b/src/plasma/private/containmentactions_p.h index 0c9801eb8..066041e67 100644 --- a/src/plasma/private/containmentactions_p.h +++ b/src/plasma/private/containmentactions_p.h @@ -32,7 +32,7 @@ public: package(0), containment(0) { - }; + } ContainmentActions *q; diff --git a/src/plasma/private/effectwatcher_p.h b/src/plasma/private/effectwatcher_p.h index b315ac659..900bf3050 100644 --- a/src/plasma/private/effectwatcher_p.h +++ b/src/plasma/private/effectwatcher_p.h @@ -34,7 +34,7 @@ class EffectWatcher: public QObject, public QAbstractNativeEventFilter Q_OBJECT public: - EffectWatcher(const QString &property, QObject *parent = 0); + EffectWatcher(const QString &property, QObject *parent = nullptr); protected: bool isEffectActive() const; diff --git a/src/plasma/private/packagestructure_p.h b/src/plasma/private/packagestructure_p.h index 76c0f93cd..7ee95d32c 100644 --- a/src/plasma/private/packagestructure_p.h +++ b/src/plasma/private/packagestructure_p.h @@ -34,7 +34,7 @@ class PackageStructureWrapper : public KPackage::PackageStructure { Q_OBJECT public: - PackageStructureWrapper(Plasma::PackageStructure *structure, QObject *parent = 0, const QVariantList &args = QVariantList()); + PackageStructureWrapper(Plasma::PackageStructure *structure, QObject *parent = nullptr, const QVariantList &args = QVariantList()); ~PackageStructureWrapper(); diff --git a/src/plasma/private/sharedtimer_p.h b/src/plasma/private/sharedtimer_p.h index cc5f0f70a..7ea04c229 100644 --- a/src/plasma/private/sharedtimer_p.h +++ b/src/plasma/private/sharedtimer_p.h @@ -41,7 +41,7 @@ protected: private: friend class TimerDriveSingleton; - explicit TimerDrive(QObject *parent = 0); + explicit TimerDrive(QObject *parent = nullptr); ~TimerDrive(); class Private; Private *const d; diff --git a/src/plasma/private/storage_p.h b/src/plasma/private/storage_p.h index 4d2209b46..2c14d254e 100644 --- a/src/plasma/private/storage_p.h +++ b/src/plasma/private/storage_p.h @@ -38,7 +38,7 @@ public: StorageJob(const QString &destination, const QString &operation, const QVariantMap ¶meters, - QObject *parent = 0); + QObject *parent = nullptr); ~StorageJob(); void setData(const QVariantMap &data); QVariantMap data() const; @@ -62,7 +62,7 @@ class Storage : public Plasma::Service Q_OBJECT public: - Storage(QObject *parent = 0); + Storage(QObject *parent = nullptr); ~Storage(); protected: diff --git a/src/plasma/private/storagethread_p.h b/src/plasma/private/storagethread_p.h index d55950cb7..58b731c37 100644 --- a/src/plasma/private/storagethread_p.h +++ b/src/plasma/private/storagethread_p.h @@ -33,7 +33,7 @@ class StorageThread : public QThread { Q_OBJECT public: - StorageThread(QObject *parent = 0); + StorageThread(QObject *parent = nullptr); ~StorageThread(); void run() Q_DECL_OVERRIDE; diff --git a/src/plasma/private/svg_p.h b/src/plasma/private/svg_p.h index 84b41ecfa..cbfa21250 100644 --- a/src/plasma/private/svg_p.h +++ b/src/plasma/private/svg_p.h @@ -37,18 +37,18 @@ class SharedSvgRenderer : public QSvgRenderer, public QSharedData public: typedef QExplicitlySharedDataPointer Ptr; - SharedSvgRenderer(QObject *parent = 0); + SharedSvgRenderer(QObject *parent = nullptr); SharedSvgRenderer( const QString &filename, const QString &styleSheet, QHash &interestingElements, - QObject *parent = 0); + QObject *parent = nullptr); SharedSvgRenderer( const QByteArray &contents, const QString &styleSheet, QHash &interestingElements, - QObject *parent = 0); + QObject *parent = nullptr); private: bool load( diff --git a/src/plasma/private/theme_p.h b/src/plasma/private/theme_p.h index a014ed795..94d37cce7 100644 --- a/src/plasma/private/theme_p.h +++ b/src/plasma/private/theme_p.h @@ -63,7 +63,7 @@ class ThemePrivate : public QObject Q_OBJECT public: - ThemePrivate(QObject *parent = 0); + ThemePrivate(QObject *parent = nullptr); ~ThemePrivate(); KConfigGroup &config(); diff --git a/src/plasma/scripting/appletscript.h b/src/plasma/scripting/appletscript.h index ada7bad42..fcd1a9155 100644 --- a/src/plasma/scripting/appletscript.h +++ b/src/plasma/scripting/appletscript.h @@ -57,7 +57,7 @@ public: * such set up that requires the Applet itself should be done * in the init() method. */ - explicit AppletScript(QObject *parent = 0); + explicit AppletScript(QObject *parent = nullptr); ~AppletScript(); /** diff --git a/src/plasma/scripting/dataenginescript.h b/src/plasma/scripting/dataenginescript.h index 3d15381eb..ef40a8c0b 100644 --- a/src/plasma/scripting/dataenginescript.h +++ b/src/plasma/scripting/dataenginescript.h @@ -49,7 +49,7 @@ public: * such set up that requires the DataEngine itself should be done * in the init() method. */ - explicit DataEngineScript(QObject *parent = 0); + explicit DataEngineScript(QObject *parent = nullptr); ~DataEngineScript(); /** diff --git a/src/plasma/scripting/scriptengine.h b/src/plasma/scripting/scriptengine.h index e1e7be85d..a54db5445 100644 --- a/src/plasma/scripting/scriptengine.h +++ b/src/plasma/scripting/scriptengine.h @@ -59,7 +59,7 @@ public: virtual bool init(); protected: - explicit ScriptEngine(QObject *parent = 0); + explicit ScriptEngine(QObject *parent = nullptr); /** * @return absolute path to the main script file for this plasmoid diff --git a/src/plasma/service.h b/src/plasma/service.h index 15a65148d..60d868eb5 100644 --- a/src/plasma/service.h +++ b/src/plasma/service.h @@ -135,7 +135,7 @@ public: * @return a started ServiceJob; the consumer may connect to relevant * signals before returning to the event loop */ - Q_INVOKABLE ServiceJob *startOperationCall(const QVariantMap &description, QObject *parent = 0); + Q_INVOKABLE ServiceJob *startOperationCall(const QVariantMap &description, QObject *parent = nullptr); /** * Query to find if an operation is enabled or not. @@ -167,7 +167,7 @@ protected: * * @param parent the parent object for this service */ - explicit Service(QObject *parent = 0); + explicit Service(QObject *parent = nullptr); /** * Constructor for plugin loading diff --git a/src/plasma/servicejob.h b/src/plasma/servicejob.h index ec51695b9..7ec9e1d31 100644 --- a/src/plasma/servicejob.h +++ b/src/plasma/servicejob.h @@ -66,7 +66,7 @@ public: * @param parent the parent object for this service */ ServiceJob(const QString &destination, const QString &operation, - const QVariantMap ¶meters, QObject *parent = 0); + const QVariantMap ¶meters, QObject *parent = nullptr); /** * Destructor diff --git a/src/plasma/svg.h b/src/plasma/svg.h index 86ddede60..d01ab14af 100644 --- a/src/plasma/svg.h +++ b/src/plasma/svg.h @@ -85,7 +85,7 @@ public: * * @related Plasma::Theme */ - explicit Svg(QObject *parent = 0); + explicit Svg(QObject *parent = nullptr); ~Svg(); /** diff --git a/src/plasma/theme.h b/src/plasma/theme.h index a1416bd42..705c7d84c 100644 --- a/src/plasma/theme.h +++ b/src/plasma/theme.h @@ -93,7 +93,7 @@ public: * Default constructor. It will be the global theme configured in plasmarc * @param parent the parent object */ - explicit Theme(QObject *parent = 0); + explicit Theme(QObject *parent = nullptr); /** * Construct a theme. It will be a custom theme instance of themeName. @@ -101,7 +101,7 @@ public: * @param parent the parent object * @since 4.3 */ - explicit Theme(const QString &themeName, QObject *parent = 0); + explicit Theme(const QString &themeName, QObject *parent = nullptr); ~Theme(); diff --git a/src/plasmaquick/appletquickitem.h b/src/plasmaquick/appletquickitem.h index d545bc964..62cd47a75 100644 --- a/src/plasmaquick/appletquickitem.h +++ b/src/plasmaquick/appletquickitem.h @@ -93,7 +93,7 @@ class PLASMAQUICK_EXPORT AppletQuickItem : public QQuickItem Q_PROPERTY(QObject *rootItem READ rootItem CONSTANT) public: - AppletQuickItem(Plasma::Applet *applet, QQuickItem *parent = 0); + AppletQuickItem(Plasma::Applet *applet, QQuickItem *parent = nullptr); ~AppletQuickItem(); ////API NOT SUPPOSED TO BE USED BY QML diff --git a/src/plasmaquick/configmodel.h b/src/plasmaquick/configmodel.h index ba2bb44db..4faff4568 100644 --- a/src/plasmaquick/configmodel.h +++ b/src/plasmaquick/configmodel.h @@ -73,7 +73,7 @@ public: VisibleRole, KCMRole }; - ConfigModel(QObject *parent = 0); + ConfigModel(QObject *parent = nullptr); ~ConfigModel(); /** diff --git a/src/plasmaquick/configview.h b/src/plasmaquick/configview.h index af5ee9520..7b97f4023 100644 --- a/src/plasmaquick/configview.h +++ b/src/plasmaquick/configview.h @@ -58,7 +58,7 @@ public: * @param applet the applet of this ConfigView * @param parent the QWindow in which this ConfigView is parented to **/ - ConfigView(Plasma::Applet *applet, QWindow *parent = 0); + ConfigView(Plasma::Applet *applet, QWindow *parent = nullptr); virtual ~ConfigView(); virtual void init(); diff --git a/src/plasmaquick/containmentview.h b/src/plasmaquick/containmentview.h index 4bdc1dee3..f890b3808 100644 --- a/src/plasmaquick/containmentview.h +++ b/src/plasmaquick/containmentview.h @@ -53,7 +53,7 @@ public: * @param corona the corona of this view * @param parent the QWindow this ContainmentView is parented to **/ - explicit ContainmentView(Plasma::Corona *corona, QWindow *parent = 0); + explicit ContainmentView(Plasma::Corona *corona, QWindow *parent = nullptr); virtual ~ContainmentView(); /** diff --git a/src/plasmaquick/dialog.h b/src/plasmaquick/dialog.h index 5299712d4..9894dffb1 100644 --- a/src/plasmaquick/dialog.h +++ b/src/plasmaquick/dialog.h @@ -167,7 +167,7 @@ public: }; Q_ENUM(BackgroundHints) - Dialog(QQuickItem *parent = 0); + Dialog(QQuickItem *parent = nullptr); ~Dialog(); //PROPERTIES ACCESSORS diff --git a/src/plasmaquick/dialogshadows_p.h b/src/plasmaquick/dialogshadows_p.h index 5d55776f8..c75c0bb24 100644 --- a/src/plasmaquick/dialogshadows_p.h +++ b/src/plasmaquick/dialogshadows_p.h @@ -37,7 +37,7 @@ class DialogShadows : public Plasma::Svg Q_OBJECT public: - explicit DialogShadows(QObject *parent = 0, const QString &prefix = QStringLiteral("dialogs/background")); + explicit DialogShadows(QObject *parent = nullptr, const QString &prefix = QStringLiteral("dialogs/background")); ~DialogShadows(); static DialogShadows *self(); diff --git a/src/plasmaquick/private/configcategory_p.h b/src/plasmaquick/private/configcategory_p.h index a5c01fa59..53f5e9602 100644 --- a/src/plasmaquick/private/configcategory_p.h +++ b/src/plasmaquick/private/configcategory_p.h @@ -49,7 +49,7 @@ class ConfigCategory : public QObject Q_PROPERTY(bool visible READ visible WRITE setVisible NOTIFY visibleChanged) public: - ConfigCategory(QObject *parent = 0); + ConfigCategory(QObject *parent = nullptr); ~ConfigCategory(); QString name() const; diff --git a/src/plasmaquick/view.h b/src/plasmaquick/view.h index e60ca87d5..b1538a326 100644 --- a/src/plasmaquick/view.h +++ b/src/plasmaquick/view.h @@ -56,7 +56,7 @@ public: * @param corona the corona of this view * @param parent the QWindow this View is parented to **/ - PLASMA_DEPRECATED explicit View(Plasma::Corona *corona, QWindow *parent = 0); + PLASMA_DEPRECATED explicit View(Plasma::Corona *corona, QWindow *parent = nullptr); PLASMA_DEPRECATED virtual ~View(); /** diff --git a/src/scriptengines/qml/plasmoid/appletinterface.h b/src/scriptengines/qml/plasmoid/appletinterface.h index e905fb35a..0a247acab 100644 --- a/src/scriptengines/qml/plasmoid/appletinterface.h +++ b/src/scriptengines/qml/plasmoid/appletinterface.h @@ -239,7 +239,7 @@ class AppletInterface : public PlasmaQuick::AppletQuickItem Q_PROPERTY(QVariantList availableScreenRegion READ availableScreenRegion NOTIFY availableScreenRegionChanged) public: - AppletInterface(DeclarativeAppletScript *script, const QVariantList &args = QVariantList(), QQuickItem *parent = 0); + AppletInterface(DeclarativeAppletScript *script, const QVariantList &args = QVariantList(), QQuickItem *parent = nullptr); ~AppletInterface(); //API not intended for the QML part diff --git a/src/scriptengines/qml/plasmoid/wallpaperinterface.h b/src/scriptengines/qml/plasmoid/wallpaperinterface.h index af40ef74c..30f1fe911 100644 --- a/src/scriptengines/qml/plasmoid/wallpaperinterface.h +++ b/src/scriptengines/qml/plasmoid/wallpaperinterface.h @@ -51,7 +51,7 @@ class WallpaperInterface : public QQuickItem Q_PROPERTY(KDeclarative::ConfigPropertyMap *configuration READ configuration NOTIFY configurationChanged) public: - WallpaperInterface(ContainmentInterface *parent = 0); + WallpaperInterface(ContainmentInterface *parent = nullptr); ~WallpaperInterface(); /**