animation.h
Go to the documentation of this file.00001
00002
00003 #ifndef _CLUTTERMM_ANIMATION_H
00004 #define _CLUTTERMM_ANIMATION_H
00005
00006
00007 #include <glibmm.h>
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026 #include <glibmm/object.h>
00027 #include <cluttermm/alpha.h>
00028 #include <cluttermm/actor.h>
00029 #include <cluttermm/interval.h>
00030 #include <cluttermm/timeline.h>
00031 #include <clutter/clutter.h>
00032
00033
00034 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00035 typedef struct _ClutterAnimation ClutterAnimation;
00036 typedef struct _ClutterAnimationClass ClutterAnimationClass;
00037 #endif
00038
00039
00040 namespace Clutter
00041 { class Animation_Class; }
00042 namespace Clutter
00043 {
00044
00045
00046 class Animation : public Glib::Object
00047 {
00048
00049
00050 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00051
00052 public:
00053 typedef Animation CppObjectType;
00054 typedef Animation_Class CppClassType;
00055 typedef ClutterAnimation BaseObjectType;
00056 typedef ClutterAnimationClass BaseClassType;
00057
00058 private: friend class Animation_Class;
00059 static CppClassType animation_class_;
00060
00061 private:
00062
00063 Animation(const Animation&);
00064 Animation& operator=(const Animation&);
00065
00066 protected:
00067 explicit Animation(const Glib::ConstructParams& construct_params);
00068 explicit Animation(ClutterAnimation* castitem);
00069
00070 #endif
00071
00072 public:
00073 virtual ~Animation();
00074
00075 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00076 static GType get_type() G_GNUC_CONST;
00077 static GType get_base_type() G_GNUC_CONST;
00078 #endif
00079
00081 ClutterAnimation* gobj() { return reinterpret_cast<ClutterAnimation*>(gobject_); }
00082
00084 const ClutterAnimation* gobj() const { return reinterpret_cast<ClutterAnimation*>(gobject_); }
00085
00087 ClutterAnimation* gobj_copy();
00088
00089 private:
00090
00091
00092 protected:
00093 Animation();
00094
00095 public:
00096
00097 static Glib::RefPtr<Animation> create();
00098
00099
00106 void set_object(const Glib::RefPtr<Glib::Object>& object);
00107
00113 Glib::RefPtr<Glib::Object> get_object();
00114
00120 Glib::RefPtr<const Glib::Object> get_object() const;
00121
00131 void set_mode(gulong mode);
00132
00139 gulong get_mode() const;
00140
00149 void set_duration(int msecs);
00150
00156 guint get_duration() const;
00157
00169 void set_loop(bool loop=true);
00170
00176 bool get_loop() const;
00177
00184 void set_timeline(const Glib::RefPtr<Timeline>& timeline);
00185
00191 Glib::RefPtr<Timeline> get_timeline() const;
00192
00201 void set_alpha(const Glib::RefPtr<Alpha>& alpha);
00202
00208 Glib::RefPtr<Alpha> get_alpha() const;
00209
00221 void completed();
00222
00234 Glib::RefPtr<Animation> bind(const std::string& property_name, const Glib::ValueBase& final);
00235
00248 void bind_interval(const std::string& property_name, const Glib::RefPtr<Interval>& interval);
00249
00257 void update_interval(const std::string& property_name, const Glib::RefPtr<Interval>& interval);
00258
00266 bool has_property(const std::string& property_name) const;
00267
00273 void unbind_property(const std::string& property_name);
00274
00284 Glib::RefPtr<Interval> get_interval(const std::string& property_name) const;
00285
00286
00292 Glib::SignalProxy0< void > signal_started();
00293
00294
00300 Glib::SignalProxy0< void > signal_completed();
00301
00302
00303 public:
00304
00305 public:
00306
00307 #ifdef GLIBMM_VFUNCS_ENABLED
00308 #endif //GLIBMM_VFUNCS_ENABLED
00309
00310 protected:
00311
00312 #ifdef GLIBMM_VFUNCS_ENABLED
00313 #endif //GLIBMM_VFUNCS_ENABLED
00314
00315
00316 #ifdef GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
00317 virtual void on_started();
00318 virtual void on_completed();
00319 #endif //GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
00320
00321
00322 };
00323
00324 }
00325
00326
00327 namespace Glib
00328 {
00337 Glib::RefPtr<Clutter::Animation> wrap(ClutterAnimation* object, bool take_copy = false);
00338 }
00339
00340
00341 #endif
00342