dmuratshin 9 years ago
parent
commit
c56c1fe0eb
3 changed files with 11 additions and 7 deletions
  1. 10 7
      oxygine/src/Actor.h
  2. 1 0
      oxygine/src/Tween.cpp
  3. 0 0
      oxygine/src/core/system_data.cpp

+ 10 - 7
oxygine/src/Actor.h

@@ -65,14 +65,17 @@ namespace oxygine
         TweenOptions& ease(Tween::EASE ease) { _ease = ease; return *this; }
         TweenOptions& ease(Tween::EASE ease) { _ease = ease; return *this; }
         TweenOptions& detach(bool detach_ = true) { _detach = detach_; return *this; }
         TweenOptions& detach(bool detach_ = true) { _detach = detach_; return *this; }
         TweenOptions& globalEase(Tween::EASE ease) { _globalEase = ease; return *this; }
         TweenOptions& globalEase(Tween::EASE ease) { _globalEase = ease; return *this; }
+        TweenOptions& doneCallback(const EventCallback& cb) { _callback = cb; return *this; }
 
 
-        timeMS  _duration;
-        timeMS  _delay;
-        Tween::EASE _ease;
-        Tween::EASE _globalEase;
-        int     _loops;
-        bool    _twoSides;
-        bool    _detach;
+
+        EventCallback   _callback;
+        timeMS          _duration;
+        timeMS          _delay;
+        Tween::EASE     _ease;
+        Tween::EASE     _globalEase;
+        int             _loops;
+        bool            _twoSides;
+        bool            _detach;
     };
     };
 
 
     class Actor : public EventDispatcher, public intrusive_list_item<spActor>, public Serializable
     class Actor : public EventDispatcher, public intrusive_list_item<spActor>, public Serializable

+ 1 - 0
oxygine/src/Tween.cpp

@@ -50,6 +50,7 @@ namespace oxygine
 		_delay = opt._delay;
 		_delay = opt._delay;
 		_detach = opt._detach;
 		_detach = opt._detach;
 		_globalEase = opt._globalEase;
 		_globalEase = opt._globalEase;
+		_cbDone = opt._callback;
 
 
 		if (_duration <= 0)
 		if (_duration <= 0)
 		{
 		{

File diff suppressed because it is too large
+ 0 - 0
oxygine/src/core/system_data.cpp


Some files were not shown because too many files changed in this diff