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

Side by Side Diff: samples/logo/logo.dart

Issue 10829459: Deprecate Math object in corelib in favor of dart:math library. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address review comments. Created 8 years, 4 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « samples/isolate_html/isolate_sample.dart ('k') | samples/matrix/matrix_client.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #import('dart:html'); 5 #import('dart:html');
6 #import('dart:math', prefix: 'Math');
6 7
7 class Color { 8 class Color {
8 int hue; 9 int hue;
9 double saturation; 10 double saturation;
10 double lightness; 11 double lightness;
11 12
12 Color(int this.hue, double this.saturation, double this.lightness); 13 Color(int this.hue, double this.saturation, double this.lightness);
13 14
14 factory Color.rgb(double red, double green, double blue) { 15 factory Color.rgb(double red, double green, double blue) {
15 final r = red; 16 final r = red;
(...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after
188 189
189 document.query("input[name=invert]").on.change.add((Event e) { 190 document.query("input[name=invert]").on.change.add((Event e) {
190 InputElement invert = e.target; 191 InputElement invert = e.target;
191 if (invert.checked) { 192 if (invert.checked) {
192 logo.classes = ['inverse']; 193 logo.classes = ['inverse'];
193 } else { 194 } else {
194 logo.classes = []; 195 logo.classes = [];
195 } 196 }
196 }); 197 });
197 } 198 }
OLDNEW
« no previous file with comments | « samples/isolate_html/isolate_sample.dart ('k') | samples/matrix/matrix_client.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698