Fix timing of onMapResized
This commit is contained in:
parent
94b2c98308
commit
704b5894d1
1 changed files with 3 additions and 3 deletions
|
@ -312,13 +312,13 @@ void Map::setDimensions(int newWidth, int newHeight, bool setNewBlockdata) {
|
|||
|
||||
int oldWidth = layout->width.toInt();
|
||||
int oldHeight = layout->height.toInt();
|
||||
layout->width = QString::number(newWidth);
|
||||
layout->height = QString::number(newHeight);
|
||||
|
||||
if (oldWidth != newWidth || oldHeight != newHeight) {
|
||||
Scripting::cb_MapResized(oldWidth, oldHeight, newWidth, newHeight);
|
||||
}
|
||||
|
||||
layout->width = QString::number(newWidth);
|
||||
layout->height = QString::number(newHeight);
|
||||
|
||||
emit mapChanged(this);
|
||||
emit mapDimensionsChanged(QSize(getWidth(), getHeight()));
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue