Commit aefa1ba6 authored by Robert Ancell's avatar Robert Ancell

gdk: Deprecate gdk_display_get_screen

parent db04c1ed
......@@ -171,7 +171,7 @@ query_change_display (ChangeDisplayInfo *info)
"to move to the new screen");
if (toplevel)
gtk_window_set_screen (GTK_WINDOW (toplevel), gdk_display_get_screen (info->current_display, 0));
gtk_window_set_screen (GTK_WINDOW (toplevel), gdk_display_get_default_screen (info->current_display));
else
gdk_display_beep (gdk_screen_get_display (screen));
}
......
......@@ -1501,6 +1501,7 @@ gdk_display_get_n_screens (GdkDisplay *display)
* Returns: (transfer none): the #GdkScreen object
*
* Since: 2.2
* Deprecated: 3.20: There is only one screen; use gdk_display_get_default_screen() to get it.
*/
GdkScreen *
gdk_display_get_screen (GdkDisplay *display,
......
......@@ -54,7 +54,7 @@ send_event (GdkWindow *window, GdkDevice *device, GdkEvent *event)
gdk_event_set_device (event, device);
gdk_event_set_source_device (event, device);
gdk_event_set_screen (event, gdk_display_get_screen (gdk_window_get_display (window), 0));
gdk_event_set_screen (event, gdk_display_get_default_screen (gdk_window_get_display (window)));
event->any.window = g_object_ref (window);
display = gdk_window_get_display (window);
......
......@@ -282,7 +282,7 @@ send_event (GdkWindow *window, GdkDevice *device, GdkEvent *event)
gdk_event_set_device (event, device);
gdk_event_set_source_device (event, device);
gdk_event_set_screen (event, gdk_display_get_screen (gdk_window_get_display (window), 0));
gdk_event_set_screen (event, gdk_display_get_default_screen (display));
event->any.window = g_object_ref (window);
display = gdk_window_get_display (window);
......
......@@ -472,7 +472,7 @@ gdk_x11_device_core_window_at_position (GdkDevice *device,
/* FIXME: untrusted clients case not multidevice-safe */
pointer_window = None;
screen = gdk_display_get_screen (display, 0);
screen = gdk_display_get_default_screen (display);
toplevels = gdk_screen_get_toplevel_windows (screen);
for (list = toplevels; list != NULL; list = list->next)
{
......
......@@ -542,7 +542,7 @@ gdk_x11_device_xi2_window_at_position (GdkDevice *device,
/* FIXME: untrusted clients case not multidevice-safe */
pointer_window = None;
screen = gdk_display_get_screen (display, 0);
screen = gdk_display_get_default_screen (display);
toplevels = gdk_screen_get_toplevel_windows (screen);
for (list = toplevels; list != NULL; list = list->next)
{
......
......@@ -464,7 +464,7 @@ display_closed_cb (GdkDisplay *display,
GdkScreen *screen;
GtkSettings *settings;
screen = gdk_display_get_screen (display, 0);
screen = gdk_display_get_default_screen (display);
settings = gtk_settings_get_for_screen (screen);
g_object_set_data_full (G_OBJECT (settings),
......@@ -494,7 +494,7 @@ display_opened_cb (GdkDisplayManager *display_manager,
}
g_value_init (&value, G_TYPE_STRING);
screen = gdk_display_get_screen (display, 0);
screen = gdk_display_get_default_screen (display);
if (gdk_screen_get_setting (screen, "gtk-modules", &value))
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment