mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-08 10:44:56 +00:00
Bug 1424284 - Part 3. mHTMLInputType should set valid value. r=masayuki
Actually, current code gets type attribute by `GetAttr`, But this cannot get valid value. If no type attribute, `mHTMLInputType` will be empty. So if type has invalid value, we should return `text` value instead. Depends on D69349 Differential Revision: https://phabricator.services.mozilla.com/D69350 --HG-- extra : moz-landing-system : lando
This commit is contained in:
parent
9151f36c46
commit
9db27b76b5
@ -1272,8 +1272,7 @@ void IMEStateManager::SetIMEState(const IMEState& aState,
|
||||
|
||||
if (aContent) {
|
||||
if (aContent->IsHTMLElement(nsGkAtoms::input)) {
|
||||
aContent->AsElement()->GetAttr(kNameSpaceID_None, nsGkAtoms::type,
|
||||
context.mHTMLInputType);
|
||||
HTMLInputElement::FromNode(aContent)->GetType(context.mHTMLInputType);
|
||||
GetActionHint(*aContent, context.mActionHint);
|
||||
} else if (aContent->IsHTMLElement(nsGkAtoms::textarea)) {
|
||||
context.mHTMLInputType.Assign(nsGkAtoms::textarea->GetUTF16String());
|
||||
|
Loading…
Reference in New Issue
Block a user