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

Unified Diff: Source/modules/device_orientation/DeviceMotionController.cpp

Issue 26434002: Cleanup: Add more conversion helpers for usage. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Updated to ToT. Patch for landing. Created 7 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: Source/modules/device_orientation/DeviceMotionController.cpp
diff --git a/Source/modules/device_orientation/DeviceMotionController.cpp b/Source/modules/device_orientation/DeviceMotionController.cpp
index 1d99ea30cdbd430fd321d0d6ef12ae133ea2b4f6..3ad87f59cd3bec1fed5e56db31ee605275f148fd 100644
--- a/Source/modules/device_orientation/DeviceMotionController.cpp
+++ b/Source/modules/device_orientation/DeviceMotionController.cpp
@@ -91,8 +91,7 @@ void DeviceMotionController::unregisterWithDispatcher()
bool DeviceMotionController::isNullEvent(Event* event)
{
- ASSERT(event->type() == EventNames::devicemotion);
- DeviceMotionEvent* motionEvent = static_cast<DeviceMotionEvent*>(event);
+ DeviceMotionEvent* motionEvent = toDeviceMotionEvent(event);
return !motionEvent->deviceMotionData()->canProvideEventData();
}

Powered by Google App Engine
This is Rietveld 408576698