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

Issue 1306993002: Cleanup friends of LayoutObject (Closed)

Created:
5 years, 4 months ago by Xianzhu
Modified:
5 years, 3 months ago
CC:
blink-reviews, blink-reviews-paint_chromium.org, blink-reviews-rendering, dshwang, eae+blinkwatch, jchaffraix+rendering, leviw+renderwatch, pdr+renderingwatchlist_chromium.org, slimming-paint-reviews_chromium.org, szager+layoutwatch_chromium.org, zoltan1
Target Ref:
refs/heads/master
Project:
blink
Visibility:
Public.

Description

Cleanup friends of LayoutObject The friends of LayoutObject only need to access the layout tree mutation methods, but get access to all LayoutObject private members. Add LayoutObject::setDangerousOneWayParent() to avoid friends. Expose several private/protected members to public which were accessed using friend relationship. Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=201265

Patch Set 1 #

Patch Set 2 : #

Patch Set 3 : #

Total comments: 9

Patch Set 4 : Simplify #

Total comments: 2

Patch Set 5 : remove LayoutBlock::promoteAllChildrenAndInsertAfter #

Total comments: 4

Patch Set 6 : document #

Total comments: 2

Patch Set 7 : #

Unified diffs Side-by-side diffs Delta from patch set Stats (+38 lines, -47 lines) Patch
M Source/core/layout/LayoutBlock.h View 1 2 3 4 1 chunk +0 lines, -3 lines 0 comments Download
M Source/core/layout/LayoutBlock.cpp View 1 2 3 4 5 4 chunks +3 lines, -24 lines 0 comments Download
M Source/core/layout/LayoutBlockFlow.cpp View 2 chunks +2 lines, -2 lines 0 comments Download
M Source/core/layout/LayoutObject.h View 1 2 3 4 5 6 8 chunks +19 lines, -12 lines 0 comments Download
M Source/core/layout/LayoutObject.cpp View 1 2 3 4 5 6 2 chunks +10 lines, -2 lines 0 comments Download
M Source/core/paint/DeprecatedPaintLayerReflectionInfo.cpp View 1 2 3 2 chunks +2 lines, -2 lines 0 comments Download
M Source/core/paint/DeprecatedPaintLayerScrollableArea.cpp View 1 2 3 4 2 chunks +2 lines, -2 lines 0 comments Download

Messages

