Drop gtk_widget_hide_on_delete

This function is misnamed - it is only ever relevant for
windows. And with the ::hide-on-delete property , it is
no longer necessary to use the signal for this simple case.
This commit is contained in:
Matthias Clasen 2018-01-02 21:58:46 -05:00
parent 2b59917a9d
commit 5759bc59c9
3 changed files with 0 additions and 29 deletions

View File

@ -4456,7 +4456,6 @@ gtk_widget_get_toplevel
gtk_widget_get_ancestor gtk_widget_get_ancestor
gtk_widget_is_ancestor gtk_widget_is_ancestor
gtk_widget_translate_coordinates gtk_widget_translate_coordinates
gtk_widget_hide_on_delete
gtk_widget_set_direction gtk_widget_set_direction
GtkTextDirection GtkTextDirection
gtk_widget_get_direction gtk_widget_get_direction

View File

@ -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 static void
update_cursor_on_state_change (GtkWidget *widget) update_cursor_on_state_change (GtkWidget *widget)
{ {

View File

@ -811,10 +811,6 @@ GDK_AVAILABLE_IN_3_94
GtkWidget * gtk_widget_pick (GtkWidget *widget, GtkWidget * gtk_widget_pick (GtkWidget *widget,
gdouble x, gdouble x,
gdouble y); gdouble y);
/* Hide widget and return TRUE.
*/
GDK_AVAILABLE_IN_ALL
gboolean gtk_widget_hide_on_delete (GtkWidget *widget);
GDK_AVAILABLE_IN_ALL GDK_AVAILABLE_IN_ALL
void gtk_widget_reset_style (GtkWidget *widget); void gtk_widget_reset_style (GtkWidget *widget);