diff --git a/src/config/advancedpagewidget.h b/src/config/advancedpagewidget.h index 621efa0..1dfe490 100644 --- a/src/config/advancedpagewidget.h +++ b/src/config/advancedpagewidget.h @@ -32,7 +32,7 @@ class QComboBox; class AdvancedPageWidget : public QWidget, public Ui::ConfigurePageAdvanced { public: - AdvancedPageWidget(QWidget* parent); + explicit AdvancedPageWidget(QWidget* parent); public: QComboBox& comboBackend() { diff --git a/src/config/filesystemcolorspagewidget.h b/src/config/filesystemcolorspagewidget.h index fd23c92..2db752e 100644 --- a/src/config/filesystemcolorspagewidget.h +++ b/src/config/filesystemcolorspagewidget.h @@ -26,7 +26,7 @@ class FileSystemColorsPageWidget : public QWidget, public Ui::ConfigurePageFileSystemColors { public: - FileSystemColorsPageWidget(QWidget* parent); + explicit FileSystemColorsPageWidget(QWidget* parent); }; #endif diff --git a/src/config/generalpagewidget.h b/src/config/generalpagewidget.h index 52de33e..89c59af 100644 --- a/src/config/generalpagewidget.h +++ b/src/config/generalpagewidget.h @@ -31,7 +31,7 @@ class QString; class GeneralPageWidget : public QWidget, public Ui::ConfigurePageGeneral { public: - GeneralPageWidget(QWidget* parent); + explicit GeneralPageWidget(QWidget* parent); public: QComboBox& comboDefaultFileSystem() { diff --git a/src/gui/applyprogressdetailswidget.h b/src/gui/applyprogressdetailswidget.h index d1a8f70..68b34b2 100644 --- a/src/gui/applyprogressdetailswidget.h +++ b/src/gui/applyprogressdetailswidget.h @@ -27,7 +27,7 @@ class ApplyProgressDetailsWidget : public QWidget, public Ui::ApplyProgressDetailsWidgetBase { public: - ApplyProgressDetailsWidget(QWidget* parent) : QWidget(parent) { + explicit ApplyProgressDetailsWidget(QWidget* parent) : QWidget(parent) { setupUi(this); } diff --git a/src/gui/applyprogressdialogwidget.h b/src/gui/applyprogressdialogwidget.h index 9961f34..170ecb6 100644 --- a/src/gui/applyprogressdialogwidget.h +++ b/src/gui/applyprogressdialogwidget.h @@ -27,7 +27,7 @@ class ApplyProgressDialogWidget : public QWidget, public Ui::ApplyProgressDialogWidgetBase { public: - ApplyProgressDialogWidget(QWidget* parent); + explicit ApplyProgressDialogWidget(QWidget* parent); public: QTreeWidget& treeTasks() { diff --git a/src/gui/createpartitiontablewidget.h b/src/gui/createpartitiontablewidget.h index 6ff0973..f637c30 100644 --- a/src/gui/createpartitiontablewidget.h +++ b/src/gui/createpartitiontablewidget.h @@ -28,7 +28,7 @@ class CreatePartitionTableWidget : public QWidget, public Ui::CreatePartitionTableWidgetBase { public: - CreatePartitionTableWidget(QWidget* parent); + explicit CreatePartitionTableWidget(QWidget* parent); public: QRadioButton& radioMSDOS() { diff --git a/src/gui/createvolumegroupdialog.cpp b/src/gui/createvolumegroupdialog.cpp index b4c0ed2..602e9c0 100644 --- a/src/gui/createvolumegroupdialog.cpp +++ b/src/gui/createvolumegroupdialog.cpp @@ -71,7 +71,7 @@ void CreateVolumeGroupDialog::setupDialog() if (toBeDeleted) continue; - if (!p.isLuks() && p.vgName() == QString() && !LvmDevice::s_DirtyPVs.contains(p.partition())) + if (!p.isLuks() && p.vgName().isEmpty() && !LvmDevice::s_DirtyPVs.contains(p.partition())) dialogWidget().listPV().addPartition(*p.partition(), false); } diff --git a/src/gui/devicepropswidget.h b/src/gui/devicepropswidget.h index 5dc8f44..e29baa8 100644 --- a/src/gui/devicepropswidget.h +++ b/src/gui/devicepropswidget.h @@ -29,7 +29,7 @@ class PartTableWidget; class DevicePropsWidget : public QWidget, public Ui::DevicePropsWidgetBase { public: - DevicePropsWidget(QWidget* parent); + explicit DevicePropsWidget(QWidget* parent); public: PartTableWidget& partTableWidget() { diff --git a/src/gui/filesystemsupportdialog.h b/src/gui/filesystemsupportdialog.h index 8a6c0fd..e93601f 100644 --- a/src/gui/filesystemsupportdialog.h +++ b/src/gui/filesystemsupportdialog.h @@ -38,7 +38,7 @@ class FileSystemSupportDialog : public QDialog Q_DISABLE_COPY(FileSystemSupportDialog) public: - FileSystemSupportDialog(QWidget* parent); + explicit FileSystemSupportDialog(QWidget* parent); ~FileSystemSupportDialog(); public: diff --git a/src/gui/filesystemsupportdialogwidget.h b/src/gui/filesystemsupportdialogwidget.h index 302776d..23739f2 100644 --- a/src/gui/filesystemsupportdialogwidget.h +++ b/src/gui/filesystemsupportdialogwidget.h @@ -24,7 +24,7 @@ class FileSystemSupportDialogWidget : public QWidget, public Ui::FileSystemSupportDialogWidgetBase { public: - FileSystemSupportDialogWidget(QWidget* parent); + explicit FileSystemSupportDialogWidget(QWidget* parent); public: QTreeWidget& tree() { diff --git a/src/gui/formattedspinbox.h b/src/gui/formattedspinbox.h index c8996e9..2c34dea 100644 --- a/src/gui/formattedspinbox.h +++ b/src/gui/formattedspinbox.h @@ -24,7 +24,7 @@ class FormattedSpinBox : public QDoubleSpinBox { public: - FormattedSpinBox(QWidget* parent = nullptr) : QDoubleSpinBox(parent) {} + explicit FormattedSpinBox(QWidget* parent = nullptr) : QDoubleSpinBox(parent) {} public: QString textFromValue(double value) const override; diff --git a/src/gui/infopane.h b/src/gui/infopane.h index c6101a6..b582755 100644 --- a/src/gui/infopane.h +++ b/src/gui/infopane.h @@ -39,7 +39,7 @@ class InfoPane : public QWidget Q_DISABLE_COPY(InfoPane) public: - InfoPane(QWidget* parent = nullptr); + explicit InfoPane(QWidget* parent = nullptr); public: void showPartition(Qt::DockWidgetArea area, const Partition& p); diff --git a/src/gui/listdevices.h b/src/gui/listdevices.h index 6aee317..7b444fc 100644 --- a/src/gui/listdevices.h +++ b/src/gui/listdevices.h @@ -38,7 +38,7 @@ class ListDevices : public QWidget, public Ui::ListDevicesBase Q_DISABLE_COPY(ListDevices) public: - ListDevices(QWidget* parent = nullptr); + explicit ListDevices(QWidget* parent = nullptr); Q_SIGNALS: void selectionChanged(const QString& device_node); diff --git a/src/gui/listoperations.h b/src/gui/listoperations.h index 9e63642..5c0a1fe 100644 --- a/src/gui/listoperations.h +++ b/src/gui/listoperations.h @@ -38,7 +38,7 @@ class ListOperations : public QWidget, public Ui::ListOperationsBase Q_DISABLE_COPY(ListOperations) public: - ListOperations(QWidget* parent = nullptr); + explicit ListOperations(QWidget* parent = nullptr); public: void setActionCollection(KActionCollection* coll) { diff --git a/src/gui/listphysicalvolumes.h b/src/gui/listphysicalvolumes.h index 7060c75..18c4f79 100644 --- a/src/gui/listphysicalvolumes.h +++ b/src/gui/listphysicalvolumes.h @@ -46,7 +46,7 @@ class ListPhysicalVolumes : public QWidget, public Ui::ListPhysicalVolumesBase Q_DISABLE_COPY(ListPhysicalVolumes) public: - ListPhysicalVolumes(QWidget* parent = nullptr); + explicit ListPhysicalVolumes(QWidget* parent = nullptr); void addPartition(const Partition& p, bool checked); diff --git a/src/gui/partitionmanagerwidget.h b/src/gui/partitionmanagerwidget.h index ec5c841..2a59ab1 100644 --- a/src/gui/partitionmanagerwidget.h +++ b/src/gui/partitionmanagerwidget.h @@ -45,7 +45,7 @@ class PartitionManagerWidget : public QWidget, Ui::PartitionManagerWidgetBase Q_DISABLE_COPY(PartitionManagerWidget) public: - PartitionManagerWidget(QWidget* parent = nullptr); + explicit PartitionManagerWidget(QWidget* parent = nullptr); virtual ~PartitionManagerWidget(); Q_SIGNALS: diff --git a/src/gui/partpropswidget.h b/src/gui/partpropswidget.h index d9e6869..e450a35 100644 --- a/src/gui/partpropswidget.h +++ b/src/gui/partpropswidget.h @@ -30,7 +30,7 @@ class PartPropsWidget : public QWidget, public Ui::PartPropsWidgetBase { public: - PartPropsWidget(QWidget* parent) : QWidget(parent) { + explicit PartPropsWidget(QWidget* parent) : QWidget(parent) { setupUi(this); m_PartWidget->setFileSystemColorCode(GuiHelpers::fileSystemColorCodesFromSettings()); diff --git a/src/gui/parttablewidget.h b/src/gui/parttablewidget.h index 4e4061c..5f5481c 100644 --- a/src/gui/parttablewidget.h +++ b/src/gui/parttablewidget.h @@ -38,7 +38,7 @@ class PartTableWidget : public PartWidgetBase Q_DISABLE_COPY(PartTableWidget) public: - PartTableWidget(QWidget* parent); + explicit PartTableWidget(QWidget* parent); qint32 borderWidth() const override { return 0; /**< @return border width */ } diff --git a/src/gui/resizevolumegroupdialog.cpp b/src/gui/resizevolumegroupdialog.cpp index 9acfc28..965554c 100644 --- a/src/gui/resizevolumegroupdialog.cpp +++ b/src/gui/resizevolumegroupdialog.cpp @@ -73,7 +73,7 @@ void ResizeVolumeGroupDialog::setupDialog() continue; if (p.vgName() == device()->name()) dialogWidget().listPV().addPartition(*p.partition(), true); - else if (p.vgName() == QString() && !LvmDevice::s_DirtyPVs.contains(p.partition())) // TODO: Remove LVM PVs in current VG + else if (p.vgName().isEmpty() && !LvmDevice::s_DirtyPVs.contains(p.partition())) // TODO: Remove LVM PVs in current VG dialogWidget().listPV().addPartition(*p.partition(), false); } diff --git a/src/gui/scanprogressdialog.h b/src/gui/scanprogressdialog.h index 94e3261..b158ffa 100644 --- a/src/gui/scanprogressdialog.h +++ b/src/gui/scanprogressdialog.h @@ -23,7 +23,7 @@ class ScanProgressDialog : public QProgressDialog { public: - ScanProgressDialog(QWidget* parent); + explicit ScanProgressDialog(QWidget* parent); void setProgress(int p) { setValue(p); diff --git a/src/gui/sizedetailswidget.h b/src/gui/sizedetailswidget.h index 98ba813..c3af339 100644 --- a/src/gui/sizedetailswidget.h +++ b/src/gui/sizedetailswidget.h @@ -29,7 +29,7 @@ class SizeDetailsWidget : public QWidget, public Ui::SizeDetailsWidgetBase { public: - SizeDetailsWidget(QWidget* parent); + explicit SizeDetailsWidget(QWidget* parent); public: QDoubleSpinBox& spinFirstSector() { diff --git a/src/gui/smartdialogwidget.h b/src/gui/smartdialogwidget.h index 3da6ec2..2f0e2b8 100644 --- a/src/gui/smartdialogwidget.h +++ b/src/gui/smartdialogwidget.h @@ -30,7 +30,7 @@ class QPoint; class SmartDialogWidget : public QWidget, public Ui::SmartDialogWidgetBase { public: - SmartDialogWidget(QWidget* parent); + explicit SmartDialogWidget(QWidget* parent); ~SmartDialogWidget(); public: diff --git a/src/gui/treelog.h b/src/gui/treelog.h index a60ac1a..4f7db0e 100644 --- a/src/gui/treelog.h +++ b/src/gui/treelog.h @@ -35,7 +35,7 @@ class TreeLog: public QWidget, public Ui::TreeLogBase Q_DISABLE_COPY(TreeLog) public: - TreeLog(QWidget* parent = nullptr); + explicit TreeLog(QWidget* parent = nullptr); ~TreeLog(); public: diff --git a/src/gui/volumegroupwidget.h b/src/gui/volumegroupwidget.h index 7263d13..7166793 100644 --- a/src/gui/volumegroupwidget.h +++ b/src/gui/volumegroupwidget.h @@ -26,7 +26,7 @@ class VolumeGroupWidget : public QWidget, public Ui::VolumeGroupWidgetBase { public: - VolumeGroupWidget(QWidget* parent) : + explicit VolumeGroupWidget(QWidget* parent) : QWidget(parent), Ui::VolumeGroupWidgetBase() { setupUi(this);