When scale is empty, default to 1.0 for profile and preview
This commit is contained in:
parent
57cd3cccd3
commit
0a4fa748a8
1 changed files with 6 additions and 1 deletions
|
@ -131,7 +131,12 @@ class previewPanel(wx.Panel):
|
|||
self.OnScale(None)
|
||||
|
||||
def OnScale(self, e):
|
||||
profile.putProfileSetting('model_scale', self.scale.GetValue())
|
||||
scale = 1.0
|
||||
if self.scale.GetValue() != '':
|
||||
scale = float(self.scale.GetValue())
|
||||
if scale <= 0.0:
|
||||
scale = 1.0
|
||||
profile.putProfileSetting('model_scale', scale)
|
||||
self.updateModelTransform()
|
||||
|
||||
def OnScaleMax(self, e):
|
||||
|
|
Loading…
Reference in a new issue