Commit c92a99f2 authored by Oksana Zhuravlova's avatar Oksana Zhuravlova Committed by Commit Bot

Remove unused references to WebDevice*Listener

This change removes the listener template parameter from
DeviceSensorEventPump and any dependencies on WebDevice*Listener.

Bug: 861902
Change-Id: I91ec5f709eaa74acca35fa884e971f3f60e8f294
Reviewed-on: https://chromium-review.googlesource.com/1176199Reviewed-by: default avatarReilly Grant <reillyg@chromium.org>
Reviewed-by: default avatarTim Volodine <timvolodine@chromium.org>
Commit-Queue: Oksana Zhuravlova <oksamyt@chromium.org>
Cr-Commit-Position: refs/heads/master@{#584111}
parent 46b48ae1
......@@ -17,7 +17,7 @@ class DeviceMotionData;
class MODULES_EXPORT DeviceMotionEventPump
: public GarbageCollectedFinalized<DeviceMotionEventPump>,
public DeviceSensorEventPump<WebDeviceMotionListener>,
public DeviceSensorEventPump,
public PlatformEventDispatcher {
USING_GARBAGE_COLLECTED_MIXIN(DeviceMotionEventPump);
......
......@@ -15,7 +15,7 @@ namespace blink {
class MODULES_EXPORT DeviceOrientationEventPump
: public GarbageCollectedFinalized<DeviceOrientationEventPump>,
public DeviceSensorEventPump<WebDeviceOrientationListener>,
public DeviceSensorEventPump,
public PlatformEventDispatcher {
USING_GARBAGE_COLLECTED_MIXIN(DeviceOrientationEventPump);
......
......@@ -14,8 +14,6 @@
#include "services/device/public/cpp/generic_sensor/sensor_reading.h"
#include "services/device/public/cpp/generic_sensor/sensor_reading_shared_buffer_reader.h"
#include "services/device/public/mojom/sensor_provider.mojom-blink.h"
#include "third_party/blink/public/platform/modules/device_orientation/web_device_motion_listener.h"
#include "third_party/blink/public/platform/modules/device_orientation/web_device_orientation_listener.h"
#include "third_party/blink/renderer/platform/timer.h"
#include "third_party/blink/renderer/platform/wtf/functional.h"
......@@ -23,7 +21,6 @@ namespace blink {
class LocalFrame;
template <typename ListenerType>
class DeviceSensorEventPump {
public:
// Default rate for firing events.
......@@ -55,10 +52,7 @@ class DeviceSensorEventPump {
SUSPENDED
};
// The default nullptr for listener is temporary until listener is eliminated
// TODO(crbug.com/861902)
virtual void Start(LocalFrame* frame,
blink::WebPlatformEventListener* listener = nullptr) {
virtual void Start(LocalFrame* frame) {
DVLOG(2) << "requested start";
if (state_ != PumpState::STOPPED)
......@@ -69,7 +63,6 @@ class DeviceSensorEventPump {
state_ = PumpState::PENDING_START;
DCHECK(!is_observing_);
listener_ = static_cast<ListenerType*>(listener);
is_observing_ = true;
SendStartMessage(frame);
......@@ -88,7 +81,6 @@ class DeviceSensorEventPump {
timer_.Stop();
DCHECK(is_observing_);
listener_ = nullptr;
is_observing_ = false;
SendStopMessage();
......@@ -136,8 +128,6 @@ class DeviceSensorEventPump {
// TaskRunnerTimer class
virtual void FireEvent(TimerBase*) = 0;
ListenerType* listener() { return listener_; }
struct SensorEntry : public device::mojom::blink::SensorClient {
SensorEntry(DeviceSensorEventPump* pump,
device::mojom::blink::SensorType sensor_type)
......@@ -336,7 +326,6 @@ class DeviceSensorEventPump {
PumpState state_;
bool is_observing_ = false;
ListenerType* listener_ = nullptr;
TaskRunnerTimer<DeviceSensorEventPump> timer_;
DISALLOW_COPY_AND_ASSIGN(DeviceSensorEventPump);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment