From a4d88e7025d570e26f527913d4dacd3f41639c34 Mon Sep 17 00:00:00 2001 From: Jocelyn Lorrey Date: Mon, 2 May 2022 15:03:08 -0400 Subject: [PATCH] [#230] Address lines that were throwing noExplicitConstructor warnings --- src/bimserver/ProjectImporter.hpp | 2 +- src/model_editor/BridgeClasses.hpp | 2 +- src/model_editor/IGSpinBoxes.hpp | 2 +- src/model_editor/InspectorDialog.hpp | 2 +- src/model_editor/ModalDialogs.hpp | 2 +- src/model_editor/OSProgressBar.hpp | 2 +- src/model_editor/PathWatcher.hpp | 2 +- src/model_editor/test/PathWatcher_GTest.cpp | 2 +- src/openstudio_app/ExternalToolsDialog.hpp | 2 +- src/openstudio_lib/CollapsibleInspector.hpp | 2 +- .../ConstructionObjectVectorController.hpp | 2 +- .../DefaultConstructionSetInspectorView.hpp | 2 +- .../DefaultConstructionSetsController.hpp | 2 +- src/openstudio_lib/EMSInspectorView.cpp | 2 +- src/openstudio_lib/GeometryEditorView.hpp | 2 +- src/openstudio_lib/GridItem.cpp | 2 +- src/openstudio_lib/GridItem.hpp | 14 +++---- src/openstudio_lib/HVACSystemsController.hpp | 4 +- .../HVACTemplateHelperDialog.hpp | 2 +- src/openstudio_lib/LifeCycleCostsTabView.hpp | 2 +- src/openstudio_lib/LoopChooserView.hpp | 2 +- src/openstudio_lib/LoopScene.hpp | 2 +- src/openstudio_lib/MainTabController.hpp | 2 +- src/openstudio_lib/MainWindow.hpp | 2 +- .../ModelObjectInspectorView.hpp | 2 +- src/openstudio_lib/ModelObjectTreeItems.hpp | 38 +++++++++---------- src/openstudio_lib/OSCollapsibleItemList.hpp | 2 +- src/openstudio_lib/OSDropZone.hpp | 2 +- src/openstudio_lib/OSItem.hpp | 2 +- src/openstudio_lib/PlanarSurfaceWidget.hpp | 2 +- .../RefrigerationController.hpp | 4 +- src/openstudio_lib/RunTabView.hpp | 2 +- src/openstudio_lib/ScheduleDayView.hpp | 6 +-- .../ScheduleSetInspectorView.hpp | 2 +- src/openstudio_lib/ScheduleSetsController.hpp | 2 +- src/openstudio_lib/ScheduleSetsView.hpp | 4 +- src/openstudio_lib/SchedulesTabView.hpp | 2 +- src/openstudio_lib/SchedulesView.hpp | 10 ++--- src/openstudio_lib/ScriptsTabView.hpp | 2 +- src/openstudio_lib/ServiceWaterGridItems.hpp | 6 +-- src/openstudio_lib/ServiceWaterScene.hpp | 4 +- .../StandardOpaqueMaterialInspectorView.hpp | 2 +- src/openstudio_lib/SummaryTabController.hpp | 2 +- src/openstudio_lib/SummaryTabView.hpp | 2 +- src/openstudio_lib/UtilityBillsController.hpp | 2 +- src/openstudio_lib/UtilityBillsView.hpp | 2 +- src/openstudio_lib/VRFController.hpp | 4 +- src/openstudio_lib/VariablesTabController.hpp | 2 +- src/openstudio_lib/VariablesTabView.hpp | 4 +- src/openstudio_lib/YearSettingsWidget.hpp | 2 +- src/openstudio_lib/ZoneChooserView.hpp | 2 +- .../BCLMeasureDialog.hpp | 2 +- .../BuildingComponentDialog.hpp | 2 +- .../BuildingComponentDialogCentralWidget.hpp | 2 +- .../CollapsibleComponentList.hpp | 2 +- src/shared_gui_components/Component.hpp | 4 +- src/shared_gui_components/ComponentList.hpp | 2 +- src/shared_gui_components/EditView.hpp | 2 +- .../LocalLibraryController.hpp | 14 +++---- src/shared_gui_components/MeasureDragData.hpp | 4 +- src/shared_gui_components/MeasureManager.hpp | 2 +- .../OSCollapsibleView.hpp | 2 +- src/shared_gui_components/OSConcepts.hpp | 4 +- .../OSGridController.hpp | 4 +- .../OSObjectSelector.hpp | 2 +- src/shared_gui_components/PageNavigator.hpp | 2 +- src/shared_gui_components/TIDItemModel.cpp | 2 +- src/shared_gui_components/TIDItemModel.hpp | 2 +- src/shared_gui_components/TextEditDialog.hpp | 2 +- .../WorkflowController.hpp | 4 +- src/shared_gui_components/WorkflowView.hpp | 2 +- 71 files changed, 120 insertions(+), 120 deletions(-) diff --git a/src/bimserver/ProjectImporter.hpp b/src/bimserver/ProjectImporter.hpp index 84d2d19bc..93486cead 100644 --- a/src/bimserver/ProjectImporter.hpp +++ b/src/bimserver/ProjectImporter.hpp @@ -53,7 +53,7 @@ class BIMSERVER_API ProjectImporter : public QDialog public: /// Default constructor - ProjectImporter(QWidget* parent); + explicit ProjectImporter(QWidget* parent); /// Start importing IFC workflow boost::optional run(); diff --git a/src/model_editor/BridgeClasses.hpp b/src/model_editor/BridgeClasses.hpp index 27d7c5887..821e9dd88 100644 --- a/src/model_editor/BridgeClasses.hpp +++ b/src/model_editor/BridgeClasses.hpp @@ -40,7 +40,7 @@ class MODELEDITOR_API ComboHighlightBridge : public QObject Q_OBJECT; public: - ComboHighlightBridge(QObject* parent); + explicit ComboHighlightBridge(QObject* parent); QObject* bridgeSender(); diff --git a/src/model_editor/IGSpinBoxes.hpp b/src/model_editor/IGSpinBoxes.hpp index f75726544..a5d839c85 100644 --- a/src/model_editor/IGSpinBoxes.hpp +++ b/src/model_editor/IGSpinBoxes.hpp @@ -43,7 +43,7 @@ class MODELEDITOR_API IGSpinBox : public QSpinBox Q_OBJECT; public: - IGSpinBox(QWidget* parent); + explicit IGSpinBox(QWidget* parent); virtual void wheelEvent(QWheelEvent* event) override; diff --git a/src/model_editor/InspectorDialog.hpp b/src/model_editor/InspectorDialog.hpp index 757874b12..df9b5a210 100644 --- a/src/model_editor/InspectorDialog.hpp +++ b/src/model_editor/InspectorDialog.hpp @@ -76,7 +76,7 @@ class MODELEDITOR_API InspectorDialog InspectorDialog(InspectorDialogClient client = InspectorDialogClient::AllOpenStudio, QWidget* parent = nullptr); /// create a new dialog for existing model - InspectorDialog(openstudio::model::Model& model, InspectorDialogClient client = InspectorDialogClient::AllOpenStudio, QWidget* parent = nullptr); + explicit InspectorDialog(openstudio::model::Model& model, InspectorDialogClient client = InspectorDialogClient::AllOpenStudio, QWidget* parent = nullptr); virtual ~InspectorDialog(); diff --git a/src/model_editor/ModalDialogs.hpp b/src/model_editor/ModalDialogs.hpp index 7bdc896c2..09017bfa6 100644 --- a/src/model_editor/ModalDialogs.hpp +++ b/src/model_editor/ModalDialogs.hpp @@ -123,7 +123,7 @@ class MODELEDITOR_API ModelObjectSelectorDialogWatcher Q_OBJECT public: - ModelObjectSelectorDialogWatcher(std::shared_ptr modelObjectSelectorDialog); + explicit ModelObjectSelectorDialogWatcher(std::shared_ptr modelObjectSelectorDialog); /// get the selected object boost::optional selectedModelObject() const; diff --git a/src/model_editor/OSProgressBar.hpp b/src/model_editor/OSProgressBar.hpp index dd7ae0a66..788833548 100644 --- a/src/model_editor/OSProgressBar.hpp +++ b/src/model_editor/OSProgressBar.hpp @@ -54,7 +54,7 @@ class OSProgressBar : public openstudio::ProgressBar OSProgressBar(QWidget* parent = nullptr); /// constructor - OSProgressBar(bool visible, QWidget* parent = nullptr); + explicit OSProgressBar(bool visible, QWidget* parent = nullptr); /// virtual destructor virtual ~OSProgressBar(); diff --git a/src/model_editor/PathWatcher.hpp b/src/model_editor/PathWatcher.hpp index 112be9d14..7e33e045b 100644 --- a/src/model_editor/PathWatcher.hpp +++ b/src/model_editor/PathWatcher.hpp @@ -56,7 +56,7 @@ class MODELEDITOR_API PathWatcher : public QObject /// if path is not a directory it is assumed to be a regular file which may or may not exist at construction, /// a timer is used to periodically check for changes to the file /// msec is the timer delay to check for updates to the file, msec does not apply if the path is a directory - PathWatcher(const openstudio::path& p, int msec = 1000); + explicit PathWatcher(const openstudio::path& p, int msec = 1000); /// virtual destructor virtual ~PathWatcher(); diff --git a/src/model_editor/test/PathWatcher_GTest.cpp b/src/model_editor/test/PathWatcher_GTest.cpp index 7434b4b07..ea4c33644 100644 --- a/src/model_editor/test/PathWatcher_GTest.cpp +++ b/src/model_editor/test/PathWatcher_GTest.cpp @@ -51,7 +51,7 @@ struct TestPathWatcher : public PathWatcher { // set periodic timer to 1 ms - TestPathWatcher(const openstudio::path& path) : PathWatcher(path, 1), added(false), changed(false), removed(false) {} + explicit TestPathWatcher(const openstudio::path& path) : PathWatcher(path, 1), added(false), changed(false), removed(false) {} virtual void onPathAdded() override { added = true; diff --git a/src/openstudio_app/ExternalToolsDialog.hpp b/src/openstudio_app/ExternalToolsDialog.hpp index e17864a89..ed637f92e 100644 --- a/src/openstudio_app/ExternalToolsDialog.hpp +++ b/src/openstudio_app/ExternalToolsDialog.hpp @@ -43,7 +43,7 @@ class ExternalToolsDialog : public QDialog Q_OBJECT public: - ExternalToolsDialog(openstudio::path t_dviewPath); + explicit ExternalToolsDialog(openstudio::path t_dviewPath); virtual ~ExternalToolsDialog(){}; diff --git a/src/openstudio_lib/CollapsibleInspector.hpp b/src/openstudio_lib/CollapsibleInspector.hpp index 9cd50fc4b..acca6d87b 100644 --- a/src/openstudio_lib/CollapsibleInspector.hpp +++ b/src/openstudio_lib/CollapsibleInspector.hpp @@ -66,7 +66,7 @@ class CollapsibleInspectorHeader : public QAbstractButton Q_OBJECT public: - CollapsibleInspectorHeader(QString text, QWidget* parent = nullptr); + explicit CollapsibleInspectorHeader(QString text, QWidget* parent = nullptr); void setChecked(bool isChecked); diff --git a/src/openstudio_lib/ConstructionObjectVectorController.hpp b/src/openstudio_lib/ConstructionObjectVectorController.hpp index 2a8c82bce..95f147f51 100644 --- a/src/openstudio_lib/ConstructionObjectVectorController.hpp +++ b/src/openstudio_lib/ConstructionObjectVectorController.hpp @@ -42,7 +42,7 @@ class ConstructionObjectVectorController : public ModelObjectVectorController Q_OBJECT public: - ConstructionObjectVectorController(QWidget* parentWidget); + explicit ConstructionObjectVectorController(QWidget* parentWidget); // Need to delete the QMutex virtual ~ConstructionObjectVectorController(); diff --git a/src/openstudio_lib/DefaultConstructionSetInspectorView.hpp b/src/openstudio_lib/DefaultConstructionSetInspectorView.hpp index 16b11b879..edfe85de2 100644 --- a/src/openstudio_lib/DefaultConstructionSetInspectorView.hpp +++ b/src/openstudio_lib/DefaultConstructionSetInspectorView.hpp @@ -286,7 +286,7 @@ class DefaultConstructionSetInspectorView : public ModelObjectInspectorView Q_OBJECT public: - DefaultConstructionSetInspectorView(const model::Model& model, QWidget* parent = nullptr); + explicit DefaultConstructionSetInspectorView(const model::Model& model, QWidget* parent = nullptr); virtual ~DefaultConstructionSetInspectorView() {} protected: diff --git a/src/openstudio_lib/DefaultConstructionSetsController.hpp b/src/openstudio_lib/DefaultConstructionSetsController.hpp index a690b9d7a..29db6ca41 100644 --- a/src/openstudio_lib/DefaultConstructionSetsController.hpp +++ b/src/openstudio_lib/DefaultConstructionSetsController.hpp @@ -39,7 +39,7 @@ class DefaultConstructionSetsController : public ModelSubTabController Q_OBJECT public: - DefaultConstructionSetsController(const model::Model& model); + explicit DefaultConstructionSetsController(const model::Model& model); virtual ~DefaultConstructionSetsController(); diff --git a/src/openstudio_lib/EMSInspectorView.cpp b/src/openstudio_lib/EMSInspectorView.cpp index ae061a1de..275f7374b 100644 --- a/src/openstudio_lib/EMSInspectorView.cpp +++ b/src/openstudio_lib/EMSInspectorView.cpp @@ -50,7 +50,7 @@ class EMSInspectorHeader : public QWidget { public: - EMSInspectorHeader(const QString& text) : QWidget() { + explicit EMSInspectorHeader(const QString& text) : QWidget() { setContentsMargins(0, 0, 0, 0); setObjectName("IGHeader"); auto layout = new QVBoxLayout(); diff --git a/src/openstudio_lib/GeometryEditorView.hpp b/src/openstudio_lib/GeometryEditorView.hpp index 19aa29932..68e396377 100644 --- a/src/openstudio_lib/GeometryEditorView.hpp +++ b/src/openstudio_lib/GeometryEditorView.hpp @@ -68,7 +68,7 @@ class DebugWebView : public QDialog Q_OBJECT; public: - DebugWebView(const QString& debugPort, QWidget* parent = nullptr); + explicit DebugWebView(const QString& debugPort, QWidget* parent = nullptr); virtual ~DebugWebView(); private: diff --git a/src/openstudio_lib/GridItem.cpp b/src/openstudio_lib/GridItem.cpp index dd77b5546..e21e51445 100644 --- a/src/openstudio_lib/GridItem.cpp +++ b/src/openstudio_lib/GridItem.cpp @@ -2537,7 +2537,7 @@ void SplitterItem::setTerminalTypes(std::vector type // A Predicate that returns true on either m_type or DualDuct struct Predicate { - Predicate(TerminalType type) : m_type(type) {} + explicit Predicate(TerminalType type) : m_type(type) {} bool operator()(TerminalType t_type) const { if ((t_type == m_type) || (t_type == TerminalType::DualDuct)) { diff --git a/src/openstudio_lib/GridItem.hpp b/src/openstudio_lib/GridItem.hpp index b32a8789c..907da2116 100644 --- a/src/openstudio_lib/GridItem.hpp +++ b/src/openstudio_lib/GridItem.hpp @@ -152,7 +152,7 @@ class NodeContextButtonItem : public ButtonItem Q_OBJECT; public: - NodeContextButtonItem(GridItem* parent); + explicit NodeContextButtonItem(GridItem* parent); signals: @@ -326,7 +326,7 @@ class OneThreeDualDuctMixerItem : public GridItem class SupplyPlenumItem : public GridItem { public: - SupplyPlenumItem(const model::ModelObject& modelObject, QGraphicsItem* parent = nullptr); + explicit SupplyPlenumItem(const model::ModelObject& modelObject, QGraphicsItem* parent = nullptr); void paint(QPainter* painter, const QStyleOptionGraphicsItem* option, QWidget* widget = nullptr) override; @@ -339,7 +339,7 @@ class SupplyPlenumItem : public GridItem class ReturnPlenumItem : public GridItem { public: - ReturnPlenumItem(const model::ModelObject& modelObject, QGraphicsItem* parent = nullptr); + explicit ReturnPlenumItem(const model::ModelObject& modelObject, QGraphicsItem* parent = nullptr); void paint(QPainter* painter, const QStyleOptionGraphicsItem* option, QWidget* widget = nullptr) override; @@ -648,7 +648,7 @@ class HorizontalBranchItem : public GridItem { public: // Dual duct means there will be two parallel paths within one item - HorizontalBranchItem(const std::vector& modelObjects, QGraphicsItem* parent = nullptr, bool dualDuct = false); + explicit HorizontalBranchItem(const std::vector& modelObjects, QGraphicsItem* parent = nullptr, bool dualDuct = false); // This signature is always used on a dual duct // modelObjectsBeforeTerminal is what it says, the outer pair for the two parallel paths @@ -724,7 +724,7 @@ class HorizontalBranchGroupItem : public GridItem class VerticalBranchItem : public GridItem { public: - VerticalBranchItem(std::vector modelObjects, QGraphicsItem* parent = nullptr); + explicit VerticalBranchItem(std::vector modelObjects, QGraphicsItem* parent = nullptr); void setPadding(unsigned); @@ -742,7 +742,7 @@ class VerticalBranchItem : public GridItem class ReverseVerticalBranchItem : public GridItem { public: - ReverseVerticalBranchItem(std::vector modelObjects, QGraphicsItem* parent = nullptr); + explicit ReverseVerticalBranchItem(std::vector modelObjects, QGraphicsItem* parent = nullptr); void setPadding(unsigned); @@ -837,7 +837,7 @@ class DemandSideItem : public GridItem class OASystemItem : public GridItem { public: - OASystemItem(model::AirLoopHVACOutdoorAirSystem& oaSystem, QGraphicsItem* parent = nullptr); + explicit OASystemItem(model::AirLoopHVACOutdoorAirSystem& oaSystem, QGraphicsItem* parent = nullptr); protected: void layout(); diff --git a/src/openstudio_lib/HVACSystemsController.hpp b/src/openstudio_lib/HVACSystemsController.hpp index bf34bab68..87db420c8 100644 --- a/src/openstudio_lib/HVACSystemsController.hpp +++ b/src/openstudio_lib/HVACSystemsController.hpp @@ -198,7 +198,7 @@ class HVACControlsController Q_OBJECT; public: - HVACControlsController(HVACSystemsController* hvacSystemsController); + explicit HVACControlsController(HVACSystemsController* hvacSystemsController); virtual ~HVACControlsController(); @@ -273,7 +273,7 @@ class HVACLayoutController Q_OBJECT; public: - HVACLayoutController(HVACSystemsController* hvacSystemsController); + explicit HVACLayoutController(HVACSystemsController* hvacSystemsController); virtual ~HVACLayoutController(); diff --git a/src/openstudio_lib/HVACTemplateHelperDialog.hpp b/src/openstudio_lib/HVACTemplateHelperDialog.hpp index ac05653ae..52da17de4 100644 --- a/src/openstudio_lib/HVACTemplateHelperDialog.hpp +++ b/src/openstudio_lib/HVACTemplateHelperDialog.hpp @@ -43,7 +43,7 @@ class HVACTemplateHelperDialog : public QDialog Q_OBJECT; public: - HVACTemplateHelperDialog(const model::Model& model, QWidget* parent = nullptr); + explicit HVACTemplateHelperDialog(const model::Model& model, QWidget* parent = nullptr); virtual ~HVACTemplateHelperDialog() {} diff --git a/src/openstudio_lib/LifeCycleCostsTabView.hpp b/src/openstudio_lib/LifeCycleCostsTabView.hpp index aefb31aaa..7f2d790de 100644 --- a/src/openstudio_lib/LifeCycleCostsTabView.hpp +++ b/src/openstudio_lib/LifeCycleCostsTabView.hpp @@ -56,7 +56,7 @@ class LifeCycleCostsView : public QWidget Q_OBJECT public: - LifeCycleCostsView(const model::Model& model); + explicit LifeCycleCostsView(const model::Model& model); virtual ~LifeCycleCostsView(); diff --git a/src/openstudio_lib/LoopChooserView.hpp b/src/openstudio_lib/LoopChooserView.hpp index dbb5777e8..7716c2b5d 100644 --- a/src/openstudio_lib/LoopChooserView.hpp +++ b/src/openstudio_lib/LoopChooserView.hpp @@ -88,7 +88,7 @@ class LoopChooserItem : public QWidget Q_OBJECT; public: - LoopChooserItem(model::Loop&, LoopChooserView* parent = nullptr); + explicit LoopChooserItem(model::Loop&, LoopChooserView* parent = nullptr); virtual ~LoopChooserItem() {} diff --git a/src/openstudio_lib/LoopScene.hpp b/src/openstudio_lib/LoopScene.hpp index 548cb8740..f517b9935 100644 --- a/src/openstudio_lib/LoopScene.hpp +++ b/src/openstudio_lib/LoopScene.hpp @@ -70,7 +70,7 @@ class LoopScene : public GridScene Q_OBJECT public: - LoopScene(model::Loop loop, QObject* parent = nullptr); + explicit LoopScene(model::Loop loop, QObject* parent = nullptr); virtual ~LoopScene() {} diff --git a/src/openstudio_lib/MainTabController.hpp b/src/openstudio_lib/MainTabController.hpp index fb046ab5b..60e6c9f89 100644 --- a/src/openstudio_lib/MainTabController.hpp +++ b/src/openstudio_lib/MainTabController.hpp @@ -45,7 +45,7 @@ class MainTabController : public OSQObjectController Q_OBJECT public: - MainTabController(MainTabView* mainContentWidget); + explicit MainTabController(MainTabView* mainContentWidget); virtual ~MainTabController(); diff --git a/src/openstudio_lib/MainWindow.hpp b/src/openstudio_lib/MainWindow.hpp index 3a32e78a5..1ad05681c 100644 --- a/src/openstudio_lib/MainWindow.hpp +++ b/src/openstudio_lib/MainWindow.hpp @@ -51,7 +51,7 @@ class MainWindow : public QMainWindow Q_OBJECT public: - MainWindow(bool isPlugin, QWidget* parent = nullptr); + explicit MainWindow(bool isPlugin, QWidget* parent = nullptr); virtual ~MainWindow() {} void addVerticalTabButton(int id, QString toolTip, const QString& selectedImagePath, const QString& unSelectedImagePath, diff --git a/src/openstudio_lib/ModelObjectInspectorView.hpp b/src/openstudio_lib/ModelObjectInspectorView.hpp index 7e18e40e5..b653f2ac1 100644 --- a/src/openstudio_lib/ModelObjectInspectorView.hpp +++ b/src/openstudio_lib/ModelObjectInspectorView.hpp @@ -106,7 +106,7 @@ class DefaultInspectorView : public ModelObjectInspectorView Q_OBJECT public: - DefaultInspectorView(const model::Model& model, QWidget* parent = nullptr); + explicit DefaultInspectorView(const model::Model& model, QWidget* parent = nullptr); virtual ~DefaultInspectorView() {} diff --git a/src/openstudio_lib/ModelObjectTreeItems.hpp b/src/openstudio_lib/ModelObjectTreeItems.hpp index ea93ff757..fe971fed5 100644 --- a/src/openstudio_lib/ModelObjectTreeItems.hpp +++ b/src/openstudio_lib/ModelObjectTreeItems.hpp @@ -147,7 +147,7 @@ class SiteShadingTreeItem : public ModelObjectTreeItem Q_OBJECT public: - SiteShadingTreeItem(const openstudio::model::Model& model, QTreeWidgetItem* parent = nullptr); + explicit SiteShadingTreeItem(const openstudio::model::Model& model, QTreeWidgetItem* parent = nullptr); virtual ~SiteShadingTreeItem() {} static std::string itemName(); @@ -163,7 +163,7 @@ class ShadingSurfaceGroupTreeItem : public ModelObjectTreeItem Q_OBJECT public: - ShadingSurfaceGroupTreeItem(const openstudio::model::ShadingSurfaceGroup& shadingSurfaceGroup, QTreeWidgetItem* parent = nullptr); + explicit ShadingSurfaceGroupTreeItem(const openstudio::model::ShadingSurfaceGroup& shadingSurfaceGroup, QTreeWidgetItem* parent = nullptr); virtual ~ShadingSurfaceGroupTreeItem() {} protected: @@ -198,7 +198,7 @@ class BuildingShadingTreeItem : public ModelObjectTreeItem Q_OBJECT public: - BuildingShadingTreeItem(const openstudio::model::Model& model, QTreeWidgetItem* parent = nullptr); + explicit BuildingShadingTreeItem(const openstudio::model::Model& model, QTreeWidgetItem* parent = nullptr); virtual ~BuildingShadingTreeItem() {} static std::string itemName(); @@ -214,7 +214,7 @@ class BuildingStoryTreeItem : public ModelObjectTreeItem Q_OBJECT public: - BuildingStoryTreeItem(const openstudio::model::BuildingStory& buildingStory, QTreeWidgetItem* parent = nullptr); + explicit BuildingStoryTreeItem(const openstudio::model::BuildingStory& buildingStory, QTreeWidgetItem* parent = nullptr); virtual ~BuildingStoryTreeItem() {} protected: @@ -227,7 +227,7 @@ class NoBuildingStoryTreeItem : public ModelObjectTreeItem Q_OBJECT public: - NoBuildingStoryTreeItem(const openstudio::model::Model& model, QTreeWidgetItem* parent = nullptr); + explicit NoBuildingStoryTreeItem(const openstudio::model::Model& model, QTreeWidgetItem* parent = nullptr); virtual ~NoBuildingStoryTreeItem() {} static std::string itemName(); @@ -244,7 +244,7 @@ class ThermalZoneTreeItem : public ModelObjectTreeItem Q_OBJECT public: - ThermalZoneTreeItem(const openstudio::model::ThermalZone& thermalZone, QTreeWidgetItem* parent = nullptr); + explicit ThermalZoneTreeItem(const openstudio::model::ThermalZone& thermalZone, QTreeWidgetItem* parent = nullptr); virtual ~ThermalZoneTreeItem() {} protected: @@ -257,7 +257,7 @@ class NoThermalZoneTreeItem : public ModelObjectTreeItem Q_OBJECT public: - NoThermalZoneTreeItem(const openstudio::model::Model& model, QTreeWidgetItem* parent = nullptr); + explicit NoThermalZoneTreeItem(const openstudio::model::Model& model, QTreeWidgetItem* parent = nullptr); virtual ~NoThermalZoneTreeItem() {} static std::string itemName(); @@ -274,7 +274,7 @@ class SpaceTypeTreeItem : public ModelObjectTreeItem Q_OBJECT public: - SpaceTypeTreeItem(const openstudio::model::SpaceType& spaceType, QTreeWidgetItem* parent = nullptr); + explicit SpaceTypeTreeItem(const openstudio::model::SpaceType& spaceType, QTreeWidgetItem* parent = nullptr); virtual ~SpaceTypeTreeItem() {} protected: @@ -288,7 +288,7 @@ class NoSpaceTypeTreeItem : public ModelObjectTreeItem Q_OBJECT public: - NoSpaceTypeTreeItem(const openstudio::model::Model& model, QTreeWidgetItem* parent = nullptr); + explicit NoSpaceTypeTreeItem(const openstudio::model::Model& model, QTreeWidgetItem* parent = nullptr); virtual ~NoSpaceTypeTreeItem() {} static std::string itemName(); @@ -305,7 +305,7 @@ class SpaceTreeItem : public ModelObjectTreeItem Q_OBJECT public: - SpaceTreeItem(const openstudio::model::Space& space, QTreeWidgetItem* parent = nullptr); + explicit SpaceTreeItem(const openstudio::model::Space& space, QTreeWidgetItem* parent = nullptr); virtual ~SpaceTreeItem() {} protected: @@ -320,7 +320,7 @@ class RoofsTreeItem : public ModelObjectTreeItem Q_OBJECT public: - RoofsTreeItem(const openstudio::model::Space& space, QTreeWidgetItem* parent = nullptr); + explicit RoofsTreeItem(const openstudio::model::Space& space, QTreeWidgetItem* parent = nullptr); virtual ~RoofsTreeItem() {} static std::string itemName(); @@ -339,7 +339,7 @@ class WallsTreeItem : public ModelObjectTreeItem Q_OBJECT public: - WallsTreeItem(const openstudio::model::Space& space, QTreeWidgetItem* parent = nullptr); + explicit WallsTreeItem(const openstudio::model::Space& space, QTreeWidgetItem* parent = nullptr); virtual ~WallsTreeItem() {} static std::string itemName(); @@ -358,7 +358,7 @@ class FloorsTreeItem : public ModelObjectTreeItem Q_OBJECT public: - FloorsTreeItem(const openstudio::model::Space& space, QTreeWidgetItem* parent = nullptr); + explicit FloorsTreeItem(const openstudio::model::Space& space, QTreeWidgetItem* parent = nullptr); virtual ~FloorsTreeItem() {} static std::string itemName(); @@ -377,7 +377,7 @@ class SurfaceTreeItem : public ModelObjectTreeItem Q_OBJECT public: - SurfaceTreeItem(const openstudio::model::Surface& surface, QTreeWidgetItem* parent = nullptr); + explicit SurfaceTreeItem(const openstudio::model::Surface& surface, QTreeWidgetItem* parent = nullptr); virtual ~SurfaceTreeItem() {} protected: @@ -391,7 +391,7 @@ class SpaceShadingTreeItem : public ModelObjectTreeItem Q_OBJECT public: - SpaceShadingTreeItem(const openstudio::model::Space& space, QTreeWidgetItem* parent = nullptr); + explicit SpaceShadingTreeItem(const openstudio::model::Space& space, QTreeWidgetItem* parent = nullptr); virtual ~SpaceShadingTreeItem() {} static std::string itemName(); @@ -410,7 +410,7 @@ class InteriorPartitionsTreeItem : public ModelObjectTreeItem Q_OBJECT public: - InteriorPartitionsTreeItem(const openstudio::model::Space& space, QTreeWidgetItem* parent = nullptr); + explicit InteriorPartitionsTreeItem(const openstudio::model::Space& space, QTreeWidgetItem* parent = nullptr); virtual ~InteriorPartitionsTreeItem() {} static std::string itemName(); @@ -429,7 +429,7 @@ class InteriorPartitionSurfaceGroupTreeItem : public ModelObjectTreeItem Q_OBJECT public: - InteriorPartitionSurfaceGroupTreeItem(const openstudio::model::InteriorPartitionSurfaceGroup& interiorPartitionSurfaceGroup, + explicit InteriorPartitionSurfaceGroupTreeItem(const openstudio::model::InteriorPartitionSurfaceGroup& interiorPartitionSurfaceGroup, QTreeWidgetItem* parent = nullptr); virtual ~InteriorPartitionSurfaceGroupTreeItem() {} @@ -444,7 +444,7 @@ class DaylightingObjectsTreeItem : public ModelObjectTreeItem Q_OBJECT public: - DaylightingObjectsTreeItem(const openstudio::model::Space& space, QTreeWidgetItem* parent = nullptr); + explicit DaylightingObjectsTreeItem(const openstudio::model::Space& space, QTreeWidgetItem* parent = nullptr); virtual ~DaylightingObjectsTreeItem() {} static std::string itemName(); @@ -462,7 +462,7 @@ class LoadsTreeItem : public ModelObjectTreeItem Q_OBJECT public: - LoadsTreeItem(const openstudio::model::Space& space, QTreeWidgetItem* parent = nullptr); + explicit LoadsTreeItem(const openstudio::model::Space& space, QTreeWidgetItem* parent = nullptr); virtual ~LoadsTreeItem() {} static std::string itemName(); diff --git a/src/openstudio_lib/OSCollapsibleItemList.hpp b/src/openstudio_lib/OSCollapsibleItemList.hpp index 3378f1ca0..716458029 100644 --- a/src/openstudio_lib/OSCollapsibleItemList.hpp +++ b/src/openstudio_lib/OSCollapsibleItemList.hpp @@ -48,7 +48,7 @@ class OSCollapsibleItemList : public OSItemSelector Q_OBJECT public: - OSCollapsibleItemList(bool addScrollArea, QWidget* parent = nullptr); + explicit OSCollapsibleItemList(bool addScrollArea, QWidget* parent = nullptr); virtual ~OSCollapsibleItemList() {} diff --git a/src/openstudio_lib/OSDropZone.hpp b/src/openstudio_lib/OSDropZone.hpp index fff000468..9f945e9da 100644 --- a/src/openstudio_lib/OSDropZone.hpp +++ b/src/openstudio_lib/OSDropZone.hpp @@ -152,7 +152,7 @@ class OSDropZone Q_OBJECT public: - OSDropZone(OSVectorController* vectorController, const QString& text = "Drag From Library", const QSize& size = QSize(0, 0), + explicit OSDropZone(OSVectorController* vectorController, const QString& text = "Drag From Library", const QSize& size = QSize(0, 0), bool growsHorizontally = true, QWidget* parent = nullptr); virtual ~OSDropZone() {} diff --git a/src/openstudio_lib/OSItem.hpp b/src/openstudio_lib/OSItem.hpp index a14b956f8..d9530a8da 100644 --- a/src/openstudio_lib/OSItem.hpp +++ b/src/openstudio_lib/OSItem.hpp @@ -54,7 +54,7 @@ class OSItemId static const QString BCL_SOURCE_ID; OSItemId(); OSItemId(const QString& itemId, const QString& sourceId, bool isDefaulted, const QString& otherData = ""); - OSItemId(const QMimeData* mimeData); + explicit OSItemId(const QMimeData* mimeData); QString itemId() const; QString sourceId() const; QString otherData() const; diff --git a/src/openstudio_lib/PlanarSurfaceWidget.hpp b/src/openstudio_lib/PlanarSurfaceWidget.hpp index 22ef16cef..351ee5042 100644 --- a/src/openstudio_lib/PlanarSurfaceWidget.hpp +++ b/src/openstudio_lib/PlanarSurfaceWidget.hpp @@ -44,7 +44,7 @@ class PlanarSurfaceWidget Q_OBJECT public: - PlanarSurfaceWidget(bool isIP, QWidget* parent = nullptr); + explicit PlanarSurfaceWidget(bool isIP, QWidget* parent = nullptr); virtual ~PlanarSurfaceWidget() {} diff --git a/src/openstudio_lib/RefrigerationController.hpp b/src/openstudio_lib/RefrigerationController.hpp index c2c0c307b..1aed60ef2 100644 --- a/src/openstudio_lib/RefrigerationController.hpp +++ b/src/openstudio_lib/RefrigerationController.hpp @@ -140,7 +140,7 @@ class RefrigerationSystemListController : public OSListController Q_OBJECT public: - RefrigerationSystemListController(RefrigerationController* refrigerationController); + explicit RefrigerationSystemListController(RefrigerationController* refrigerationController); RefrigerationController* refrigerationController() const; QSharedPointer itemAt(int i) override; @@ -194,7 +194,7 @@ class RefrigerationSystemListItem : public OSListItem Q_OBJECT public: - RefrigerationSystemListItem(const model::RefrigerationSystem& refrigerationSystem, OSListController* listController = nullptr); + explicit RefrigerationSystemListItem(const model::RefrigerationSystem& refrigerationSystem, OSListController* listController = nullptr); virtual ~RefrigerationSystemListItem() {} QString systemName() const; diff --git a/src/openstudio_lib/RunTabView.hpp b/src/openstudio_lib/RunTabView.hpp index 45a245138..0c2922436 100644 --- a/src/openstudio_lib/RunTabView.hpp +++ b/src/openstudio_lib/RunTabView.hpp @@ -113,7 +113,7 @@ class RunTabView : public MainTabView Q_OBJECT; public: - RunTabView(const model::Model& model, QWidget* parent = nullptr); + explicit RunTabView(const model::Model& model, QWidget* parent = nullptr); virtual ~RunTabView() {} diff --git a/src/openstudio_lib/ScheduleDayView.hpp b/src/openstudio_lib/ScheduleDayView.hpp index 00e84a499..20a3d13ee 100644 --- a/src/openstudio_lib/ScheduleDayView.hpp +++ b/src/openstudio_lib/ScheduleDayView.hpp @@ -350,7 +350,7 @@ class DaySchedulePlotArea : public QGraphicsView Q_OBJECT public: - DaySchedulePlotArea(ScheduleDayEditor* scheduleDayEditor); + explicit DaySchedulePlotArea(ScheduleDayEditor* scheduleDayEditor); virtual ~DaySchedulePlotArea() {} @@ -400,7 +400,7 @@ class DayScheduleOverview : public QWidget Q_OBJECT public: - DayScheduleOverview(ScheduleDayView* scheduleRuleView); + explicit DayScheduleOverview(ScheduleDayView* scheduleRuleView); virtual ~DayScheduleOverview() {} @@ -568,7 +568,7 @@ class CalendarSegmentItem : public QGraphicsItem class ScheduleTypeLimitItem : public QGraphicsItem { public: - ScheduleTypeLimitItem(bool isUpperLimit, QGraphicsItem* parent = nullptr); + explicit ScheduleTypeLimitItem(bool isUpperLimit, QGraphicsItem* parent = nullptr); virtual ~ScheduleTypeLimitItem() {} diff --git a/src/openstudio_lib/ScheduleSetInspectorView.hpp b/src/openstudio_lib/ScheduleSetInspectorView.hpp index 614bac257..77bf0e4d9 100644 --- a/src/openstudio_lib/ScheduleSetInspectorView.hpp +++ b/src/openstudio_lib/ScheduleSetInspectorView.hpp @@ -196,7 +196,7 @@ class ScheduleSetInspectorView : public ModelObjectInspectorView Q_OBJECT public: - ScheduleSetInspectorView(const model::Model& model, QWidget* parent = nullptr); + explicit ScheduleSetInspectorView(const model::Model& model, QWidget* parent = nullptr); virtual ~ScheduleSetInspectorView() {} protected: diff --git a/src/openstudio_lib/ScheduleSetsController.hpp b/src/openstudio_lib/ScheduleSetsController.hpp index 86586e37e..5058b76b2 100644 --- a/src/openstudio_lib/ScheduleSetsController.hpp +++ b/src/openstudio_lib/ScheduleSetsController.hpp @@ -39,7 +39,7 @@ class ScheduleSetsController : public ModelSubTabController Q_OBJECT public: - ScheduleSetsController(const model::Model& model); + explicit ScheduleSetsController(const model::Model& model); virtual ~ScheduleSetsController() {} diff --git a/src/openstudio_lib/ScheduleSetsView.hpp b/src/openstudio_lib/ScheduleSetsView.hpp index 376be4424..00f486e9c 100644 --- a/src/openstudio_lib/ScheduleSetsView.hpp +++ b/src/openstudio_lib/ScheduleSetsView.hpp @@ -44,7 +44,7 @@ class ScheduleSetsView : public ModelSubTabView Q_OBJECT public: - ScheduleSetsView(const openstudio::model::Model& model, QWidget* parent = nullptr); + explicit ScheduleSetsView(const openstudio::model::Model& model, QWidget* parent = nullptr); virtual ~ScheduleSetsView() {} @@ -57,7 +57,7 @@ class ScheduleSetsInspectorView : public ModelObjectInspectorView Q_OBJECT public: - ScheduleSetsInspectorView(const model::Model& model, QWidget* parent = nullptr); + explicit ScheduleSetsInspectorView(const model::Model& model, QWidget* parent = nullptr); virtual ~ScheduleSetsInspectorView() {} diff --git a/src/openstudio_lib/SchedulesTabView.hpp b/src/openstudio_lib/SchedulesTabView.hpp index ba989bfcc..1375e7e73 100644 --- a/src/openstudio_lib/SchedulesTabView.hpp +++ b/src/openstudio_lib/SchedulesTabView.hpp @@ -39,7 +39,7 @@ class SchedulesTabView : public MainTabView Q_OBJECT public: - SchedulesTabView(const model::Model& model, QWidget* parent = nullptr); + explicit SchedulesTabView(const model::Model& model, QWidget* parent = nullptr); virtual ~SchedulesTabView() {} }; diff --git a/src/openstudio_lib/SchedulesView.hpp b/src/openstudio_lib/SchedulesView.hpp index c03a69a12..aabdcbc60 100644 --- a/src/openstudio_lib/SchedulesView.hpp +++ b/src/openstudio_lib/SchedulesView.hpp @@ -320,7 +320,7 @@ class ScheduleTabHeader Q_OBJECT public: - ScheduleTabHeader(ScheduleTab* scheduleTab, QWidget* parent = nullptr); + explicit ScheduleTabHeader(ScheduleTab* scheduleTab, QWidget* parent = nullptr); virtual ~ScheduleTabHeader() {} @@ -379,7 +379,7 @@ class ScheduleTabContent Q_OBJECT public: - ScheduleTabContent(ScheduleTab* scheduleTab, QWidget* parent = nullptr); + explicit ScheduleTabContent(ScheduleTab* scheduleTab, QWidget* parent = nullptr); virtual ~ScheduleTabContent() {} @@ -703,7 +703,7 @@ class ScheduleRulesetNameWidget Q_OBJECT public: - ScheduleRulesetNameWidget(const model::ScheduleRuleset& scheduleRuleset); + explicit ScheduleRulesetNameWidget(const model::ScheduleRuleset& scheduleRuleset); virtual ~ScheduleRulesetNameWidget() {} @@ -721,7 +721,7 @@ class YearOverview Q_OBJECT public: - YearOverview(const model::ScheduleRuleset& scheduleRuleset, QWidget* parent = nullptr); + explicit YearOverview(const model::ScheduleRuleset& scheduleRuleset, QWidget* parent = nullptr); virtual ~YearOverview() {} @@ -779,7 +779,7 @@ class MonthView Q_OBJECT public: - MonthView(YearOverview* yearOverview); + explicit MonthView(YearOverview* yearOverview); virtual ~MonthView() {} diff --git a/src/openstudio_lib/ScriptsTabView.hpp b/src/openstudio_lib/ScriptsTabView.hpp index 709732ff5..a74bfa0ed 100644 --- a/src/openstudio_lib/ScriptsTabView.hpp +++ b/src/openstudio_lib/ScriptsTabView.hpp @@ -45,7 +45,7 @@ class ScriptsTabView : public MainTabView Q_OBJECT public: - ScriptsTabView(QWidget* t_parent); + explicit ScriptsTabView(QWidget* t_parent); virtual ~ScriptsTabView() {} diff --git a/src/openstudio_lib/ServiceWaterGridItems.hpp b/src/openstudio_lib/ServiceWaterGridItems.hpp index ef8c9712b..6b8b4c9dc 100644 --- a/src/openstudio_lib/ServiceWaterGridItems.hpp +++ b/src/openstudio_lib/ServiceWaterGridItems.hpp @@ -46,7 +46,7 @@ class WaterUseConnectionsDetailScene; class ServiceWaterItem : public GridItem { public: - ServiceWaterItem(ServiceWaterScene* serviceWaterScene); + explicit ServiceWaterItem(ServiceWaterScene* serviceWaterScene); protected: void paint(QPainter* painter, const QStyleOptionGraphicsItem* option, QWidget* widget = nullptr) override; @@ -55,7 +55,7 @@ class ServiceWaterItem : public GridItem class WaterUseConnectionsDetailItem : public GridItem { public: - WaterUseConnectionsDetailItem(WaterUseConnectionsDetailScene* waterUseConnectionsDetailScene); + explicit WaterUseConnectionsDetailItem(WaterUseConnectionsDetailScene* waterUseConnectionsDetailScene); protected: void paint(QPainter* painter, const QStyleOptionGraphicsItem* option, QWidget* widget = nullptr) override; @@ -175,7 +175,7 @@ class HotWaterJunctionItem : public DoubleTwoFourStraightItem class ColdWaterJunctionItem : public GridItem { public: - ColdWaterJunctionItem(int isElbow, QGraphicsItem* parent = nullptr); + explicit ColdWaterJunctionItem(int isElbow, QGraphicsItem* parent = nullptr); protected: void paint(QPainter* painter, const QStyleOptionGraphicsItem* option, QWidget* widget = nullptr) override; diff --git a/src/openstudio_lib/ServiceWaterScene.hpp b/src/openstudio_lib/ServiceWaterScene.hpp index 5a1b3c8c4..49c46f06f 100644 --- a/src/openstudio_lib/ServiceWaterScene.hpp +++ b/src/openstudio_lib/ServiceWaterScene.hpp @@ -49,7 +49,7 @@ class ServiceWaterScene : public GridScene Q_OBJECT public: - ServiceWaterScene(const model::Model& model); + explicit ServiceWaterScene(const model::Model& model); virtual ~ServiceWaterScene() {} @@ -78,7 +78,7 @@ class WaterUseConnectionsDetailScene : public GridScene Q_OBJECT public: - WaterUseConnectionsDetailScene(const model::WaterUseConnections& waterUseConnections); + explicit WaterUseConnectionsDetailScene(const model::WaterUseConnections& waterUseConnections); virtual ~WaterUseConnectionsDetailScene() {} diff --git a/src/openstudio_lib/StandardOpaqueMaterialInspectorView.hpp b/src/openstudio_lib/StandardOpaqueMaterialInspectorView.hpp index a74eb371c..12e58286d 100644 --- a/src/openstudio_lib/StandardOpaqueMaterialInspectorView.hpp +++ b/src/openstudio_lib/StandardOpaqueMaterialInspectorView.hpp @@ -43,7 +43,7 @@ class StandardOpaqueMaterialInspectorView : public ModelObjectInspectorView Q_OBJECT public: - StandardOpaqueMaterialInspectorView(const model::Model& model, QWidget* parent = nullptr); + explicit StandardOpaqueMaterialInspectorView(const model::Model& model, QWidget* parent = nullptr); virtual ~StandardOpaqueMaterialInspectorView() {} diff --git a/src/openstudio_lib/SummaryTabController.hpp b/src/openstudio_lib/SummaryTabController.hpp index d5f768900..e62933786 100644 --- a/src/openstudio_lib/SummaryTabController.hpp +++ b/src/openstudio_lib/SummaryTabController.hpp @@ -41,7 +41,7 @@ class SummaryTabController : public MainTabController Q_OBJECT public: - SummaryTabController(const model::Model& model); + explicit SummaryTabController(const model::Model& model); virtual ~SummaryTabController() {} }; diff --git a/src/openstudio_lib/SummaryTabView.hpp b/src/openstudio_lib/SummaryTabView.hpp index 1f9e29cf6..31c79db4c 100644 --- a/src/openstudio_lib/SummaryTabView.hpp +++ b/src/openstudio_lib/SummaryTabView.hpp @@ -40,7 +40,7 @@ class SummaryTabView : public MainTabView Q_OBJECT public: - SummaryTabView(const model::Model& model, QWidget* parent = nullptr); + explicit SummaryTabView(const model::Model& model, QWidget* parent = nullptr); virtual ~SummaryTabView() {} }; diff --git a/src/openstudio_lib/UtilityBillsController.hpp b/src/openstudio_lib/UtilityBillsController.hpp index e9b42af9d..5c9adaa7c 100644 --- a/src/openstudio_lib/UtilityBillsController.hpp +++ b/src/openstudio_lib/UtilityBillsController.hpp @@ -39,7 +39,7 @@ class UtilityBillsController : public ModelSubTabController Q_OBJECT public: - UtilityBillsController(const model::Model& model); + explicit UtilityBillsController(const model::Model& model); virtual ~UtilityBillsController() {} diff --git a/src/openstudio_lib/UtilityBillsView.hpp b/src/openstudio_lib/UtilityBillsView.hpp index 7beda45c3..9e802ec09 100644 --- a/src/openstudio_lib/UtilityBillsView.hpp +++ b/src/openstudio_lib/UtilityBillsView.hpp @@ -77,7 +77,7 @@ class UtilityBillsView : public ModelSubTabView Q_OBJECT public: - UtilityBillsView(const model::Model& model, QWidget* parent = nullptr); + explicit UtilityBillsView(const model::Model& model, QWidget* parent = nullptr); virtual ~UtilityBillsView(); diff --git a/src/openstudio_lib/VRFController.hpp b/src/openstudio_lib/VRFController.hpp index f164b5551..7756f61b6 100644 --- a/src/openstudio_lib/VRFController.hpp +++ b/src/openstudio_lib/VRFController.hpp @@ -107,7 +107,7 @@ class VRFSystemListController : public OSListController Q_OBJECT public: - VRFSystemListController(VRFController* vrfController); + explicit VRFSystemListController(VRFController* vrfController); VRFController* vrfController() const; @@ -159,7 +159,7 @@ class VRFSystemListItem : public OSListItem Q_OBJECT public: - VRFSystemListItem(const model::AirConditionerVariableRefrigerantFlow& vrfSystem, OSListController* listController = nullptr); + explicit VRFSystemListItem(const model::AirConditionerVariableRefrigerantFlow& vrfSystem, OSListController* listController = nullptr); virtual ~VRFSystemListItem() {} diff --git a/src/openstudio_lib/VariablesTabController.hpp b/src/openstudio_lib/VariablesTabController.hpp index 3a20598c4..013e33c96 100644 --- a/src/openstudio_lib/VariablesTabController.hpp +++ b/src/openstudio_lib/VariablesTabController.hpp @@ -39,7 +39,7 @@ class VariablesTabController : public MainTabController Q_OBJECT public: - VariablesTabController(const model::Model& model); + explicit VariablesTabController(const model::Model& model); virtual ~VariablesTabController() {} }; diff --git a/src/openstudio_lib/VariablesTabView.hpp b/src/openstudio_lib/VariablesTabView.hpp index 4bb906f61..8a8eec2c3 100644 --- a/src/openstudio_lib/VariablesTabView.hpp +++ b/src/openstudio_lib/VariablesTabView.hpp @@ -83,7 +83,7 @@ class VariablesList Q_OBJECT; public: - VariablesList(openstudio::model::Model t_model); + explicit VariablesList(openstudio::model::Model t_model); virtual ~VariablesList(); private slots: @@ -111,7 +111,7 @@ class VariablesTabView : public MainTabView Q_OBJECT; public: - VariablesTabView(openstudio::model::Model t_model, QWidget* parent = nullptr); + explicit VariablesTabView(openstudio::model::Model t_model, QWidget* parent = nullptr); virtual ~VariablesTabView() {} diff --git a/src/openstudio_lib/YearSettingsWidget.hpp b/src/openstudio_lib/YearSettingsWidget.hpp index 19c2c1e0b..b2a1442ac 100644 --- a/src/openstudio_lib/YearSettingsWidget.hpp +++ b/src/openstudio_lib/YearSettingsWidget.hpp @@ -70,7 +70,7 @@ class YearSettingsWidget // A list of the months. static std::vector months(); - YearSettingsWidget(const model::Model& model, QWidget* parent = nullptr); + explicit YearSettingsWidget(const model::Model& model, QWidget* parent = nullptr); bool calendarYearChecked(); diff --git a/src/openstudio_lib/ZoneChooserView.hpp b/src/openstudio_lib/ZoneChooserView.hpp index f0cb79943..9ce331e89 100644 --- a/src/openstudio_lib/ZoneChooserView.hpp +++ b/src/openstudio_lib/ZoneChooserView.hpp @@ -86,7 +86,7 @@ class ZoneChooserItem : public QWidget Q_OBJECT; public: - ZoneChooserItem(model::ThermalZone&, ZoneChooserView* parent = nullptr); + explicit ZoneChooserItem(model::ThermalZone&, ZoneChooserView* parent = nullptr); virtual ~ZoneChooserItem() {} diff --git a/src/shared_gui_components/BCLMeasureDialog.hpp b/src/shared_gui_components/BCLMeasureDialog.hpp index 13bcc00bf..4006fbbf7 100644 --- a/src/shared_gui_components/BCLMeasureDialog.hpp +++ b/src/shared_gui_components/BCLMeasureDialog.hpp @@ -52,7 +52,7 @@ class BCLMeasureDialog : public OSDialog BCLMeasureDialog(QWidget* parent = nullptr); /// Constructor of the dialog to create a copy of an existing BCL Measure - BCLMeasureDialog(const BCLMeasure& bclMeasure, QWidget* parent = nullptr); + explicit BCLMeasureDialog(const BCLMeasure& bclMeasure, QWidget* parent = nullptr); virtual ~BCLMeasureDialog(); diff --git a/src/shared_gui_components/BuildingComponentDialog.hpp b/src/shared_gui_components/BuildingComponentDialog.hpp index 8f0c47a62..b8421fb8f 100644 --- a/src/shared_gui_components/BuildingComponentDialog.hpp +++ b/src/shared_gui_components/BuildingComponentDialog.hpp @@ -55,7 +55,7 @@ class BuildingComponentDialog : public QDialog Q_OBJECT public: - BuildingComponentDialog(std::string& filterType, bool isBclDlg = true, QWidget* parent = nullptr); + explicit BuildingComponentDialog(std::string& filterType, bool isBclDlg = true, QWidget* parent = nullptr); virtual ~BuildingComponentDialog() {} int currentTIDSelection(); diff --git a/src/shared_gui_components/BuildingComponentDialogCentralWidget.hpp b/src/shared_gui_components/BuildingComponentDialogCentralWidget.hpp index 5c4645581..888079b52 100644 --- a/src/shared_gui_components/BuildingComponentDialogCentralWidget.hpp +++ b/src/shared_gui_components/BuildingComponentDialogCentralWidget.hpp @@ -61,7 +61,7 @@ class BuildingComponentDialogCentralWidget public: BuildingComponentDialogCentralWidget(QWidget* parent = nullptr); - BuildingComponentDialogCentralWidget(int tid, QWidget* parent = nullptr); + explicit BuildingComponentDialogCentralWidget(int tid, QWidget* parent = nullptr); virtual ~BuildingComponentDialogCentralWidget(); int tid() const; void setTid(const std::string& filterType, int tid, int pageIdx, const QString& title, const QString& searchString = ""); diff --git a/src/shared_gui_components/CollapsibleComponentList.hpp b/src/shared_gui_components/CollapsibleComponentList.hpp index 63cd781ce..5da98a333 100644 --- a/src/shared_gui_components/CollapsibleComponentList.hpp +++ b/src/shared_gui_components/CollapsibleComponentList.hpp @@ -48,7 +48,7 @@ class CollapsibleComponentList : public QWidget public: CollapsibleComponentList(QWidget* parent = nullptr); - CollapsibleComponentList(const std::vector& collapsibleComponents, QWidget* parent = nullptr); + explicit CollapsibleComponentList(const std::vector& collapsibleComponents, QWidget* parent = nullptr); virtual ~CollapsibleComponentList() {} // return the checked component in the list, NULL if list is empty Component* checkedComponent() const; diff --git a/src/shared_gui_components/Component.hpp b/src/shared_gui_components/Component.hpp index 261505416..f92c0e042 100644 --- a/src/shared_gui_components/Component.hpp +++ b/src/shared_gui_components/Component.hpp @@ -48,8 +48,8 @@ class Component : public QAbstractButton Q_OBJECT public: - Component(const BCLMeasure& bclMeasure, bool showAbridgedView = true, bool showCheckBox = true, QWidget* parent = nullptr); - Component(const BCLSearchResult& bclSearchResult, bool showAbridgedView = true, bool showCheckBox = true, QWidget* parent = nullptr); + explicit Component(const BCLMeasure& bclMeasure, bool showAbridgedView = true, bool showCheckBox = true, QWidget* parent = nullptr); + explicit Component(const BCLSearchResult& bclSearchResult, bool showAbridgedView = true, bool showCheckBox = true, QWidget* parent = nullptr); Component(bool showAbridgedView = false, bool showCheckBox = false, QWidget* parent = nullptr); Component(const Component& other); virtual ~Component() = default; diff --git a/src/shared_gui_components/ComponentList.hpp b/src/shared_gui_components/ComponentList.hpp index 2e9fd3351..e7c38c874 100644 --- a/src/shared_gui_components/ComponentList.hpp +++ b/src/shared_gui_components/ComponentList.hpp @@ -46,7 +46,7 @@ class ComponentList : public QWidget public: ComponentList(QWidget* parent = nullptr); - ComponentList(const std::vector& components, QWidget* parent = nullptr); + explicit ComponentList(const std::vector& components, QWidget* parent = nullptr); virtual ~ComponentList() {} // return the checked component in the list, NULL if list is empty Component* checkedComponent() const; diff --git a/src/shared_gui_components/EditView.hpp b/src/shared_gui_components/EditView.hpp index 51ace053b..84533fe63 100644 --- a/src/shared_gui_components/EditView.hpp +++ b/src/shared_gui_components/EditView.hpp @@ -62,7 +62,7 @@ class EditRubyMeasureView : public QWidget Q_OBJECT public: - EditRubyMeasureView(bool applyMeasureNow); + explicit EditRubyMeasureView(bool applyMeasureNow); virtual ~EditRubyMeasureView() {} QLineEdit* nameLineEdit; diff --git a/src/shared_gui_components/LocalLibraryController.hpp b/src/shared_gui_components/LocalLibraryController.hpp index 10cdc4522..605254698 100644 --- a/src/shared_gui_components/LocalLibraryController.hpp +++ b/src/shared_gui_components/LocalLibraryController.hpp @@ -71,7 +71,7 @@ class LocalLibraryController : public QObject public: QPointer localLibraryView; - LocalLibraryController(openstudio::BaseApp* t_app, bool onlyShowModelMeasures = false); + explicit LocalLibraryController(openstudio::BaseApp* t_app, bool onlyShowModelMeasures = false); virtual ~LocalLibraryController(); @@ -111,7 +111,7 @@ class LibraryTypeItem : public OSListItem Q_OBJECT public: - LibraryTypeItem(const QString& name); + explicit LibraryTypeItem(const QString& name); virtual ~LibraryTypeItem() {} QString name() const { @@ -133,7 +133,7 @@ class LibraryTypeItemDelegate : public OSItemDelegate QWidget* view(QSharedPointer dataSource) override; public: - LibraryTypeItemDelegate(BaseApp* t_app); + explicit LibraryTypeItemDelegate(BaseApp* t_app); virtual ~LibraryTypeItemDelegate() {} private: @@ -186,7 +186,7 @@ class LibraryGroupItemDelegate : public OSItemDelegate QWidget* view(QSharedPointer dataSource) override; public: - LibraryGroupItemDelegate(BaseApp* t_app); + explicit LibraryGroupItemDelegate(BaseApp* t_app); virtual ~LibraryGroupItemDelegate() {} private: @@ -246,7 +246,7 @@ class LibrarySubGroupItemDelegate : public OSItemDelegate QWidget* view(QSharedPointer dataSource) override; public: - LibrarySubGroupItemDelegate(BaseApp* t_app); + explicit LibrarySubGroupItemDelegate(BaseApp* t_app); virtual ~LibrarySubGroupItemDelegate() {} private: @@ -258,7 +258,7 @@ class LibrarySubGroupListController : public OSListController Q_OBJECT; public: - LibrarySubGroupListController(BaseApp* t_app); + explicit LibrarySubGroupListController(BaseApp* t_app); virtual ~LibrarySubGroupListController() {} QSharedPointer itemAt(int i) override; @@ -327,7 +327,7 @@ class LibraryItemDelegate : public OSItemDelegate Q_OBJECT; public: - LibraryItemDelegate(BaseApp* t_app); + explicit LibraryItemDelegate(BaseApp* t_app); virtual ~LibraryItemDelegate() {} QWidget* view(QSharedPointer dataSource) override; diff --git a/src/shared_gui_components/MeasureDragData.hpp b/src/shared_gui_components/MeasureDragData.hpp index 981f9cf40..6037fee1a 100644 --- a/src/shared_gui_components/MeasureDragData.hpp +++ b/src/shared_gui_components/MeasureDragData.hpp @@ -47,9 +47,9 @@ class MeasureDragData : QObject static QString mimeType(openstudio::MeasureType type); - MeasureDragData(const QByteArray& data); + explicit MeasureDragData(const QByteArray& data); - MeasureDragData(const UUID& id); + explicit MeasureDragData(const UUID& id); virtual ~MeasureDragData() {} diff --git a/src/shared_gui_components/MeasureManager.hpp b/src/shared_gui_components/MeasureManager.hpp index d6c5234f1..598b298be 100644 --- a/src/shared_gui_components/MeasureManager.hpp +++ b/src/shared_gui_components/MeasureManager.hpp @@ -96,7 +96,7 @@ class MeasureManager : public QObject Q_OBJECT; public: - MeasureManager(BaseApp* t_app); + explicit MeasureManager(BaseApp* t_app); virtual ~MeasureManager() {} diff --git a/src/shared_gui_components/OSCollapsibleView.hpp b/src/shared_gui_components/OSCollapsibleView.hpp index ea8852222..4817e7917 100644 --- a/src/shared_gui_components/OSCollapsibleView.hpp +++ b/src/shared_gui_components/OSCollapsibleView.hpp @@ -46,7 +46,7 @@ class OSHeader : public QPushButton Q_OBJECT public: - OSHeader(QPushButton* button); + explicit OSHeader(QPushButton* button); virtual ~OSHeader() {} diff --git a/src/shared_gui_components/OSConcepts.hpp b/src/shared_gui_components/OSConcepts.hpp index 4bd5c650a..e716bc0b6 100644 --- a/src/shared_gui_components/OSConcepts.hpp +++ b/src/shared_gui_components/OSConcepts.hpp @@ -262,7 +262,7 @@ class ConceptProxy { public: template - ConceptProxy(const T& t_obj) : m_any(t_obj) {} + explicit ConceptProxy(const T& t_obj) : m_any(t_obj) {} template T cast() const { @@ -295,7 +295,7 @@ class BaseConcept public: virtual ~BaseConcept() {} - BaseConcept(const Heading& t_heading, bool t_hasClickFocus = false) + explicit BaseConcept(const Heading& t_heading, bool t_hasClickFocus = false) : m_heading(t_heading), m_selector(false), m_parent(false), m_hasClickFocus(t_hasClickFocus) {} // isSelector is true for checkbox cells in the select column diff --git a/src/shared_gui_components/OSGridController.hpp b/src/shared_gui_components/OSGridController.hpp index 5168e289d..95f8b6893 100644 --- a/src/shared_gui_components/OSGridController.hpp +++ b/src/shared_gui_components/OSGridController.hpp @@ -107,7 +107,7 @@ class DataSource /// it's rendered with the function OSGridController::makeWidget function just like every /// other widget, so it can really be anything. template - DataSource(const std::function(InputType)>& t_sourceFunc, bool t_wantsPlaceholder = false, + explicit DataSource(const std::function(InputType)>& t_sourceFunc, bool t_wantsPlaceholder = false, const QSharedPointer& t_dropZoneConcept = QSharedPointer()) : m_wantsPlaceholder(t_wantsPlaceholder), m_dropZoneConcept(t_dropZoneConcept) { typedef decltype(t_sourceFunc) IncommingFuncType; @@ -661,7 +661,7 @@ class HorizontalHeaderWidget : public QWidget Q_OBJECT public: - HorizontalHeaderWidget(const QString& fieldName, QWidget* parent = nullptr); + explicit HorizontalHeaderWidget(const QString& fieldName, QWidget* parent = nullptr); virtual ~HorizontalHeaderWidget(); void addWidget(const QSharedPointer& t_widget); diff --git a/src/shared_gui_components/OSObjectSelector.hpp b/src/shared_gui_components/OSObjectSelector.hpp index b6c152e23..fb8b2caf6 100644 --- a/src/shared_gui_components/OSObjectSelector.hpp +++ b/src/shared_gui_components/OSObjectSelector.hpp @@ -120,7 +120,7 @@ class OSObjectSelector : public QObject Q_OBJECT; public: - OSObjectSelector(QObject* parent); + explicit OSObjectSelector(QObject* parent); enum PropertyChange { diff --git a/src/shared_gui_components/PageNavigator.hpp b/src/shared_gui_components/PageNavigator.hpp index 307030683..a40800183 100644 --- a/src/shared_gui_components/PageNavigator.hpp +++ b/src/shared_gui_components/PageNavigator.hpp @@ -44,7 +44,7 @@ class PageNavigator : public QWidget Q_OBJECT public: - PageNavigator(int numPages, int numPagesListed = 5, QWidget* parent = nullptr); + explicit PageNavigator(int numPages, int numPagesListed = 5, QWidget* parent = nullptr); virtual ~PageNavigator(); void setNumPages(int numPages); void setNumPagesListed(int numPagesListed = 5); diff --git a/src/shared_gui_components/TIDItemModel.cpp b/src/shared_gui_components/TIDItemModel.cpp index e1803f5ab..6ee0d46fd 100644 --- a/src/shared_gui_components/TIDItemModel.cpp +++ b/src/shared_gui_components/TIDItemModel.cpp @@ -37,7 +37,7 @@ namespace openstudio { class TIDItem { public: - TIDItem(const QDomElement& element, TIDItem* parent = nullptr) { + explicit TIDItem(const QDomElement& element, TIDItem* parent = nullptr) { m_parentItem = parent; QString tagName = element.tagName(); diff --git a/src/shared_gui_components/TIDItemModel.hpp b/src/shared_gui_components/TIDItemModel.hpp index d7f6081ff..d72ee2fad 100644 --- a/src/shared_gui_components/TIDItemModel.hpp +++ b/src/shared_gui_components/TIDItemModel.hpp @@ -43,7 +43,7 @@ class TIDItemModel : public QAbstractItemModel Q_OBJECT public: - TIDItemModel(const QDomDocument& document, QObject* parent = nullptr); + explicit TIDItemModel(const QDomDocument& document, QObject* parent = nullptr); virtual ~TIDItemModel(); diff --git a/src/shared_gui_components/TextEditDialog.hpp b/src/shared_gui_components/TextEditDialog.hpp index e8f859a79..f6d2654f2 100644 --- a/src/shared_gui_components/TextEditDialog.hpp +++ b/src/shared_gui_components/TextEditDialog.hpp @@ -41,7 +41,7 @@ class TextEditDialog : public OSDialog Q_OBJECT public: - TextEditDialog(const QString& windowTitle, const QString& windowMessage = QString(), QWidget* parent = nullptr); + explicit TextEditDialog(const QString& windowTitle, const QString& windowMessage = QString(), QWidget* parent = nullptr); virtual ~TextEditDialog(); diff --git a/src/shared_gui_components/WorkflowController.hpp b/src/shared_gui_components/WorkflowController.hpp index 1dd5eebae..7f7662199 100644 --- a/src/shared_gui_components/WorkflowController.hpp +++ b/src/shared_gui_components/WorkflowController.hpp @@ -68,7 +68,7 @@ class WorkflowController : public OSListController Q_OBJECT public: - WorkflowController(BaseApp* t_baseApp); + explicit WorkflowController(BaseApp* t_baseApp); QSharedPointer itemAt(int i) override; @@ -121,7 +121,7 @@ class WorkflowStepController : public OSListController Q_OBJECT public: - WorkflowStepController(BaseApp* t_baseApp); + explicit WorkflowStepController(BaseApp* t_baseApp); }; // MeasureStepController controls a list of MeasureStepItems diff --git a/src/shared_gui_components/WorkflowView.hpp b/src/shared_gui_components/WorkflowView.hpp index a924517fd..1a62d3de7 100644 --- a/src/shared_gui_components/WorkflowView.hpp +++ b/src/shared_gui_components/WorkflowView.hpp @@ -99,7 +99,7 @@ class WorkflowSectionView : public OSCollapsibleView Q_OBJECT public: - WorkflowSectionView(MeasureType measureType); + explicit WorkflowSectionView(MeasureType measureType); virtual ~WorkflowSectionView() {}