mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-01-26 18:35:20 +00:00
use enum for brushshape at scenetoolshapebrush
This commit is contained in:
parent
bae8636ec0
commit
4f9ec24e41
@ -58,7 +58,7 @@ CSVWidget::ShapeBrushSizeControls::ShapeBrushSizeControls(const QString &title,
|
|||||||
|
|
||||||
CSVWidget::ShapeBrushWindow::ShapeBrushWindow(CSMDoc::Document& document, QWidget *parent)
|
CSVWidget::ShapeBrushWindow::ShapeBrushWindow(CSMDoc::Document& document, QWidget *parent)
|
||||||
: QFrame(parent, Qt::Popup),
|
: QFrame(parent, Qt::Popup),
|
||||||
mBrushShape(0),
|
mBrushShape(BrushShape_Point),
|
||||||
mBrushSize(1),
|
mBrushSize(1),
|
||||||
mDocument(document)
|
mDocument(document)
|
||||||
{
|
{
|
||||||
@ -151,10 +151,10 @@ void CSVWidget::ShapeBrushWindow::setBrushSize(int brushSize)
|
|||||||
|
|
||||||
void CSVWidget::ShapeBrushWindow::setBrushShape()
|
void CSVWidget::ShapeBrushWindow::setBrushShape()
|
||||||
{
|
{
|
||||||
if(mButtonPoint->isChecked()) mBrushShape = 0;
|
if(mButtonPoint->isChecked()) mBrushShape = BrushShape_Point;
|
||||||
if(mButtonSquare->isChecked()) mBrushShape = 1;
|
if(mButtonSquare->isChecked()) mBrushShape = BrushShape_Square;
|
||||||
if(mButtonCircle->isChecked()) mBrushShape = 2;
|
if(mButtonCircle->isChecked()) mBrushShape = BrushShape_Circle;
|
||||||
if(mButtonCustom->isChecked()) mBrushShape = 3;
|
if(mButtonCustom->isChecked()) mBrushShape = BrushShape_Custom;
|
||||||
emit passBrushShape(mBrushShape);
|
emit passBrushShape(mBrushShape);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -53,6 +53,15 @@ namespace CSVWidget
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
|
enum BrushShape
|
||||||
|
{
|
||||||
|
BrushShape_Point = 0,
|
||||||
|
BrushShape_Square = 1,
|
||||||
|
BrushShape_Circle = 2,
|
||||||
|
BrushShape_Custom = 3
|
||||||
|
};
|
||||||
|
|
||||||
ShapeBrushWindow(CSMDoc::Document& document, QWidget *parent = 0);
|
ShapeBrushWindow(CSMDoc::Document& document, QWidget *parent = 0);
|
||||||
void configureButtonInitialSettings(QPushButton *button);
|
void configureButtonInitialSettings(QPushButton *button);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user