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

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

Issue 2758933002: Fix default initialization for DeviceMotionEvent.interval. (Closed)
Patch Set: Rebased. Created 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/WebKit/Source/modules/device_orientation/DeviceMotionData.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/modules/device_orientation/DeviceMotionEvent.cpp
diff --git a/third_party/WebKit/Source/modules/device_orientation/DeviceMotionEvent.cpp b/third_party/WebKit/Source/modules/device_orientation/DeviceMotionEvent.cpp
index 1975a4963a52b3e27bd5563f661f5d9e91a12a8c..e8a83b41fb21b19258df0bd0da87f82b08878107 100644
--- a/third_party/WebKit/Source/modules/device_orientation/DeviceMotionEvent.cpp
+++ b/third_party/WebKit/Source/modules/device_orientation/DeviceMotionEvent.cpp
@@ -81,11 +81,8 @@ DeviceRotationRate* DeviceMotionEvent::rotationRate() {
}
double DeviceMotionEvent::interval(bool& isNull) const {
- if (m_deviceMotionData->canProvideInterval())
- return m_deviceMotionData->interval();
-
- isNull = true;
- return 0;
+ isNull = false;
+ return m_deviceMotionData->interval();
}
const AtomicString& DeviceMotionEvent::interfaceName() const {
« no previous file with comments | « third_party/WebKit/Source/modules/device_orientation/DeviceMotionData.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698