[hamster-applet] removeTweener seemed to have been forgotten in the way
- From: Toms Baugis <tbaugis src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [hamster-applet] removeTweener seemed to have been forgotten in the way
- Date: Sat, 14 Nov 2009 21:36:54 +0000 (UTC)
commit 538325e0ea61eef9bc46416ea4976d75b9170c57
Author: Toms Bauģis <toms baugis gmail com>
Date: Sat Nov 14 21:34:06 2009 +0000
removeTweener seemed to have been forgotten in the way
hamster/pytweener.py | 10 +++++-----
1 files changed, 5 insertions(+), 5 deletions(-)
---
diff --git a/hamster/pytweener.py b/hamster/pytweener.py
index 7cfafb7..6232207 100644
--- a/hamster/pytweener.py
+++ b/hamster/pytweener.py
@@ -9,7 +9,7 @@
import math
class Tweener:
- def __init__(self, duration = None, tween = None):
+ def __init__(self, duration = 0.5, tween = None):
"""Tweener
This class manages all active tweens, and provides a factory for
creating and spawning tween motions."""
@@ -69,12 +69,12 @@ class Tweener:
self.currentTweens.append( tw )
return tw
- def removeTween( tweenObj ):
- if self.currentTweens.contains( tweenObj ):
+ def removeTween(self, tweenObj):
+ if tweenObj in self.currentTweens:
tweenObj.complete = True
#self.currentTweens.remove( tweenObj )
- def getTweensAffectingObject( self, obj ):
+ def getTweensAffectingObject(self, obj):
"""Get a list of all tweens acting on the specified object
Useful for manipulating tweens on the fly"""
tweens = []
@@ -83,7 +83,7 @@ class Tweener:
tweens.append(t)
return tweens
- def removeTweeningFrom( self, obj ):
+ def removeTweeningFrom(self, obj):
"""Stop tweening an object, without completing the motion
or firing the completeFunction"""
for t in self.currentTweens:
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]