Bug 1895208 - Refactor IsFocusable checks to take flags rather than bool arguments. r=smaug
This doesn't change behavior on its own, but it's likely we want to make the tab focusability more complicated in bug 1895184, and this will make changes to this area less painful. Differential Revision: https://phabricator.services.mozilla.com/D209525
This commit is contained in:
@@ -6423,10 +6423,10 @@ void HTMLInputElement::RemoveFromRadioGroup() {
|
||||
mRadioGroupContainer = nullptr;
|
||||
}
|
||||
|
||||
bool HTMLInputElement::IsHTMLFocusable(bool aWithMouse, bool* aIsFocusable,
|
||||
int32_t* aTabIndex) {
|
||||
bool HTMLInputElement::IsHTMLFocusable(IsFocusableFlags aFlags,
|
||||
bool* aIsFocusable, int32_t* aTabIndex) {
|
||||
if (nsGenericHTMLFormControlElementWithState::IsHTMLFocusable(
|
||||
aWithMouse, aIsFocusable, aTabIndex)) {
|
||||
aFlags, aIsFocusable, aTabIndex)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -6440,7 +6440,7 @@ bool HTMLInputElement::IsHTMLFocusable(bool aWithMouse, bool* aIsFocusable,
|
||||
return false;
|
||||
}
|
||||
|
||||
const bool defaultFocusable = IsFormControlDefaultFocusable(aWithMouse);
|
||||
const bool defaultFocusable = IsFormControlDefaultFocusable(aFlags);
|
||||
if (CreatesDateTimeWidget()) {
|
||||
if (aTabIndex) {
|
||||
// We only want our native anonymous child to be tabable to, not ourself.
|
||||
|
||||
Reference in New Issue
Block a user