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

Unified Diff: samples/pop_pop_win/lib/src/game_manager.dart

Issue 242443008: samples/pop_pop_win: now based on StageXL (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: tiny nit Created 6 years, 8 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/pop_pop_win/lib/src/game/game.dart ('k') | samples/pop_pop_win/lib/src/game_storage.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: samples/pop_pop_win/lib/src/game_manager.dart
diff --git a/samples/pop_pop_win/lib/src/html/game_manager.dart b/samples/pop_pop_win/lib/src/game_manager.dart
similarity index 89%
rename from samples/pop_pop_win/lib/src/html/game_manager.dart
rename to samples/pop_pop_win/lib/src/game_manager.dart
index e07a872976d3c4b61cc82b403424eb9d7b5dffbc..3d939711b6d271b5622a67d1d82f7410d8555795 100644
--- a/samples/pop_pop_win/lib/src/html/game_manager.dart
+++ b/samples/pop_pop_win/lib/src/game_manager.dart
@@ -1,4 +1,9 @@
-part of pop_pop_win.html;
+library pop_pop_win.game_manager;
+
+import 'dart:async';
+
+import 'game_storage.dart';
+import 'game.dart';
abstract class GameManager {
final int _width, _height, _bombCount;
@@ -15,7 +20,7 @@ abstract class GameManager {
Game get game => _game;
- Stream<EventArgs> get bestTimeUpdated => _gameStorage.bestTimeUpdated;
+ Stream get bestTimeUpdated => _gameStorage.bestTimeUpdated;
Future<int> get bestTimeMilliseconds =>
_gameStorage.getBestTimeMilliseconds(_width, _height, _bombCount);
@@ -30,11 +35,11 @@ abstract class GameManager {
}
final f = new Field(_bombCount, _width, _height);
_game = new Game(f);
- _updatedEventId = _game.updated.listen(gameUpdated);
+ _updatedEventId = _game.updated.listen((_) => gameUpdated());
_gameStateChangedId = _game.stateChanged.listen(_gameStateChanged);
}
- void gameUpdated(args);
+ void gameUpdated() {}
void resetScores() {
_gameStorage.reset();
« no previous file with comments | « samples/pop_pop_win/lib/src/game/game.dart ('k') | samples/pop_pop_win/lib/src/game_storage.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698