summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--README2
-rw-r--r--configure.ac12
-rw-r--r--stickynotes/Makefile.am4
-rw-r--r--stickynotes/stickynotes.c47
-rw-r--r--stickynotes/stickynotes.h3
5 files changed, 35 insertions, 33 deletions
diff --git a/README b/README
index 05089f01..e137fcef 100644
--- a/README
+++ b/README
@@ -24,7 +24,7 @@ You need at least:
mate-vfs
libglade-2.4.0
libxklavier-1.13
- libmatewnck
+ libwnck
system-tools-backends-1.1.3
libgtop-2.12.0
diff --git a/configure.ac b/configure.ac
index c35380b7..8e8788bb 100644
--- a/configure.ac
+++ b/configure.ac
@@ -17,7 +17,7 @@ GIO_REQUIRED=2.15.3
LIBPANEL4_REQUIRED=1.5.2
LIBGTOP_REQUIRED=2.11.92
LIBXKLAVIER_REQUIRED=4.0
-LIBMATEWNCK_REQUIRED=1.3.0
+LIBWNCK_REQUIRED=2.30.0
LIBMATE_DESKTOP_REQUIRED=1.1.0
LIBNOTIFY_REQUIRED=0.7.0
HAL_REQUIRED=0.5.3
@@ -142,12 +142,12 @@ fi
AC_SUBST(MATE_SETTINGS_DAEMON_CFLAGS)
AC_SUBST(MATE_SETTINGS_DAEMON_LIBS)
-dnl -- check for libmatewnck (required) -------------------------------------------
-PKG_CHECK_MODULES(LIBMATEWNCK, libmatewnck >= $LIBMATEWNCK_REQUIRED,,
- AC_MSG_ERROR([libmatewnck is required to build mate-applets.], 1))
+dnl -- check for libwnck (required) -------------------------------------------
+PKG_CHECK_MODULES(LIBWNCK, libwnck-1.0 >= $LIBWNCK_REQUIRED,,
+ AC_MSG_ERROR([libwnck is required to build mate-applets.], 1))
-AC_SUBST(LIBMATEWNCK_CFLAGS)
-AC_SUBST(LIBMATEWNCK_LIBS)
+AC_SUBST(LIBWNCK_CFLAGS)
+AC_SUBST(LIBWNCK_LIBS)
dnl -- check for libnotify (optional) -----------------------------------------
LIBNOTIFY_CFLAGS=
diff --git a/stickynotes/Makefile.am b/stickynotes/Makefile.am
index 9036bd7b..0206a41d 100644
--- a/stickynotes/Makefile.am
+++ b/stickynotes/Makefile.am
@@ -13,7 +13,7 @@ AM_CPPFLAGS = \
-I. \
-I$(srcdir) \
$(MATE_APPLETS4_CFLAGS) \
- $(LIBMATEWNCK_CFLAGS) \
+ $(LIBWNCK_CFLAGS) \
$(XML2_CFLAGS) \
-DSTICKYNOTES_MENU_UI_DIR=\""$(uidir)"\"\
-DSTICKYNOTES_ICONDIR=\"$(datadir)/pixmaps/mate-stickynotes/\"
@@ -34,7 +34,7 @@ stickynotes_applet_SOURCES = \
stickynotes_applet_LDADD = \
$(MATE_APPLETS4_LIBS) \
- $(LIBMATEWNCK_LIBS) \
+ $(LIBWNCK_LIBS) \
$(XML2_LIBS) \
-lX11
diff --git a/stickynotes/stickynotes.c b/stickynotes/stickynotes.c
index eb926fc3..1796ebae 100644
--- a/stickynotes/stickynotes.c
+++ b/stickynotes/stickynotes.c
@@ -21,7 +21,8 @@
#include <libxml/parser.h>
#include <X11/Xatom.h>
#include <gdk/gdkx.h>
-#include <libmatewnck/libmatewnck.h>
+#define WNCK_I_KNOW_THIS_IS_UNSTABLE 1
+#include <libwnck/libwnck.h>
#include <string.h>
#include "stickynotes.h"
@@ -36,7 +37,7 @@ static gboolean save_scheduled = FALSE;
static void response_cb (GtkWidget *dialog, gint id, gpointer data);
-/* Based on a function found in matewnck */
+/* Based on a function found in wnck */
static void
set_icon_geometry (GdkWindow *window,
int x,
@@ -639,23 +640,23 @@ stickynote_set_visible (StickyNote *note, gboolean visible)
else if (note->workspace > 0)
{
#if 0
- MatewnckWorkspace *matewnck_ws;
+ WnckWorkspace *wnck_ws;
gulong xid;
- MatewnckWindow *matewnck_win;
- MatewnckScreen *matewnck_screen;
+ WnckWindow *wnck_win;
+ WnckScreen *wnck_screen;
g_print ("set_visible(): workspace = %i\n",
note->workspace);
xid = GDK_WINDOW_XID (note->w_window->window);
- matewnck_screen = matewnck_screen_get_default ();
- matewnck_win = matewnck_window_get (xid);
- matewnck_ws = matewnck_screen_get_workspace (
- matewnck_screen,
+ wnck_screen = wnck_screen_get_default ();
+ wnck_win = wnck_window_get (xid);
+ wnck_ws = wnck_screen_get_workspace (
+ wnck_screen,
note->workspace - 1);
- if (matewnck_win && matewnck_ws)
- matewnck_window_move_to_workspace (
- matewnck_win, matewnck_ws);
+ if (wnck_win && wnck_ws)
+ wnck_window_move_to_workspace (
+ wnck_win, wnck_ws);
else
g_print ("set_visible(): errr\n");
#endif
@@ -722,7 +723,7 @@ void stickynotes_remove(StickyNote *note)
gboolean
stickynotes_save_now (void)
{
- MatewnckScreen *matewnck_screen;
+ WnckScreen *wnck_screen;
const gchar *title;
GtkTextBuffer *buffer;
GtkTextIter start, end;
@@ -737,12 +738,12 @@ stickynotes_save_now (void)
xmlDocSetRootElement(doc, root);
xmlNewProp(root, XML_CHAR("version"), XML_CHAR (VERSION));
- matewnck_screen = matewnck_screen_get_default ();
- matewnck_screen_force_update (matewnck_screen);
+ wnck_screen = wnck_screen_get_default ();
+ wnck_screen_force_update (wnck_screen);
/* For all sticky notes */
for (i = 0; i < g_list_length(stickynotes->notes); i++) {
- MatewnckWindow *matewnck_win;
+ WnckWindow *wnck_win;
gulong xid = 0;
/* Access the current note in the list */
@@ -757,13 +758,13 @@ stickynotes_save_now (void)
gchar *y_str = g_strdup_printf("%d", note->y);
xid = GDK_WINDOW_XID (gtk_widget_get_window (note->w_window));
- matewnck_win = matewnck_window_get (xid);
+ wnck_win = wnck_window_get (xid);
if (!g_settings_get_boolean (stickynotes->settings, "sticky") &&
- matewnck_win)
+ wnck_win)
note->workspace = 1 +
- matewnck_workspace_get_number (
- matewnck_window_get_workspace (matewnck_win));
+ wnck_workspace_get_number (
+ wnck_window_get_workspace (wnck_win));
else
note->workspace = 0;
@@ -852,7 +853,7 @@ stickynotes_load (GdkScreen *screen)
xmlDocPtr doc = NULL;
xmlNodePtr root;
xmlNodePtr node;
- /* MatewnckScreen *matewnck_screen; */
+ /* WnckScreen *wnck_screen; */
GList *new_notes, *tmp1; /* Lists of StickyNote*'s */
GList *new_nodes; /* Lists of xmlNodePtr's */
int x, y, w, h;
@@ -1040,8 +1041,8 @@ stickynotes_load (GdkScreen *screen)
tmp1 = new_notes;
/*
- matewnck_screen = matewnck_screen_get_default ();
- matewnck_screen_force_update (matewnck_screen);
+ wnck_screen = wnck_screen_get_default ();
+ wnck_screen_force_update (wnck_screen);
*/
while (tmp1)
diff --git a/stickynotes/stickynotes.h b/stickynotes/stickynotes.h
index 7ec97871..4073c42e 100644
--- a/stickynotes/stickynotes.h
+++ b/stickynotes/stickynotes.h
@@ -20,7 +20,8 @@
#ifndef __STICKYNOTES_H__
#define __STICKYNOTES_H__
-#include <libmatewnck/libmatewnck.h>
+#define WNCK_I_KNOW_THIS_IS_UNSTABLE 1
+#include <libwnck/libwnck.h>
#include <stickynotes_applet.h>
typedef struct