[webkit-changes] [WebKit/WebKit] 40332c: Fix canvas fallback content focusability computation

Tim Nguyen noreply at github.com
Sat Dec 17 08:02:50 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 40332c5701cc30c1b1be025aaa3e454e2faf81b0
      https://github.com/WebKit/WebKit/commit/40332c5701cc30c1b1be025aaa3e454e2faf81b0
  Author: Tim Nguyen <ntim at apple.com>
  Date:   2022-12-17 (Sat, 17 Dec 2022)

  Changed paths:
    M LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-canvas-element/canvas-descendants-focusability-003.tentative-expected.txt
    M LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-canvas-element/canvas-descendants-focusability-005-expected.txt
    M LayoutTests/imported/w3c/web-platform-tests/inert/inert-canvas-fallback-content-expected.txt
    M Source/WebCore/dom/Element.cpp
    M Source/WebCore/dom/Element.h
    M Source/WebCore/html/HTMLAreaElement.cpp

  Log Message:
  -----------
  Fix canvas fallback content focusability computation
https://bugs.webkit.org/show_bug.cgi?id=239017
rdar://91830204

Reviewed by Ryosuke Niwa.

Fallback content for canvas should go through all the normal checks for focusability. The only thing that differs is
that the fallback content should not be focusable if the canvas isn't.

Rename `isFocusableWithoutResolvingFullStyle` to `hasFocusableStyle` since the old name was misleading (suggests that it
is the same as `isFocusable` without resolving the full style, which isn't true).

* LayoutTests/imported/w3c/web-platform-tests/inert/inert-canvas-fallback-content-expected.txt:
* Source/WebCore/dom/Element.cpp:
(WebCore::Element::isFocusable const):
(WebCore::Element::isFocusableWithoutResolvingFullStyle const): Deleted.
* Source/WebCore/dom/Element.h:
* Source/WebCore/html/HTMLAreaElement.cpp:
(WebCore::HTMLAreaElement::isFocusable const):

Canonical link: https://commits.webkit.org/258043@main




More information about the webkit-changes mailing list