comparison orpg/mapper/map_prop_dialog.py @ 19:78407d627cba traipse_dev

Beginning of Code Clean-up. Some code untested, may break!
author sirebral
date Sat, 25 Jul 2009 17:24:40 -0500
parents 4385a7d0efd1
children 072ffc1d466f
comparison
equal deleted inserted replaced
18:67b900deb35c 19:78407d627cba
209 def on_ok(self,evt): 209 def on_ok(self,evt):
210 try: 210 try:
211 self.size = (int(self.ctrls[CTRL_WIDTH].GetValue()),int(self.ctrls[CTRL_HEIGHT].GetValue())) 211 self.size = (int(self.ctrls[CTRL_WIDTH].GetValue()),int(self.ctrls[CTRL_HEIGHT].GetValue()))
212 except: 212 except:
213 pass 213 pass
214 # dlg = wx.MessageDialog(frame, 'Invalid Size',"Error") 214 #dlg = wx.MessageDialog(frame, 'Invalid Size',"Error")
215 # dlg.ShowModal() 215 #dlg.ShowModal()
216 # dlg.Destroy() 216 #dlg.Destroy()
217 if self.ctrls[CTRL_BG_COLOR].GetValue() == True: 217 if self.ctrls[CTRL_BG_COLOR].GetValue() == True:
218 self.bg_layer.set_color(self.ctrls[CTRL_BG_COLOR_VALUE].GetBackgroundColour()) 218 self.bg_layer.set_color(self.ctrls[CTRL_BG_COLOR_VALUE].GetBackgroundColour())
219 elif self.ctrls[CTRL_TEXTURE].GetValue() == True: 219 elif self.ctrls[CTRL_TEXTURE].GetValue() == True:
220 self.bg_layer.set_texture(self.ctrls[CTRL_TEXTURE_PATH].GetValue()) 220 self.bg_layer.set_texture(self.ctrls[CTRL_TEXTURE_PATH].GetValue())
221 elif self.ctrls[CTRL_IMAGE].GetValue() == True: 221 elif self.ctrls[CTRL_IMAGE].GetValue() == True: