Changeset 165388 in webkit


Ignore:
Timestamp:
Mar 10, 2014 11:48:49 AM (10 years ago)
Author:
stavila@adobe.com
Message:

[CSS Regions] Hit-testing is not working properly inside scrollable regions
https://bugs.webkit.org/show_bug.cgi?id=130015

Reviewed by Antti Koivisto.

Source/WebCore:

When hit-testing inside the flow thread's layer, the scrolled offset
of the current region must be taken into consideration.

Test: fast/regions/scrollable-regions-hit-testing-inside.html

  • rendering/RenderLayer.cpp:

(WebCore::RenderLayer::calculateClipRects):

LayoutTests:

Added test for hit-testing inside scrollable regions.

  • fast/regions/scrollable-regions-hit-testing-inside-expected.html: Added.
  • fast/regions/scrollable-regions-hit-testing-inside.html: Added.
Location:
trunk
Files:
2 added
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r165387 r165388  
     12014-03-10  Radu Stavila  <stavila@adobe.com>
     2
     3        [CSS Regions] Hit-testing is not working properly inside scrollable regions
     4        https://bugs.webkit.org/show_bug.cgi?id=130015
     5
     6        Reviewed by Antti Koivisto.
     7
     8        Added test for hit-testing inside scrollable regions.
     9
     10        * fast/regions/scrollable-regions-hit-testing-inside-expected.html: Added.
     11        * fast/regions/scrollable-regions-hit-testing-inside.html: Added.
     12
    1132014-03-10  Hans Muller  <hmuller@adobe.com>
    214
  • trunk/Source/WebCore/ChangeLog

    r165387 r165388  
     12014-03-10  Radu Stavila  <stavila@adobe.com>
     2
     3        [CSS Regions] Hit-testing is not working properly inside scrollable regions
     4        https://bugs.webkit.org/show_bug.cgi?id=130015
     5
     6        Reviewed by Antti Koivisto.
     7
     8        When hit-testing inside the flow thread's layer, the scrolled offset
     9        of the current region must be taken into consideration.
     10
     11        Test: fast/regions/scrollable-regions-hit-testing-inside.html
     12
     13        * rendering/RenderLayer.cpp:
     14        (WebCore::RenderLayer::calculateClipRects):
     15
    1162014-03-10  Hans Muller  <hmuller@adobe.com>
    217
  • trunk/Source/WebCore/rendering/RenderLayer.cpp

    r165211 r165388  
    68776877
    68786878    LayoutRect regionContentBox = toRenderBlockFlow(&renderer())->contentBoxRect();
     6879    IntSize scrolledContentOffset = region->fragmentContainer().hasOverflowClip() ? region->fragmentContainer().scrolledContentOffset() : IntSize();
    68796880
    68806881    RenderLayer* resultLayer = 0;
     
    68856886            continue;
    68866887
    6887         LayoutSize hitTestOffset = portionLocation - (fragment.layerBounds.location() + regionContentBox.location());
     6888        LayoutSize hitTestOffset = portionLocation - (fragment.layerBounds.location() + regionContentBox.location()) + scrolledContentOffset;
    68886889
    68896890        // Always ignore clipping, since the RenderFlowThread has nothing to do with the bounds of the FrameView.
Note: See TracChangeset for help on using the changeset viewer.