? gdk/gdkmarshalers.h
Index: gdk/linux-fb/Makefile.am
===================================================================
RCS file: /cvs/gnome/gtk+/gdk/linux-fb/Makefile.am,v
retrieving revision 1.20
diff -u -r1.20 Makefile.am
--- gdk/linux-fb/Makefile.am	2002/08/05 21:10:06	1.20
+++ gdk/linux-fb/Makefile.am	2002/08/15 06:22:24
@@ -73,6 +73,8 @@
 	gdkfbmanager.h
 
 gdkfbmanager_sources = gdkfbmanager.c 
+gdkfbmanager_LDFLAGS = $(GLIB_LIBS)
 gdkfbswitch_sources = gdkfbswitch.c
+gdkfbswitch_LDFLAGS = $(GLIB_LIBS)
 
 EXTRA_DIST=x-cursors.xbm
Index: gdk/linux-fb/gdkcolor-fb.c
===================================================================
RCS file: /cvs/gnome/gtk+/gdk/linux-fb/gdkcolor-fb.c,v
retrieving revision 1.17
diff -u -r1.17 gdkcolor-fb.c
--- gdk/linux-fb/gdkcolor-fb.c	2001/11/05 00:23:44	1.17
+++ gdk/linux-fb/gdkcolor-fb.c	2002/08/15 06:22:24
@@ -40,6 +40,7 @@
 static void  gdk_fb_color_round_to_hw (GdkColor *color);
 
 static gpointer parent_class;
+static GdkColormap *default_colormap = NULL;
 
 static void
 gdk_colormap_finalize (GObject *object)
@@ -202,7 +203,7 @@
 }
 
 GdkColormap*
-gdk_colormap_get_system (void)
+gdk_screen_get_system_colormap (GdkScreen *screen)
 {
   static GdkColormap *colormap = NULL;
 
@@ -310,6 +311,19 @@
   return colormap;
 }
 
+GdkColormap*
+gdk_screen_get_default_colormap (GdkScreen *screen)
+{
+  return default_colormap;
+}
+
+void
+gdk_screen_set_default_colormap (GdkScreen   *screen,
+				 GdkColormap *colormap)
+{
+  default_colormap = colormap;
+}
+
 gint
 gdk_colormap_get_system_size (void)
 {
@@ -853,4 +867,12 @@
       g_assert_not_reached ();
       break;
     }
+}
+
+GdkScreen*
+gdk_colormap_get_screen (GdkColormap *cmap)
+{
+  g_return_val_if_fail (cmap != NULL, NULL);
+
+  return gdk_screen_get_default ();
 }
Index: gdk/linux-fb/gdkcursor-fb.c
===================================================================
RCS file: /cvs/gnome/gtk+/gdk/linux-fb/gdkcursor-fb.c,v
retrieving revision 1.13
diff -u -r1.13 gdkcursor-fb.c
--- gdk/linux-fb/gdkcursor-fb.c	2001/09/07 21:49:54	1.13
+++ gdk/linux-fb/gdkcursor-fb.c	2002/08/15 06:22:24
@@ -192,7 +192,8 @@
 };
 
 GdkCursor*
-gdk_cursor_new (GdkCursorType cursor_type)
+gdk_cursor_new_for_display (GdkDisplay    *display,
+			    GdkCursorType  cursor_type)
 {
   GdkCursor *cursor;
   
@@ -527,4 +528,10 @@
 
   gdk_fb_mouse_get_info (&x, &y, NULL);
   gdk_fb_cursor_move (x, y, win);
+}
+
+GdkDisplay *
+gdk_cursor_get_display (GdkCursor *cursor)
+{
+  return gdk_display_get_default ();
 }
Index: gdk/linux-fb/gdkdrawable-fb2.c
===================================================================
RCS file: /cvs/gnome/gtk+/gdk/linux-fb/gdkdrawable-fb2.c,v
retrieving revision 1.33
diff -u -r1.33 gdkdrawable-fb2.c
--- gdk/linux-fb/gdkdrawable-fb2.c	2002/01/25 17:10:03	1.33
+++ gdk/linux-fb/gdkdrawable-fb2.c	2002/08/15 06:22:25
@@ -86,6 +86,7 @@
 static void         gdk_fb_set_colormap       (GdkDrawable      *drawable,
 					       GdkColormap      *colormap);
 static gint         gdk_fb_get_depth          (GdkDrawable      *drawable);
