Commit 7df070d6 authored by Matthias Clasen's avatar Matthias Clasen
Browse files

gdk: Move default group api to the X11 backend

This is the only place where it is implemented.
parent 9722bb4d
......@@ -81,7 +81,6 @@ gdk_display_close
gdk_display_is_closed
gdk_display_is_rgba
gdk_display_is_composited
gdk_display_get_default_group
gdk_display_supports_input_shapes
gdk_display_get_app_launch_context
gdk_display_notify_startup_complete
......@@ -819,6 +818,7 @@ gdk_x11_display_get_xrootwindow
gdk_x11_display_get_xcursor
gdk_x11_display_grab
gdk_x11_display_ungrab
gdk_x11_display_get_default_group
gdk_x11_display_error_trap_push
gdk_x11_display_error_trap_pop
gdk_x11_display_error_trap_pop_ignored
......
......@@ -265,14 +265,6 @@ gdk_broadway_display_has_pending (GdkDisplay *display)
return FALSE;
}
static GdkSurface *
gdk_broadway_display_get_default_group (GdkDisplay *display)
{
g_return_val_if_fail (GDK_IS_DISPLAY (display), NULL);
return NULL;
}
static void
gdk_broadway_display_dispose (GObject *object)
{
......@@ -441,7 +433,6 @@ gdk_broadway_display_class_init (GdkBroadwayDisplayClass * class)
display_class->flush = gdk_broadway_display_flush;
display_class->has_pending = gdk_broadway_display_has_pending;
display_class->queue_events = _gdk_broadway_display_queue_events;
display_class->get_default_group = gdk_broadway_display_get_default_group;
display_class->get_next_serial = gdk_broadway_display_get_next_serial;
display_class->notify_startup_complete = gdk_broadway_display_notify_startup_complete;
......
......@@ -994,25 +994,6 @@ gdk_display_flush (GdkDisplay *display)
GDK_DISPLAY_GET_CLASS (display)->flush (display);
}
/**
* gdk_display_get_default_group:
* @display: a #GdkDisplay
*
* Returns the default group leader surface for all toplevel surfaces
* on @display. This surface is implicitly created by GDK.
* See gdk_surface_set_group().
*
* Returns: (transfer none): The default group leader surface
* for @display
**/
GdkSurface *
gdk_display_get_default_group (GdkDisplay *display)
{
g_return_val_if_fail (GDK_IS_DISPLAY (display), NULL);
return GDK_DISPLAY_GET_CLASS (display)->get_default_group (display);
}
/**
* gdk_display_get_clipboard:
* @display: a #GdkDisplay
......
......@@ -71,9 +71,6 @@ gboolean gdk_display_supports_input_shapes (GdkDisplay *display);
GDK_AVAILABLE_IN_ALL
GdkDisplay *gdk_display_get_default (void);
GDK_AVAILABLE_IN_ALL
GdkSurface *gdk_display_get_default_group (GdkDisplay *display);
GDK_AVAILABLE_IN_ALL
GdkClipboard * gdk_display_get_clipboard (GdkDisplay *display);
GDK_AVAILABLE_IN_ALL
......
......@@ -123,7 +123,6 @@ struct _GdkDisplayClass
gboolean (*has_pending) (GdkDisplay *display);
void (*queue_events) (GdkDisplay *display);
void (*make_default) (GdkDisplay *display);
GdkSurface * (*get_default_group) (GdkDisplay *display);
GdkAppLaunchContext * (*get_app_launch_context) (GdkDisplay *display);
......
......@@ -846,14 +846,6 @@ gdk_wayland_display_has_pending (GdkDisplay *display)
return FALSE;
}
static GdkSurface *
gdk_wayland_display_get_default_group (GdkDisplay *display)
{
g_return_val_if_fail (GDK_IS_DISPLAY (display), NULL);
return NULL;
}
static gulong
gdk_wayland_display_get_next_serial (GdkDisplay *display)
{
......@@ -1012,7 +1004,6 @@ gdk_wayland_display_class_init (GdkWaylandDisplayClass *class)
display_class->make_default = gdk_wayland_display_make_default;
display_class->has_pending = gdk_wayland_display_has_pending;
display_class->queue_events = _gdk_wayland_display_queue_events;
display_class->get_default_group = gdk_wayland_display_get_default_group;
display_class->get_app_launch_context = _gdk_wayland_display_get_app_launch_context;
display_class->get_next_serial = gdk_wayland_display_get_next_serial;
display_class->get_startup_notification_id = gdk_wayland_display_get_startup_notification_id;
......
......@@ -612,16 +612,6 @@ gdk_win32_display_get_name (GdkDisplay *display)
return display_name_cache;
}
static GdkSurface *
gdk_win32_display_get_default_group (GdkDisplay *display)
{
g_return_val_if_fail (GDK_IS_DISPLAY (display), NULL);
g_warning ("gdk_display_get_default_group not yet implemented");
return NULL;
}
static void
gdk_win32_display_beep (GdkDisplay *display)
{
......@@ -1061,7 +1051,6 @@ gdk_win32_display_class_init (GdkWin32DisplayClass *klass)
display_class->flush = gdk_win32_display_flush;
display_class->has_pending = _gdk_win32_display_has_pending;
display_class->queue_events = _gdk_win32_display_queue_events;
display_class->get_default_group = gdk_win32_display_get_default_group;
//? display_class->get_app_launch_context = _gdk_win32_display_get_app_launch_context;
......
......@@ -1829,7 +1829,18 @@ gdk_x11_display_has_pending (GdkDisplay *display)
return XPending (GDK_DISPLAY_XDISPLAY (display));
}
static GdkSurface *
/**
* gdk_x11_display_get_default_group:
* @display: a #GdkDisplay
*
* Returns the default group leader surface for all toplevel surfaces
* on @display. This surface is implicitly created by GDK.
* See gdk_surface_set_group().
*
* Returns: (transfer none): The default group leader surface
* for @display
*/
GdkSurface *
gdk_x11_display_get_default_group (GdkDisplay *display)
{
g_return_val_if_fail (GDK_IS_DISPLAY (display), NULL);
......@@ -2937,7 +2948,6 @@ gdk_x11_display_class_init (GdkX11DisplayClass * class)
display_class->make_default = gdk_x11_display_make_default;
display_class->has_pending = gdk_x11_display_has_pending;
display_class->queue_events = _gdk_x11_display_queue_events;
display_class->get_default_group = gdk_x11_display_get_default_group;
display_class->get_app_launch_context = _gdk_x11_display_get_app_launch_context;
display_class->get_next_serial = gdk_x11_display_get_next_serial;
......
......@@ -3392,7 +3392,7 @@ gdk_x11_surface_set_group (GdkSurface *surface,
toplevel = _gdk_x11_surface_get_toplevel (surface);
if (leader == NULL)
leader = gdk_display_get_default_group (gdk_surface_get_display (surface));
leader = gdk_x11_display_get_default_group (gdk_surface_get_display (surface));
if (toplevel->group_leader != leader)
{
......
......@@ -128,6 +128,9 @@ void gdk_x11_display_error_trap_pop_ignored (GdkDispla
GDK_AVAILABLE_IN_ALL
void gdk_x11_set_sm_client_id (const char *sm_client_id);
GDK_AVAILABLE_IN_ALL
GdkSurface * gdk_x11_display_get_default_group (GdkDisplay *display);
G_END_DECLS
#endif /* __GDK_X11_DISPLAY_H__ */
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