Index: gdk/gdk.h
===================================================================
RCS file: /cvs/gnome/gtk+/gdk/gdk.h,v
retrieving revision 1.105
diff -p -u -r1.105 gdk.h
--- gdk/gdk.h	28 Nov 2004 06:45:52 -0000	1.105
+++ gdk/gdk.h	19 Feb 2005 22:22:20 -0000
@@ -177,6 +177,9 @@ gboolean gdk_event_send_client_message_f
 						    GdkNativeWindow winid);
 
 void gdk_notify_startup_complete (void);
+#ifdef GDK_WINDOWING_X11
+guint32 gdk_x11_get_user_time_libgtk_only (GdkDisplay *display);
+#endif
 
 /* Threading
  */
Index: gdk/x11/gdkdisplay-x11.c
===================================================================
RCS file: /cvs/gnome/gtk+/gdk/x11/gdkdisplay-x11.c,v
retrieving revision 1.51.2.4
diff -p -u -r1.51.2.4 gdkdisplay-x11.c
--- gdk/x11/gdkdisplay-x11.c	1 Feb 2005 18:07:39 -0000	1.51.2.4
+++ gdk/x11/gdkdisplay-x11.c	19 Feb 2005 22:22:20 -0000
@@ -1184,3 +1184,19 @@ gdk_display_store_clipboard (GdkDisplay 
   gdk_error_trap_pop ();
 
 }
+
+/**
+ * gdk_x11_get_user_time_libgtk_only
+ * @display: a #GdkDisplay
+ *
+ * Returns the timestamp of the last user interaction on 
+ * @display. The timestamp is taken from events caused
+ * by user interaction such as key presses or pointer 
+ * movements. See gdk_x11_window_set_user_time().
+ */
+guint32
+gdk_x11_get_user_time_libgtk_only (GdkDisplay *display)
+{
+  return GDK_DISPLAY_X11 (display)->user_time;
+}
+
Index: gtk/gtkwindow.c
===================================================================
RCS file: /cvs/gnome/gtk+/gtk/gtkwindow.c,v
retrieving revision 1.281.2.2
diff -p -u -r1.281.2.2 gtkwindow.c
--- gtk/gtkwindow.c	2 Feb 2005 03:54:07 -0000	1.281.2.2
+++ gtk/gtkwindow.c	19 Feb 2005 22:22:22 -0000
@@ -5932,8 +5932,13 @@ gtk_window_present (GtkWindow *window)
       /* note that gdk_window_focus() will also move the window to
        * the current desktop, for WM spec compliant window managers.
        */
+#ifdef GDK_WINDOWING_X11
+      gdk_window_focus (widget->window,
+                        gdk_x11_get_user_time_libgtk_only (gtk_widget_get_display (widget)));
+#else
       gdk_window_focus (widget->window,
                         gtk_get_current_event_time ());
+#endif
     }
   else
     {
