summaryrefslogtreecommitdiff
path: root/stickynotes/stickynotes_applet_callbacks.c
diff options
context:
space:
mode:
authorMonsta <[email protected]>2015-02-26 11:50:20 +0300
committerStefano Karapetsas <[email protected]>2015-03-15 18:58:51 +0100
commit9ff3e1b03e0beae87a6a77451c738cc8f34ec7c8 (patch)
tree9068b8f6c85d926e0cc1cf4fe1139687d8e18e40 /stickynotes/stickynotes_applet_callbacks.c
parent8b02bc96f1e48a5dbcc459c8898464a891c01e0e (diff)
downloadmate-applets-9ff3e1b03e0beae87a6a77451c738cc8f34ec7c8.tar.bz2
mate-applets-9ff3e1b03e0beae87a6a77451c738cc8f34ec7c8.tar.xz
stickynotes: use mate_panel_applet_set_background_widget
Diffstat (limited to 'stickynotes/stickynotes_applet_callbacks.c')
-rw-r--r--stickynotes/stickynotes_applet_callbacks.c49
1 files changed, 0 insertions, 49 deletions
diff --git a/stickynotes/stickynotes_applet_callbacks.c b/stickynotes/stickynotes_applet_callbacks.c
index 6414db5c..2da02a32 100644
--- a/stickynotes/stickynotes_applet_callbacks.c
+++ b/stickynotes/stickynotes_applet_callbacks.c
@@ -228,55 +228,6 @@ void applet_size_allocate_cb(GtkWidget *widget, GtkAllocation *allocation, Stick
return;
}
-/* Applet Callback : Change the applet background. */
-void
-applet_change_bg_cb (MatePanelApplet *mate_panel_applet,
- MatePanelAppletBackgroundType type,
- GdkColor *color,
-#if GTK_CHECK_VERSION (3, 0, 0)
- cairo_pattern_t *pattern,
-#else
- GdkPixmap *pixmap,
-#endif
- StickyNotesApplet *applet)
-{
-#if !GTK_CHECK_VERSION (3, 0, 0)
- /* Taken from TrashApplet */
- GtkRcStyle *rc_style;
- GtkStyle *style;
-
- if (!applet) g_print ("arrg, no applet!\n");
-
- /* reset style */
- gtk_widget_set_style (GTK_WIDGET (applet->w_applet), NULL);
- rc_style = gtk_rc_style_new ();
- gtk_widget_modify_style (GTK_WIDGET (applet->w_applet), rc_style);
- g_object_unref (rc_style);
-
- switch (type)
- {
- case PANEL_NO_BACKGROUND:
- break;
- case PANEL_COLOR_BACKGROUND:
- gtk_widget_modify_bg (GTK_WIDGET (applet->w_applet),
- GTK_STATE_NORMAL, color);
- break;
- case PANEL_PIXMAP_BACKGROUND:
- style = gtk_style_copy (
- gtk_widget_get_style (GTK_WIDGET (applet->w_applet)));
- if (style->bg_pixmap[GTK_STATE_NORMAL])
- g_object_unref (
- style->bg_pixmap[GTK_STATE_NORMAL]);
- style->bg_pixmap[GTK_STATE_NORMAL] = g_object_ref (
- pixmap);
- gtk_widget_set_style (
- GTK_WIDGET (applet->w_applet), style);
- g_object_unref (style);
- break;
- }
-#endif
-}
-
/* Applet Callback : Deletes the applet. */
void applet_destroy_cb (MatePanelApplet *mate_panel_applet, StickyNotesApplet *applet)
{