Changeset 254492 in webkit


Ignore:
Timestamp:
Jan 13, 2020 9:40:51 PM (4 years ago)
Author:
Simon Fraser
Message:

Scrollbar hiding on iOS via ::-webkit-scrollbar { display: none } doesn't work
https://bugs.webkit.org/show_bug.cgi?id=206197

Reviewed by Tim Horton.
Source/WebCore:

The logic added in r251369 was reversed, causing scrollbar hiding to not work correctly.

Tested by fast/scrolling/ios/scrollbar-hiding.html

  • rendering/RenderScrollbar.cpp:

(WebCore::RenderScrollbar::isHiddenByStyle const):

LayoutTests:

The logic added in r251369 was reversed, causing scrollbar hiding to not work correctly.

  • fast/scrolling/ios/scrollbar-hiding-expected.txt:
Location:
trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r254486 r254492  
     12020-01-13  Simon Fraser  <simon.fraser@apple.com>
     2
     3        Scrollbar hiding on iOS via ::-webkit-scrollbar { display: none } doesn't work
     4        https://bugs.webkit.org/show_bug.cgi?id=206197
     5
     6        Reviewed by Tim Horton.
     7       
     8        The logic added in r251369 was reversed, causing scrollbar hiding to not work correctly.
     9
     10        * fast/scrolling/ios/scrollbar-hiding-expected.txt:
     11
    1122020-01-13  Pablo Saavedra  <psaavedra@igalia.com>
    213
  • trunk/LayoutTests/fast/scrolling/ios/scrollbar-hiding-expected.txt

    r251369 r254492  
    3636        (vertical scrollbar mode 0)
    3737        (has enabled horizontal scrollbar 1)
     38        (has enabled vertical scrollbar 1)))
     39    (overflow scrolling node
     40      (scrollable area size width=200 height=100)
     41      (total content size width=400 height=200)
     42      (last committed scroll position (0,0))
     43      (scrollable area parameters
     44        (horizontal scroll elasticity 1)
     45        (vertical scroll elasticity 1)
     46        (horizontal scrollbar mode 0)
     47        (vertical scrollbar mode 0)
     48        (has enabled horizontal scrollbar 1)
    3849        (has enabled vertical scrollbar 1)
    39         (horizontal scrollbar hidden by style 1)
    4050        (vertical scrollbar hidden by style 1)))
    4151    (overflow scrolling node
     
    6272        (has enabled horizontal scrollbar 1)
    6373        (has enabled vertical scrollbar 1)
    64         (vertical scrollbar hidden by style 1)))
    65     (overflow scrolling node
    66       (scrollable area size width=200 height=100)
    67       (total content size width=400 height=200)
    68       (last committed scroll position (0,0))
    69       (scrollable area parameters
    70         (horizontal scroll elasticity 1)
    71         (vertical scroll elasticity 1)
    72         (horizontal scrollbar mode 0)
    73         (vertical scrollbar mode 0)
    74         (has enabled horizontal scrollbar 1)
    75         (has enabled vertical scrollbar 1)))))
     74        (horizontal scrollbar hidden by style 1)
     75        (vertical scrollbar hidden by style 1)))))
  • trunk/Source/WebCore/ChangeLog

    r254490 r254492  
     12020-01-13  Simon Fraser  <simon.fraser@apple.com>
     2
     3        Scrollbar hiding on iOS via ::-webkit-scrollbar { display: none } doesn't work
     4        https://bugs.webkit.org/show_bug.cgi?id=206197
     5
     6        Reviewed by Tim Horton.
     7
     8        The logic added in r251369 was reversed, causing scrollbar hiding to not work correctly.
     9       
     10        Tested by fast/scrolling/ios/scrollbar-hiding.html
     11
     12        * rendering/RenderScrollbar.cpp:
     13        (WebCore::RenderScrollbar::isHiddenByStyle const):
     14
    1152020-01-13  Jer Noble  <jer.noble@apple.com>
    216
  • trunk/Source/WebCore/rendering/RenderScrollbar.cpp

    r252628 r254492  
    364364{
    365365    std::unique_ptr<RenderStyle> partStyle = getScrollbarPseudoStyle(ScrollbarBGPart, pseudoForScrollbarPart(ScrollbarBGPart));
    366     return partStyle && partStyle->display() != DisplayType::None;
    367 }
    368 
    369 }
     366    return partStyle && partStyle->display() == DisplayType::None;
     367}
     368
     369}
Note: See TracChangeset for help on using the changeset viewer.