forked from qt-creator/qt-creator
ModelEditor: Use more explicit constructors
Change-Id: I67880be3f463ae8fb6bf3243114f90bd9bb78104 Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
This commit is contained in:
@@ -72,7 +72,7 @@ namespace qmt {
|
||||
class DiagramSceneModel::OriginItem : public QGraphicsItem
|
||||
{
|
||||
public:
|
||||
OriginItem(QGraphicsItem *parent = 0)
|
||||
explicit OriginItem(QGraphicsItem *parent = 0)
|
||||
: QGraphicsItem(parent)
|
||||
{
|
||||
}
|
||||
|
@@ -58,7 +58,7 @@ static const qreal CONTENTS_BORDER_HORIZONTAL = 4.0;
|
||||
class AnnotationItem::AnnotationTextItem : public QGraphicsTextItem
|
||||
{
|
||||
public:
|
||||
AnnotationTextItem(QGraphicsItem *parent)
|
||||
explicit AnnotationTextItem(QGraphicsItem *parent)
|
||||
: QGraphicsTextItem(parent)
|
||||
{
|
||||
}
|
||||
|
@@ -60,7 +60,7 @@ static const qreal CONTENTS_BORDER_HORIZONTAL = 4.0;
|
||||
class BoundaryItem::BoundaryTextItem : public QGraphicsTextItem
|
||||
{
|
||||
public:
|
||||
BoundaryTextItem(QGraphicsItem *parent)
|
||||
explicit BoundaryTextItem(QGraphicsItem *parent)
|
||||
: QGraphicsTextItem(parent)
|
||||
{
|
||||
}
|
||||
|
@@ -48,7 +48,7 @@ namespace qmt {
|
||||
class ArrowItem::GraphicsPathItem : public QGraphicsPathItem
|
||||
{
|
||||
public:
|
||||
GraphicsPathItem(QGraphicsItem *parent)
|
||||
explicit GraphicsPathItem(QGraphicsItem *parent)
|
||||
: QGraphicsPathItem(parent)
|
||||
{
|
||||
}
|
||||
@@ -65,7 +65,7 @@ public:
|
||||
class ArrowItem::GraphicsHeadItem : public QGraphicsItem
|
||||
{
|
||||
public:
|
||||
GraphicsHeadItem(QGraphicsItem *parent)
|
||||
explicit GraphicsHeadItem(QGraphicsItem *parent)
|
||||
: QGraphicsItem(parent)
|
||||
{
|
||||
}
|
||||
@@ -250,7 +250,7 @@ private:
|
||||
class ArrowItem::GraphicsShaftItem : public ArrowItem::GraphicsPathItem
|
||||
{
|
||||
public:
|
||||
GraphicsShaftItem(QGraphicsItem *parent)
|
||||
explicit GraphicsShaftItem(QGraphicsItem *parent)
|
||||
: GraphicsPathItem(parent)
|
||||
{
|
||||
}
|
||||
|
@@ -74,7 +74,7 @@ private:
|
||||
class TreeModel::ItemFactory : public MConstVisitor
|
||||
{
|
||||
public:
|
||||
ItemFactory(TreeModel *treeModel)
|
||||
explicit ItemFactory(TreeModel *treeModel)
|
||||
: m_treeModel(treeModel)
|
||||
{
|
||||
QMT_CHECK(m_treeModel);
|
||||
|
@@ -52,9 +52,7 @@ namespace qmt {
|
||||
class IconShape::IconShapePrivate
|
||||
{
|
||||
public:
|
||||
IconShapePrivate()
|
||||
{
|
||||
}
|
||||
IconShapePrivate() = default;
|
||||
|
||||
IconShapePrivate(const IconShapePrivate &rhs)
|
||||
: m_shapes(CloneAll(rhs.m_shapes))
|
||||
|
@@ -41,7 +41,7 @@ namespace qmt {
|
||||
class StyleController::Parameters : public StyleEngine::Parameters
|
||||
{
|
||||
public:
|
||||
Parameters(StyleController *styleController)
|
||||
explicit Parameters(StyleController *styleController)
|
||||
: m_styleController(styleController)
|
||||
{
|
||||
}
|
||||
|
Reference in New Issue
Block a user