Commit d7266b25 authored by Benjamin Otte's avatar Benjamin Otte
Browse files

Replace "gint" with "int"

parent 46423e61
......@@ -81,11 +81,11 @@ constraint_editor_application_activate (GApplication *app)
static void
constraint_editor_application_open (GApplication *app,
GFile **files,
gint n_files,
int n_files,
const gchar *hint)
{
ConstraintEditorWindow *win;
gint i;
int i;
for (i = 0; i < n_files; i++)
{
......
......@@ -193,7 +193,7 @@ constraint_editor_window_load (ConstraintEditorWindow *self,
static void
open_response_cb (GtkNativeDialog *dialog,
gint response,
int response,
ConstraintEditorWindow *self)
{
gtk_native_dialog_hide (dialog);
......@@ -285,7 +285,7 @@ serialize_model (GListModel *list)
static void
save_response_cb (GtkNativeDialog *dialog,
gint response,
int response,
ConstraintEditorWindow *self)
{
gtk_native_dialog_hide (dialog);
......
......@@ -92,7 +92,7 @@ activate_new (GSimpleAction *action,
static void
open_response_cb (GtkNativeDialog *dialog,
gint response_id,
int response_id,
gpointer user_data)
{
GtkFileChooserNative *native = user_data;
......@@ -245,8 +245,8 @@ update_statusbar (GtkTextBuffer *buffer,
DemoApplicationWindow *window)
{
gchar *msg;
gint row, col;
gint count;
int row, col;
int count;
GtkTextIter iter;
/* clear any previous message, underflow is allowed */
......
......@@ -47,7 +47,7 @@ on_assistant_close_cancel (GtkWidget *widget, gpointer data)
static void
on_assistant_prepare (GtkWidget *widget, GtkWidget *page, gpointer data)
{
gint current_page, n_pages;
int current_page, n_pages;
gchar *title;
current_page = gtk_assistant_get_current_page (GTK_ASSISTANT (widget));
......@@ -70,7 +70,7 @@ on_entry_changed (GtkWidget *widget, gpointer data)
{
GtkAssistant *assistant = GTK_ASSISTANT (data);
GtkWidget *current_page;
gint page_number;
int page_number;
const gchar *text;
page_number = gtk_assistant_get_current_page (assistant);
......
......@@ -38,7 +38,7 @@ create_icon_store (void)
GtkTreeIter iter;
GtkListStore *store;
gint i;
int i;
store = gtk_list_store_new (2, G_TYPE_STRING, G_TYPE_STRING);
......@@ -77,7 +77,7 @@ set_sensitive (GtkCellLayout *cell_layout,
gpointer data)
{
GtkTreePath *path;
gint *indices;
int *indices;
gboolean sensitive;
path = gtk_tree_model_get_path (tree_model, iter);
......@@ -175,7 +175,7 @@ create_capital_store (void)
GtkTreeIter iter, iter2;
GtkTreeStore *store;
gint i;
int i;
store = gtk_tree_store_new (1, G_TYPE_STRING);
......
......@@ -75,7 +75,7 @@ setup_listbox (GtkBuilder *builder,
{
GtkWidget *normal_row;
GtkWidget *listbox;
gint i;
int i;
normal_row = NULL;
listbox = gtk_list_box_new ();
......
......@@ -16,7 +16,7 @@ message_dialog_clicked (GtkButton *button,
gpointer user_data)
{
GtkWidget *dialog;
static gint i = 1;
static int i = 1;
dialog = gtk_message_dialog_new (GTK_WINDOW (window),
GTK_DIALOG_MODAL | GTK_DIALOG_DESTROY_WITH_PARENT,
......
......@@ -16,9 +16,9 @@
typedef struct
{
gint number;
int number;
gchar *product;
gint yummy;
int yummy;
}
Item;
......@@ -74,7 +74,7 @@ add_items (void)
static GtkTreeModel *
create_items_model (void)
{
gint i = 0;
int i = 0;
GtkListStore *model;
GtkTreeIter iter;
......@@ -109,7 +109,7 @@ static GtkTreeModel *
create_numbers_model (void)
{
#define N_NUMBERS 10
gint i = 0;
int i = 0;
GtkListStore *model;
GtkTreeIter iter;
......@@ -192,7 +192,7 @@ remove_item (GtkWidget *widget, gpointer data)
if (gtk_tree_selection_get_selected (selection, NULL, &iter))
{
gint i;
int i;
GtkTreePath *path;
path = gtk_tree_model_get_path (model, &iter);
......@@ -211,7 +211,7 @@ separator_row (GtkTreeModel *model,
gpointer data)
{
GtkTreePath *path;
gint idx;
int idx;
path = gtk_tree_model_get_path (model, iter);
idx = gtk_tree_path_get_indices (path)[0];
......@@ -241,7 +241,7 @@ cell_edited (GtkCellRendererText *cell,
GtkTreePath *path = gtk_tree_path_new_from_string (path_string);
GtkTreeIter iter;
gint column = GPOINTER_TO_INT (g_object_get_data (G_OBJECT (cell), "column"));
int column = GPOINTER_TO_INT (g_object_get_data (G_OBJECT (cell), "column"));
gtk_tree_model_get_iter (model, &iter, path);
......@@ -249,7 +249,7 @@ cell_edited (GtkCellRendererText *cell,
{
case COLUMN_ITEM_NUMBER:
{
gint i;
int i;
i = gtk_tree_path_get_indices (path)[0];
g_array_index (articles, Item, i).number = atoi (new_text);
......@@ -261,7 +261,7 @@ cell_edited (GtkCellRendererText *cell,
case COLUMN_ITEM_PRODUCT:
{
gint i;
int i;
gchar *old_text;
gtk_tree_model_get (model, &iter, column, &old_text, -1);
......
......@@ -13,7 +13,7 @@
static GtkWidget *window = NULL;
static void
response_cb (GtkDialog *dialog, gint response_id)
response_cb (GtkDialog *dialog, int response_id)
{
gtk_window_destroy (GTK_WINDOW (window));
window = NULL;
......
......@@ -22,7 +22,7 @@ format_number (GtkTreeViewColumn *col,
GtkTreeIter *iter,
gpointer data)
{
gint num;
int num;
gchar *text;
gtk_tree_model_get (model, iter, GPOINTER_TO_INT (data), &num, -1);
......@@ -35,11 +35,11 @@ static void
filter_modify_func (GtkTreeModel *model,
GtkTreeIter *iter,
GValue *value,
gint column,
int column,
gpointer data)
{
GtkTreeModelFilter *filter_model = GTK_TREE_MODEL_FILTER (model);
gint width, height;
int width, height;
GtkTreeModel *child_model;
GtkTreeIter child_iter;
......@@ -75,7 +75,7 @@ visible_func (GtkTreeModel *model,
GtkTreeIter *iter,
gpointer data)
{
gint width;
int width;
gtk_tree_model_get (model, iter,
WIDTH_COLUMN, &width,
......
......@@ -716,7 +716,7 @@ do_flowbox (GtkWidget *do_widget)
"YellowGreen",
NULL
};
gint i;
int i;
if (!window)
{
......
......@@ -295,7 +295,7 @@ update_display (void)
GList *l;
PangoAttrList *attrs;
PangoAttribute *attr;
gint ins, bound;
int ins, bound;
guint start, end;
PangoLanguage *lang;
char *font_desc;
......@@ -479,7 +479,7 @@ update_script_combo (void)
{
GtkListStore *store;
hb_font_t *hb_font;
gint i, j, k;
int i, j, k;
PangoFont *pango_font;
GHashTable *tags;
GHashTableIter iter;
......@@ -593,7 +593,7 @@ update_script_combo (void)
static void
update_features (void)
{
gint i, j;
int i, j;
GtkTreeModel *model;
GtkTreeIter iter;
guint script_index, lang_index;
......
......@@ -36,11 +36,11 @@ adjustment_get_normalized_value (GtkAdjustment *adj)
static void
val_to_xy (GtkFontPlane *plane,
gint *x,
gint *y)
int *x,
int *y)
{
gdouble u, v;
gint width, height;
int width, height;
width = gtk_widget_get_allocated_width (GTK_WIDGET (plane));
height = gtk_widget_get_allocated_height (GTK_WIDGET (plane));
......@@ -57,8 +57,8 @@ plane_snapshot (GtkWidget *widget,
GtkSnapshot *snapshot)
{
GtkFontPlane *plane = GTK_FONT_PLANE (widget);
gint x, y;
gint width, height;
int x, y;
int width, height;
cairo_t *cr;
val_to_xy (plane, &x, &y);
......@@ -125,8 +125,8 @@ adjustment_set_normalized_value (GtkAdjustment *adj,
static void
update_value (GtkFontPlane *plane,
gint x,
gint y)
int x,
int y)
{
GtkWidget *widget = GTK_WIDGET (plane);
gdouble u, v;
......
......@@ -98,7 +98,7 @@ gtk_fishbowl_measure (GtkWidget *widget,
GHashTableIter iter;
gpointer key, value;
GtkFishbowlChild *child;
gint child_min, child_nat;
int child_min, child_nat;
*minimum = 0;
*natural = 0;
......
......@@ -18,7 +18,7 @@ static void
insert_link (GtkTextBuffer *buffer,
GtkTextIter *iter,
const char *text,
gint page)
int page)
{
GtkTextTag *tag;
......@@ -35,7 +35,7 @@ insert_link (GtkTextBuffer *buffer,
*/
static void
show_page (GtkTextBuffer *buffer,
gint page)
int page)
{
GtkTextIter iter;
......@@ -91,7 +91,7 @@ follow_if_link (GtkWidget *text_view,
for (tagp = tags; tagp != NULL; tagp = tagp->next)
{
GtkTextTag *tag = tagp->data;
gint page = GPOINTER_TO_INT (g_object_get_data (G_OBJECT (tag), "page"));
int page = GPOINTER_TO_INT (g_object_get_data (G_OBJECT (tag), "page"));
if (page != 0)
{
......@@ -134,8 +134,8 @@ key_pressed (GtkEventController *controller,
}
static void set_cursor_if_appropriate (GtkTextView *text_view,
gint x,
gint y);
int x,
int y);
static void
released_cb (GtkGestureClick *gesture,
......@@ -183,8 +183,8 @@ static gboolean hovering_over_link = FALSE;
*/
static void
set_cursor_if_appropriate (GtkTextView *text_view,
gint x,
gint y)
int x,
int y)
{
GSList *tags = NULL, *tagp = NULL;
GtkTextIter iter;
......@@ -196,7 +196,7 @@ set_cursor_if_appropriate (GtkTextView *text_view,
for (tagp = tags; tagp != NULL; tagp = tagp->next)
{
GtkTextTag *tag = tagp->data;
gint page = GPOINTER_TO_INT (g_object_get_data (G_OBJECT (tag), "page"));
int page = GPOINTER_TO_INT (g_object_get_data (G_OBJECT (tag), "page"));
if (page != 0)
{
......
......@@ -90,7 +90,7 @@ fill_store (GtkListStore *store)
g_dir_close (dir);
}
static gint
static int
sort_func (GtkTreeModel *model,
GtkTreeIter *a,
GtkTreeIter *b,
......
......@@ -20,7 +20,7 @@ fill_store (GtkListStore *store)
{
GtkTreeIter iter;
const gchar *text[] = { "Red", "Green", "Blue", "Yellow" };
gint i;
int i;
/* First clear the store */
gtk_list_store_clear (store);
......@@ -60,10 +60,10 @@ set_cell_color (GtkCellLayout *cell_layout,
if (gdk_rgba_parse (&color, text))
pixel =
((gint)(color.red * 255)) << 24 |
((gint)(color.green * 255)) << 16 |
((gint)(color.blue * 255)) << 8 |
((gint)(color.alpha * 255));
((int)(color.red * 255)) << 24 |
((int)(color.green * 255)) << 16 |
((int)(color.blue * 255)) << 8 |
((int)(color.alpha * 255));
g_free (text);
......
......@@ -43,10 +43,10 @@ progressive_prepared_callback (GdkPixbufLoader *loader,
static void
progressive_updated_callback (GdkPixbufLoader *loader,
gint x,
gint y,
gint width,
gint height,
int x,
int y,
int width,
int height,
gpointer data)
{
GtkWidget *picture;
......@@ -58,7 +58,7 @@ progressive_updated_callback (GdkPixbufLoader *loader,
gtk_picture_set_pixbuf (GTK_PICTURE (picture), pixbuf);
}
static gint
static int
progressive_timeout (gpointer data)
{
GtkWidget *picture;
......
......@@ -8,7 +8,7 @@
static void
on_bar_response (GtkInfoBar *info_bar,
gint response_id,
int response_id,
gpointer user_data)
{
GtkWidget *dialog;
......
......@@ -9,7 +9,7 @@
static void
response_cb (GtkWidget *dialog,
gint response_id,
int response_id,
gpointer data)
{
gtk_window_destroy (GTK_WINDOW (dialog));
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment