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

Side by Side Diff: samples/swarm/swarm_ui_lib/touch/FxUtil.dart

Issue 12441003: Rename String.concat to operator+. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address comments. Created 7 years, 9 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
OLDNEW
1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, 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 part of touch; 5 part of touch;
6 6
7 /** 7 /**
8 * Common effects related helpers. 8 * Common effects related helpers.
9 */ 9 */
10 class FxUtil { 10 class FxUtil {
(...skipping 29 matching lines...) Expand all
40 static void setWebkitTransform( 40 static void setWebkitTransform(
41 Element el, num x, num y, [num z = 0, 41 Element el, num x, num y, [num z = 0,
42 num rotation = null, num scale = null, 42 num rotation = null, num scale = null,
43 num originX = null, num originY = null]) { 43 num originX = null, num originY = null]) {
44 final style = el.style; 44 final style = el.style;
45 // TODO(jacobr): create a helper class that simplifies building 45 // TODO(jacobr): create a helper class that simplifies building
46 // transformation matricies that will be set as CSS styles. We should 46 // transformation matricies that will be set as CSS styles. We should
47 // consider using CSSMatrix although that may be overkill. 47 // consider using CSSMatrix although that may be overkill.
48 String transform = '${TRANSLATE_3D}(${x}px,${y}px,${z}px)'; 48 String transform = '${TRANSLATE_3D}(${x}px,${y}px,${z}px)';
49 if (rotation != null) { 49 if (rotation != null) {
50 transform = transform.concat(' ${ROTATE}(${rotation}deg)'); 50 transform += ' ${ROTATE}(${rotation}deg)';
51 } 51 }
52 if (scale != null) { 52 if (scale != null) {
53 transform = transform.concat(' ${SCALE}(${scale})'); 53 transform += ' ${SCALE}(${scale})';
54 } 54 }
55 style.transform = transform; 55 style.transform = transform;
56 if (originX != null || originY != null) { 56 if (originX != null || originY != null) {
57 assert(originX != null && originY != null); 57 assert(originX != null && originY != null);
58 style.transformOrigin = '${originX}px ${originY}px'; 58 style.transformOrigin = '${originX}px ${originY}px';
59 } 59 }
60 } 60 }
61 61
62 /** 62 /**
63 * Determine the position of an [element] relative to a [target] element. 63 * Determine the position of an [element] relative to a [target] element.
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 style.left = '${x}px'; 96 style.left = '${x}px';
97 style.top = '${y}px'; 97 style.top = '${y}px';
98 } 98 }
99 } 99 }
100 100
101 class TransitionTimingFunction { 101 class TransitionTimingFunction {
102 static const EASE_IN = 'ease-in'; 102 static const EASE_IN = 'ease-in';
103 static const EASE_OUT = 'ease-out'; 103 static const EASE_OUT = 'ease-out';
104 static const EASE_IN_OUT = 'ease-in-out'; 104 static const EASE_IN_OUT = 'ease-in-out';
105 } 105 }
OLDNEW
« no previous file with comments | « runtime/tests/vm/dart/inline_stack_frame_test.dart ('k') | sdk/lib/_internal/compiler/implementation/lib/js_string.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698