Fix declaration and signedness warnings in gdom frontend

This commit is contained in:
Alexander Butenko 2012-02-13 01:34:47 +01:00 committed by Christian Dywan
parent 669167eb9e
commit 7bf5005617

View file

@ -102,7 +102,8 @@ get_absolute_offset_for_element (WebKitDOMElement* element,
gboolean ismainframe) gboolean ismainframe)
{ {
WebKitDOMElement* offset_parent; WebKitDOMElement* offset_parent;
gint i, offset_top = 0, offset_left = 0; gint offset_top = 0, offset_left = 0;
gulong i;
g_object_get (element, "offset-left", &offset_left, g_object_get (element, "offset-left", &offset_left,
"offset-top", &offset_top, "offset-top", &offset_top,
@ -149,13 +150,14 @@ formhistory_reposition_popup (FormHistoryPriv* priv)
WebKitDOMNodeList* frames; WebKitDOMNodeList* frames;
GtkWidget* view; GtkWidget* view;
GdkWindow* window; GdkWindow* window;
GtkWidget* toplevel;
gint rx, ry; gint rx, ry;
gint wx, wy; gint wx, wy;
glong x = 0, y = 0; glong x = 0, y = 0;
glong height; glong height;
view = g_object_get_data (G_OBJECT (priv->element), "webview"); view = g_object_get_data (G_OBJECT (priv->element), "webview");
GtkWidget* toplevel = gtk_widget_get_toplevel (view); toplevel = gtk_widget_get_toplevel (view);
/* Position of a root window */ /* Position of a root window */
window = gtk_widget_get_window (toplevel); window = gtk_widget_get_window (toplevel);
gdk_window_get_position (window, &rx, &ry); gdk_window_get_position (window, &rx, &ry);
@ -192,7 +194,7 @@ formhistory_suggestions_show (FormHistoryPriv* priv)
gchar* likedvalue; gchar* likedvalue;
int pos = 0; int pos = 0;
g_return_if_fail (priv->element); g_return_val_if_fail (priv->element, FALSE);
g_object_get (priv->element, g_object_get (priv->element,
"name", &name, "name", &name,
@ -232,8 +234,8 @@ formhistory_suggestions_show (FormHistoryPriv* priv)
while (result == SQLITE_ROW) while (result == SQLITE_ROW)
{ {
pos++;
const unsigned char* text = sqlite3_column_text (stmt, 0); const unsigned char* text = sqlite3_column_text (stmt, 0);
pos++;
gtk_list_store_insert_with_values (store, NULL, pos, 0, text, -1); gtk_list_store_insert_with_values (store, NULL, pos, 0, text, -1);
result = sqlite3_step (stmt); result = sqlite3_step (stmt);
} }
@ -259,7 +261,7 @@ formhistory_editbox_key_pressed_cb (WebKitDOMElement* element,
{ {
glong key; glong key;
GtkTreePath* path; GtkTreePath* path;
const gchar* keyword; gchar* keyword;
gint matches; gint matches;
/* FIXME: Priv is still set after module is disabled */ /* FIXME: Priv is still set after module is disabled */
@ -376,7 +378,7 @@ formhistory_DOMContentLoaded_cb (WebKitDOMElement* window,
WebKitDOMEvent* dom_event, WebKitDOMEvent* dom_event,
FormHistoryPriv* priv) FormHistoryPriv* priv)
{ {
int i; gulong i;
WebKitDOMDocument* doc; WebKitDOMDocument* doc;
WebKitDOMNodeList* inputs; WebKitDOMNodeList* inputs;
WebKitDOMNodeList* frames; WebKitDOMNodeList* frames;
@ -424,7 +426,7 @@ formhistory_setup_suggestions (WebKitWebView* web_view,
{ {
WebKitDOMDocument* doc; WebKitDOMDocument* doc;
WebKitDOMNodeList* frames; WebKitDOMNodeList* frames;
int i; gulong i;
FormHistoryPriv* priv = g_object_get_data (G_OBJECT (extension), "priv"); FormHistoryPriv* priv = g_object_get_data (G_OBJECT (extension), "priv");
doc = webkit_web_view_get_dom_document (web_view); doc = webkit_web_view_get_dom_document (web_view);