Index: third_party/WebKit/Source/modules/sensor/SensorProviderProxy.cpp |
diff --git a/third_party/WebKit/Source/modules/sensor/SensorProviderProxy.cpp b/third_party/WebKit/Source/modules/sensor/SensorProviderProxy.cpp |
index 5039dbab7b6c718112a0ef01d3ed814a7f104de9..970089e90533d01985aa04ef0639100484457f0c 100644 |
--- a/third_party/WebKit/Source/modules/sensor/SensorProviderProxy.cpp |
+++ b/third_party/WebKit/Source/modules/sensor/SensorProviderProxy.cpp |
@@ -4,6 +4,7 @@ |
#include "modules/sensor/SensorProviderProxy.h" |
+#include "core/dom/ExecutionContext.h" |
#include "modules/sensor/SensorProxy.h" |
#include "platform/mojo/MojoHelper.h" |
#include "public/platform/InterfaceProvider.h" |
@@ -42,14 +43,15 @@ DEFINE_TRACE(SensorProviderProxy) { |
} |
SensorProxy* SensorProviderProxy::getOrCreateSensor( |
- device::mojom::blink::SensorType type) { |
+ device::mojom::blink::SensorType type, |
+ ExecutionContext* context) { |
for (SensorProxy* sensor : m_sensors) { |
// TODO(Mikhail) : Hash sensors by type for efficiency. |
if (sensor->type() == type) |
return sensor; |
} |
- SensorProxy* sensor = new SensorProxy(type, this); |
+ SensorProxy* sensor = new SensorProxy(type, context, this); |
m_sensors.add(sensor); |
return sensor; |