2 * this file is part of evince, a gnome document viewer
4 * Copyright (C) 2007 Carlos Garnacho <carlos@imendio.com>
6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Library General Public
8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version.
11 * This library is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Library General Public License for more details.
16 * You should have received a copy of the GNU Library General Public
17 * License along with this library; if not, write to the
18 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
19 * Boston, MA 02111-1307, USA.
22 #ifndef __EV_TIMELINE_H__
23 #define __EV_TIMELINE_H__
25 #include <glib-object.h>
29 #define EV_TYPE_TIMELINE (ev_timeline_get_type ())
30 #define EV_TIMELINE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), EV_TYPE_TIMELINE, EvTimeline))
31 #define EV_TIMELINE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), EV_TYPE_TIMELINE, EvTimelineClass))
32 #define EV_IS_TIMELINE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), EV_TYPE_TIMELINE))
33 #define EV_IS_TIMELINE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), EV_TYPE_TIMELINE))
34 #define EV_TIMELINE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), EV_TYPE_TIMELINE, EvTimelineClass))
36 typedef struct EvTimeline EvTimeline;
37 typedef struct EvTimelineClass EvTimelineClass;
40 GObject parent_instance;
43 struct EvTimelineClass {
44 GObjectClass parent_class;
47 void (* start) (EvTimeline *timeline);
50 void (* started) (EvTimeline *timeline);
51 void (* finished) (EvTimeline *timeline);
52 void (* paused) (EvTimeline *timeline);
54 void (* frame) (EvTimeline *timeline,
59 GType ev_timeline_get_type (void) G_GNUC_CONST;
61 EvTimeline *ev_timeline_new (guint duration);
63 void ev_timeline_start (EvTimeline *timeline);
64 void ev_timeline_pause (EvTimeline *timeline);
65 void ev_timeline_rewind (EvTimeline *timeline);
67 gboolean ev_timeline_is_running (EvTimeline *timeline);
69 guint ev_timeline_get_fps (EvTimeline *timeline);
70 void ev_timeline_set_fps (EvTimeline *timeline,
73 gboolean ev_timeline_get_loop (EvTimeline *timeline);
74 void ev_timeline_set_loop (EvTimeline *timeline,
77 guint ev_timeline_get_duration (EvTimeline *timeline);
78 void ev_timeline_set_duration (EvTimeline *timeline,
81 gdouble ev_timeline_get_progress (EvTimeline *timeline);
86 #endif /* __EV_TIMELINE_H__ */