diff options
author | Benjamin Otte <otte@redhat.com> | 2020-07-24 15:54:49 +0200 |
---|---|---|
committer | Benjamin Otte <otte@redhat.com> | 2020-07-25 00:47:36 +0200 |
commit | d7266b25ba5f2f21a5bd19d0fb88aca530e4d265 (patch) | |
tree | 8dc515efd6e0c0b0da1d7e02049f284edd6050ff /gtk/gtkspinbutton.c | |
parent | 46423e614d4fcf142d9578d4788dde664ea280f9 (diff) | |
download | gtk+-d7266b25ba5f2f21a5bd19d0fb88aca530e4d265.tar.gz |
Replace "gint" with "int"
Diffstat (limited to 'gtk/gtkspinbutton.c')
-rw-r--r-- | gtk/gtkspinbutton.c | 46 |
1 files changed, 23 insertions, 23 deletions
diff --git a/gtk/gtkspinbutton.c b/gtk/gtkspinbutton.c index 3da876839c..2bada1e6fd 100644 --- a/gtk/gtkspinbutton.c +++ b/gtk/gtkspinbutton.c @@ -124,7 +124,7 @@ * // Provides a function to retrieve an integer value from a GtkSpinButton * // and creates a spin button to model percentage values. * - * gint + * int * grab_int_value (GtkSpinButton *button, * gpointer user_data) * { @@ -222,9 +222,9 @@ struct _GtkSpinButtonClass { GtkWidgetClass parent_class; - gint (*input) (GtkSpinButton *spin_button, - gdouble *new_value); - gint (*output) (GtkSpinButton *spin_button); + int (*input) (GtkSpinButton *spin_button, + gdouble *new_value); + int (*output) (GtkSpinButton *spin_button); void (*value_changed) (GtkSpinButton *spin_button); /* Action signals for keybindings, do not connect to these */ @@ -289,14 +289,14 @@ static void gtk_spin_button_snap (GtkSpinButton *spin_button, gdouble val); static void gtk_spin_button_insert_text (GtkEditable *editable, const gchar *new_text, - gint new_text_length, - gint *position); + int new_text_length, + int *position); static void gtk_spin_button_real_spin (GtkSpinButton *spin_button, gdouble step); static void gtk_spin_button_real_change_value (GtkSpinButton *spin, GtkScrollType scroll); -static gint gtk_spin_button_default_input (GtkSpinButton *spin_button, +static int gtk_spin_button_default_input (GtkSpinButton *spin_button, gdouble *new_val); static void gtk_spin_button_default_output (GtkSpinButton *spin_button); @@ -1133,7 +1133,7 @@ gtk_spin_button_set_orientation (GtkSpinButton *spin, static gchar * weed_out_neg_zero (gchar *str, - gint digits) + int digits) { if (str[0] == '-') { @@ -1199,7 +1199,7 @@ gtk_spin_button_state_flags_changed (GtkWidget *widget, GTK_WIDGET_CLASS (gtk_spin_button_parent_class)->state_flags_changed (widget, previous_state); } -static gint +static int gtk_spin_button_timer (GtkSpinButton *spin_button) { gboolean retval = FALSE; @@ -1391,8 +1391,8 @@ gtk_spin_button_activate (GtkText *entry, static void gtk_spin_button_insert_text (GtkEditable *editable, const gchar *new_text, - gint new_text_length, - gint *position) + int new_text_length, + int *position) { GtkSpinButton *spin = GTK_SPIN_BUTTON (editable); @@ -1400,11 +1400,11 @@ gtk_spin_button_insert_text (GtkEditable *editable, { struct lconv *lc; gboolean sign; - gint dotpos = -1; - gint i; + int dotpos = -1; + int i; guint32 pos_sign; guint32 neg_sign; - gint entry_length; + int entry_length; const gchar *entry_text; entry_text = gtk_editable_get_text (GTK_EDITABLE (spin->entry)); @@ -1461,7 +1461,7 @@ gtk_spin_button_insert_text (GtkEditable *editable, } if (dotpos > -1 && *position > dotpos && - (gint)spin->digits - entry_length + (int)spin->digits - entry_length + dotpos - new_text_length + 1 < 0) return; @@ -1476,7 +1476,7 @@ gtk_spin_button_insert_text (GtkEditable *editable, else if (new_text[i] == *(lc->decimal_point)) { if (!spin->digits || dotpos > -1 || - (new_text_length - 1 - i + entry_length - *position > (gint)spin->digits)) + (new_text_length - 1 - i + entry_length - *position > (int)spin->digits)) return; dotpos = *position + i; } @@ -1539,7 +1539,7 @@ gtk_spin_button_real_spin (GtkSpinButton *spin_button, g_signal_emit (spin_button, spinbutton_signals[WRAPPED], 0); } -static gint +static int gtk_spin_button_default_input (GtkSpinButton *spin_button, gdouble *new_val) { @@ -1687,7 +1687,7 @@ gtk_spin_button_new_with_range (gdouble min, { GtkAdjustment *adjustment; GtkSpinButton *spin; - gint digits; + int digits; g_return_val_if_fail (min <= max, NULL); g_return_val_if_fail (step != 0.0, NULL); @@ -1699,7 +1699,7 @@ gtk_spin_button_new_with_range (gdouble min, if (fabs (step) >= 1.0 || step == 0.0) digits = 0; else { - digits = abs ((gint) floor (log10 (fabs (step)))); + digits = abs ((int) floor (log10 (fabs (step)))); if (digits > MAX_DIGITS) digits = MAX_DIGITS; } @@ -1914,7 +1914,7 @@ gtk_spin_button_get_value (GtkSpinButton *spin_button) * * Returns: the value of @spin_button */ -gint +int gtk_spin_button_get_value_as_int (GtkSpinButton *spin_button) { gdouble val; @@ -1945,7 +1945,7 @@ gtk_spin_button_set_value (GtkSpinButton *spin_button, gtk_adjustment_set_value (spin_button->adjustment, value); else { - gint return_val = FALSE; + int return_val = FALSE; g_signal_emit (spin_button, spinbutton_signals[OUTPUT], 0, &return_val); if (!return_val) gtk_spin_button_default_output (spin_button); @@ -2209,8 +2209,8 @@ void gtk_spin_button_update (GtkSpinButton *spin_button) { gdouble val; - gint error = 0; - gint return_val; + int error = 0; + int return_val; g_return_if_fail (GTK_IS_SPIN_BUTTON (spin_button)); |