summaryrefslogtreecommitdiff
path: root/applets/wncklet/showdesktop.c
diff options
context:
space:
mode:
Diffstat (limited to 'applets/wncklet/showdesktop.c')
-rw-r--r--applets/wncklet/showdesktop.c46
1 files changed, 24 insertions, 22 deletions
diff --git a/applets/wncklet/showdesktop.c b/applets/wncklet/showdesktop.c
index 7cfcb88d..6a268135 100644
--- a/applets/wncklet/showdesktop.c
+++ b/applets/wncklet/showdesktop.c
@@ -21,8 +21,6 @@
* 02111-1307, USA.
*/
-#define WNCK_I_KNOW_THIS_IS_UNSTABLE 1
-
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
@@ -32,7 +30,7 @@
#include <gtk/gtk.h>
#include <gdk/gdkx.h>
-#include <libwnck/screen.h>
+#include <libmatewnck/screen.h>
#include "wncklet.h"
#include "showdesktop.h"
@@ -52,7 +50,7 @@ typedef struct {
GtkOrientation orient;
int size;
- WnckScreen* wnck_screen;
+ MatewnckScreen* matewnck_screen;
guint showing_desktop: 1;
guint button_activate;
@@ -70,7 +68,7 @@ static void update_button_display(ShowDesktopData* sdd);
static void theme_changed_callback(GtkIconTheme* icon_theme, ShowDesktopData* sdd);
static void button_toggled_callback(GtkWidget* button, ShowDesktopData* sdd);
-static void show_desktop_changed_callback(WnckScreen* screen, ShowDesktopData* sdd);
+static void show_desktop_changed_callback(MatewnckScreen* screen, ShowDesktopData* sdd);
/* this is when the panel orientation changes */
@@ -281,10 +279,10 @@ static void applet_destroyed(GtkWidget* applet, ShowDesktopData* sdd)
sdd->button_activate = 0;
}
- if (sdd->wnck_screen != NULL)
+ if (sdd->matewnck_screen != NULL)
{
- g_signal_handlers_disconnect_by_func(sdd->wnck_screen, show_desktop_changed_callback, sdd);
- sdd->wnck_screen = NULL;
+ g_signal_handlers_disconnect_by_func(sdd->matewnck_screen, show_desktop_changed_callback, sdd);
+ sdd->matewnck_screen = NULL;
}
if (sdd->icon_theme != NULL)
@@ -343,21 +341,21 @@ static void show_desktop_applet_realized(MatePanelApplet* applet, gpointer data)
sdd = (ShowDesktopData*) data;
- if (sdd->wnck_screen != NULL)
- g_signal_handlers_disconnect_by_func(sdd->wnck_screen, show_desktop_changed_callback, sdd);
+ if (sdd->matewnck_screen != NULL)
+ g_signal_handlers_disconnect_by_func(sdd->matewnck_screen, show_desktop_changed_callback, sdd);
if (sdd->icon_theme != NULL)
g_signal_handlers_disconnect_by_func(sdd->icon_theme, theme_changed_callback, sdd);
screen = gtk_widget_get_screen(sdd->applet);
- sdd->wnck_screen = wnck_screen_get(gdk_screen_get_number (screen));
+ sdd->matewnck_screen = matewnck_screen_get(gdk_screen_get_number (screen));
- if (sdd->wnck_screen != NULL)
- wncklet_connect_while_alive(sdd->wnck_screen, "showing_desktop_changed", G_CALLBACK(show_desktop_changed_callback), sdd, sdd->applet);
+ if (sdd->matewnck_screen != NULL)
+ wncklet_connect_while_alive(sdd->matewnck_screen, "showing_desktop_changed", G_CALLBACK(show_desktop_changed_callback), sdd, sdd->applet);
else
- g_warning("Could not get WnckScreen!");
+ g_warning("Could not get MatewnckScreen!");
- show_desktop_changed_callback(sdd->wnck_screen, sdd);
+ show_desktop_changed_callback(sdd->matewnck_screen, sdd);
sdd->icon_theme = gtk_icon_theme_get_for_screen (screen);
wncklet_connect_while_alive(sdd->icon_theme, "changed", G_CALLBACK(theme_changed_callback), sdd, sdd->applet);
@@ -463,17 +461,21 @@ static void display_help_dialog(GtkAction* action, ShowDesktopData* sdd)
static void display_about_dialog(GtkAction* action, ShowDesktopData* sdd)
{
static const gchar* authors[] = {
+ "Perberos <[email protected]>",
+ "Steve Zesch <[email protected]>",
+ "Stefano Karapetsas <[email protected]>",
"Havoc Pennington <[email protected]>",
NULL
};
static const char* documenters[] = {
- "Sun MATE Documentation Team <[email protected]>",
+ "Sun GNOME Documentation Team <[email protected]>",
NULL
};
/* Translator credits */
//const char* translator_credits = _("translator-credits");
char copyright[] = \
+ "Copyright \xc2\xa9 2011 Perberos\n"
"Copyright \xc2\xa9 2002 Red Hat, Inc.";
gtk_show_about_dialog(GTK_WINDOW(sdd->applet),
@@ -486,7 +488,7 @@ static void display_about_dialog(GtkAction* action, ShowDesktopData* sdd)
"logo-icon-name", SHOW_DESKTOP_ICON,
"translator-credits", _("translator-credits"),
"version", VERSION,
- "website", "http://matsusoft.com.ar/projects/mate/",
+ "website", "http://www.mate-desktop.org/",
NULL);
}
@@ -518,16 +520,16 @@ static void button_toggled_callback(GtkWidget* button, ShowDesktopData* sdd)
return;
}
- if (sdd->wnck_screen != NULL)
- wnck_screen_toggle_showing_desktop(sdd->wnck_screen, gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(button)));
+ if (sdd->matewnck_screen != NULL)
+ matewnck_screen_toggle_showing_desktop(sdd->matewnck_screen, gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(button)));
update_button_display (sdd);
}
-static void show_desktop_changed_callback(WnckScreen* screen, ShowDesktopData* sdd)
+static void show_desktop_changed_callback(MatewnckScreen* screen, ShowDesktopData* sdd)
{
- if (sdd->wnck_screen != NULL)
- sdd->showing_desktop = wnck_screen_get_showing_desktop(sdd->wnck_screen);
+ if (sdd->matewnck_screen != NULL)
+ sdd->showing_desktop = matewnck_screen_get_showing_desktop(sdd->matewnck_screen);
update_button_state (sdd);
}