| Index: content/browser/device_orientation/observer_delegate.cc
|
| diff --git a/content/browser/device_orientation/observer_delegate.cc b/content/browser/device_orientation/observer_delegate.cc
|
| index 05798101923b3cd4bcd2a959a97e38bc27991edf..eaf3e6d6cc2997f5fb93bd1d2a76cd52bbf5ace5 100644
|
| --- a/content/browser/device_orientation/observer_delegate.cc
|
| +++ b/content/browser/device_orientation/observer_delegate.cc
|
| @@ -6,6 +6,7 @@
|
|
|
| #include "base/logging.h"
|
| #include "content/browser/device_orientation/device_data.h"
|
| +#include "content/browser/device_orientation/motion.h"
|
| #include "content/browser/device_orientation/orientation.h"
|
| #include "ipc/ipc_sender.h"
|
|
|
| @@ -35,8 +36,15 @@ void ObserverDelegate::OnDeviceDataUpdate(
|
| }
|
|
|
| DeviceData* ObserverDelegate::EmptyDeviceData(DeviceData::Type type) {
|
| - DCHECK(type == DeviceData::kTypeOrientation);
|
| - return new Orientation();
|
| + switch (type) {
|
| + case DeviceData::kTypeMotion:
|
| + return new Motion();
|
| + case DeviceData::kTypeOrientation:
|
| + return new Orientation();
|
| + case DeviceData::kTypeTest:
|
| + NOTREACHED();
|
| + return NULL;
|
| + }
|
| }
|
|
|
| } // namespace device_orientation
|
|
|