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

Unified Diff: client/html/src/DeviceMotionEventWrappingImplementation.dart

Issue 8404013: Add constructors to all the event classes. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Get rid of html testing stuff and fix uses of init*Event. Created 9 years, 2 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
Index: client/html/src/DeviceMotionEventWrappingImplementation.dart
diff --git a/client/html/generated/src/wrapping/_DeviceMotionEventWrappingImplementation.dart b/client/html/src/DeviceMotionEventWrappingImplementation.dart
similarity index 54%
rename from client/html/generated/src/wrapping/_DeviceMotionEventWrappingImplementation.dart
rename to client/html/src/DeviceMotionEventWrappingImplementation.dart
index 429788042f5b0a5d35866e188b1cfadab98086b6..84ea98dbaa21f1a708de1d6f61ddf0f14632a463 100644
--- a/client/html/generated/src/wrapping/_DeviceMotionEventWrappingImplementation.dart
+++ b/client/html/src/DeviceMotionEventWrappingImplementation.dart
@@ -2,10 +2,15 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
-// WARNING: Do not edit - generated code.
-
class DeviceMotionEventWrappingImplementation extends EventWrappingImplementation implements DeviceMotionEvent {
- DeviceMotionEventWrappingImplementation._wrap(ptr) : super._wrap(ptr) {}
+ DeviceMotionEventWrappingImplementation._wrap(ptr) : super._wrap(ptr);
+
+ factory DeviceMotionEventWrappingImplementation(String type,
+ [bool canBubble = false, bool cancelable = false]) {
+ final e = dom.document.createEvent("DeviceMotionEvent");
+ e.initEvent(type, canBubble, cancelable);
+ return LevelDom.wrapDeviceMotionEvent(e);
+ }
- num get interval() { return _ptr.interval; }
+ num get interval() => _ptr.interval;
}

Powered by Google App Engine
This is Rietveld 408576698