From 64085c8de3d061f22d5213f8f5a99b82c3e480f8 Mon Sep 17 00:00:00 2001 From: iobyte Date: Mon, 19 Feb 2024 19:56:14 +0000 Subject: [PATCH] trackeditor: show selected properties tab git-svn-id: https://svn.code.sf.net/p/speed-dreams/code/trunk@9328 30fe4595-0a0c-4342-8851-515496e4dcbd --- .../trackeditor/gui/properties/PropertiesDialog.java | 9 ++++++++- src/tools/trackeditor/utils/Properties.java | 2 +- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/src/tools/trackeditor/gui/properties/PropertiesDialog.java b/src/tools/trackeditor/gui/properties/PropertiesDialog.java index 2f729f77a..1c0ad6fdf 100644 --- a/src/tools/trackeditor/gui/properties/PropertiesDialog.java +++ b/src/tools/trackeditor/gui/properties/PropertiesDialog.java @@ -29,6 +29,7 @@ import javax.swing.JButton; import javax.swing.JDialog; import javax.swing.JPanel; import javax.swing.JTabbedPane; +import javax.swing.SwingUtilities; import gui.EditorFrame; import utils.Editor; @@ -116,7 +117,13 @@ public class PropertiesDialog extends JDialog tabbedPane.addTab("Lights", null, getTrackLightProperties(), null); tabbedPane.addTab("Sectors", null, getSectorProperties(), null); tabbedPane.addTab("Image", null, getImageProperties(), null); - tabbedPane.setSelectedIndex(editorFrame.getProject().getPropertiesEditorTab()); + SwingUtilities.invokeLater( new Runnable() + { + public void run() + { + tabbedPane.setSelectedIndex(editorFrame.getProject().getPropertiesEditorTab()); + } + }); } return tabbedPane; } diff --git a/src/tools/trackeditor/utils/Properties.java b/src/tools/trackeditor/utils/Properties.java index 36624cdd3..d4b40cc7c 100644 --- a/src/tools/trackeditor/utils/Properties.java +++ b/src/tools/trackeditor/utils/Properties.java @@ -34,7 +34,7 @@ public class Properties private static Properties instance = new Properties(); private Vector propertiesListeners = new Vector(); public final String title = "sd2-trackeditor"; - public final String version = "1.4.47"; + public final String version = "1.4.48"; private String path; private double imageScale = 1;