Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(224)

Issue 492053002: Use LayoutRect during addFocusRingRects to avoid loss of precision (Closed)

Created:
6 years, 4 months ago by Xianzhu
Modified:
6 years, 3 months ago
CC:
blink-reviews, blink-reviews-rendering, krit, eae+blinkwatch, ed+blinkwatch_opera.com, f(malita), fs, gyuyoung.kim_webkit.org, jchaffraix+rendering, kouhei+svg_chromium.org, leviw+renderwatch, pdr., rwlbuis, rune+blink, Stephen Chennney, zoltan1
Project:
blink
Visibility:
Public.

Description

Use LayoutRect during addFocusRingRects to avoid loss of precision Previously we use IntRect to store focus ring rects during addFocusRingRects(). This causes 1-pixel offset or size error when the result is offsetted again (e.g. when the focused element contains layers). Use LayoutRect to avoid errors. Also avoid pixel-snapping when passing additionalOffset. BUG=405422 TEST=fast/sub-pixel/focus-ring-around-sub-pixel-layer.html Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=181567

Patch Set 1 #

Total comments: 4

Patch Set 2 : Rebased, etc. #

Total comments: 1

Patch Set 3 : NeedsRebaseline (pixel tests about focus rings. 1-pixel width diff at the edge because of different rounding) #

Unified diffs Side-by-side diffs Delta from patch set Stats (+82 lines, -74 lines) Patch
M LayoutTests/TestExpectations View 1 2 1 chunk +14 lines, -0 lines 0 comments Download
M Source/core/rendering/RenderBlock.h View 1 1 chunk +1 line, -1 line 0 comments Download
M Source/core/rendering/RenderBlock.cpp View 1 3 chunks +5 lines, -5 lines 0 comments Download
M Source/core/rendering/RenderBox.h View 1 1 chunk +1 line, -1 line 0 comments Download
M Source/core/rendering/RenderBox.cpp View 1 2 chunks +8 lines, -8 lines 0 comments Download
M Source/core/rendering/RenderInline.h View 1 1 chunk +1 line, -1 line 0 comments Download
M Source/core/rendering/RenderInline.cpp View 1 2 chunks +25 lines, -29 lines 0 comments Download
M Source/core/rendering/RenderObject.h View 1 2 chunks +2 lines, -2 lines 0 comments Download
M Source/core/rendering/RenderObject.cpp View 1 2 4 chunks +13 lines, -15 lines 0 comments Download
M Source/core/rendering/RenderTextControl.h View 1 chunk +1 line, -1 line 0 comments Download
M Source/core/rendering/RenderTextControl.cpp View 1 chunk +2 lines, -2 lines 0 comments Download
M Source/core/rendering/svg/RenderSVGContainer.h View 1 chunk +1 line, -1 line 0 comments Download
M Source/core/rendering/svg/RenderSVGContainer.cpp View 1 chunk +2 lines, -2 lines 0 comments Download
M Source/core/rendering/svg/RenderSVGImage.h View 1 chunk +1 line, -1 line 0 comments Download
M Source/core/rendering/svg/RenderSVGImage.cpp View 1 chunk +2 lines, -2 lines 0 comments Download
M Source/core/rendering/svg/RenderSVGShape.h View 1 chunk +1 line, -1 line 0 comments Download
M Source/core/rendering/svg/RenderSVGShape.cpp View 1 chunk +2 lines, -2 lines 0 comments Download

Messages

Total messages: 14 (5 generated)
Julien - ping for review
Some early comments, Levi would probably have more on the general direction (I wasn't totally ...
6 years, 4 months ago (2014-08-20 22:12:31 UTC) #1
Xianzhu
https://codereview.chromium.org/492053002/diff/1/Source/core/rendering/RenderInline.cpp File Source/core/rendering/RenderInline.cpp (right): https://codereview.chromium.org/492053002/diff/1/Source/core/rendering/RenderInline.cpp#newcode1401 Source/core/rendering/RenderInline.cpp:1401: : toRenderBox(continuation())->location() - containingBlock()->location()); On 2014/08/20 22:12:31, Julien Chaffraix ...
6 years, 3 months ago (2014-09-04 00:29:12 UTC) #3
leviw_travelin_and_unemployed
lgtm https://codereview.chromium.org/492053002/diff/40001/Source/core/rendering/RenderObject.cpp File Source/core/rendering/RenderObject.cpp (right): https://codereview.chromium.org/492053002/diff/40001/Source/core/rendering/RenderObject.cpp#newcode1226 Source/core/rendering/RenderObject.cpp:1226: focusRingIntRects.append(pixelSnappedIntRect(focusRingRects[i])); It's unfortunate we're making an extra data ...
6 years, 3 months ago (2014-09-05 20:17:19 UTC) #4
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/wangxianzhu@chromium.org/492053002/40001
6 years, 3 months ago (2014-09-05 21:25:32 UTC) #6
Julien - ping for review
lgtm2
6 years, 3 months ago (2014-09-05 21:27:01 UTC) #7
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/wangxianzhu@chromium.org/492053002/60001
6 years, 3 months ago (2014-09-05 22:44:52 UTC) #9
commit-bot: I haz the power
Exceeded time limit waiting for builds to trigger.
6 years, 3 months ago (2014-09-06 04:45:34 UTC) #11
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/wangxianzhu@chromium.org/492053002/60001
6 years, 3 months ago (2014-09-08 16:04:19 UTC) #13
commit-bot: I haz the power
6 years, 3 months ago (2014-09-08 16:05:30 UTC) #14
Message was sent while issue was closed.
Committed patchset #3 (id:60001) as 181567

Powered by Google App Engine
This is Rietveld 408576698