[webkit-changes] [WebKit/WebKit] dbcaef: Counters are always generated content and cannot b...

Ahmad Saleem noreply at github.com
Mon Dec 19 06:46:32 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: dbcaeff80040bbfadeee5162d44a7e8ee7415b81
      https://github.com/WebKit/WebKit/commit/dbcaeff80040bbfadeee5162d44a7e8ee7415b81
  Author: Ahmad Saleem <ahmad.saleem792+github at gmail.com>
  Date:   2022-12-19 (Mon, 19 Dec 2022)

  Changed paths:
    A LayoutTests/editing/selection/text-selection-counter-expected.html
    A LayoutTests/editing/selection/text-selection-counter.html
    M LayoutTests/platform/ios/TestExpectations
    M Source/WebCore/rendering/RenderCounter.h

  Log Message:
  -----------
  Counters are always generated content and cannot be selected

Counters are always generated content and cannot be selected
https://bugs.webkit.org/show_bug.cgi?id=249500

Reviewed by Ryosuke Niwa.

This patch is to align Webkit behavior with Blink / Chromium and Gecko / Firefox.

Merge - https://chromium.googlesource.com/chromium/src.git/+/9d8a90f8a7f49c673bcd4e369efc84c62cc18285

This patch is modify the overriding behavior where RenderCounter inherits the logic of CanBeSelectionLeaf(), which returns always true, from RenderText. This is to modify to explicitly return false for
RenderCount as it is always generated content.

* Source/WebCore/rendering/RenderCount.h: Add bool "CanBeSelectionLeaf" with return value as "false"
* LayoutTests/editing/selection/text-selection-counter.html: Add Test Case
* LayoutTests/editing/selection/text-selection-counter-expected.html: Add Test Case Expectation
* LayoutTests/platform/ios/TestExpectations: Updated to skip added test on iOS platform due to selection support

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




More information about the webkit-changes mailing list