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

Unified Diff: samples/third_party/dromaeo/tests/RunnerSuite.dart

Issue 12258020: Reverting setTimeout removal. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « samples/third_party/dromaeo/Dromaeo.dart ('k') | sdk/lib/html/dart2js/html_dart2js.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: samples/third_party/dromaeo/tests/RunnerSuite.dart
diff --git a/samples/third_party/dromaeo/tests/RunnerSuite.dart b/samples/third_party/dromaeo/tests/RunnerSuite.dart
index 42143c521fb23148ca762fa93bb6b6dd210339c8..f4d8c6fd2024d466f3f843e05005a84b98dd650d 100644
--- a/samples/third_party/dromaeo/tests/RunnerSuite.dart
+++ b/samples/third_party/dromaeo/tests/RunnerSuite.dart
@@ -51,7 +51,7 @@ class Suite {
// Run the test several times.
try {
- // TODO(antonm): use timer to schedule next run as JS
+ // TODO(antonm): use .setTimeout to schedule next run as JS
// version does. That allows to report the intermidiate results
// more smoothly as well.
for (int i = 0; i < _N_RUNS; i++) {
@@ -90,12 +90,12 @@ class Suite {
if (currentOperation < _operations.length) {
_operations[currentOperation]();
currentOperation++;
- new Timer(const Duration(milliseconds: 1), handler);
+ _window.setTimeout(handler, 1);
} else {
_postMessage('over');
}
}
- Timer.run(handler);
+ _window.setTimeout(handler, 0);
}
_reportTestResults(String name, Result result) {
« no previous file with comments | « samples/third_party/dromaeo/Dromaeo.dart ('k') | sdk/lib/html/dart2js/html_dart2js.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698