diff --git a/docs/reference/gtk/gtk4-sections.txt b/docs/reference/gtk/gtk4-sections.txt index 658504401e..b4ef5fabf8 100644 --- a/docs/reference/gtk/gtk4-sections.txt +++ b/docs/reference/gtk/gtk4-sections.txt @@ -4456,7 +4456,6 @@ gtk_widget_get_toplevel gtk_widget_get_ancestor gtk_widget_is_ancestor gtk_widget_translate_coordinates -gtk_widget_hide_on_delete gtk_widget_set_direction GtkTextDirection gtk_widget_get_direction diff --git a/gtk/gtkwidget.c b/gtk/gtkwidget.c index 8aa7c4b1ba..776ba0bef5 100644 --- a/gtk/gtkwidget.c +++ b/gtk/gtkwidget.c @@ -3783,30 +3783,6 @@ gtk_widget_real_hide (GtkWidget *widget) } } -/** - * gtk_widget_hide_on_delete: - * @widget: a #GtkWidget - * - * Utility function; intended to be connected to the #GtkWidget::delete-event - * signal on a #GtkWindow. The function calls gtk_widget_hide() on its - * argument, then returns %TRUE. If connected to ::delete-event, the - * result is that clicking the close button for a window (on the - * window frame, top right corner usually) will hide but not destroy - * the window. By default, GTK+ destroys windows when ::delete-event - * is received. - * - * Returns: %TRUE - **/ -gboolean -gtk_widget_hide_on_delete (GtkWidget *widget) -{ - g_return_val_if_fail (GTK_IS_WIDGET (widget), FALSE); - - gtk_widget_hide (widget); - - return TRUE; -} - static void update_cursor_on_state_change (GtkWidget *widget) { diff --git a/gtk/gtkwidget.h b/gtk/gtkwidget.h index d995077c64..150662a3e0 100644 --- a/gtk/gtkwidget.h +++ b/gtk/gtkwidget.h @@ -811,10 +811,6 @@ GDK_AVAILABLE_IN_3_94 GtkWidget * gtk_widget_pick (GtkWidget *widget, gdouble x, gdouble y); -/* Hide widget and return TRUE. - */ -GDK_AVAILABLE_IN_ALL -gboolean gtk_widget_hide_on_delete (GtkWidget *widget); GDK_AVAILABLE_IN_ALL void gtk_widget_reset_style (GtkWidget *widget);