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

Issue 2128633002: cc: Set up the framework to restrict access to Layer internals. (Closed)

Created:
4 years, 5 months ago by khushalsagar
Modified:
4 years, 5 months ago
Reviewers:
enne (OOO), Khushal
CC:
cc-bugs_chromium.org, chromium-reviews
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

cc: Clean up Layer and the Layer public API. To create a distinction between the Layer data that is received from the embedder and values that are internally cached or set during PropertyTree building, move the embedder data, callbacks and interfaces into a seperate struct. Also move public methods on Layer which are meant to be used internally in cc but shouldn't be made available to the embedder to private and restrict access using an explicit friend list. The patch only moves the variables and method declarations and should be a no-op. BUG=625284 CQ_INCLUDE_TRYBOTS=tryserver.blink:linux_blink_rel Committed: https://crrev.com/b51998fe37830e22bd770de5f5ad08b663b465fd Cr-Commit-Position: refs/heads/master@{#404286}

Patch Set 1 #

Patch Set 2 : Addressed comments. #

Patch Set 3 : Move data from embedder into struct. #

Total comments: 5

Patch Set 4 : Also add change to make methods private. #

Patch Set 5 : Move out the inner struct. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+688 lines, -560 lines) Patch
M cc/BUILD.gn View 3 1 chunk +2 lines, -0 lines 0 comments Download
M cc/cc_tests.gyp View 1 3 1 chunk +2 lines, -0 lines 0 comments Download
M cc/layers/heads_up_display_layer.cc View 1 2 1 chunk +1 line, -1 line 0 comments Download
M cc/layers/layer.h View 1 2 3 4 22 chunks +163 lines, -127 lines 0 comments Download
M cc/layers/layer.cc View 1 2 3 4 61 chunks +323 lines, -308 lines 0 comments Download
M cc/layers/layer_unittest.cc View 1 2 3 4 12 chunks +134 lines, -117 lines 0 comments Download
M cc/layers/painted_scrollbar_layer.cc View 1 2 1 chunk +1 line, -1 line 0 comments Download
M cc/layers/texture_layer.cc View 1 2 1 chunk +1 line, -1 line 0 comments Download
M cc/layers/video_layer.cc View 1 2 1 chunk +1 line, -1 line 0 comments Download
M cc/test/fake_picture_layer.cc View 1 2 1 chunk +2 lines, -2 lines 0 comments Download
A cc/test/layer_internals_for_test.h View 1 3 1 chunk +28 lines, -0 lines 0 comments Download
A cc/test/layer_internals_for_test.cc View 1 3 1 chunk +27 lines, -0 lines 0 comments Download
M cc/trees/layer_tree_host_unittest.cc View 3 2 chunks +2 lines, -1 line 0 comments Download
M cc/trees/tree_synchronizer_unittest.cc View 1 2 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 34 (13 generated)
Khushal
If we are using friend classes then this looks like the cleanest way to restrict ...
4 years, 5 months ago (2016-07-06 18:31:43 UTC) #3
enne (OOO)
I think this would work but just feels a little bit more overengineered than maybe ...
4 years, 5 months ago (2016-07-06 19:57:42 UTC) #4
Khushal
On 2016/07/06 19:57:42, enne wrote: > I think this would work but just feels a ...
4 years, 5 months ago (2016-07-06 20:36:42 UTC) #5
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2128633002/20001
4 years, 5 months ago (2016-07-06 20:37:50 UTC) #7
enne (OOO)
Thanks! lgtm
4 years, 5 months ago (2016-07-06 20:49:01 UTC) #8
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: linux_android_rel_ng on master.tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/linux_android_rel_ng/builds/99303)
4 years, 5 months ago (2016-07-06 22:08:46 UTC) #11
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2128633002/40001
4 years, 5 months ago (2016-07-07 02:38:25 UTC) #14
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
4 years, 5 months ago (2016-07-07 03:54:10 UTC) #16
Khushal
I'll just move the data that comes from the embedder into a separate struct. We ...
4 years, 5 months ago (2016-07-07 16:43:06 UTC) #18
enne (OOO)
I think making functions private and friend classes would also help clean up the layer ...
4 years, 5 months ago (2016-07-07 17:32:01 UTC) #19
Khushal
Okay, included the initial change for making methods private as well. I'll see if there ...
4 years, 5 months ago (2016-07-07 18:16:40 UTC) #21
Khushal
On 2016/07/07 18:16:40, Khushal wrote: > Okay, included the initial change for making methods private ...
4 years, 5 months ago (2016-07-07 22:00:31 UTC) #23
enne (OOO)
https://codereview.chromium.org/2128633002/diff/40001/cc/layers/layer.h File cc/layers/layer.h (right): https://codereview.chromium.org/2128633002/diff/40001/cc/layers/layer.h#newcode619 cc/layers/layer.h:619: struct Data { On 2016/07/07 at 18:16:39, Khushal wrote: ...
4 years, 5 months ago (2016-07-07 22:10:10 UTC) #24
Khushal
https://codereview.chromium.org/2128633002/diff/40001/cc/layers/layer.h File cc/layers/layer.h (right): https://codereview.chromium.org/2128633002/diff/40001/cc/layers/layer.h#newcode619 cc/layers/layer.h:619: struct Data { On 2016/07/07 22:10:10, enne wrote: > ...
4 years, 5 months ago (2016-07-07 22:23:07 UTC) #25
enne (OOO)
https://codereview.chromium.org/2128633002/diff/40001/cc/layers/layer.h File cc/layers/layer.h (right): https://codereview.chromium.org/2128633002/diff/40001/cc/layers/layer.h#newcode619 cc/layers/layer.h:619: struct Data { On 2016/07/07 at 22:23:07, Khushal wrote: ...
4 years, 5 months ago (2016-07-07 22:24:54 UTC) #26
Khushal
On 2016/07/07 22:24:54, enne wrote: > https://codereview.chromium.org/2128633002/diff/40001/cc/layers/layer.h > File cc/layers/layer.h (right): > > https://codereview.chromium.org/2128633002/diff/40001/cc/layers/layer.h#newcode619 > ...
4 years, 5 months ago (2016-07-07 23:00:48 UTC) #27
enne (OOO)
lgtm
4 years, 5 months ago (2016-07-07 23:10:36 UTC) #28
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2128633002/80001
4 years, 5 months ago (2016-07-07 23:23:43 UTC) #30
commit-bot: I haz the power
Committed patchset #5 (id:80001)
4 years, 5 months ago (2016-07-08 01:04:38 UTC) #31
commit-bot: I haz the power
CQ bit was unchecked.
4 years, 5 months ago (2016-07-08 01:05:06 UTC) #32
commit-bot: I haz the power
4 years, 5 months ago (2016-07-08 01:05:53 UTC) #34
Message was sent while issue was closed.
Patchset 5 (id:??) landed as
https://crrev.com/b51998fe37830e22bd770de5f5ad08b663b465fd
Cr-Commit-Position: refs/heads/master@{#404286}

Powered by Google App Engine
This is Rietveld 408576698