diff options
| author | Paul Buetow <paul@buetow.org> | 2008-05-18 19:29:30 +0000 |
|---|---|---|
| committer | Paul Buetow <paul@buetow.org> | 2008-05-18 19:29:30 +0000 |
| commit | 2d45de18df35f6d3ba4ca0b86ec1188e49637413 (patch) | |
| tree | 6c84c8cd14a89a6dabeada811c6477d1e5459767 /sources/prefs/editors/VSProtocolEditor.java | |
| parent | c46ed2242876bfb267ed0b6823c8a3e99ac62dd6 (diff) | |
The TaskManager works partly.
Diffstat (limited to 'sources/prefs/editors/VSProtocolEditor.java')
| -rw-r--r-- | sources/prefs/editors/VSProtocolEditor.java | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/sources/prefs/editors/VSProtocolEditor.java b/sources/prefs/editors/VSProtocolEditor.java index 1cf5059..d0762a3 100644 --- a/sources/prefs/editors/VSProtocolEditor.java +++ b/sources/prefs/editors/VSProtocolEditor.java @@ -27,7 +27,7 @@ public class VSProtocolEditor extends VSEditorFrame { public VSProtocolEditor(VSPrefs prefs, Component relativeTo, VSProtocol protocol) { super(prefs, relativeTo, protocol, prefs.getString("name") + " - " - + protocol.getProtocolName() + " " + prefs.getString("lang.editor"), ALL_PREFERENCES); + + protocol.getName() + " " + prefs.getString("lang.editor"), ALL_PREFERENCES); this.protocol = protocol; this.taskManager = protocol.getProcess().getSimulationPanel().getTaskManager(); @@ -130,12 +130,12 @@ public class VSProtocolEditor extends VSEditorFrame { } private void initClientServerCheckboxes() { - final String protocolName = protocol.getProtocolName(); + final String eventName = protocol.getName(); final VSProcess process = protocol.getProcess(); - String protocolKey = "sim."+protocolName.toLowerCase()+".client.enabled!"; + String protocolKey = "sim."+eventName.toLowerCase()+".client.enabled!"; clientCheckBox.setSelected(process.getBoolean(protocolKey)); - protocolKey = "sim."+protocolName.toLowerCase()+".server.enabled!"; + protocolKey = "sim."+eventName.toLowerCase()+".server.enabled!"; serverCheckBox.setSelected(process.getBoolean(protocolKey)); } @@ -235,10 +235,10 @@ public class VSProtocolEditor extends VSEditorFrame { resetTaskManager(); final VSProcess process = protocol.getProcess(); - final String protocolName = protocol.getProtocolName(); - String protocolKey = "sim."+protocolName.toLowerCase()+".client.enabled!"; + final String eventName = protocol.getName(); + String protocolKey = "sim."+eventName.toLowerCase()+".client.enabled!"; clientCheckBox.setSelected(process.getBoolean(protocolKey)); - protocolKey = "sim."+protocolName.toLowerCase()+".server.enabled!"; + protocolKey = "sim."+eventName.toLowerCase()+".server.enabled!"; serverCheckBox.setSelected(process.getBoolean(protocolKey)); takeOverButton.setEnabled(clientCheckBox.isSelected()); @@ -269,7 +269,7 @@ public class VSProtocolEditor extends VSEditorFrame { numItems = clientComboBox.getItemCount(); for (int i = 0; i < numItems; ++i) { long taskTime = VSTools.getStringTime((String) clientComboBox.getItemAt(i)); - VSTask task = new VSTask(taskTime, protocol.getProcess(), protocol); + VSTask task = new VSTask(taskTime, protocol.getProcess(), protocol, VSTask.LOCAL); task.isProgrammed(true); tasks.addLast(task); } @@ -277,12 +277,12 @@ public class VSProtocolEditor extends VSEditorFrame { taskManager.modifyProtocolTasks(protocol, tasks); final VSProcess process = protocol.getProcess(); - final String protocolName = protocol.getProtocolName(); - String protocolKey = "sim."+protocolName.toLowerCase()+".client.enabled!"; + final String eventName = protocol.getName(); + String protocolKey = "sim."+eventName.toLowerCase()+".client.enabled!"; process.setBoolean(protocolKey, clientCheckBox.isSelected()); protocol.isClient(clientCheckBox.isSelected()); - protocolKey = "sim."+protocolName.toLowerCase()+".server.enabled!"; + protocolKey = "sim."+eventName.toLowerCase()+".server.enabled!"; process.setBoolean(protocolKey, serverCheckBox.isSelected()); protocol.isServer(serverCheckBox.isSelected()); |
