Переглянути джерело

Merge pull request #82442 from YuriSizov/theme-editor-release-me-from-this-nightmare-where-i-try-to-escape-the-editor-but-it-doesnt-let-me-go-and-i-keep-running-and-running-and-eventually-a-little-leak-comes-out

Fix leak when closing theme editor preview tabs
Yuri Sizov 1 рік тому
батько
коміт
46e48c5a3d
1 змінених файлів з 2 додано та 0 видалено
  1. 2 0
      editor/plugins/theme_editor_plugin.cpp

+ 2 - 0
editor/plugins/theme_editor_plugin.cpp

@@ -3583,6 +3583,8 @@ void ThemeEditor::_remove_preview_tab(int p_tab) {
 		}
 
 		preview_tabs_content->remove_child(preview_tab);
+		preview_tab->queue_free();
+
 		preview_tabs->remove_tab(p_tab);
 		_change_preview_tab(preview_tabs->get_current_tab());
 	}