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

Issue 1151673002: Sky: different tack for custom Rect type in the Canvas API. (Closed)

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

Description

Sky: different tack for custom Rect type in the Canvas API. Rect is now a dart-only type, defined in its own .dart file. I use DartConverter when passing a Rect into C++. I also special-cased Rect in the IDL compiler so that it's passed by value, instead of allocating a new Rect object on the heap. This also adds a mechanism to add custom .dart files to dart_sky.dart - used by Rect.dart. R=eseidel@chromium.org Committed: https://chromium.googlesource.com/external/mojo/+/35734ee34225770865be6e5bbe1a2476299333de

Patch Set 1 #

Patch Set 2 : . #

Patch Set 3 : Float32List #

Unified diffs Side-by-side diffs Delta from patch set Stats (+146 lines, -88 lines) Patch
M sky/engine/bindings/BUILD.gn View 2 chunks +9 lines, -1 line 0 comments Download
M sky/engine/bindings/scripts/code_generator_dart.py View 2 chunks +8 lines, -11 lines 0 comments Download
M sky/engine/bindings/scripts/dart_types.py View 2 chunks +2 lines, -0 lines 0 comments Download
M sky/engine/bindings/scripts/templates/dart_blink.template View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M sky/engine/bindings/scripts/templates/interface_dart.template View 3 chunks +4 lines, -7 lines 0 comments Download
M sky/engine/core/core.gni View 1 2 chunks +4 lines, -0 lines 0 comments Download
M sky/engine/core/painting/Canvas.h View 1 3 chunks +5 lines, -4 lines 0 comments Download
M sky/engine/core/painting/Canvas.cpp View 1 5 chunks +9 lines, -20 lines 0 comments Download
D sky/engine/core/painting/Canvas.dart View 1 chunk +0 lines, -40 lines 0 comments Download
M sky/engine/core/painting/Canvas.idl View 2 chunks +5 lines, -5 lines 0 comments Download
A sky/engine/core/painting/Rect.h View 1 1 chunk +29 lines, -0 lines 0 comments Download
A sky/engine/core/painting/Rect.cpp View 1 2 1 chunk +53 lines, -0 lines 0 comments Download
A sky/engine/core/painting/Rect.dart View 1 2 1 chunk +17 lines, -0 lines 0 comments Download

Messages

Total messages: 8 (2 generated)
Matt Perry
5 years, 7 months ago (2015-05-20 19:12:52 UTC) #2
abarth-chromium
Would it be better to use https://api.dartlang.org/apidocs/channels/stable/dartdoc-viewer/dart:typed_data.Float32x4 as the internal representation of the Rect?
5 years, 7 months ago (2015-05-20 19:51:06 UTC) #4
abarth-chromium
Then you could use Dart_TypedDataAcquireData to get at the data faster.
5 years, 7 months ago (2015-05-20 19:52:26 UTC) #5
eseidel
lgtm modulo abarth's question.
5 years, 7 months ago (2015-05-20 20:31:11 UTC) #6
Matt Perry
On 2015/05/20 19:52:26, abarth wrote: > Then you could use Dart_TypedDataAcquireData to get at the ...
5 years, 7 months ago (2015-05-20 20:55:40 UTC) #7
Matt Perry
5 years, 7 months ago (2015-05-20 21:58:41 UTC) #8
Message was sent while issue was closed.
Committed patchset #3 (id:40001) manually as
35734ee34225770865be6e5bbe1a2476299333de (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698