--- a/ConfigTreeNode.py Sun Apr 07 16:23:49 2019 +0200
+++ b/ConfigTreeNode.py Sun Apr 07 21:08:07 2019 +0200
@@ -127,7 +127,7 @@
# TODO match config's fields name and fields contents
return reduce(add, [
CTNChild.CTNSearch(criteria)
- for CTNChild in self.IterChildren()],[])
+ for CTNChild in self.IterChildren()], [])
def GetIconName(self):
return None
--- a/controls/LocationCellEditor.py Sun Apr 07 16:23:49 2019 +0200
+++ b/controls/LocationCellEditor.py Sun Apr 07 21:08:07 2019 +0200
@@ -85,7 +85,7 @@
def GetName(self):
return self.VariableName
-
+
def OnSize(self, event):
self.Layout()
@@ -188,7 +188,7 @@
if message is not None:
wx.CallAfter(self.Table.Parent.ShowErrorMessage, message)
return None
- old_name = self.Table.GetValueByName(row, 'Name')
+ old_name = self.Table.GetValueByName(row, 'Name')
self.Table.SetValueByName(row, 'Name', name)
self.Table.Parent.OnVariableNameChange(old_name, name)
self.Table.SetValueByName(row, 'Location', loc)
@@ -197,7 +197,7 @@
self.Table.SetValueByName(row, 'Type', var_type)
else:
wx.CallAfter(self.Table.Parent.ShowErrorMessage,
- _("Selected location is identical to previous one"))
+ _("Selected location is identical to previous one"))
self.CellControl.Disable()
return changed
--- a/controls/VariablePanel.py Sun Apr 07 16:23:49 2019 +0200
+++ b/controls/VariablePanel.py Sun Apr 07 21:08:07 2019 +0200
@@ -151,7 +151,6 @@
return value
def SetValue(self, row, col, value):
- print("SetValue",row, col, value)
if col < len(self.colnames):
colname = self.GetColLabelValue(col, False)
if colname == "Name":
--- a/editors/Viewer.py Sun Apr 07 16:23:49 2019 +0200
+++ b/editors/Viewer.py Sun Apr 07 21:08:07 2019 +0200
@@ -595,8 +595,8 @@
# Add Divergence Menu items to the given menu
def AddDivergenceMenuItems(self, menu, delete=False):
- add_branch = self.AppendItem(menu, _(u'Add Divergence Branch'),
- self.OnAddBranchMenu)
+ self.AppendItem(menu, _(u'Add Divergence Branch'),
+ self.OnAddBranchMenu)
delete_branch = self.AppendItem(menu, _(u'Delete Divergence Branch'),
self.OnDeleteBranchMenu)
@@ -640,7 +640,7 @@
menu.AppendSeparator()
self.AppendItem(menu, _(u'Comment'),
- self.GetAddMenuCallBack(self.AddNewComment))
+ self.GetAddMenuCallBack(self.AddNewComment))
# Add Default Menu items to the given menu
def AddDefaultMenuItems(self, menu, edit=False, block=False):
@@ -667,8 +667,8 @@
menu.AppendSeparator()
- cut = self.AppendItem(menu, _(u'Cut'), self.GetClipboardCallBack(self.Cut))
- copy = self.AppendItem(menu, _(u'Copy'), self.GetClipboardCallBack(self.Copy))
+ cut = self.AppendItem(menu, _(u'Cut'), self.GetClipboardCallBack(self.Cut))
+ copy = self.AppendItem(menu, _(u'Copy'), self.GetClipboardCallBack(self.Copy))
paste = self.AppendItem(menu, _(u'Paste'), self.GetAddMenuCallBack(self.Paste))
cut.Enable(block)
@@ -1631,13 +1631,13 @@
def PopupVariableMenu(self):
menu = wx.Menu(title='')
variable_type = self.SelectedElement.GetType()
- for type_label, type in [(_("Input"), INPUT),
- (_("Output"), OUTPUT),
- (_("InOut"), INOUT)]:
+ for type_label, vtype in [(_("Input"), INPUT),
+ (_("Output"), OUTPUT),
+ (_("InOut"), INOUT)]:
item = self.AppendItem(menu, type_label,
- self.GetChangeVariableTypeMenuFunction(type),
+ self.GetChangeVariableTypeMenuFunction(vtype),
kind=wx.ITEM_RADIO)
- if type == variable_type:
+ if vtype == variable_type:
item.Check(True)
menu.AppendSeparator()
self.AddDefaultMenuItems(menu, block=True)
@@ -1647,12 +1647,12 @@
def PopupConnectionMenu(self):
menu = wx.Menu(title='')
connection_type = self.SelectedElement.GetType()
- for type_label, type in [(_("Connector"), CONNECTOR),
- (_("Continuation"), CONTINUATION)]:
+ for type_label, ctype in [(_("Connector"), CONNECTOR),
+ (_("Continuation"), CONTINUATION)]:
item = self.AppendItem(menu, type_label,
- self.GetChangeConnectionTypeMenuFunction(type),
+ self.GetChangeConnectionTypeMenuFunction(ctype),
kind=wx.ITEM_RADIO)
- if type == variable_type:
+ if ctype == connection_type:
item.Check(True)
menu.AppendSeparator()
self.AddDefaultMenuItems(menu, block=True)
@@ -2135,8 +2135,8 @@
# Popup contextual menu
menu = wx.Menu()
- for text, callback in items :
- self.AppendItem(menu, text, callback)
+ for text, callback in items:
+ self.AppendItem(menu, text, callback)
self.PopupMenu(menu)
self.SelectedElement.StartConnected.HighlightParentBlock(False)