button: Remove _{get,set}_focus_click

Deprecated for the GtkWidget variant. Also remove some unused fields
from the GtkButtonPrivate struct.
This commit is contained in:
Timm Bäder
2016-10-02 19:54:37 +02:00
committed by Benjamin Otte
parent 10a92a210b
commit 10e24d58c3
3 changed files with 0 additions and 55 deletions

View File

@@ -1704,51 +1704,6 @@ gtk_button_get_use_underline (GtkButton *button)
return button->priv->use_underline;
}
/**
* gtk_button_set_focus_on_click:
* @button: a #GtkButton
* @focus_on_click: whether the button grabs focus when clicked with the mouse
*
* Sets whether the button will grab focus when it is clicked with the mouse.
* Making mouse clicks not grab focus is useful in places like toolbars where
* you dont want the keyboard focus removed from the main area of the
* application.
*
* Since: 2.4
*
* Deprecated: 3.20: Use gtk_widget_set_focus_on_click() instead
*/
void
gtk_button_set_focus_on_click (GtkButton *button,
gboolean focus_on_click)
{
g_return_if_fail (GTK_IS_BUTTON (button));
gtk_widget_set_focus_on_click (GTK_WIDGET (button), focus_on_click);
}
/**
* gtk_button_get_focus_on_click:
* @button: a #GtkButton
*
* Returns whether the button grabs focus when it is clicked with the mouse.
* See gtk_button_set_focus_on_click().
*
* Returns: %TRUE if the button grabs focus when it is clicked with
* the mouse.
*
* Since: 2.4
*
* Deprecated: 3.20: Use gtk_widget_get_focus_on_click() instead
*/
gboolean
gtk_button_get_focus_on_click (GtkButton *button)
{
g_return_val_if_fail (GTK_IS_BUTTON (button), FALSE);
return gtk_widget_get_focus_on_click (GTK_WIDGET (button));
}
static void
gtk_button_update_state (GtkButton *button)
{

View File

@@ -111,11 +111,6 @@ void gtk_button_set_use_underline (GtkButton *button,
gboolean use_underline);
GDK_AVAILABLE_IN_ALL
gboolean gtk_button_get_use_underline (GtkButton *button);
GDK_DEPRECATED_IN_3_20_FOR(gtk_widget_set_focus_on_click)
void gtk_button_set_focus_on_click (GtkButton *button,
gboolean focus_on_click);
GDK_DEPRECATED_IN_3_20_FOR(gtk_widget_get_focus_on_click)
gboolean gtk_button_get_focus_on_click (GtkButton *button);
GDK_AVAILABLE_IN_ALL
void gtk_button_set_image (GtkButton *button,
GtkWidget *image);

View File

@@ -41,9 +41,6 @@ struct _GtkButtonPrivate
GtkGesture *gesture;
gfloat xalign;
gfloat yalign;
/* This is only used by checkbox and subclasses */
gfloat baseline_align;
@@ -55,10 +52,8 @@ struct _GtkButtonPrivate
guint align_set : 1;
guint button_down : 1;
guint constructed : 1;
guint image_is_stock : 1;
guint in_button : 1;
guint use_action_appearance : 1;
guint use_stock : 1;
guint use_underline : 1;
guint always_show_image : 1;
};