Skip to content
Snippets Groups Projects
Commit af604312 authored by Marco Biasini's avatar Marco Biasini
Browse files

make this work with python 2.4

parent ec92a87e
No related merge requests found
......@@ -23,7 +23,7 @@ class SpacenavControl(QtCore.QObject):
if r==0.0:
return 0.0
rr=r/abs(r)*max(0.0,abs(r)-0.9)
return rr/abs(rr)*(math.pow(1.01,abs(rr))-1.0)*40.0/self.speed if abs(rr)>0.0 else 0.0
return abs(rr)>0 and rr/abs(rr)*(math.pow(1.01,abs(rr))-1.0)*40.0/self.speed or 0.0
if(self.trans):
tf.ApplyXAxisTranslation(d(tx))
tf.ApplyYAxisTranslation(d(ty))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment