diff options
Diffstat (limited to 'stickynotes/stickynotes_applet.h')
-rw-r--r-- | stickynotes/stickynotes_applet.h | 112 |
1 files changed, 57 insertions, 55 deletions
diff --git a/stickynotes/stickynotes_applet.h b/stickynotes/stickynotes_applet.h index 4d10c387..072318d3 100644 --- a/stickynotes/stickynotes_applet.h +++ b/stickynotes/stickynotes_applet.h @@ -26,85 +26,87 @@ #include <gio/gio.h> #include <mate-panel-applet.h> +#define STICKYNOTES_SCHEMA "org.mate.stickynotes" -#define STICKYNOTES_SCHEMA "org.mate.stickynotes" - -#define STICKYNOTES_STOCK_LOCKED "stickynotes-stock-locked" -#define STICKYNOTES_STOCK_UNLOCKED "stickynotes-stock-unlocked" -#define STICKYNOTES_STOCK_CLOSE "stickynotes-stock-close" -#define STICKYNOTES_STOCK_RESIZE_SE "stickynotes-stock-resize-se" -#define STICKYNOTES_STOCK_RESIZE_SW "stickynotes-stock-resize-sw" +#define STICKYNOTES_STOCK_LOCKED "stickynotes-stock-locked" +#define STICKYNOTES_STOCK_UNLOCKED "stickynotes-stock-unlocked" +#define STICKYNOTES_STOCK_CLOSE "stickynotes-stock-close" +#define STICKYNOTES_STOCK_RESIZE_SE "stickynotes-stock-resize-se" +#define STICKYNOTES_STOCK_RESIZE_SW "stickynotes-stock-resize-sw" /* Global Sticky Notes instance */ typedef struct { - GtkBuilder *builder; - - GtkWidget *w_prefs; /* The prefs dialog */ - GtkAdjustment *w_prefs_width; - GtkAdjustment *w_prefs_height; - GtkWidget *w_prefs_color; - GtkWidget *w_prefs_font_color; - GtkWidget *w_prefs_sys_color; - GtkWidget *w_prefs_font; - GtkWidget *w_prefs_sys_font; - GtkWidget *w_prefs_sticky; - GtkWidget *w_prefs_force; - GtkWidget *w_prefs_desktop; - - GList *notes; /* Linked-List of all the sticky notes */ - GList *applets; /* Linked-List of all the applets */ - - cairo_surface_t *icon_normal; /* Normal applet icon */ - cairo_surface_t *icon_prelight; /* Prelighted applet icon */ - - GSettings *settings; /* Shared GSettings */ - - gint max_height; - guint last_timeout_data; - - gboolean visible; /* Toggle show/hide notes */ + GtkBuilder *builder; + + GtkWidget *w_prefs; /* The prefs dialog */ + GtkAdjustment *w_prefs_width; + GtkAdjustment *w_prefs_height; + GtkWidget *w_prefs_color; + GtkWidget *w_prefs_font_color; + GtkWidget *w_prefs_sys_color; + GtkWidget *w_prefs_font; + GtkWidget *w_prefs_sys_font; + GtkWidget *w_prefs_sticky; + GtkWidget *w_prefs_force; + GtkWidget *w_prefs_desktop; + + GList *notes; /* Linked-List of all the sticky notes */ + GList *applets; /* Linked-List of all the applets */ + + cairo_surface_t *icon_normal; /* Normal applet icon */ + cairo_surface_t *icon_prelight; /* Prelighted applet icon */ + + GSettings *settings; /* Shared GSettings */ + + gint max_height; + guint last_timeout_data; + + gboolean visible; /* Toggle show/hide notes */ } StickyNotes; /* Sticky Notes Applet */ typedef struct { - GtkWidget *w_applet; /* The applet */ - GtkWidget *w_image; /* The applet icon */ + GtkWidget *w_applet; /* The applet */ + GtkWidget *w_image; /* The applet icon */ - GtkWidget *destroy_all_dialog; /* The applet it's destroy all dialog */ - - gboolean prelighted; /* Whether applet is prelighted */ + GtkWidget *destroy_all_dialog; /* The applet it's destroy all dialog */ - gint panel_size; - MatePanelAppletOrient panel_orient; + gboolean prelighted; /* Whether applet is prelighted */ - GtkActionGroup *action_group; - GtkWidget *menu_tip; + gint panel_size; + MatePanelAppletOrient panel_orient; + + GtkActionGroup *action_group; + GtkWidget *menu_tip; } StickyNotesApplet; - + typedef enum { - STICKYNOTES_NEW = 0, - STICKYNOTES_SET_VISIBLE, - STICKYNOTES_SET_LOCKED + STICKYNOTES_NEW = 0, + STICKYNOTES_SET_VISIBLE, + STICKYNOTES_SET_LOCKED } StickyNotesDefaultAction; extern StickyNotes *stickynotes; -void stickynotes_applet_init(MatePanelApplet *mate_panel_applet); -void stickynotes_applet_init_prefs(void); +void stickynotes_applet_init (MatePanelApplet *mate_panel_applet); +void stickynotes_applet_init_prefs (void); -StickyNotesApplet * stickynotes_applet_new(MatePanelApplet *mate_panel_applet); +StickyNotesApplet * stickynotes_applet_new (MatePanelApplet *mate_panel_applet); -void stickynotes_applet_update_icon(StickyNotesApplet *applet); -void stickynotes_applet_update_prefs(void); -void stickynotes_applet_update_menus(void); -void stickynotes_applet_update_tooltips(void); +void stickynotes_applet_update_icon (StickyNotesApplet *applet); +void stickynotes_applet_update_prefs (void); +void stickynotes_applet_update_menus (void); +void stickynotes_applet_update_tooltips (void); -void stickynotes_applet_do_default_action(GdkScreen *screen); +void stickynotes_applet_do_default_action (GdkScreen *screen); -void stickynotes_applet_panel_icon_get_geometry (int *x, int *y, int *width, int *height); +void stickynotes_applet_panel_icon_get_geometry (int *x, + int *y, + int *width, + int *height); #endif /* __STICKYNOTES_APPLET_H__ */ |