Chromium Code Reviews| Index: Source/core/frame/DeviceSensorEventController.h |
| diff --git a/Source/core/frame/DeviceSensorEventController.h b/Source/core/frame/DeviceSensorEventController.h |
| index 085f1e2a1c71b79e0d7aa6e248347f329eec47e9..dc4ac0bcfa63635e31b8f75122b6737bdb4aad8d 100644 |
| --- a/Source/core/frame/DeviceSensorEventController.h |
| +++ b/Source/core/frame/DeviceSensorEventController.h |
| @@ -41,7 +41,7 @@ public: |
| void stopUpdating(); |
| protected: |
| - explicit DeviceSensorEventController(Document&); |
| + explicit DeviceSensorEventController(Document*); |
| virtual ~DeviceSensorEventController(); |
| void dispatchDeviceEvent(const PassRefPtrWillBeRawPtr<Event>); |
| @@ -60,7 +60,9 @@ private: |
| void fireDeviceEvent(Timer<DeviceSensorEventController>*); |
| - Document& m_document; |
| + // Will be null if created in a detached state, without |
| + // a frame (and its document.) |
| + Document* m_document; |
|
abarth-chromium
2014/04/28 17:58:14
Maybe rather than storing this pointer, this class
sof
2014/04/28 18:58:42
Thanks, I like that suggestion, will try to make i
|
| bool m_isActive; |
| bool m_needsCheckingNullEvents; |
| Timer<DeviceSensorEventController> m_timer; |