From: Daniel Carl Date: Sat, 16 Feb 2013 10:46:31 +0000 (+0100) Subject: Fixed wrong check if a fired hint is an input. X-Git-Url: https://git.owens.tech/dummy.html/dummy.html/git?a=commitdiff_plain;h=8ce52393e5b6d34cee82133950afe4e181b8f742;p=vimb.git Fixed wrong check if a fired hint is an input. We considered every html form input element as editable. This brakes the next submit element on duckduckgo's search result page. Now we exclude the input type submit, reset and image from the editable input elements. --- diff --git a/src/dom.c b/src/dom.c index f805e91..9ebba04 100644 --- a/src/dom.c +++ b/src/dom.c @@ -126,11 +126,13 @@ gboolean dom_is_editable(Element* element) } char *type = webkit_dom_element_get_attribute(element, "type"); if (!g_ascii_strcasecmp(tagname, "input") - || !g_ascii_strcasecmp(type, "text") - || !g_ascii_strcasecmp(type, "password") + && g_ascii_strcasecmp(type, "submit") + && g_ascii_strcasecmp(type, "reset") + && g_ascii_strcasecmp(type, "image") ) { return TRUE; } + return FALSE; }