diff options
Diffstat (limited to 'Lib/lib-tk')
| -rw-r--r-- | Lib/lib-tk/Tkinter.py | 2 | ||||
| -rw-r--r-- | Lib/lib-tk/turtle.py | 8 |
2 files changed, 5 insertions, 5 deletions
diff --git a/Lib/lib-tk/Tkinter.py b/Lib/lib-tk/Tkinter.py index 3ec3407..af77544 100644 --- a/Lib/lib-tk/Tkinter.py +++ b/Lib/lib-tk/Tkinter.py @@ -188,7 +188,7 @@ class Variable: else: self._name = 'PY_VAR' + repr(_varnum) _varnum += 1 - if value != None: + if value is not None: self.set(value) elif not self._tk.call("info", "exists", self._name): self.set(self._default) diff --git a/Lib/lib-tk/turtle.py b/Lib/lib-tk/turtle.py index fcde9af..e4cac29 100644 --- a/Lib/lib-tk/turtle.py +++ b/Lib/lib-tk/turtle.py @@ -749,25 +749,25 @@ def setup(**geometry): global _width, _height, _startx, _starty width = geometry.get('width',_width) - if width >= 0 or width == None: + if width >= 0 or width is None: _width = width else: raise ValueError, "width can not be less than 0" height = geometry.get('height',_height) - if height >= 0 or height == None: + if height >= 0 or height is None: _height = height else: raise ValueError, "height can not be less than 0" startx = geometry.get('startx', _startx) - if startx >= 0 or startx == None: + if startx >= 0 or startx is None: _startx = _startx else: raise ValueError, "startx can not be less than 0" starty = geometry.get('starty', _starty) - if starty >= 0 or starty == None: + if starty >= 0 or starty is None: _starty = starty else: raise ValueError, "startx can not be less than 0" |
