@@ -98,6 +98,7 @@ def getInput(self):
98
98
99
99
for k ,v in self .inputDict ['Mappings' ].iteritems ():
100
100
#print v
101
+ print "values" ,v
101
102
v ['IntendedTimeSpacing' ] = self .spinTimeSpacing .GetValue ()
102
103
i = self .choiceUnitID .GetSelection ()
103
104
unitID = self .timeUnits [str (self .choiceUnitID .GetString (i ))]
@@ -108,28 +109,6 @@ def getInput(self):
108
109
109
110
return self .inputDict
110
111
111
- """
112
- def setInput(self, data):
113
- # Update the list control only if the new data is different.
114
- if cmp(self.prev_data, data) != 0:
115
- try:
116
- for i in range(0, self.m_listCtrl1.GetNumberCols()):
117
- if str(self.m_listCtrl1.GetColLabelValue(i))\
118
- in self.inputDict['Mappings'].keys():
119
- self.m_listCtrl1.SetColLabelRenderer(\
120
- i,
121
- MyColLabelRenderer('#50c061'))
122
- else:
123
- self.m_listCtrl1.SetColLabelRenderer(\
124
- i,
125
- MyColLabelRenderer(wx.SystemSettings.GetColour(wx.SYS_COLOUR_BACKGROUND)))
126
- self.m_listCtrl1.Refresh()
127
- except KeyError:
128
- pass
129
- # Important to make a deep copy, or else
130
- # data gets changed.
131
- self.prev_data = deepcopy(data)
132
- """
133
112
134
113
def setInput (self , data ):
135
114
"""
@@ -175,6 +154,7 @@ def setInputMappingList(self, existingData, read):
175
154
with any mappings that already exist *and*
176
155
match the variables from the configuration file.
177
156
"""
157
+ # Determine if any mappings exist.
178
158
try :
179
159
existingData ["Mappings" ]
180
160
except KeyError :
@@ -337,7 +317,7 @@ def runSeriesSelectDialog(self):
337
317
dlg = SeriesSelectDialog (self ,
338
318
variable = self .selectedColumn ,
339
319
database = self .parent .db )
340
- dlg .CenterOnParent ()
320
+ # dlg.CenterOnParent()
341
321
if dlg .ShowModal () == wx .ID_OK :
342
322
dlg .selectedResult .variableName = self .selectedColumn
343
323
#print dlg.selectedResult.variableNameCV
@@ -350,16 +330,6 @@ def runSeriesSelectDialog(self):
350
330
'ResultID' :int (dlg .selectedResult .resultID ),
351
331
'LastByteRead' :0 ,
352
332
'CalculateAggInterval' :'false' }})
353
- #if "Mappings" not in self.inputDict.keys():
354
- # self.inputDict.update({'Mappings':{}})
355
-
356
- #if self.selectedColumn not in \
357
- #self.inputDict["Mappings"].keys():
358
- # self.inputDict['Mappings'].update(\
359
- # {str(self.selectedColumn):{\
360
- # 'ResultID':int(dlg.selectedResult.resultID),
361
- # 'LastByteRead':0,
362
- # 'CalculateAggInterval':'false'}})
363
333
364
334
#pprint.pprint(self.inputDict)
365
335
for m in self .m_listCtrl3 .GetObjects ():
0 commit comments