+static GdkScreen*   gdk_fb_get_screen         (GdkDrawable      *drawable);
 static GdkVisual*   gdk_fb_get_visual         (GdkDrawable      *drawable);
 static void         gdk_fb_drawable_finalize  (GObject *object);
 
@@ -219,6 +220,7 @@
   drawable_class->get_size = gdk_fb_get_size;
  
   drawable_class->get_depth = gdk_fb_get_depth;
+  drawable_class->get_screen = gdk_fb_get_screen;
   drawable_class->get_visual = gdk_fb_get_visual;
   
   drawable_class->_copy_to_image = _gdk_fb_copy_to_image;
@@ -1303,6 +1305,12 @@
 gdk_fb_get_depth (GdkDrawable *drawable)
 {
   return GDK_DRAWABLE_FBDATA (drawable)->depth;
+}
+
+static GdkScreen*
+gdk_fb_get_screen (GdkDrawable *drawable)
+{
+  return gdk_screen_get_default();
 }
 
 static GdkVisual*
Index: gdk/linux-fb/gdkevents-fb.c
===================================================================
RCS file: /cvs/gnome/gtk+/gdk/linux-fb/gdkevents-fb.c,v
retrieving revision 1.10
diff -u -r1.10 gdkevents-fb.c
--- gdk/linux-fb/gdkevents-fb.c	2001/09/07 21:49:54	1.10
+++ gdk/linux-fb/gdkevents-fb.c	2002/08/15 06:22:25
@@ -87,16 +87,17 @@
 gboolean
 gdk_events_pending (void)
 {
-  return _gdk_event_queue_find_first () ? TRUE : FALSE;
+  return fb_events_check (NULL);
 }
 
 GdkEvent*
 gdk_event_get_graphics_expose (GdkWindow *window)
 {
+  GdkDisplay *display = gdk_display_get_default ();
   GList *ltmp;
   g_return_val_if_fail (window != NULL, NULL);
   
-  for (ltmp = _gdk_queued_events; ltmp; ltmp = ltmp->next)
+  for (ltmp = display->queued_events; ltmp; ltmp = ltmp->next)
     {
       GdkEvent *event = ltmp->data;
       if (event->type == GDK_EXPOSE &&
@@ -108,7 +109,7 @@
     {
       GdkEvent *retval = ltmp->data;
 
-      _gdk_event_queue_remove_link (ltmp);
+      _gdk_event_queue_remove_link (display, ltmp);
       g_list_free_1 (ltmp);
 
       return retval;
@@ -118,7 +119,7 @@
 }
 
 void
-_gdk_events_queue (void)
+_gdk_events_queue (GdkDisplay *display)
 {  
 }
 
@@ -138,7 +139,7 @@
 
   GDK_THREADS_ENTER ();
 
-  retval = (_gdk_event_queue_find_first () != NULL);
+  retval = (_gdk_event_queue_find_first (gdk_display_get_default ()) != NULL);
 
   GDK_THREADS_LEAVE ();
 
@@ -154,7 +155,7 @@
 
   GDK_THREADS_ENTER ();
 
-  while ((event = _gdk_event_unqueue ()))
+  while ((event = _gdk_event_unqueue (gdk_display_get_default ())))
     {
       if (event->type == GDK_EXPOSE &&
 	  event->expose.window == _gdk_parent_root)
@@ -199,19 +200,28 @@
 }
 
 gboolean
-gdk_event_send_client_message (GdkEvent *event, guint32 xid)
+gdk_event_send_client_message_for_display (GdkDisplay *display,
+					   GdkEvent   *event,
+					   guint32     xid)
 {
   return FALSE;
 }
 
 void
-gdk_event_send_clientmessage_toall (GdkEvent *sev)
+gdk_screen_broadcast_client_message (GdkScreen *screen,
+				     GdkEvent  *sev)
 {
 }
 
 gboolean
-gdk_setting_get (const gchar *name,
-		 GValue      *value)
+gdk_screen_get_setting (GdkScreen   *screen,
+			const gchar *name,
+			GValue      *value)
 {
   return FALSE;
+}
+
+void
+gdk_display_sync (GdkDisplay *display)
+{
 }
Index: gdk/linux-fb/gdkfont-fb.c
===================================================================
RCS file: /cvs/gnome/gtk+/gdk/linux-fb/gdkfont-fb.c,v
retrieving revision 1.17
diff -u -r1.17 gdkfont-fb.c
--- gdk/linux-fb/gdkfont-fb.c	2001/11/24 21:52:50	1.17
+++ gdk/linux-fb/gdkfont-fb.c	2002/08/15 06:22:25
@@ -87,7 +87,8 @@
 }
 
 GdkFont*
-gdk_font_from_description (PangoFontDescription *desc)
+gdk_font_from_description_for_display (GdkDisplay           *display,
+				       PangoFontDescription *desc)
 {
   GdkFont *font;
   GdkFontPrivateFB *private;
@@ -154,7 +155,8 @@
 
 
 GdkFont*
-gdk_font_load (const gchar *font_name)
+gdk_font_load_for_display (GdkDisplay  *display,
+			   const gchar *font_name)
 {
   GdkFont *font;
   GdkFontPrivateFB *private;
Index: gdk/linux-fb/gdkglobals-fb.c
===================================================================
RCS file: /cvs/gnome/gtk+/gdk/linux-fb/gdkglobals-fb.c,v
retrieving revision 1.8
diff -u -r1.8 gdkglobals-fb.c
--- gdk/linux-fb/gdkglobals-fb.c	2001/09/07 21:49:54	1.8
+++ gdk/linux-fb/gdkglobals-fb.c	2002/08/15 06:22:25
@@ -35,6 +35,10 @@
 gboolean _gdk_fb_keyboard_grab_owner_events;
 GdkEventMask _gdk_fb_pointer_grab_events, _gdk_fb_keyboard_grab_events;
 
+GdkDisplay *_gdk_display = NULL;
+GdkScreen *_gdk_screen = NULL;
+GdkWindow *_gdk_parent_root = NULL;
+
 GdkFBWindow *gdk_root_window = NULL;
 GdkFBDisplay *gdk_display = NULL;
 GdkCursor *_gdk_fb_pointer_grab_cursor;
Index: gdk/linux-fb/gdkimage-fb.c
===================================================================
RCS file: /cvs/gnome/gtk+/gdk/linux-fb/gdkimage-fb.c,v
retrieving revision 1.17
diff -u -r1.17 gdkimage-fb.c
--- gdk/linux-fb/gdkimage-fb.c	2002/01/25 17:10:03	1.17
+++ gdk/linux-fb/gdkimage-fb.c	2002/08/15 06:22:25
@@ -105,7 +105,8 @@
 
 
 GdkImage*
-_gdk_image_new_for_depth (GdkImageType  type,
+_gdk_image_new_for_depth (GdkScreen    *screen,
+			  GdkImageType  type,
 			  GdkVisual    *visual,
 			  gint          width,
 			  gint          height,
@@ -171,15 +172,6 @@
 }
 
 GdkImage*
-gdk_image_new (GdkImageType  type,
-	       GdkVisual    *visual,
-	       gint          width,
-	       gint          height)
-{
-  return _gdk_image_new_for_depth (type, visual, width, height, -1);
-}
-
-GdkImage*
 _gdk_fb_copy_to_image (GdkDrawable    *drawable,
 		       GdkImage       *image,
 		       gint            src_x,
@@ -343,7 +335,8 @@
 
 /* copy/pasted from gdkimage-win32.c */
 gint
-_gdk_windowing_get_bits_for_depth (gint depth)
+_gdk_windowing_get_bits_for_depth (GdkDisplay *display,
+				   gint        depth)
 {
   if ((1 == depth) || (8 == depth) || (16 == depth) || 
       (24 == depth) || (32 == depth))
Index: gdk/linux-fb/gdkinputprivate.h
===================================================================
RCS file: /cvs/gnome/gtk+/gdk/linux-fb/gdkinputprivate.h,v
retrieving revision 1.7
diff -u -r1.7 gdkinputprivate.h
--- gdk/linux-fb/gdkinputprivate.h	2002/08/02 20:22:43	1.7
+++ gdk/linux-fb/gdkinputprivate.h	2002/08/15 06:22:25
@@ -126,6 +126,7 @@
 /* Global data */
 
 extern const GdkDevice gdk_input_core_info;
+extern GdkDevice *_gdk_core_pointer;
 extern GList *_gdk_input_devices;
 extern GList *_gdk_input_windows;
 
Index: gdk/linux-fb/gdkkeyboard-fb.c
===================================================================
RCS file: /cvs/gnome/gtk+/gdk/linux-fb/gdkkeyboard-fb.c,v
retrieving revision 1.15
diff -u -r1.15 gdkkeyboard-fb.c
--- gdk/linux-fb/gdkkeyboard-fb.c	2002/04/05 15:11:00	1.15
+++ gdk/linux-fb/gdkkeyboard-fb.c	2002/08/15 06:22:26
@@ -147,12 +147,18 @@
 };
 
 GdkKeymap*
-gdk_keymap_get_default (void)
+gdk_keymap_get_default_for_display (GdkDisplay *display)
 {
   if (default_keymap == NULL)
     default_keymap = g_object_new (gdk_keymap_get_type (), NULL);
 
   return default_keymap;
+}
+
+GdkKeymap*
+gdk_keymap_get_for_display (GdkDisplay *display)
+{
+  return gdk_keymap_get_default_for_display (display);
 }
 
 PangoDirection
Index: gdk/linux-fb/gdkmain-fb.c
===================================================================
RCS file: /cvs/gnome/gtk+/gdk/linux-fb/gdkmain-fb.c,v
retrieving revision 1.32
diff -u -r1.32 gdkmain-fb.c
--- gdk/linux-fb/gdkmain-fb.c	2002/03/21 00:41:43	1.32
+++ gdk/linux-fb/gdkmain-fb.c	2002/08/15 06:22:26
@@ -799,11 +799,11 @@
   g_free (display);
 }
 
-gboolean
-_gdk_windowing_init_check (int argc, char **argv)
+void
+_gdk_windowing_init (int *argc, char ***argv)
 {
   if (gdk_initialized)
-    return TRUE;
+    return;
 
   /* Create new session and become session leader */
   setsid();
@@ -811,7 +811,7 @@
   gdk_display = gdk_fb_display_new ();
 
   if (!gdk_display)
-    return FALSE;
+    return;
 
   gdk_shadow_fb_init ();
   
@@ -822,7 +822,7 @@
       g_warning ("Failed to initialize keyboard");
       gdk_fb_display_destroy (gdk_display);
       gdk_display = NULL;
-      return FALSE;
+      return;
     }
   
   if (!gdk_fb_mouse_init (!gdk_display->manager_blocked))
@@ -831,17 +831,44 @@
       gdk_fb_keyboard_close ();
       gdk_fb_display_destroy (gdk_display);
       gdk_display = NULL;
-      return FALSE;
+      return;
     }
 
   gdk_initialized = TRUE;
 
   _gdk_selection_property = gdk_atom_intern ("GDK_SELECTION", FALSE);
 
-  
-  return TRUE;
 }
 
+void
+_gdk_windowing_set_default_display (GdkDisplay *display)
+{
+}
+
+GdkDisplay *
+gdk_display_open (const gchar *display_name)
+{
+  if (_gdk_display != NULL)
+    return NULL; /* single display only */
+
+  _gdk_display = g_object_new (GDK_TYPE_DISPLAY, NULL);
+  _gdk_screen = g_object_new (GDK_TYPE_SCREEN, NULL);
+
+  _gdk_visual_init ();
+  gdk_screen_set_default_colormap (_gdk_screen,
+                                   gdk_screen_get_system_colormap (_gdk_screen));
+  _gdk_windowing_window_init ();
+  _gdk_windowing_image_init ();
+  _gdk_events_init ();
+  _gdk_input_init ();
+  _gdk_dnd_init ();
+
+  g_signal_emit_by_name (gdk_display_manager_get (),
+			 "display_opened", _gdk_display);
+
+  return _gdk_display;
+}
+
 /*
  *--------------------------------------------------------------
  * gdk_pointer_grab
@@ -933,7 +960,7 @@
 
 /*
  *--------------------------------------------------------------
- * gdk_pointer_ungrab
+ * gdk_display_pointer_ungrab
  *
  *   Releases any pointer grab
  *
@@ -947,7 +974,8 @@
  */
 
 void
-gdk_pointer_ungrab (guint32 time)
+gdk_display_pointer_ungrab (GdkDisplay *display,
+			    guint32     time)
 {
   gdk_fb_pointer_ungrab (time, FALSE);
 }
@@ -993,7 +1021,7 @@
 
 /*
  *--------------------------------------------------------------
- * gdk_pointer_is_grabbed
+ * gdk_display_pointer_is_grabbed
  *
  *   Tell wether there is an active x pointer grab in effect
  *
@@ -1007,7 +1035,7 @@
  */
 
 gint
-gdk_pointer_is_grabbed (void)
+gdk_display_pointer_is_grabbed (GdkDisplay *display)
 {
   return _gdk_fb_pointer_grab_window != NULL;
 }
@@ -1033,9 +1061,9 @@
  */
 
 GdkGrabStatus
-gdk_keyboard_grab (GdkWindow *	   window,
-		   gint		   owner_events,
-		   guint32	   time)
+gdk_keyboard_grab (GdkWindow  *window,
+		   gint        owner_events,
+		   guint32     time)
 {
   g_return_val_if_fail (window != NULL, 0);
   g_return_val_if_fail (GDK_IS_WINDOW (window), 0);
@@ -1051,7 +1079,7 @@
 
 /*
  *--------------------------------------------------------------
- * gdk_keyboard_ungrab
+ * gdk_display_keyboard_ungrab
  *
  *   Releases any keyboard grab
  *
@@ -1065,7 +1093,8 @@
  */
 
 void
-gdk_keyboard_ungrab (guint32 time)
+gdk_display_keyboard_ungrab (GdkDisplay *display,
+			     guint32     time)
 {
   if (_gdk_fb_keyboard_grab_window)
     gdk_window_unref (_gdk_fb_keyboard_grab_window);
@@ -1073,7 +1102,8 @@
 }
 
 gboolean
-gdk_pointer_grab_info_libgtk_only (GdkWindow **grab_window,
+gdk_pointer_grab_info_libgtk_only (GdkDisplay *display,
+				   GdkWindow **grab_window,
 				   gboolean   *owner_events)
 {
   if (_gdk_fb_pointer_grab_window)
@@ -1090,8 +1120,9 @@
 }
 
 gboolean
-gdk_keyboard_grab_info_libgtk_only (GdkWindow **grab_window,
-                                   gboolean   *owner_events)
+gdk_keyboard_grab_info_libgtk_only (GdkDisplay *display,
+				    GdkWindow **grab_window,
+				    gboolean   *owner_events)
 {
   if (_gdk_fb_keyboard_grab_window)
     {
@@ -1109,7 +1140,7 @@
 
 /*
  *--------------------------------------------------------------
- * gdk_screen_width
+ * gdk_screen_get_width
  *
  *   Return the width of the screen.
  *
@@ -1123,14 +1154,14 @@
  */
 
 gint
-gdk_screen_width (void)
+gdk_screen_get_width (GdkScreen *screen)
 {
   return gdk_display->fb_width;
 }
 
 /*
  *--------------------------------------------------------------
- * gdk_screen_height
+ * gdk_screen_get_height
  *
  *   Return the height of the screen.
  *
@@ -1144,14 +1175,14 @@
  */
 
 gint
-gdk_screen_height (void)
+gdk_screen_get_height (GdkScreen *screen)
 {
   return gdk_display->fb_height;
 }
 
 /*
  *--------------------------------------------------------------
- * gdk_screen_width_mm
+ * gdk_screen_get_width_mm
  *
  *   Return the width of the screen in millimeters.
  *
@@ -1165,14 +1196,14 @@
  */
 
 gint
-gdk_screen_width_mm (void)
+gdk_screen_get_width_mm (GdkScreen *screen)
 {
   return 0.5 + gdk_screen_width () * (25.4 / 72.);
 }
 
 /*
  *--------------------------------------------------------------
- * gdk_screen_height
+ * gdk_screen_get_height_mm
  *
  *   Return the height of the screen in millimeters.
  *
@@ -1186,14 +1217,14 @@
  */
 
 gint
-gdk_screen_height_mm (void)
+gdk_screen_get_height_mm (GdkScreen *screen)
 {
   return 0.5 + gdk_screen_height () * (25.4 / 72.);
 }
 
 /*
  *--------------------------------------------------------------
- * gdk_set_sm_client_id
+ * gdk_display_set_sm_client_id
  *
  *   Set the SM_CLIENT_ID property on the WM_CLIENT_LEADER window
  *   so that the window manager can save our state using the
@@ -1214,10 +1245,21 @@
  */
 
 void
-gdk_set_sm_client_id (const gchar* sm_client_id)
+gdk_display_set_sm_client_id (GdkDisplay*  display,
+			      const gchar* sm_client_id)
 {
 }
 
+void
+gdk_screen_get_monitor_geometry (GdkScreen    *screen, 
+				 gint          num_monitor,
+				 GdkRectangle *dest)
+{
+  dest->x = 0;
+  dest->y = 0;
+  dest->width = gdk_screen_width ();
+  dest->height = gdk_screen_height ();
+}
 
 extern void keyboard_shutdown(void);
 
@@ -1260,9 +1302,53 @@
   return g_strdup (s);
 }
 
+GdkDisplay *
+gdk_screen_get_display (GdkScreen *screen)
+{
+  return _gdk_display;
+}
+
+GdkScreen *
+gdk_display_get_screen (GdkDisplay *display,
+			gint        screen_num)
+{
+  return _gdk_screen;
+}
+
+GdkScreen *
+gdk_display_get_default_screen (GdkDisplay *display)
+{
+  return _gdk_screen;
+}
+
+int
+gdk_display_get_n_screens (GdkDisplay *display)
+{
+  return 1;
+}
+
+G_CONST_RETURN gchar *
+gdk_display_get_name (GdkDisplay *display)
+{
+  return gdk_get_display_arg_name ();
+}
+
+int
+gdk_screen_get_n_monitors (GdkScreen *screen)
+{
+  return 1;
+}
+
+gint
+gdk_screen_get_number (GdkScreen *screen)
+{
+  g_return_val_if_fail (GDK_IS_SCREEN (screen), 0);  
+  
+  return 0;
+}
 
 void
-gdk_beep (void)
+gdk_display_beep (GdkDisplay *display)
 {
   static int pitch = 600, duration = 100;
   gulong arg;
@@ -1523,7 +1609,7 @@
     }
   
   if (append_to_queue)
-    _gdk_event_queue_append (event);
+    _gdk_event_queue_append (gdk_display_get_default (), event);
   
   return event;
 }
Index: gdk/linux-fb/gdkmouse-fb.c
===================================================================
RCS file: /cvs/gnome/gtk+/gdk/linux-fb/gdkmouse-fb.c,v
retrieving revision 1.10
diff -u -r1.10 gdkmouse-fb.c
--- gdk/linux-fb/gdkmouse-fb.c	2002/03/22 16:06:05	1.10
+++ gdk/linux-fb/gdkmouse-fb.c	2002/08/15 06:22:27
@@ -20,6 +20,7 @@
 #include <gdk/gdk.h>
 #include <gdk/gdkinternals.h>
 #include "gdkprivate-fb.h"
+#include "gdkinputprivate.h"
 #include <stdlib.h>
 #include <sys/types.h>
 #include <fcntl.h>
@@ -183,11 +184,11 @@
       event->button.x_root = mouse->x;
       event->button.y_root = mouse->y;
       
-      _gdk_event_queue_append (event);
+      _gdk_event_queue_append (gdk_display_get_default (), event);
       
       /* For double-clicks */
       if (press_event)
-	_gdk_event_button_generate (event);
+	_gdk_event_button_generate (gdk_display_get_default (), event);
     }
 
   nbuttons = 0;
Index: gdk/linux-fb/gdkpango-fb.c
===================================================================
RCS file: /cvs/gnome/gtk+/gdk/linux-fb/gdkpango-fb.c,v
retrieving revision 1.18
diff -u -r1.18 gdkpango-fb.c
--- gdk/linux-fb/gdkpango-fb.c	2001/11/24 21:52:50	1.18
+++ gdk/linux-fb/gdkpango-fb.c	2002/08/15 06:22:27
@@ -5,7 +5,7 @@
 #include <pango/pangoft2.h>
 
 PangoContext *
-gdk_pango_context_get (void)
+gdk_pango_context_get_for_screen (GdkScreen *screen)
 {
   return pango_ft2_get_context (75.0, 75.0);
 }
Index: gdk/linux-fb/gdkprivate-fb.h
===================================================================
RCS file: /cvs/gnome/gtk+/gdk/linux-fb/gdkprivate-fb.h,v
retrieving revision 1.32
diff -u -r1.32 gdkprivate-fb.h
--- gdk/linux-fb/gdkprivate-fb.h	2002/01/25 17:10:03	1.32
+++ gdk/linux-fb/gdkprivate-fb.h	2002/08/15 06:22:27
@@ -426,6 +426,8 @@
 extern gboolean _gdk_fb_keyboard_grab_owner_events;
 
 extern GdkFBDisplay *gdk_display;
+extern GdkDisplay *_gdk_display;
+extern GdkScreen *_gdk_screen;
 extern FILE *debug_out;
 GdkEvent *gdk_event_make(GdkWindow *window,
 			 GdkEventType type,
Index: gdk/linux-fb/gdkselection-fb.c
===================================================================
RCS file: /cvs/gnome/gtk+/gdk/linux-fb/gdkselection-fb.c,v
retrieving revision 1.8
diff -u -r1.8 gdkselection-fb.c
--- gdk/linux-fb/gdkselection-fb.c	2001/09/08 00:30:13	1.8
+++ gdk/linux-fb/gdkselection-fb.c	2002/08/15 06:22:27
@@ -65,10 +65,11 @@
 }
 
 gint
-gdk_selection_owner_set (GdkWindow *owner,
-			 GdkAtom    selection,
-			 guint32    time,
-			 gint       send_event)
+gdk_selection_owner_set_for_display (GdkDisplay *display,
+				     GdkWindow  *owner,
+				     GdkAtom     selection,
+				     guint32     time,
+				     gint        send_event)
 {
   GSList *tmp_list;
   OwnerInfo *info;
@@ -99,7 +100,8 @@
 }
 
 GdkWindow*
-gdk_selection_owner_get (GdkAtom selection)
+gdk_selection_owner_get_for_display (GdkDisplay *display,
+				     GdkAtom     selection)
 {
   OwnerInfo *info;
   GSList *tmp_list;
@@ -204,11 +206,12 @@
 
 
 void
-gdk_selection_send_notify (guint32  requestor,
-			   GdkAtom  selection,
-			   GdkAtom  target,
-			   GdkAtom  property,
-			   guint32  time)
+gdk_selection_send_notify_for_display (GdkDisplay *display,
+				       guint32     requestor,
+				       GdkAtom     selection,
+				       GdkAtom     target,
+				       GdkAtom     property,
+				       guint32     time)
 {
   GdkEvent *event;
   GdkWindow *event_window;
@@ -225,9 +228,12 @@
 }
 
 gint
-gdk_text_property_to_text_list (GdkAtom encoding, gint format, 
-				const guchar *text, gint length,
-				gchar ***list)
+gdk_text_property_to_text_list_for_display (GdkDisplay   *display,
+					    GdkAtom       encoding,
+					    gint          format, 
+					    const guchar *text,
+					    gint          length,
+					    gchar      ***list)
 {
   g_warning ("gdk_text_property_to_text_list() not implemented\n");
   return 0;
@@ -241,9 +247,12 @@
 }
 
 gint
-gdk_string_to_compound_text (const gchar *str,
-			     GdkAtom *encoding, gint *format,
-			     guchar **ctext, gint *length)
+gdk_string_to_compound_text_for_display (GdkDisplay  *display,
+					 const gchar *str,
+					 GdkAtom     *encoding,
+					 gint        *format,
+					 guchar     **ctext,
+					 gint        *length)
 {
   g_warning ("gdk_string_to_compound_text() not implemented\n");
   return 0;
@@ -275,7 +284,7 @@
 }
 
 /**
- * gdk_utf8_to_compound_text:
+ * gdk_utf8_to_compound_text_for_display:
  * @str:      a UTF-8 string
  * @encoding: location to store resulting encoding
  * @format:   location to store format of the result
@@ -289,11 +298,12 @@
  *               false.
  **/
 gboolean
-gdk_utf8_to_compound_text (const gchar *str,
-			   GdkAtom     *encoding,
-			   gint        *format,
-			   guchar     **ctext,
-			   gint        *length)
+gdk_utf8_to_compound_text_for_display (GdkDisplay  *display,
+				       const gchar *str,
+				       GdkAtom     *encoding,
+				       gint        *format,
+				       guchar     **ctext,
+				       gint        *length)
 {
   g_warning ("gdk_utf8_to_compound_text() not implemented\n");
   return 0;
@@ -370,7 +380,7 @@
 
 
 /**
- * gdk_text_property_to_utf8_list:
+ * gdk_text_property_to_utf8_list_for_display:
  * @encoding: an atom representing the encoding of the text
  * @format:   the format of the property
  * @text:     the text to convert
@@ -385,11 +395,12 @@
  *               list.
  **/
 gint 
-gdk_text_property_to_utf8_list (GdkAtom        encoding,
-				gint           format,
-				const guchar  *text,
-				gint           length,
-				gchar       ***list)
+gdk_text_property_to_utf8_list_for_display (GdkDisplay    *display,
+					    GdkAtom        encoding,
+					    gint           format,
+					    const guchar  *text,
+					    gint           length,
+					    gchar       ***list)
 {
   g_return_val_if_fail (text != NULL, 0);
   g_return_val_if_fail (length >= 0, 0);
Index: gdk/linux-fb/gdkvisual-fb.c
===================================================================
RCS file: /cvs/gnome/gtk+/gdk/linux-fb/gdkvisual-fb.c,v
retrieving revision 1.8
diff -u -r1.8 gdkvisual-fb.c
--- gdk/linux-fb/gdkvisual-fb.c	2001/09/07 21:49:54	1.8
+++ gdk/linux-fb/gdkvisual-fb.c	2002/08/15 06:22:27
@@ -155,7 +155,7 @@
 }
 
 GdkVisual*
-gdk_visual_get_system (void)
+gdk_screen_get_system_visual (GdkScreen *screen)
 {
   return system_visual;
 }
@@ -214,7 +214,15 @@
 }
 
 GList*
-gdk_list_visuals (void)
+gdk_screen_list_visuals (GdkScreen *screen)
 {
   return g_list_append (NULL, gdk_visual_get_system ());
+}
+
+GdkScreen *
+gdk_visual_get_screen (GdkVisual *visual)
+{
+  g_return_val_if_fail (GDK_IS_VISUAL (visual), NULL);
+
+  return gdk_screen_get_default ();
 }
Index: gdk/linux-fb/gdkwindow-fb.c
===================================================================
RCS file: /cvs/gnome/gtk+/gdk/linux-fb/gdkwindow-fb.c,v
retrieving revision 1.45
diff -u -r1.45 gdkwindow-fb.c
--- gdk/linux-fb/gdkwindow-fb.c	2002/05/14 19:45:07	1.45
+++ gdk/linux-fb/gdkwindow-fb.c	2002/08/15 06:22:28
@@ -2252,7 +2252,8 @@
 }
 
 GdkWindow*
-gdk_window_foreign_new (GdkNativeWindow anid)
+gdk_window_foreign_new_for_display (GdkDisplay      *display,
+				    GdkNativeWindow  anid)
 {
   return (GdkWindow*) gdk_drawable_ref (anid);
 }
@@ -2263,3 +2264,16 @@
   return (GdkWindow*) (anid);
 }
 
+GdkWindow *
+gdk_window_lookup_for_display (GdkDisplay *display, GdkNativeWindow anid)
+{
+  g_return_val_if_fail (display == gdk_display_get_default(), NULL);
+
+  return (GdkWindow*) (anid);
+}
+
+GdkWindow *
+gdk_screen_get_root_window (GdkScreen *screen)
+{
+  return _gdk_parent_root;
+}
