Skip to content

Commit 98206c4

Browse files
committed
Sprite: Update costume before calling the interface in setSize()
1 parent 2f7619f commit 98206c4

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/scratch/sprite.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -216,13 +216,13 @@ void Sprite::setSize(double newSize)
216216
eng->requestRedraw();
217217
}
218218

219-
if (impl->iface)
220-
impl->iface->onSizeChanged(impl->size);
221-
222219
auto costume = currentCostume();
223220

224221
if (costume)
225222
costume->setScale(newSize / 100);
223+
224+
if (impl->iface)
225+
impl->iface->onSizeChanged(impl->size);
226226
}
227227

228228
/*! Overrides Target#setCostumeIndex(). */

0 commit comments

Comments
 (0)