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

Side by Side Diff: dart/samples/ui_lib/view/PagedViews.dart

Issue 11233061: Revert "Parts must start with 'part of'" and "Attempt to fix VM build" (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 8 years, 1 month 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 | « dart/samples/ui_lib/view/MeasureText.dart ('k') | dart/samples/ui_lib/view/SliderMenu.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 part of view;
2
3 // 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
4 // 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
5 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
6 4
7 class PageState { 5 class PageState {
8 final ObservableValue<int> current; 6 final ObservableValue<int> current;
9 final ObservableValue<int> target; 7 final ObservableValue<int> target;
10 final ObservableValue<int> length; 8 final ObservableValue<int> length;
11 PageState() : 9 PageState() :
12 current = new ObservableValue<int>(0), 10 current = new ObservableValue<int>(0),
(...skipping 267 matching lines...) Expand 10 before | Expand all | Expand 10 after
280 return perPage * (columnSize + _columnGap); 278 return perPage * (columnSize + _columnGap);
281 } 279 }
282 280
283 void _onPageSelected() { 281 void _onPageSelected() {
284 _container.rect.then((ElementRect rect) { 282 _container.rect.then((ElementRect rect) {
285 int translate = -pages.target.value * _computePageSize(rect); 283 int translate = -pages.target.value * _computePageSize(rect);
286 scroller.throwTo(translate, 0); 284 scroller.throwTo(translate, 0);
287 }); 285 });
288 } 286 }
289 } 287 }
OLDNEW
« no previous file with comments | « dart/samples/ui_lib/view/MeasureText.dart ('k') | dart/samples/ui_lib/view/SliderMenu.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698