Total messages: 34 (11 generated)
Xianzhu
5 years, 4 months ago (2015-08-21 19:52:05 UTC) #2
leviw_travelin_and_unemployed
https://codereview.chromium.org/1306993002/diff/40001/Source/core/layout/LayoutObject.h File Source/core/layout/LayoutObject.h (right): https://codereview.chromium.org/1306993002/diff/40001/Source/core/layout/LayoutObject.h#newcode264 Source/core/layout/LayoutObject.h:264: class DangerousLayoutTreeMutator { I'd refactor this out of the ...
5 years, 4 months ago (2015-08-21 21:10:42 UTC) #3
pdr.
LGTM, DangerousLayoutTreeMutator is a fun name. +cc esprehn, could you please take a look too?
5 years, 4 months ago (2015-08-21 21:11:58 UTC) #5
pdr.
On 2015/08/21 at 21:10:42, leviw wrote: > https://codereview.chromium.org/1306993002/diff/40001/Source/core/layout/LayoutObject.h > File Source/core/layout/LayoutObject.h (right): > > https://codereview.chromium.org/1306993002/diff/40001/Source/core/layout/LayoutObject.h#newcode264 ...
5 years, 4 months ago (2015-08-21 21:14:20 UTC) #6
leviw_travelin_and_unemployed
On 2015/08/21 at 21:11:58, pdr wrote: > LGTM, DangerousLayoutTreeMutator is a fun name. I also ...
5 years, 4 months ago (2015-08-21 21:15:15 UTC) #7
esprehn
Can we fix the bug and do the refactor separately? It's hard to review this ...
5 years, 4 months ago (2015-08-21 21:20:32 UTC) #8
Xianzhu
The new patch is much simpler because we only need to expose setParent() which is ...
5 years, 4 months ago (2015-08-21 22:52:19 UTC) #9
mstensho (USE GERRIT)
https://codereview.chromium.org/1306993002/diff/60001/Source/core/layout/LayoutBlock.cpp File Source/core/layout/LayoutBlock.cpp (right): https://codereview.chromium.org/1306993002/diff/60001/Source/core/layout/LayoutBlock.cpp#newcode558 Source/core/layout/LayoutBlock.cpp:558: moveAllChildrenTo(toLayoutBoxModelObject(parent()), nextSibling()); Might as well get rid of promoteAllChildrenAndInsertAfter(), ...
5 years, 4 months ago (2015-08-24 10:37:27 UTC) #11
Xianzhu
https://codereview.chromium.org/1306993002/diff/60001/Source/core/layout/LayoutBlock.cpp File Source/core/layout/LayoutBlock.cpp (right): https://codereview.chromium.org/1306993002/diff/60001/Source/core/layout/LayoutBlock.cpp#newcode558 Source/core/layout/LayoutBlock.cpp:558: moveAllChildrenTo(toLayoutBoxModelObject(parent()), nextSibling()); On 2015/08/24 10:37:27, mstensho wrote: > Might ...
5 years, 4 months ago (2015-08-24 16:41:34 UTC) #12
Xianzhu
Any more comments?
5 years, 3 months ago (2015-08-25 22:45:08 UTC) #13
chrishtr
https://codereview.chromium.org/1306993002/diff/80001/Source/core/layout/LayoutObject.h File Source/core/layout/LayoutObject.h (right): https://codereview.chromium.org/1306993002/diff/80001/Source/core/layout/LayoutObject.h#newcode1060 Source/core/layout/LayoutObject.h:1060: void removeFromLayoutFlowThread(); Document. https://codereview.chromium.org/1306993002/diff/80001/Source/core/layout/LayoutObject.h#newcode1062 Source/core/layout/LayoutObject.h:1062: virtual void updateAnonymousChildStyle(const LayoutObject& ...
5 years, 3 months ago (2015-08-25 23:27:35 UTC) #14
Xianzhu
https://codereview.chromium.org/1306993002/diff/80001/Source/core/layout/LayoutObject.h File Source/core/layout/LayoutObject.h (right): https://codereview.chromium.org/1306993002/diff/80001/Source/core/layout/LayoutObject.h#newcode1060 Source/core/layout/LayoutObject.h:1060: void removeFromLayoutFlowThread(); On 2015/08/25 23:27:35, chrishtr wrote: > Document. ...
5 years, 3 months ago (2015-08-26 00:23:53 UTC) #15
chrishtr
lgtm https://codereview.chromium.org/1306993002/diff/100001/Source/core/layout/LayoutObject.h File Source/core/layout/LayoutObject.h (right): https://codereview.chromium.org/1306993002/diff/100001/Source/core/layout/LayoutObject.h#newcode264 Source/core/layout/LayoutObject.h:264: void setDangerousOneWayParent(LayoutObject* parent) I don't think this needs ...
5 years, 3 months ago (2015-08-26 02:59:19 UTC) #16
esprehn
lgtm, beautiful. Land away after fixing christr@'s nit.
5 years, 3 months ago (2015-08-26 07:43:47 UTC) #17
Xianzhu
https://codereview.chromium.org/1306993002/diff/100001/Source/core/layout/LayoutObject.h File Source/core/layout/LayoutObject.h (right): https://codereview.chromium.org/1306993002/diff/100001/Source/core/layout/LayoutObject.h#newcode264 Source/core/layout/LayoutObject.h:264: void setDangerousOneWayParent(LayoutObject* parent) On 2015/08/26 02:59:19, chrishtr wrote: > ...
5 years, 3 months ago (2015-08-26 16:12:04 UTC) #18
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1306993002/120001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1306993002/120001
5 years, 3 months ago (2015-08-26 16:12:18 UTC) #21
commit-bot: I haz the power
Try jobs failed on following builders: mac_chromium_rel_ng on tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_rel_ng/builds/104696)
5 years, 3 months ago (2015-08-26 16:37:14 UTC) #23
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1306993002/120001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1306993002/120001
5 years, 3 months ago (2015-08-26 16:44:01 UTC) #25
commit-bot: I haz the power
Try jobs failed on following builders: win_chromium_x64_rel_ng on tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_x64_rel_ng/builds/95904)
5 years, 3 months ago (2015-08-26 16:51:12 UTC) #27
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1306993002/120001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1306993002/120001
5 years, 3 months ago (2015-08-26 16:52:01 UTC) #29
commit-bot: I haz the power
Try jobs failed on following builders: mac_chromium_rel_ng on tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_rel_ng/builds/104717)
5 years, 3 months ago (2015-08-26 17:06:17 UTC) #31
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1306993002/120001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1306993002/120001
5 years, 3 months ago (2015-08-26 23:11:35 UTC) #33
commit-bot: I haz the power
5 years, 3 months ago (2015-08-27 00:18:03 UTC) #34
Message was sent while issue was closed.
Committed patchset #7 (id:120001) as
https://src.chromium.org/viewvc/blink?view=rev&revision=201265

Powered by Google App Engine
This is Rietveld 408576698