src/corelib/animation/qabstractanimation.h
changeset 3 41300fa6a67c
parent 0 1918ee327afb
child 4 3b1da2848fc7
--- a/src/corelib/animation/qabstractanimation.h	Tue Jan 26 12:42:25 2010 +0200
+++ b/src/corelib/animation/qabstractanimation.h	Tue Feb 02 00:43:10 2010 +0200
@@ -59,6 +59,8 @@
 class Q_CORE_EXPORT QAbstractAnimation : public QObject
 {
     Q_OBJECT
+    Q_ENUMS(State)
+    Q_ENUMS(Direction)
     Q_PROPERTY(State state READ state NOTIFY stateChanged)
     Q_PROPERTY(int loopCount READ loopCount WRITE setLoopCount)
     Q_PROPERTY(int currentTime READ currentTime WRITE setCurrentTime)
@@ -93,6 +95,9 @@
     Direction direction() const;
     void setDirection(Direction direction);
 
+    int currentTime() const;
+    int currentLoopTime() const;
+
     int loopCount() const;
     void setLoopCount(int loopCount);
     int currentLoop() const;
@@ -100,11 +105,9 @@
     virtual int duration() const = 0;
     int totalDuration() const;
 
-    int currentTime() const;
-
 Q_SIGNALS:
     void finished();
-    void stateChanged(QAbstractAnimation::State oldState, QAbstractAnimation::State newState);
+    void stateChanged(QAbstractAnimation::State newState, QAbstractAnimation::State oldState);
     void currentLoopChanged(int currentLoop);
     void directionChanged(QAbstractAnimation::Direction);
 
@@ -112,6 +115,7 @@
     void start(QAbstractAnimation::DeletionPolicy policy = KeepWhenStopped);
     void pause();
     void resume();
+    void setPaused(bool);
     void stop();
     void setCurrentTime(int msecs);
 
@@ -120,7 +124,7 @@
     bool event(QEvent *event);
 
     virtual void updateCurrentTime(int currentTime) = 0;
-    virtual void updateState(QAbstractAnimation::State oldState, QAbstractAnimation::State newState);
+    virtual void updateState(QAbstractAnimation::State newState, QAbstractAnimation::State oldState);
     virtual void updateDirection(QAbstractAnimation::Direction direction);
 
 private: