mirror of
https://github.com/aseprite/aseprite.git
synced 2025-04-17 08:43:11 +00:00
Restore brush pattern correctly from user preferences
This commit is contained in:
parent
a2d9f3fc76
commit
6f72666330
@ -271,10 +271,17 @@ private:
|
||||
|
||||
class ContextBar::BrushPatternField : public ComboBox {
|
||||
public:
|
||||
BrushPatternField() : m_lock(false) {
|
||||
BrushPatternField() {
|
||||
// We use "m_lock" variable to avoid setting the pattern
|
||||
// brush when we call ComboBox::addItem() (because the first
|
||||
// addItem() generates an onChange() event).
|
||||
m_lock = true;
|
||||
addItem("Pattern aligned to source");
|
||||
addItem("Pattern aligned to destination");
|
||||
addItem("Paint brush");
|
||||
m_lock = false;
|
||||
|
||||
setSelectedItemIndex((int)Preferences::instance().brush.pattern());
|
||||
}
|
||||
|
||||
void setBrushPattern(BrushPattern type) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user