--- a/controls/LocationCellEditor.py Tue Mar 26 23:24:30 2013 +0100
+++ b/controls/LocationCellEditor.py Tue Mar 26 23:25:18 2013 +0100
@@ -85,13 +85,36 @@
dialog = BrowseLocationsDialog(self, self.VarType, self.Controller)
if dialog.ShowModal() == wx.ID_OK:
infos = dialog.GetValues()
+ location = infos["location"] - self.Location.SetValue(infos["location"])
+ if not infos["location"].startswith("%"): + dialog = wx.SingleChoiceDialog(self, + _("Select a variable class:"), _("Variable class"), + ["Input", "Output", "Memory"], + wx.DEFAULT_DIALOG_STYLE|wx.OK|wx.CANCEL) + if dialog.ShowModal() == wx.ID_OK: + selected = dialog.GetSelection() + self.Location.SetFocus() + location = "%I" + location + location = "%Q" + location + location = "%M" + location + self.Location.SetValue(location) self.VarType = infos["IEC_type"]
def OnLocationChar(self, event):