Deprecate gdk_display_put_event

The documentation already tells you not to
use this function.

Ifdef the remaining users in the X11 backend.
This commit is contained in:
Matthias Clasen 2023-01-09 15:29:24 -05:00
parent f59b506674
commit 0073bb79a7
4 changed files with 9 additions and 3 deletions

View File

@ -471,8 +471,8 @@ gdk_display_get_event (GdkDisplay *display)
* Appends the given event onto the front of the event
* queue for @display.
*
* This function is only useful in very special situations
* and should not be used by applications.
* Deprecated: 4.10: This function is only useful in very
* special situations and should not be used by applications.
**/
void
gdk_display_put_event (GdkDisplay *display,

View File

@ -104,7 +104,7 @@ GDK_AVAILABLE_IN_ALL
GdkMonitor * gdk_display_get_monitor_at_surface (GdkDisplay *display,
GdkSurface *surface);
GDK_AVAILABLE_IN_ALL
GDK_DEPRECATED_IN_4_10
void gdk_display_put_event (GdkDisplay *display,
GdkEvent *event);

View File

@ -1450,7 +1450,9 @@ _gdk_device_manager_xi2_handle_focus (GdkSurface *surface,
GdkEvent *event;
event = gdk_focus_event_new (surface, device, focus_in);
G_GNUC_BEGIN_IGNORE_DEPRECATIONS
gdk_display_put_event (gdk_surface_get_display (surface), event);
G_GNUC_END_IGNORE_DEPRECATIONS
gdk_event_unref (event);
}
}

View File

@ -119,7 +119,9 @@ handle_focus_change (GdkEvent *event)
focus_event = gdk_focus_event_new (gdk_event_get_surface (event),
gdk_event_get_device (event),
focus_in);
G_GNUC_BEGIN_IGNORE_DEPRECATIONS
gdk_display_put_event (gdk_event_get_display (event), focus_event);
G_GNUC_END_IGNORE_DEPRECATIONS
gdk_event_unref (focus_event);
}
}
@ -206,7 +208,9 @@ handle_touch_synthetic_crossing (GdkEvent *event)
if (crossing)
{
G_GNUC_BEGIN_IGNORE_DEPRECATIONS
gdk_display_put_event (gdk_seat_get_display (seat), crossing);
G_GNUC_END_IGNORE_DEPRECATIONS
gdk_event_unref (crossing);
}
}