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

Unified Diff: sky/examples/raw/painting.sky

Issue 1180873003: Sky: Small fixes to Gradient interface. Added comments and renamed constructors. (Closed) Base URL: git@github.com:/domokit/mojo.git@master
Patch Set: Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « sky/engine/core/painting/Gradient.dart ('k') | sky/sdk/lib/framework/painting/box_painter.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/examples/raw/painting.sky
diff --git a/sky/examples/raw/painting.sky b/sky/examples/raw/painting.sky
index feb702c813ab54b8542f851eb6a4fe969f3161df..b4326aee1eda9973c00847e9ebf5fbdcdcd95fd3 100644
--- a/sky/examples/raw/painting.sky
+++ b/sky/examples/raw/painting.sky
@@ -26,10 +26,9 @@ void main() {
paint.color = const Color.fromARGB(128, 255, 0, 255);
context.rotate(math.PI/4.0);
- Gradient yellowBlue = new Gradient.Linear(
+ Gradient yellowBlue = new Gradient.linear(
[new Point(-radius, -radius), new Point(0.0, 0.0)],
- [const Color(0xFFFFFF00), const Color(0xFF0000FF)],
- null);
+ [const Color(0xFFFFFF00), const Color(0xFF0000FF)]);
context.drawRect(new Rect.fromLTRB(-radius, -radius, radius, radius),
new Paint()..setShader(yellowBlue));
@@ -67,7 +66,7 @@ void main() {
..setColorMode(TransferMode.srcMode)
..setPaintBits(-1),
(Paint layerPaint) {
- Gradient redYellow = new Gradient.Radial(
+ Gradient redYellow = new Gradient.radial(
new Point(0.0, 0.0), radius/3.0,
[const Color(0xFFFFFF00), const Color(0xFFFF0000)],
null, TileMode.mirror);
« no previous file with comments | « sky/engine/core/painting/Gradient.dart ('k') | sky/sdk/lib/framework/painting/box_painter.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698