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

Issue 1185423003: Add a Paint::toString() method to describe our Paint objects. (Closed)

Created:
5 years, 6 months ago by Matt Perry
Modified:
5 years, 6 months ago
Reviewers:
Hixie, abarth-chromium
CC:
abarth-chromium, gregsimon, jackson_old, mojo-reviews_chromium.org, qsr+mojo_chromium.org
Base URL:
git@github.com:/domokit/mojo.git@master
Target Ref:
refs/heads/master
Project:
mojo
Visibility:
Public.

Description

Add a Paint::toString() method to describe our Paint objects. Add a test for RenderDecoratedBox sets up the Paint object correctly. R=abarth@chromium.org Committed: https://chromium.googlesource.com/external/mojo/+/76be4bdb6cd360535148321afc2b153200286108

Patch Set 1 #

Patch Set 2 : less verbose toString #

Total comments: 8

Patch Set 3 : abarth #

Unified diffs Side-by-side diffs Delta from patch set Stats (+257 lines, -221 lines) Patch
M sky/engine/core/painting/Paint.h View 2 chunks +27 lines, -25 lines 0 comments Download
M sky/engine/core/painting/Paint.cpp View 1 2 1 chunk +58 lines, -28 lines 0 comments Download
M sky/engine/core/painting/Paint.idl View 1 chunk +2 lines, -0 lines 0 comments Download
M sky/examples/raw/painting.sky View 1 2 1 chunk +3 lines, -3 lines 0 comments Download
M sky/examples/raw/shadow.dart View 1 2 1 chunk +1 line, -1 line 0 comments Download
M sky/examples/rendering/shadowed_box.dart View 1 2 1 chunk +1 line, -1 line 0 comments Download
M sky/tests/examples/sector-expected.txt View 1 2 28 chunks +109 lines, -109 lines 0 comments Download
M sky/tests/examples/stocks-expected.txt View 1 2 3 chunks +4 lines, -4 lines 0 comments Download
M sky/tests/raw/box_layout-expected.txt View 1 2 1 chunk +2 lines, -2 lines 0 comments Download
M sky/tests/raw/render_box.dart View 1 1 chunk +8 lines, -1 line 0 comments Download
M sky/tests/raw/render_box-expected.txt View 1 1 chunk +1 line, -1 line 0 comments Download
M sky/tests/raw/render_flex-expected.txt View 1 1 chunk +9 lines, -9 lines 0 comments Download
M sky/tests/raw/sector_layout-expected.txt View 1 1 chunk +5 lines, -5 lines 0 comments Download
M sky/tests/resources/display_list.dart View 1 2 3 chunks +9 lines, -14 lines 0 comments Download
M sky/tests/widgets/buttons-expected.txt View 1 2 3 chunks +4 lines, -4 lines 0 comments Download
M sky/tests/widgets/dialog-expected.txt View 1 2 1 chunk +2 lines, -2 lines 0 comments Download
M sky/tests/widgets/syncs1-expected.txt View 1 2 6 chunks +12 lines, -12 lines 0 comments Download

Messages

Total messages: 6 (2 generated)
Matt Perry
ping
5 years, 6 months ago (2015-06-18 17:16:44 UTC) #2
abarth-chromium
lgtm https://codereview.chromium.org/1185423003/diff/20001/sky/engine/core/painting/Paint.cpp File sky/engine/core/painting/Paint.cpp (right): https://codereview.chromium.org/1185423003/diff/20001/sky/engine/core/painting/Paint.cpp#newcode18 sky/engine/core/painting/Paint.cpp:18: void SkToString(const char* title, const T* sk_obj, String* ...
5 years, 6 months ago (2015-06-18 17:30:52 UTC) #4
Matt Perry
Committed patchset #3 (id:40001) manually as 76be4bdb6cd360535148321afc2b153200286108 (presubmit successful).
5 years, 6 months ago (2015-06-18 17:47:32 UTC) #5
Matt Perry
5 years, 6 months ago (2015-06-18 17:59:33 UTC) #6
Message was sent while issue was closed.
https://codereview.chromium.org/1185423003/diff/20001/sky/engine/core/paintin...
File sky/engine/core/painting/Paint.cpp (right):

https://codereview.chromium.org/1185423003/diff/20001/sky/engine/core/paintin...
sky/engine/core/painting/Paint.cpp:18: void SkToString(const char* title, const
T* sk_obj, String* result) {
On 2015/06/18 17:30:52, abarth wrote:
> s/sk_obj/sk_object/

Done.

https://codereview.chromium.org/1185423003/diff/20001/sky/engine/core/paintin...
sky/engine/core/painting/Paint.cpp:21: SkString str;
On 2015/06/18 17:30:52, abarth wrote:
> s/str/string
> 
> (Please use complete words for variable names.)

Done.

https://codereview.chromium.org/1185423003/diff/20001/sky/engine/core/paintin...
sky/engine/core/painting/Paint.cpp:24: }
On 2015/06/18 17:30:52, abarth wrote:
> e usually put these sorts of things inside an anonymous namespace inside the
> blink namespace.

Done.

https://codereview.chromium.org/1185423003/diff/20001/sky/engine/core/paintin...
sky/engine/core/painting/Paint.cpp:64: String result = "Paint(";
On 2015/06/18 17:30:51, abarth wrote:
> s/String/StringBuilder/
> 
> String's append method is super expensive because it reallocates the String's
> buffer each time.  Instead, StringBuilder knows now to build strings
> efficiently.

Done.

Powered by Google App Engine
This is Rietveld 408576698