From a90a5cba08fdf6c0ceb95101c275108a152a3aed Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Wed, 12 Jun 2024 07:35:37 +0200 Subject: Merging upstream version 127.0. Signed-off-by: Daniel Baumann --- dom/html/HTMLButtonElement.cpp | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'dom/html/HTMLButtonElement.cpp') diff --git a/dom/html/HTMLButtonElement.cpp b/dom/html/HTMLButtonElement.cpp index 0d9cc921ad..7d7fa7f548 100644 --- a/dom/html/HTMLButtonElement.cpp +++ b/dom/html/HTMLButtonElement.cpp @@ -12,13 +12,13 @@ #include "nsAttrValueInlines.h" #include "nsIContentInlines.h" #include "nsGkAtoms.h" -#include "nsStyleConsts.h" #include "nsPresContext.h" #include "nsIFormControl.h" #include "nsIFrame.h" #include "nsIFormControlFrame.h" #include "mozilla/dom/Document.h" #include "mozilla/ContentEvents.h" +#include "mozilla/FocusModel.h" #include "mozilla/EventDispatcher.h" #include "mozilla/EventStateManager.h" #include "mozilla/MouseEvents.h" @@ -113,15 +113,14 @@ void HTMLButtonElement::GetType(nsAString& aType) { int32_t HTMLButtonElement::TabIndexDefault() { return 0; } -bool HTMLButtonElement::IsHTMLFocusable(bool aWithMouse, bool* aIsFocusable, +bool HTMLButtonElement::IsHTMLFocusable(IsFocusableFlags aFlags, + bool* aIsFocusable, int32_t* aTabIndex) { if (nsGenericHTMLFormControlElementWithState::IsHTMLFocusable( - aWithMouse, aIsFocusable, aTabIndex)) { + aFlags, aIsFocusable, aTabIndex)) { return true; } - - *aIsFocusable = IsFormControlDefaultFocusable(aWithMouse) && !IsDisabled(); - + *aIsFocusable = IsFormControlDefaultFocusable(aFlags) && !IsDisabled(); return false; } -- cgit v1.2.3