Debian Codegraph @

libgnome-desktop/gnome-bg/gnome-bg-slide-show.h

raw symbols SCIP
1 /* gnome-bg-slide_show.h - fade window background between two surfaces
2
3 Copyright 2008, Red Hat, Inc.
4
5 This file is part of the Gnome Library.
6
7 The Gnome Library is free software; you can redistribute it and/or
8 modify it under the terms of the GNU Library General Public License as
9 published by the Free Software Foundation; either version 2 of the
10 License, or (at your option) any later version.
11
12 The Gnome Library is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 Library General Public License for more details.
16
17 You should have received a copy of the GNU Library General Public
18 License along with the Gnome Library; see the file COPYING.LIB. If not,
19 write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
20 Boston, MA 02110-1301, USA.
21
22 Author: Ray Strode <[email protected]>
23 */
24
25 #ifndef __GNOME_BG_SLIDE_SHOW_H__
26 #define __GNOME_BG_SLIDE_SHOW_H__
27
28 #ifndef GNOME_DESKTOP_USE_UNSTABLE_API
29 #error GnomeBGSlideShow is unstable API. You must define GNOME_DESKTOP_USE_UNSTABLE_API before including gnome-bg-slide_show.h
30 #endif
31
32 #include <gio/gio.h>
33
34 G_BEGIN_DECLS
35
36 #define GNOME_BG_TYPE_SLIDE_SHOW (gnome_bg_slide_show_get_type ())
37 #define GNOME_BG_SLIDE_SHOW(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GNOME_BG_TYPE_SLIDE_SHOW, GnomeBGSlideShow))
38 #define GNOME_BG_SLIDE_SHOW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GNOME_BG_TYPE_SLIDE_SHOW, GnomeBGSlideShowClass))
39 #define GNOME_BG_IS_SLIDE_SHOW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GNOME_BG_TYPE_SLIDE_SHOW))
40 #define GNOME_BG_IS_SLIDE_SHOW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GNOME_BG_TYPE_SLIDE_SHOW))
41 #define GNOME_BG_SLIDE_SHOW_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GNOME_BG_TYPE_SLIDE_SHOW, GnomeBGSlideShowClass))
42
43 typedef struct _GnomeBGSlideShowPrivate GnomeBGSlideShowPrivate;
44 typedef struct _GnomeBGSlideShow GnomeBGSlideShow;
45 typedef struct _GnomeBGSlideShowClass GnomeBGSlideShowClass;
46
47 struct _GnomeBGSlideShow
48 {
49 GObject parent_object;
50
51 GnomeBGSlideShowPrivate *priv;
52 };
53
54 struct _GnomeBGSlideShowClass
55 {
56 GObjectClass parent_class;
57 };
58
59 G_DEFINE_AUTOPTR_CLEANUP_FUNC(GnomeBGSlideShow, g_object_unref)
60
61 GType gnome_bg_slide_show_get_type (void);
62 GnomeBGSlideShow *gnome_bg_slide_show_new (const char *filename);
63 gboolean gnome_bg_slide_show_load (GnomeBGSlideShow *self,
64 GError **error);
65
66 void gnome_bg_slide_show_load_async (GnomeBGSlideShow *self,
67 GCancellable *cancellable,
68 GAsyncReadyCallback callback,
69 gpointer user_data);
70 gboolean gnome_bg_slide_show_load_finish (GnomeBGSlideShow *self,
71 GAsyncResult *res,
72 GError **error);
73
74 gboolean gnome_bg_slide_show_get_slide (GnomeBGSlideShow *self,
75 int frame_number,
76 int width,
77 int height,
78 gdouble *progress,
79 double *duration,
80 gboolean *is_fixed,
81 const char **file1,
82 const char **file2);
83
84 void gnome_bg_slide_show_get_current_slide (GnomeBGSlideShow *self,
85 int width,
86 int height,
87 gdouble *progress,
88 double *duration,
89 gboolean *is_fixed,
90 const char **file1,
91 const char **file2);
92
93
94 double gnome_bg_slide_show_get_start_time (GnomeBGSlideShow *self);
95 double gnome_bg_slide_show_get_total_duration (GnomeBGSlideShow *self);
96 gboolean gnome_bg_slide_show_get_has_multiple_sizes (GnomeBGSlideShow *self);
97 int gnome_bg_slide_show_get_num_slides (GnomeBGSlideShow *self);
98 G_END_DECLS
99
100 #endif