Quellcode durchsuchen

Merge pull request #33575 from KoBeWi/zoomset

Properly handle zoom when opening tileset editor
Rémi Verschelde vor 5 Jahren
Ursprung
Commit
da4079f231
1 geänderte Dateien mit 2 neuen und 2 gelöschten Zeilen
  1. 2 2
      editor/plugins/tile_set_editor_plugin.cpp

+ 2 - 2
editor/plugins/tile_set_editor_plugin.cpp

@@ -3235,8 +3235,8 @@ void TileSetEditor::update_workspace_minsize() {
 	delete tiles;
 
 	workspace->set_custom_minimum_size(workspace_min_size + WORKSPACE_MARGIN * 2);
-	workspace_container->set_custom_minimum_size(workspace_min_size + WORKSPACE_MARGIN * 2);
-	workspace_overlay->set_custom_minimum_size(workspace_min_size + WORKSPACE_MARGIN * 2);
+	workspace_container->set_custom_minimum_size(workspace_min_size * workspace->get_scale() + WORKSPACE_MARGIN * 2);
+	workspace_overlay->set_custom_minimum_size(workspace_min_size * workspace->get_scale() + WORKSPACE_MARGIN * 2);
 }
 
 void TileSetEditor::update_edited_region(const Vector2 &end_point) {