diff options
Diffstat (limited to 'frontends/gtk/throbber.h')
-rw-r--r-- | frontends/gtk/throbber.h | 33 |
1 files changed, 20 insertions, 13 deletions
diff --git a/frontends/gtk/throbber.h b/frontends/gtk/throbber.h index e0b47e15c..c8529d2e2 100644 --- a/frontends/gtk/throbber.h +++ b/frontends/gtk/throbber.h @@ -16,20 +16,27 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ -#ifndef __GTK_THROBBER_H__ -#define __GTK_THROBBER_H__ - -#include <gtk/gtk.h> - -struct nsgtk_throbber -{ - int nframes; /**< Number of frames in the throbber */ - GdkPixbuf **framedata; -}; - -extern struct nsgtk_throbber *nsgtk_throbber; +#ifndef NETSURF_GTK_THROBBER_H +#define NETSURF_GTK_THROBBER_H +/** + * Initialise global throbber context + */ nserror nsgtk_throbber_init(void); + +/** + * release global throbber context + */ void nsgtk_throbber_finalise(void); -#endif /* __GTK_THROBBER_H__ */ +/** + * get the pixbuf of a given frame of the throbber + * + * \param frame The frame number starting at 0 for stopped frame + * \param pixbuf updated on success + * \return NSERROR_OK and pixbuf updated on success, NSERROR_BAD_SIZE if frame + * is out of range else error code. + */ +nserror nsgtk_throbber_get_frame(int frame, GdkPixbuf **pixbuf); + +#endif /* NETSURF_GTK_THROBBER_H */ |