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

Unified Diff: third_party/WebKit/Source/modules/device_orientation/DeviceMotionEvent.idl

Issue 1387453002: Sync the DeviceOrientation and DeviceMotion interfaces with the spec (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: remove spec bug link Created 5 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: third_party/WebKit/Source/modules/device_orientation/DeviceMotionEvent.idl
diff --git a/third_party/WebKit/Source/modules/device_orientation/DeviceMotionEvent.idl b/third_party/WebKit/Source/modules/device_orientation/DeviceMotionEvent.idl
index c75497aaf66eb379aece1d4d7fb13d3bdeedd9bc..138f704d832bbbaf95bbff161b42a8ba99ad7e60 100644
--- a/third_party/WebKit/Source/modules/device_orientation/DeviceMotionEvent.idl
+++ b/third_party/WebKit/Source/modules/device_orientation/DeviceMotionEvent.idl
@@ -23,11 +23,17 @@
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
+// http://w3c.github.io/deviceorientation/spec-source-orientation.html#devicemotion
+
+// TODO(philipj): DeviceMotionEvent should have a constructor.
interface DeviceMotionEvent : Event {
- readonly attribute DeviceAcceleration acceleration;
- readonly attribute DeviceAcceleration accelerationIncludingGravity;
- readonly attribute DeviceRotationRate rotationRate;
+ readonly attribute DeviceAcceleration? acceleration;
+ readonly attribute DeviceAcceleration? accelerationIncludingGravity;
+ readonly attribute DeviceRotationRate? rotationRate;
readonly attribute double? interval;
+
+ // TODO(philipj): The init*Event() methods are not in the spec:
+ // https://github.com/w3c/deviceorientation/issues/18
[Custom, Measure] void initDeviceMotionEvent([Default=Undefined] optional DOMString type,
[Default=Undefined] optional boolean bubbles,
[Default=Undefined] optional boolean cancelable,

Powered by Google App Engine
This is Rietveld 408576698