--- a/connectors/SchemeEditor.py Thu Mar 07 21:57:18 2019 +0100
+++ b/connectors/SchemeEditor.py Mon Mar 11 01:03:32 2019 +0100
@@ -5,15 +5,15 @@
from __future__ import absolute_import
-from itertools import repeat, izip_longest
from functools import partial
import wx
from controls.IDBrowser import IDBrowser
+
class SchemeEditor(wx.Panel):
def __init__(self, scheme, parent, *args, **kwargs):
- self.txtctrls = {}
+ self.txtctrls = {}
wx.Panel.__init__(self, parent, *args, **kwargs)
self.fieldsizer = wx.FlexGridSizer(cols=2, hgap=10, vgap=10)
@@ -25,8 +25,9 @@
txtctrl = wx.TextCtrl(parent=self, size=wx.Size(200, -1))
self.txtctrls[tag] = txtctrl
for win, flag in [
- (wx.StaticText(self, label=label), wx.ALIGN_CENTER_VERTICAL),
- (txtctrl, wx.GROW)]:
+ (wx.StaticText(self, label=label),
+ wx.ALIGN_CENTER_VERTICAL),
+ (txtctrl, wx.GROW)]:
self.fieldsizer.AddWindow(win, flag=flag)
self.fieldsizer.AddSpacer(20)
@@ -45,9 +46,8 @@
self.SetSizer(self.fieldsizer)
def SetFields(self, fields):
- for tag, label in self.model:
+ for tag, _label in self.model:
self.txtctrls[tag].SetValue(fields[tag])
def GetFields(self):
- return {tag: self.txtctrls[tag].GetValue() for tag,label in self.model}
-
+ return {tag: self.txtctrls[tag].GetValue() for tag, _label in self.model}