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

Side by Side Diff: sky/framework/debug/shake-to-reload.sky

Issue 990493002: Make package: work like Dart expects in preparation for a Sky SDK (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Made deploy_sdk 100x faster in the --dev-environment case Created 5 years, 9 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 unified diff | Download patch
OLDNEW
1 <script> 1 <script>
2 import '/sky/framework/shell.dart' as shell;
3 import 'dart:sky'; 2 import 'dart:sky';
3 import 'package:sky/framework/shell.dart' as shell;
4 import 'package:sky/services/sensors/sensors.mojom.dart'; 4 import 'package:sky/services/sensors/sensors.mojom.dart';
5 5
6 // TODO(abarth): We should factor this out into a kinematics library. 6 // TODO(abarth): We should factor this out into a kinematics library.
7 class _ShakeDetector extends SensorListener { 7 class _ShakeDetector extends SensorListener {
8 _ShakeDetector() { 8 _ShakeDetector() {
9 SensorServiceProxy sensorService = new SensorServiceProxy.unbound(); 9 SensorServiceProxy sensorService = new SensorServiceProxy.unbound();
10 shell.requestService(sensorService); 10 shell.requestService(sensorService);
11 11
12 _stub = new SensorListenerStub.unbound()..impl = this; 12 _stub = new SensorListenerStub.unbound()..impl = this;
13 sensorService.ptr.addListener(SensorType_ACCELEROMETER, _stub); 13 sensorService.ptr.addListener(SensorType_ACCELEROMETER, _stub);
(...skipping 18 matching lines...) Expand all
32 bool isShaking = false; 32 bool isShaking = false;
33 SensorListenerStub _stub; 33 SensorListenerStub _stub;
34 } 34 }
35 35
36 _ShakeDetector _detector; 36 _ShakeDetector _detector;
37 37
38 void _init(_) { 38 void _init(_) {
39 _detector = new _ShakeDetector(); 39 _detector = new _ShakeDetector();
40 } 40 }
41 </script> 41 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698