| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 import 'dart:sky' as sky; | 5 import 'dart:sky' as sky; |
| 6 | 6 |
| 7 import 'package:vector_math/vector_math.dart'; | 7 import 'package:vector_math/vector_math.dart'; |
| 8 import 'package:sky/animation/animation_performance.dart'; | 8 import 'package:sky/animation/animation_performance.dart'; |
| 9 import 'package:sky/base/lerp.dart'; | 9 import 'package:sky/base/lerp.dart'; |
| 10 import 'package:sky/painting/text_style.dart'; | 10 import 'package:sky/painting/text_style.dart'; |
| (...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 158 )); | 158 )); |
| 159 } | 159 } |
| 160 | 160 |
| 161 return new Container( | 161 return new Container( |
| 162 child: new SizeObserver(child: new Block(items), callback: _handleSizeChan
ged), | 162 child: new SizeObserver(child: new Block(items), callback: _handleSizeChan
ged), |
| 163 padding: const EdgeDims.symmetric(vertical: 12.0, horizontal: 8.0), | 163 padding: const EdgeDims.symmetric(vertical: 12.0, horizontal: 8.0), |
| 164 decoration: new BoxDecoration(backgroundColor: Theme.of(this).primarySwatc
h[50]) | 164 decoration: new BoxDecoration(backgroundColor: Theme.of(this).primarySwatc
h[50]) |
| 165 ); | 165 ); |
| 166 } | 166 } |
| 167 | 167 |
| 168 @override |
| 168 Widget build() { | 169 Widget build() { |
| 169 return new Scaffold( | 170 return new Scaffold( |
| 170 toolbar: new ToolBar(center: new Text('Swipe Away')), | 171 toolbar: new ToolBar(center: new Text('Swipe Away')), |
| 171 body: _buildCardCollection( | 172 body: _buildCardCollection( |
| 172 [48.0, 64.0, 82.0, 46.0, 60.0, 55.0, 84.0, 96.0, 50.0, | 173 [48.0, 64.0, 82.0, 46.0, 60.0, 55.0, 84.0, 96.0, 50.0, |
| 173 48.0, 64.0, 82.0, 46.0, 60.0, 55.0, 84.0, 96.0, 50.0]) | 174 48.0, 64.0, 82.0, 46.0, 60.0, 55.0, 84.0, 96.0, 50.0]) |
| 174 ); | 175 ); |
| 175 } | 176 } |
| 176 } | 177 } |
| 177 | 178 |
| 178 void main() { | 179 void main() { |
| 179 runApp(new CardCollectionApp()); | 180 runApp(new CardCollectionApp()); |
| 180 } | 181 } |
| OLD | NEW |