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

Unified Diff: samples/solar/solar.dart

Issue 11367040: Removing Element.rect. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
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 side-by-side diff with in-line comments
Download patch
Index: samples/solar/solar.dart
diff --git a/samples/solar/solar.dart b/samples/solar/solar.dart
index 36bf1d6a22b71a21eff339f887a6a78bf6616c12..59a490d7fa031ffb84298156b3461dc420b68525 100644
--- a/samples/solar/solar.dart
+++ b/samples/solar/solar.dart
@@ -69,9 +69,9 @@ class SolarSystem {
start() {
// Measure the canvas element.
- canvas.parent.rect.then((ElementRect rect) {
- _width = rect.client.width;
- _height = rect.client.height;
+ window.requestLayoutFrame(() {
+ _width = canvas.parent.clientWidth;
+ _height = canvas.parent.clientHeight;
canvas.width = _width;

Powered by Google App Engine
This is Rietveld 408576698