From 4041ca0f69e227400a6a2547326d7b8f1e162ed5 Mon Sep 17 00:00:00 2001 From: Carlos Garnacho Date: Tue, 3 Jan 2023 14:02:53 +0100 Subject: [PATCH] gdkdisplay: Deprecate gdk_display_notify_startup_complete() We have various layers where we store the startup ID for a request, since this API does not have a GdkToplevel that we can refer about for the Wayland platform, this is the most obvious candidate to start untangling these various layers. Deprecate this call, it is already unused in the gtk/ side. --- gdk/gdkdisplay.c | 2 ++ gdk/gdkdisplay.h | 2 +- gtk/gtkwindow.c | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/gdk/gdkdisplay.c b/gdk/gdkdisplay.c index a1caff68eb..ef158e45b8 100644 --- a/gdk/gdkdisplay.c +++ b/gdk/gdkdisplay.c @@ -1148,6 +1148,8 @@ _gdk_display_get_next_serial (GdkDisplay *display) * with custom startup-notification identifier unless * [method@Gtk.Window.set_auto_startup_notification] * is called to disable that feature. + * + * Deprecated: 4.10. Using gdk_toplevel_set_startup_id() is sufficient. */ void gdk_display_notify_startup_complete (GdkDisplay *display, diff --git a/gdk/gdkdisplay.h b/gdk/gdkdisplay.h index c3b1c49469..0a07221dc1 100644 --- a/gdk/gdkdisplay.h +++ b/gdk/gdkdisplay.h @@ -83,7 +83,7 @@ GdkClipboard * gdk_display_get_clipboard (GdkDisplay GDK_AVAILABLE_IN_ALL GdkClipboard * gdk_display_get_primary_clipboard (GdkDisplay *display); -GDK_AVAILABLE_IN_ALL +GDK_DEPRECATED_IN_4_10_FOR(gdk_toplevel_set_startup_id) void gdk_display_notify_startup_complete (GdkDisplay *display, const char *startup_id); GDK_AVAILABLE_IN_ALL diff --git a/gtk/gtkwindow.c b/gtk/gtkwindow.c index fc7f22cdb4..d5cb7cc121 100644 --- a/gtk/gtkwindow.c +++ b/gtk/gtkwindow.c @@ -5896,7 +5896,7 @@ _gtk_window_set_is_active (GtkWindow *window, * Sets whether the window should request startup notification. * * By default, after showing the first `GtkWindow`, GTK calls - * [method@Gdk.Display.notify_startup_complete]. Call this function + * [method@Gdk.Toplevel.set_startup_id]. Call this function * to disable the automatic startup notification. You might do this * if your first window is a splash screen, and you want to delay * notification until after your real main window has been shown, -- 2.30.2