aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRoss Burton <ross.burton@intel.com>2013-07-17 17:44:11 +0100
committerJussi Kukkonen <jussi.kukkonen@intel.com>2016-04-25 13:57:54 +0300
commit87654d05f20ec08cbca3fd61fba539516d031aa4 (patch)
treee727985e003af1d69646aad5f013aff270557a43
parenta8b067214a2aab901ccc6670e0a7b286c21a2739 (diff)
downloadmatchbox-panel-2-87654d05f20ec08cbca3fd61fba539516d031aa4.tar.gz
matchbox-panel-2-87654d05f20ec08cbca3fd61fba539516d031aa4.tar.bz2
matchbox-panel-2-87654d05f20ec08cbca3fd61fba539516d031aa4.zip
showdesktop: port to use scaling-image2
-rw-r--r--applets/showdesktop/showdesktop.c14
1 files changed, 5 insertions, 9 deletions
diff --git a/applets/showdesktop/showdesktop.c b/applets/showdesktop/showdesktop.c
index e40ebc3..14f9d96 100644
--- a/applets/showdesktop/showdesktop.c
+++ b/applets/showdesktop/showdesktop.c
@@ -11,11 +11,11 @@
#include <gdk/gdkx.h>
#include <X11/Xatom.h>
#include <matchbox-panel/mb-panel.h>
-#include <matchbox-panel/mb-panel-scaling-image.h>
+#include <matchbox-panel/mb-panel-scaling-image2.h>
typedef struct {
GtkButton *button;
- MBPanelScalingImage *image;
+ MBPanelScalingImage2 *image;
gboolean active;
@@ -45,15 +45,11 @@ show_desktop_applet_free (ShowDesktopApplet *applet)
static void
set_active (ShowDesktopApplet *applet, gboolean active)
{
- const char *icon;
-
applet->active = active;
/* TODO: remove this function and instead use a toggle button? */
- icon = "panel-user-desktop";
-
- mb_panel_scaling_image_set_icon (applet->image, icon);
+ mb_panel_scaling_image2_set_icon (applet->image, "panel-user-desktop");
}
/* Sync @applet with the _NET_SHOWING_DESKTOP root window property */
@@ -206,8 +202,8 @@ mb_panel_applet_create (const char *id,
gtk_widget_set_name (button, "MatchboxPanelShowDesktop");
- image = mb_panel_scaling_image_new (orientation, NULL);
- applet->image = MB_PANEL_SCALING_IMAGE (image);
+ image = mb_panel_scaling_image2_new (orientation, NULL);
+ applet->image = MB_PANEL_SCALING_IMAGE2 (image);
gtk_container_add (GTK_CONTAINER (button), image);