[Title] Fixed remember username and password in case when
username is input tag with type equal to email
[Issue#] WEB-567
[Problem] Remember password feature was working only for
password field and not for username field in case
of sites like www.gmail.com
[Cause] The logic to populate data was missing if the
type of input tag was email and hence was ignoring it
[Solution] Added condition to check if input tag has type as
email while populating value
[Developer] Dhirendra Kumar(dhirendra.kr@samsung.com)
Change-Id: I8c6a883492761e4eea934e25d6c99c7b55f3df30
for (size_t i = 0; i < passwordFormData.size(); i++) {
passwordFormAutofill += String::format(" inputFields = document.getElementsByName(\"%s\");"
" for (var i = 0; i < inputFields.length; i++)"
- " if (inputFields[i].tagName.toLowerCase() == \"input\" && (inputFields[i].type.toLowerCase() == \"text\" || inputFields[i].type.toLowerCase() == \"password\"))"
+ " if (inputFields[i].tagName.toLowerCase() == \"input\" && (inputFields[i].type.toLowerCase() == \"text\" || inputFields[i].type.toLowerCase() == \"password\" || inputFields[i].type.toLowerCase() == \"email\"))"
" inputFields[i].value = \"%s\";",
passwordFormData[i].first.utf8().data(), passwordFormData[i].second.utf8().data());
}