~freecad-community/freecad-extras/assembly2

« back to all changes in this revision

Viewing changes to degreesOfFreedomAnimation.py

  • Committer: looooo
  • Date: 2017-04-29 20:45:27 UTC
  • mto: This revision was merged to the branch mainline in revision 182.
  • Revision ID: git-v1:b1dec62143dc055898bad6a73fb53e87cb9f68e2
py3: exceptions + dict.has_key
except Error msg: --> except Error as msg:
dict.has_key(value) --> value in dict

Show diffs side-by-side

added added

removed removed

Lines of Context:
79
79
         self._startAnimation( [d for d in self.constraintSystem.degreesOfFreedom] )
80
80
 
81
81
    def reject(self): #or more correctly close, given the button settings
82
 
        if  moduleVars.has_key('animation'):
 
82
        if  'animation' in moduleVars:
83
83
            moduleVars['animation'].timer.stop()
84
84
            self.constraintSystem.variableManager.updateFreeCADValues(moduleVars['animation'].X_before_animation)
85
85
            del moduleVars['animation']