Changeset 125306 in webkit
- Timestamp:
- Aug 10, 2012 11:42:38 AM (12 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r125304 r125306 1 2012-08-10 Allan Sandfeld Jensen <allan.jensen@nokia.com> 2 3 [Transforms] Hit test issue with large scale() transform 4 https://bugs.webkit.org/show_bug.cgi?id=23170 5 6 Reviewed by Simon Fraser. 7 8 New test checking that we can hit the bottom-right part of an element with 9 a large scale transformation. 10 11 Modified test-input on perspective-clipped.html, since it was mathematically 12 0.1px inside the transformed target, but used to miss due to bad rounding. 13 14 * fast/transforms/hit-test-large-scale-expected.txt: Added. 15 * fast/transforms/hit-test-large-scale.html: Added. 16 * transforms/3d/hit-testing/perspective-clipped-expected.txt: 17 * transforms/3d/hit-testing/perspective-clipped.html: 18 1 19 2012-08-10 Takashi Sakamoto <tasak@google.com> 2 20 -
trunk/LayoutTests/transforms/3d/hit-testing/perspective-clipped-expected.txt
r116543 r125306 10 10 Element at 370, 280 has id "bottomLayer": PASS 11 11 Element at 35, 340 has id "backgroundLayer": PASS 12 Element at 37 0, 340 has id "backgroundLayer": PASS12 Element at 371, 340 has id "backgroundLayer": PASS 13 13 -
trunk/LayoutTests/transforms/3d/hit-testing/perspective-clipped.html
r116543 r125306 80 80 // Points within the axis-aligned bounding box of the bottom layer, but not actually on the layer itself 81 81 { 'point': [35, 340], 'target' : 'backgroundLayer' }, 82 { 'point': [37 0, 340], 'target' : 'backgroundLayer' },82 { 'point': [371, 340], 'target' : 'backgroundLayer' }, 83 83 ]; 84 84 -
trunk/Source/WebCore/ChangeLog
r125305 r125306 1 2012-08-10 Allan Sandfeld Jensen <allan.jensen@nokia.com> 2 3 [Transforms] Hit test issue with large scale() transform 4 https://bugs.webkit.org/show_bug.cgi?id=23170 5 6 Reviewed by Simon Fraser. 7 8 By using normal rounding to determine the top-left corner of the 9 hit-tested rectangle, we end up offsetting the hit test by up to 10 half a pixel, once scaled to x60, this creates a 30px error. 11 12 Normal rounding is replaced with floored rounding which means the 13 hit-tested pixel will now always be the pixel containing the 14 point. 15 16 Test: fast/transforms/hit-test-large-scale.html 17 18 * rendering/HitTestResult.cpp: 19 (WebCore::HitTestPoint::HitTestPoint): 20 (WebCore::HitTestPoint::intersectsRect): 21 (WebCore::HitTestPoint::rectForPoint): 22 1 23 2012-08-10 Florin Malita <fmalita@chromium.org> 2 24 -
trunk/Source/WebCore/rendering/HitTestResult.cpp
r123754 r125306 68 68 69 69 HitTestPoint::HitTestPoint(const FloatPoint& point) 70 : m_point( roundedLayoutPoint(point))70 : m_point(flooredLayoutPoint(point)) 71 71 , m_boundingBox(rectForPoint(m_point, 0, 0, 0, 0)) 72 72 , m_transformedPoint(point) … … 84 84 , m_isRectBased(true) 85 85 { 86 m_point = roundedLayoutPoint(point);86 m_point = flooredLayoutPoint(point); 87 87 m_boundingBox = enclosingIntRect(quad.boundingBox()); 88 88 m_isRectilinear = quad.isRectilinear(); … … 182 182 IntRect HitTestPoint::rectForPoint(const LayoutPoint& point, unsigned topPadding, unsigned rightPadding, unsigned bottomPadding, unsigned leftPadding) 183 183 { 184 IntPoint actualPoint( roundedIntPoint(point));184 IntPoint actualPoint(flooredIntPoint(point)); 185 185 actualPoint -= IntSize(leftPadding, topPadding); 186 186
Note: See TracChangeset
for help on using the changeset viewer.