diff options
| author | Paul Buetow <paul@buetow.org> | 2008-05-21 01:54:06 +0000 |
|---|---|---|
| committer | Paul Buetow <paul@buetow.org> | 2008-05-21 01:54:06 +0000 |
| commit | 6059b54e23e742db068da5e4a53b8b1b046db121 (patch) | |
| tree | 72e51fefd35efe5d013d16b4ac26240d7216660f /sources/simulator | |
| parent | 8d5c21477617e4d08bd098069c7628830675abb7 (diff) | |
Introduced a new VSEditorFrame.
No more need for the VSProtcolEditor!
Diffstat (limited to 'sources/simulator')
| -rw-r--r-- | sources/simulator/VSMain.java | 2 | ||||
| -rw-r--r-- | sources/simulator/VSSimulation.java | 11 | ||||
| -rw-r--r-- | sources/simulator/VSSimulationCanvas.java | 3 | ||||
| -rw-r--r-- | sources/simulator/VSSimulatorFrame.java | 3 |
4 files changed, 8 insertions, 11 deletions
diff --git a/sources/simulator/VSMain.java b/sources/simulator/VSMain.java index 53560f4..926f450 100644 --- a/sources/simulator/VSMain.java +++ b/sources/simulator/VSMain.java @@ -19,7 +19,7 @@ public class VSMain { private void init(VSPrefs prefs, Component relativeTo) { VSSimulatorFrame simulatorFrame = new VSSimulatorFrame(prefs, relativeTo); - new VSSimulationEditor(prefs, simulatorFrame); + new VSEditorFrame(prefs, relativeTo, new VSSimulationEditor(prefs, simulatorFrame)); } public static void main(String[] args) { diff --git a/sources/simulator/VSSimulation.java b/sources/simulator/VSSimulation.java index cf1e677..bd19ff0 100644 --- a/sources/simulator/VSSimulation.java +++ b/sources/simulator/VSSimulation.java @@ -307,13 +307,6 @@ public class VSSimulation extends JPanel { splitPane1.setOneTouchExpandable(true); tabbedPane.addTab(prefs.getString("lang.events"), splitPane1); - //JSplitPane splitPane2 = new JSplitPane(); - //splitPane2.setOrientation(JSplitPane.VERTICAL_SPLIT); - //splitPane2.setTopComponent(processesComboBox); - //splitPane2.setBottomComponent(tabbedPane); - editPanel.add(processesComboBox); - editPanel.add(tabbedPane); - processesComboBox.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent ae) { localTextFields.set(lastSelectedProcessNum, localTextField.getText()); @@ -352,7 +345,9 @@ public class VSSimulation extends JPanel { globalVariablesPanel = new JPanel(); tabbedPane.add(prefs.getString("lang.variables"), variablesPanel); tabbedPane.add(prefs.getString("lang.variables.global"), globalVariablesPanel); - //tabbedPane.add(prefs.getString("lang.variables.global"), new JTextArea(0, 0)); + + editPanel.add(processesComboBox); + editPanel.add(tabbedPane); return editPanel; } diff --git a/sources/simulator/VSSimulationCanvas.java b/sources/simulator/VSSimulationCanvas.java index 37f5f51..3fb6add 100644 --- a/sources/simulator/VSSimulationCanvas.java +++ b/sources/simulator/VSSimulationCanvas.java @@ -740,7 +740,8 @@ public class VSSimulationCanvas extends Canvas implements Runnable, MouseMotionL public void editProcess(VSProcess process) { if (process != null) { process.updatePrefs(); - new VSProcessEditor(prefs, simulation.getSimulatorFrame(), process); + new VSEditorFrame(prefs, simulation.getSimulatorFrame(), + new VSProcessEditor(prefs, process)); } } diff --git a/sources/simulator/VSSimulatorFrame.java b/sources/simulator/VSSimulatorFrame.java index e27f896..37c0900 100644 --- a/sources/simulator/VSSimulatorFrame.java +++ b/sources/simulator/VSSimulatorFrame.java @@ -203,7 +203,8 @@ public class VSSimulatorFrame extends VSFrame implements ActionListener { removeCurrentSimulation(); } else if (source.getText().equals(prefs.getString("lang.simulation.new"))) { - new VSSimulationEditor(VSDefaultPrefs.init(), this); + VSPrefs newPrefs = VSDefaultPrefs.init(); + new VSEditorFrame(newPrefs, this, new VSSimulationEditor(newPrefs, this)); } else if (source.getText().equals(prefs.getString("lang.window.new"))) { new VSMain(VSDefaultPrefs.init(), this); |
