Fix minimum connection bounds
This commit is contained in:
parent
15e69dc9e7
commit
fa859a691f
2 changed files with 7 additions and 0 deletions
|
@ -67,6 +67,7 @@ The **"Breaking Changes"** listed below are changes that have been made in the d
|
||||||
- Fix Border Width/Height being set to 0 when creating a new map from an existing layout.
|
- Fix Border Width/Height being set to 0 when creating a new map from an existing layout.
|
||||||
- Fix certain UI elements not highlighting red on some platforms.
|
- Fix certain UI elements not highlighting red on some platforms.
|
||||||
- Fix Open Config Folder not responding
|
- Fix Open Config Folder not responding
|
||||||
|
- Properly update the minimum offset for a connection when the map is changed.
|
||||||
|
|
||||||
## [4.5.0] - 2021-12-26
|
## [4.5.0] - 2021-12-26
|
||||||
### Added
|
### Added
|
||||||
|
|
|
@ -1753,6 +1753,12 @@ void Editor::setConnectionMap(QString mapName) {
|
||||||
setConnectionEditControlsEnabled(true);
|
setConnectionEditControlsEnabled(true);
|
||||||
selected_connection_item->connection->map_name = mapName;
|
selected_connection_item->connection->map_name = mapName;
|
||||||
setCurrentConnectionDirection(selected_connection_item->connection->direction);
|
setCurrentConnectionDirection(selected_connection_item->connection->direction);
|
||||||
|
|
||||||
|
// New map may have a different minimum offset than the last one. The maximum will be the same.
|
||||||
|
int min = selected_connection_item->getMinOffset();
|
||||||
|
ui->spinBox_ConnectionOffset->setMinimum(min);
|
||||||
|
onConnectionOffsetChanged(qMax(min, selected_connection_item->connection->offset));
|
||||||
|
|
||||||
updateMirroredConnectionMap(selected_connection_item->connection, originalMapName);
|
updateMirroredConnectionMap(selected_connection_item->connection, originalMapName);
|
||||||
maskNonVisibleConnectionTiles();
|
maskNonVisibleConnectionTiles();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue