Changeset 235749 in webkit


Ignore:
Timestamp:
Sep 6, 2018 12:48:08 PM (6 years ago)
Author:
commit-queue@webkit.org
Message:

Group options of scrollRectToVisible into a struct
https://bugs.webkit.org/show_bug.cgi?id=189352

Patch by Frederic Wang <fwang@igalia.com> on 2018-09-06
Reviewed by Simon Fraser.

Source/WebCore:

RenderLayer::scrollRectToVisible and RenderObject::scrollRectToVisible have several
parameters to configure the type of scrolling. This patch groups the const options into a
single struct to make easier to handle them in the future. For example, an #ifdefed scroll
behavior option will be added in bug 188043. This refactoring can maybe help too for other
scroll extensions (e.g. bug 176454 and bug 161611).

No new tests, behavior unchanged.

  • accessibility/AccessibilityObject.cpp:

(WebCore::AccessibilityObject::scrollToMakeVisible const): Pass options via a struct.

  • dom/Element.cpp:

(WebCore::Element::scrollIntoView): Ditto.
(WebCore::Element::scrollIntoViewIfNeeded): Ditto.
(WebCore::Element::scrollIntoViewIfNotVisible): Ditto.

  • editing/FrameSelection.cpp: Include RenderLayer.h in all WebKit ports in order to define

ScrollRectToVisibleOptions.
(WebCore::FrameSelection::revealSelection): Pass options via a struct.

  • page/FrameView.cpp:

(WebCore::FrameView::scrollToFocusedElementInternal): Ditto.
(WebCore::FrameView::scrollToAnchor): Ditto.

  • rendering/RenderLayer.cpp:

(WebCore::RenderLayer::scrollRectToVisible): Pass options via a struct. Note that
absoluteRect and insideFixed are modified in this function.
(WebCore::RenderLayer::autoscroll): Pass options via a struct.

  • rendering/RenderLayer.h: Add ScrollRectToVisibleOptions and use it in order to pass

scrollRectToVisible options.

  • rendering/RenderObject.cpp:

(WebCore::RenderObject::scrollRectToVisible): Pass options via a struct

  • rendering/RenderObject.h: Forward-declare ScrollRectToVisibleOptions and use in order to

pass scrollRectToVisible options.

Source/WebKitLegacy/mac:

  • WebView/WebFrame.mm: Add header to use ScrollRectToVisibleOptions.

(-[WebFrame _scrollDOMRangeToVisible:]): Pass options via a struct.
(-[WebFrame _scrollDOMRangeToVisible:withInset:]): Ditto.

