[gnome-shell] Fix for gdk/x11 changes
- From: Owen Taylor <otaylor src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell] Fix for gdk/x11 changes
- Date: Wed, 22 Dec 2010 21:37:12 +0000 (UTC)
commit c546ad9720c060c2f47cb224855d19e82688bcec
Author: Owen W. Taylor <otaylor fishsoup net>
Date: Wed Dec 22 16:26:08 2010 -0500
Fix for gdk/x11 changes
Handle the move of gdk_window_lookup() and gdk_window_foreign_new()
into the gdk_x11_ namespace.
src/shell-global.c | 3 ++-
src/shell-tray-manager.c | 9 ++++++---
src/st/st-im-text.c | 5 +++--
src/tray/na-tray-manager.c | 1 -
4 files changed, 11 insertions(+), 7 deletions(-)
---
diff --git a/src/shell-global.c b/src/shell-global.c
index 71eb728..2cf6ec6 100644
--- a/src/shell-global.c
+++ b/src/shell-global.c
@@ -530,7 +530,8 @@ shell_global_set_cursor (ShellGlobal *global,
{
ClutterStage *stage = CLUTTER_STAGE (meta_plugin_get_stage (global->plugin));
- global->stage_window = gdk_window_foreign_new (clutter_x11_get_stage_window (stage));
+ global->stage_window = gdk_x11_window_foreign_new_for_display (gdk_display_get_default (),
+ clutter_x11_get_stage_window (stage));
}
gdk_window_set_cursor (global->stage_window, cursor);
diff --git a/src/shell-tray-manager.c b/src/shell-tray-manager.c
index ec6c8ae..370297f 100644
--- a/src/shell-tray-manager.c
+++ b/src/shell-tray-manager.c
@@ -198,6 +198,7 @@ shell_tray_manager_manage_stage (ShellTrayManager *manager,
{
Window stage_xwindow;
GdkWindow *stage_window;
+ GdkDisplay *display;
GdkScreen *screen;
g_return_if_fail (manager->priv->stage == NULL);
@@ -212,13 +213,15 @@ shell_tray_manager_manage_stage (ShellTrayManager *manager,
* in in some way. (The Clutter/Mutter combo is currently incapable
* of multi-screen operation, so alternatively we could just assume
* that clutter_x11_get_default_screen() gives us the right
- * screen.)
+ * screen.) We assume, in any case, that we are using the default
+ * GDK display.
*/
- stage_window = gdk_window_lookup (stage_xwindow);
+ display = gdk_display_get_default();
+ stage_window = gdk_x11_window_lookup_for_display (display, stage_xwindow);
if (stage_window)
g_object_ref (stage_window);
else
- stage_window = gdk_window_foreign_new (stage_xwindow);
+ stage_window = gdk_x11_window_foreign_new_for_display (display, stage_xwindow);
screen = gdk_window_get_screen (stage_window);
diff --git a/src/st/st-im-text.c b/src/st/st-im-text.c
index 2b3f0fd..c2a0bf5 100644
--- a/src/st/st-im-text.c
+++ b/src/st/st-im-text.c
@@ -61,6 +61,7 @@
#include <glib.h>
#include <gtk/gtk.h>
#include <gdk/gdkkeysyms.h>
+#include <gdk/gdkx.h>
#include <X11/extensions/XKB.h>
#include "st-im-text.h"
@@ -200,11 +201,11 @@ window_for_actor (ClutterActor *actor)
stage = clutter_actor_get_stage (actor);
xwindow = clutter_x11_get_stage_window ((ClutterStage *)stage);
- window = gdk_window_lookup_for_display (display, xwindow);
+ window = gdk_x11_window_lookup_for_display (display, xwindow);
if (window)
g_object_ref (window);
else
- window = gdk_window_foreign_new_for_display (display, xwindow);
+ window = gdk_x11_window_foreign_new_for_display (display, xwindow);
return window;
}
diff --git a/src/tray/na-tray-manager.c b/src/tray/na-tray-manager.c
index 64300bc..d53c902 100644
--- a/src/tray/na-tray-manager.c
+++ b/src/tray/na-tray-manager.c
@@ -27,7 +27,6 @@
#include "na-tray-manager.h"
#include "gtk-compat.h"
-#include <gdkconfig.h>
#include <glib/gi18n-lib.h>
#if defined (GDK_WINDOWING_X11)
#include <gdk/gdkx.h>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]