Made undo tool aware of circle count to decrement. Refactored tool ID's to be enum
This commit is contained in:
committed by
borgmanJeremy
parent
ed4ea1377b
commit
6afa3ca26a
@@ -40,10 +40,10 @@ RectangleTool::name() const
|
||||
return tr("Rectangle");
|
||||
}
|
||||
|
||||
QString
|
||||
RectangleTool::nameID()
|
||||
ToolType
|
||||
RectangleTool::nameID() const
|
||||
{
|
||||
return QLatin1String("");
|
||||
return ToolType::RECTANGLE;
|
||||
}
|
||||
|
||||
QString
|
||||
|
||||
@@ -27,7 +27,6 @@ public:
|
||||
|
||||
QIcon icon(const QColor& background, bool inEditor) const override;
|
||||
QString name() const override;
|
||||
static QString nameID();
|
||||
QString description() const override;
|
||||
|
||||
CaptureTool* copy(QObject* parent = nullptr) override;
|
||||
@@ -37,6 +36,9 @@ public:
|
||||
void paintMousePreview(QPainter& painter,
|
||||
const CaptureContext& context) override;
|
||||
|
||||
protected:
|
||||
ToolType nameID() const override;
|
||||
|
||||
public slots:
|
||||
void drawStart(const CaptureContext& context) override;
|
||||
void pressed(const CaptureContext& context) override;
|
||||
|
||||
Reference in New Issue
Block a user