Location:
trunk/Source
Files:
11 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r235748 r235749  
     12018-09-06  Frederic Wang  <fwang@igalia.com>
     2
     3        Group options of scrollRectToVisible into a struct
     4        https://bugs.webkit.org/show_bug.cgi?id=189352
     5
     6        Reviewed by Simon Fraser.
     7
     8        RenderLayer::scrollRectToVisible and RenderObject::scrollRectToVisible have several
     9        parameters to configure the type of scrolling. This patch groups the const options into a
     10        single struct to make easier to handle them in the future. For example, an #ifdefed scroll
     11        behavior option will be added in bug 188043. This refactoring can maybe help too for other
     12        scroll extensions (e.g. bug 176454 and bug 161611).
     13
     14        No new tests, behavior unchanged.
     15
     16        * accessibility/AccessibilityObject.cpp:
     17        (WebCore::AccessibilityObject::scrollToMakeVisible const): Pass options via a struct.
     18        * dom/Element.cpp:
     19        (WebCore::Element::scrollIntoView): Ditto.
     20        (WebCore::Element::scrollIntoViewIfNeeded): Ditto.
     21        (WebCore::Element::scrollIntoViewIfNotVisible): Ditto.
     22        * editing/FrameSelection.cpp: Include RenderLayer.h in all WebKit ports in order to define
     23        ScrollRectToVisibleOptions.
     24        (WebCore::FrameSelection::revealSelection): Pass options via a struct.
     25        * page/FrameView.cpp:
     26        (WebCore::FrameView::scrollToFocusedElementInternal): Ditto.
     27        (WebCore::FrameView::scrollToAnchor): Ditto.
     28        * rendering/RenderLayer.cpp:
     29        (WebCore::RenderLayer::scrollRectToVisible): Pass options via a struct. Note that
     30        absoluteRect and insideFixed are modified in this function.
     31        (WebCore::RenderLayer::autoscroll): Pass options via a struct.
     32        * rendering/RenderLayer.h: Add ScrollRectToVisibleOptions and use it in order to pass
     33        scrollRectToVisible options.
     34        * rendering/RenderObject.cpp:
     35        (WebCore::RenderObject::scrollRectToVisible): Pass options via a struct
     36        * rendering/RenderObject.h: Forward-declare ScrollRectToVisibleOptions and use in order to
     37        pass scrollRectToVisible options.
     38
    1392018-09-06  Wenson Hsieh  <wenson_hsieh@apple.com>
    240
  • trunk/Source/WebCore/accessibility/AccessibilityObject.cpp

    r235560 r235749  
    29932993
    29942994    if (auto* renderer = this->renderer())
    2995         renderer->scrollRectToVisible(SelectionRevealMode::Reveal, boundingBoxRect(), false, ScrollAlignment::alignCenterIfNeeded, ScrollAlignment::alignCenterIfNeeded, ShouldAllowCrossOriginScrolling::Yes);
     2995        renderer->scrollRectToVisible(boundingBoxRect(), false, { SelectionRevealMode::Reveal, ScrollAlignment::alignCenterIfNeeded, ScrollAlignment::alignCenterIfNeeded, ShouldAllowCrossOriginScrolling::Yes });
    29962996}
    29972997
  • trunk/Source/WebCore/dom/Element.cpp

    r235736 r235749  
    693693    ScrollAlignment alignX = toScrollAlignment(options.inlinePosition, false);
    694694    ScrollAlignment alignY = toScrollAlignment(options.blockPosition, true);
    695     renderer()->scrollRectToVisible(SelectionRevealMode::Reveal, absoluteBounds, insideFixed, alignX, alignY, ShouldAllowCrossOriginScrolling::No);
     695    renderer()->scrollRectToVisible(absoluteBounds, insideFixed, { SelectionRevealMode::Reveal, alignX, alignY, ShouldAllowCrossOriginScrolling::No });
    696696}
    697697
     
    707707    // Align to the top / bottom and to the closest edge.
    708708    if (alignToTop)
    709         renderer()->scrollRectToVisible(SelectionRevealMode::Reveal, absoluteBounds, insideFixed, ScrollAlignment::alignToEdgeIfNeeded, ScrollAlignment::alignTopAlways, ShouldAllowCrossOriginScrolling::No);
     709        renderer()->scrollRectToVisible(absoluteBounds, insideFixed, { SelectionRevealMode::Reveal, ScrollAlignment::alignToEdgeIfNeeded, ScrollAlignment::alignTopAlways, ShouldAllowCrossOriginScrolling::No });
    710710    else
    711         renderer()->scrollRectToVisible(SelectionRevealMode::Reveal, absoluteBounds, insideFixed, ScrollAlignment::alignToEdgeIfNeeded, ScrollAlignment::alignBottomAlways, ShouldAllowCrossOriginScrolling::No);
     711        renderer()->scrollRectToVisible(absoluteBounds, insideFixed, { SelectionRevealMode::Reveal, ScrollAlignment::alignToEdgeIfNeeded, ScrollAlignment::alignBottomAlways, ShouldAllowCrossOriginScrolling::No });
    712712}
    713713
     
    722722    LayoutRect absoluteBounds = renderer()->absoluteAnchorRect(&insideFixed);
    723723    if (centerIfNeeded)
    724         renderer()->scrollRectToVisible(SelectionRevealMode::Reveal, absoluteBounds, insideFixed, ScrollAlignment::alignCenterIfNeeded, ScrollAlignment::alignCenterIfNeeded, ShouldAllowCrossOriginScrolling::No);
     724        renderer()->scrollRectToVisible(absoluteBounds, insideFixed, { SelectionRevealMode::Reveal, ScrollAlignment::alignCenterIfNeeded, ScrollAlignment::alignCenterIfNeeded, ShouldAllowCrossOriginScrolling::No });
    725725    else
    726         renderer()->scrollRectToVisible(SelectionRevealMode::Reveal, absoluteBounds, insideFixed, ScrollAlignment::alignToEdgeIfNeeded, ScrollAlignment::alignToEdgeIfNeeded, ShouldAllowCrossOriginScrolling::No);
     726        renderer()->scrollRectToVisible(absoluteBounds, insideFixed, { SelectionRevealMode::Reveal, ScrollAlignment::alignToEdgeIfNeeded, ScrollAlignment::alignToEdgeIfNeeded, ShouldAllowCrossOriginScrolling::No });
    727727}
    728728
     
    737737    LayoutRect absoluteBounds = renderer()->absoluteAnchorRect(&insideFixed);
    738738    if (centerIfNotVisible)
    739         renderer()->scrollRectToVisible(SelectionRevealMode::Reveal, absoluteBounds, insideFixed, ScrollAlignment::alignCenterIfNotVisible, ScrollAlignment::alignCenterIfNotVisible, ShouldAllowCrossOriginScrolling::No);
     739        renderer()->scrollRectToVisible(absoluteBounds, insideFixed, { SelectionRevealMode::Reveal, ScrollAlignment::alignCenterIfNotVisible, ScrollAlignment::alignCenterIfNotVisible, ShouldAllowCrossOriginScrolling::No });
    740740    else
    741         renderer()->scrollRectToVisible(SelectionRevealMode::Reveal, absoluteBounds, insideFixed, ScrollAlignment::alignToEdgeIfNotVisible, ScrollAlignment::alignToEdgeIfNotVisible, ShouldAllowCrossOriginScrolling::No);
     741        renderer()->scrollRectToVisible(absoluteBounds, insideFixed, { SelectionRevealMode::Reveal, ScrollAlignment::alignToEdgeIfNotVisible, ScrollAlignment::alignToEdgeIfNotVisible, ShouldAllowCrossOriginScrolling::No });
    742742}
    743743
  • trunk/Source/WebCore/editing/FrameSelection.cpp

    r235560 r235749  
    5454#include "InlineTextBox.h"
    5555#include "Page.h"
     56#include "RenderLayer.h"
    5657#include "RenderText.h"
    5758#include "RenderTextControl.h"
     
    7273#include "ChromeClient.h"
    7374#include "Color.h"
    74 #include "RenderLayer.h"
    7575#include "RenderObject.h"
    7676#include "RenderStyle.h"
     
    23752375            if (!m_scrollingSuppressCount) {
    23762376                layer->setAdjustForIOSCaretWhenScrolling(true);
    2377                 layer->scrollRectToVisible(revealMode, rect, insideFixed, alignment, alignment, ShouldAllowCrossOriginScrolling::Yes);
     2377                layer->scrollRectToVisible(rect, insideFixed, { revealMode, alignment, alignment, ShouldAllowCrossOriginScrolling::Yes });
    23782378                layer->setAdjustForIOSCaretWhenScrolling(false);
    23792379                updateAppearance();
     
    23862386        // the selection rect could intersect more than just that.
    23872387        // See <rdar://problem/4799899>.
    2388         if (start.deprecatedNode()->renderer()->scrollRectToVisible(revealMode, rect, insideFixed, alignment, alignment, ShouldAllowCrossOriginScrolling::Yes))
     2388        if (start.deprecatedNode()->renderer()->scrollRectToVisible(rect, insideFixed, { revealMode, alignment, alignment, ShouldAllowCrossOriginScrolling::Yes }))
    23892389            updateAppearance();
    23902390#endif
  • trunk/Source/WebCore/page/FrameView.cpp

    r235560 r235749  
    23372337    bool insideFixed;
    23382338    LayoutRect absoluteBounds = renderer->absoluteAnchorRect(&insideFixed);
    2339     renderer->scrollRectToVisible(m_selectionRevealModeForFocusedElement, absoluteBounds, insideFixed, ScrollAlignment::alignCenterIfNeeded, ScrollAlignment::alignCenterIfNeeded, ShouldAllowCrossOriginScrolling::No);
     2339    renderer->scrollRectToVisible(absoluteBounds, insideFixed, { m_selectionRevealModeForFocusedElement, ScrollAlignment::alignCenterIfNeeded, ScrollAlignment::alignCenterIfNeeded, ShouldAllowCrossOriginScrolling::No });
    23402340}
    23412341
     
    31113111    // Align to the top and to the closest side (this matches other browsers).
    31123112    if (anchorNode->renderer()->style().isHorizontalWritingMode())
    3113         anchorNode->renderer()->scrollRectToVisible(SelectionRevealMode::Reveal, rect, insideFixed, ScrollAlignment::alignToEdgeIfNeeded, ScrollAlignment::alignTopAlways, ShouldAllowCrossOriginScrolling::No);
     3113        anchorNode->renderer()->scrollRectToVisible(rect, insideFixed, { SelectionRevealMode::Reveal, ScrollAlignment::alignToEdgeIfNeeded, ScrollAlignment::alignTopAlways, ShouldAllowCrossOriginScrolling::No });
    31143114    else if (anchorNode->renderer()->style().isFlippedBlocksWritingMode())
    3115         anchorNode->renderer()->scrollRectToVisible(SelectionRevealMode::Reveal, rect, insideFixed, ScrollAlignment::alignRightAlways, ScrollAlignment::alignToEdgeIfNeeded, ShouldAllowCrossOriginScrolling::No);
     3115        anchorNode->renderer()->scrollRectToVisible(rect, insideFixed, { SelectionRevealMode::Reveal, ScrollAlignment::alignRightAlways, ScrollAlignment::alignToEdgeIfNeeded, ShouldAllowCrossOriginScrolling::No });
    31163116    else
    3117         anchorNode->renderer()->scrollRectToVisible(SelectionRevealMode::Reveal, rect, insideFixed, ScrollAlignment::alignLeftAlways, ScrollAlignment::alignToEdgeIfNeeded, ShouldAllowCrossOriginScrolling::No);
     3117        anchorNode->renderer()->scrollRectToVisible(rect, insideFixed, { SelectionRevealMode::Reveal, ScrollAlignment::alignLeftAlways, ScrollAlignment::alignToEdgeIfNeeded, ShouldAllowCrossOriginScrolling::No });
    31183118
    31193119    if (AXObjectCache* cache = frame().document()->existingAXObjectCache())
  • trunk/Source/WebCore/rendering/RenderLayer.cpp

    r235630 r235749  
    25032503}
    25042504
    2505 void RenderLayer::scrollRectToVisible(SelectionRevealMode revealMode, const LayoutRect& absoluteRect, bool insideFixed, const ScrollAlignment& alignX, const ScrollAlignment& alignY, ShouldAllowCrossOriginScrolling shouldAllowCrossOriginScrolling)
     2505void RenderLayer::scrollRectToVisible(const LayoutRect& absoluteRect, bool insideFixed, const ScrollRectToVisibleOptions& options)
    25062506{
    25072507    LOG_WITH_STREAM(Scrolling, stream << "Layer " << this << " scrollRectToVisible " << absoluteRect);
     
    25242524        LayoutRect localExposeRect(box->absoluteToLocalQuad(FloatQuad(FloatRect(absoluteRect))).boundingBox());
    25252525        LayoutRect layerBounds(0, 0, box->clientWidth(), box->clientHeight());
    2526         LayoutRect revealRect = getRectToExpose(layerBounds, localExposeRect, insideFixed, alignX, alignY);
     2526        LayoutRect revealRect = getRectToExpose(layerBounds, localExposeRect, insideFixed, options.alignX, options.alignY);
    25272527
    25282528        ScrollOffset clampedScrollOffset = clampScrollOffset(scrollOffset() + toIntSize(roundedIntRect(revealRect).location()));
     
    25482548
    25492549                LayoutRect viewRect = frameView.visibleContentRect(LegacyIOSDocumentVisibleRect);
    2550                 LayoutRect exposeRect = getRectToExpose(viewRect, absoluteRect, insideFixed, alignX, alignY);
     2550                LayoutRect exposeRect = getRectToExpose(viewRect, absoluteRect, insideFixed, options.alignX, options.alignY);
    25512551
    25522552                IntPoint scrollOffset(roundedIntPoint(exposeRect.location()));
     
    25552555                frameView.setScrollPosition(scrollOffset);
    25562556
    2557                 if (shouldAllowCrossOriginScrolling == ShouldAllowCrossOriginScrolling::Yes || frameView.safeToPropagateScrollToParent()) {
     2557                if (options.shouldAllowCrossOriginScrolling == ShouldAllowCrossOriginScrolling::Yes || frameView.safeToPropagateScrollToParent()) {
    25582558                    parentLayer = ownerElement->renderer()->enclosingLayer();
    25592559                    // Convert the rect into the coordinate space of the parent frame's document.
     
    25642564            }
    25652565        } else {
    2566             if (revealMode == SelectionRevealMode::RevealUpToMainFrame && frameView.frame().isMainFrame())
     2566            if (options.revealMode == SelectionRevealMode::RevealUpToMainFrame && frameView.frame().isMainFrame())
    25672567                return;
    25682568
     
    25762576            targetRect.move(0, frameView.headerHeight());
    25772577
    2578             LayoutRect revealRect = getRectToExpose(viewRect, targetRect, insideFixed, alignX, alignY);
     2578            LayoutRect revealRect = getRectToExpose(viewRect, targetRect, insideFixed, options.alignX, options.alignY);
    25792579           
    25802580            frameView.setScrollPosition(roundedIntPoint(revealRect.location()));
     
    25902590   
    25912591    if (parentLayer)
    2592         parentLayer->scrollRectToVisible(revealMode, newRect, insideFixed, alignX, alignY, shouldAllowCrossOriginScrolling);
     2592        parentLayer->scrollRectToVisible(newRect, insideFixed, options);
    25932593}
    25942594
     
    27132713{
    27142714    IntPoint currentDocumentPosition = renderer().view().frameView().windowToContents(positionInWindow);
    2715     scrollRectToVisible(SelectionRevealMode::Reveal, LayoutRect(currentDocumentPosition, LayoutSize(1, 1)), false, ScrollAlignment::alignToEdgeIfNeeded, ScrollAlignment::alignToEdgeIfNeeded, ShouldAllowCrossOriginScrolling::Yes);
     2715    scrollRectToVisible(LayoutRect(currentDocumentPosition, LayoutSize(1, 1)), false, { SelectionRevealMode::Reveal, ScrollAlignment::alignToEdgeIfNeeded, ScrollAlignment::alignToEdgeIfNeeded, ShouldAllowCrossOriginScrolling::Yes });
    27162716}
    27172717
  • trunk/Source/WebCore/rendering/RenderLayer.h

    r235630 r235749  
    121121};
    122122
     123struct ScrollRectToVisibleOptions {
     124    SelectionRevealMode revealMode { SelectionRevealMode::Reveal };
     125    const ScrollAlignment& alignX { ScrollAlignment::alignCenterIfNeeded };
     126    const ScrollAlignment& alignY { ScrollAlignment::alignCenterIfNeeded };
     127    ShouldAllowCrossOriginScrolling shouldAllowCrossOriginScrolling { ShouldAllowCrossOriginScrolling::No };
     128};
     129
    123130class RenderLayer final : public ScrollableArea {
    124131    WTF_MAKE_FAST_ALLOCATED;
     
    219226
    220227    // "absoluteRect" is in scaled document coordinates.
    221     void scrollRectToVisible(SelectionRevealMode, const LayoutRect& absoluteRect, bool insideFixed, const ScrollAlignment& alignX, const ScrollAlignment& alignY, ShouldAllowCrossOriginScrolling);
     228    void scrollRectToVisible(const LayoutRect& absoluteRect, bool insideFixed, const ScrollRectToVisibleOptions&);
    222229
    223230    bool scrollsOverflow() const;
  • trunk/Source/WebCore/rendering/RenderObject.cpp

    r232178 r235749  
    415415}
    416416
    417 bool RenderObject::scrollRectToVisible(SelectionRevealMode revealMode, const LayoutRect& absoluteRect, bool insideFixed, const ScrollAlignment& alignX, const ScrollAlignment& alignY, ShouldAllowCrossOriginScrolling shouldAllowCrossOriginScrolling)
    418 {
    419     if (revealMode == SelectionRevealMode::DoNotReveal)
     417bool RenderObject::scrollRectToVisible(const LayoutRect& absoluteRect, bool insideFixed, const ScrollRectToVisibleOptions& options)
     418{
     419    if (options.revealMode == SelectionRevealMode::DoNotReveal)
    420420        return false;
    421421
     
    424424        return false;
    425425
    426     enclosingLayer->scrollRectToVisible(revealMode, absoluteRect, insideFixed, alignX, alignY, shouldAllowCrossOriginScrolling);
     426    enclosingLayer->scrollRectToVisible(absoluteRect, insideFixed, options);
    427427    return true;
    428428}
  • trunk/Source/WebCore/rendering/RenderObject.h

    r234215 r235749  
    8484enum class ShouldAllowCrossOriginScrolling { No, Yes };
    8585
     86struct ScrollRectToVisibleOptions;
     87
    8688#if ENABLE(DASHBOARD_SUPPORT)
    8789struct AnnotatedRegionValue {
     
    159161
    160162    // Scrolling is a RenderBox concept, however some code just cares about recursively scrolling our enclosing ScrollableArea(s).
    161     WEBCORE_EXPORT bool scrollRectToVisible(SelectionRevealMode, const LayoutRect& absoluteRect, bool insideFixed, const ScrollAlignment& alignX = ScrollAlignment::alignCenterIfNeeded, const ScrollAlignment& alignY = ScrollAlignment::alignCenterIfNeeded, ShouldAllowCrossOriginScrolling = ShouldAllowCrossOriginScrolling::No);
     163    WEBCORE_EXPORT bool scrollRectToVisible(const LayoutRect& absoluteRect, bool insideFixed, const ScrollRectToVisibleOptions&);
    162164
    163165    // Convenience function for getting to the nearest enclosing box of a RenderObject.
  • trunk/Source/WebKitLegacy/mac/ChangeLog

    r235748 r235749  
     12018-09-06  Frederic Wang  <fwang@igalia.com>
     2
     3        Group options of scrollRectToVisible into a struct
     4        https://bugs.webkit.org/show_bug.cgi?id=189352
     5
     6        Reviewed by Simon Fraser.
     7
     8        * WebView/WebFrame.mm: Add header to use ScrollRectToVisibleOptions.
     9        (-[WebFrame _scrollDOMRangeToVisible:]): Pass options via a struct.
     10        (-[WebFrame _scrollDOMRangeToVisible:withInset:]): Ditto.
     11
    1122018-09-06  Wenson Hsieh  <wenson_hsieh@apple.com>
    213
  • trunk/Source/WebKitLegacy/mac/WebView/WebFrame.mm

    r235560 r235749  
    9090#import <WebCore/PluginData.h>
    9191#import <WebCore/PrintContext.h>
     92#import <WebCore/RenderLayer.h>
    9293#import <WebCore/RenderView.h>
    9394#import <WebCore/RenderWidget.h>
     
    742743    if (startNode && startNode->renderer()) {
    743744#if !PLATFORM(IOS)
    744         startNode->renderer()->scrollRectToVisible(SelectionRevealMode::Reveal, enclosingIntRect(rangeRect), insideFixed, ScrollAlignment::alignToEdgeIfNeeded, ScrollAlignment::alignToEdgeIfNeeded, ShouldAllowCrossOriginScrolling::Yes);
     745        startNode->renderer()->scrollRectToVisible(enclosingIntRect(rangeRect), insideFixed, { SelectionRevealMode::Reveal, ScrollAlignment::alignToEdgeIfNeeded, ScrollAlignment::alignToEdgeIfNeeded, ShouldAllowCrossOriginScrolling::Yes });
    745746#else
    746747        RenderLayer* layer = startNode->renderer()->enclosingLayer();
    747748        if (layer) {
    748749            layer->setAdjustForIOSCaretWhenScrolling(true);
    749             startNode->renderer()->scrollRectToVisible(SelectionRevealMode::Reveal, enclosingIntRect(rangeRect), insideFixed, ScrollAlignment::alignToEdgeIfNeeded, ScrollAlignment::alignToEdgeIfNeeded, ShouldAllowCrossOriginScrolling::Yes);
     750            startNode->renderer()->scrollRectToVisible(enclosingIntRect(rangeRect), insideFixed, { SelectionRevealMode::Reveal, ScrollAlignment::alignToEdgeIfNeeded, ScrollAlignment::alignToEdgeIfNeeded, ShouldAllowCrossOriginScrolling::Yes });
    750751            layer->setAdjustForIOSCaretWhenScrolling(false);
    751752            _private->coreFrame->selection().setCaretRectNeedsUpdate();
     
    767768        if (layer) {
    768769            layer->setAdjustForIOSCaretWhenScrolling(true);
    769             startNode->renderer()->scrollRectToVisible(SelectionRevealMode::Reveal, enclosingIntRect(rangeRect), insideFixed, ScrollAlignment::alignToEdgeIfNeeded, ScrollAlignment::alignToEdgeIfNeeded, ShouldAllowCrossOriginScrolling::Yes);
     770            startNode->renderer()->scrollRectToVisible(enclosingIntRect(rangeRect), insideFixed, { SelectionRevealMode::Reveal, ScrollAlignment::alignToEdgeIfNeeded, ScrollAlignment::alignToEdgeIfNeeded, ShouldAllowCrossOriginScrolling::Yes});
    770771            layer->setAdjustForIOSCaretWhenScrolling(false);
    771772
Note: See TracChangeset for help on using the changeset viewer.