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

Unified Diff: third_party/WebKit/Source/modules/sensor/SensorProviderProxy.h

Issue 2458453002: [sensors] Add Permission guard to the generic sensor apis.
Patch Set: rebase + blink reformat Created 3 years, 8 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: third_party/WebKit/Source/modules/sensor/SensorProviderProxy.h
diff --git a/third_party/WebKit/Source/modules/sensor/SensorProviderProxy.h b/third_party/WebKit/Source/modules/sensor/SensorProviderProxy.h
index eea1338d15f70941bdd5c9834af8f4eb6210ac17..eec4a402d530f4f8808e80dc76fcc8ffebbe5fb5 100644
--- a/third_party/WebKit/Source/modules/sensor/SensorProviderProxy.h
+++ b/third_party/WebKit/Source/modules/sensor/SensorProviderProxy.h
@@ -10,9 +10,11 @@
#include "device/generic_sensor/public/interfaces/sensor_provider.mojom-blink.h"
#include "platform/Supplementable.h"
#include "platform/heap/Handle.h"
+#include "public/platform/modules/permissions/permission.mojom-blink.h"
namespace blink {
+class SecurityOrigin;
class SensorProxy;
// This class wraps 'SensorProvider' mojo interface and it manages
@@ -28,10 +30,14 @@ class SensorProviderProxy final
~SensorProviderProxy();
- SensorProxy* CreateSensorProxy(device::mojom::blink::SensorType, Page*);
+ SensorProxy* CreateSensorProxy(device::mojom::blink::SensorType,
+ Page*,
+ RefPtr<SecurityOrigin>);
SensorProxy* GetSensorProxy(device::mojom::blink::SensorType);
+ void resetPermissionService();
+
DECLARE_VIRTUAL_TRACE();
private:
@@ -52,6 +58,7 @@ class SensorProviderProxy final
SensorsSet sensor_proxies_;
device::mojom::blink::SensorProviderPtr sensor_provider_;
+ mojom::blink::PermissionServicePtr permission_service_;
};
} // namespace blink
« no previous file with comments | « third_party/WebKit/Source/modules/sensor/Sensor.cpp ('k') | third_party/WebKit/Source/modules/sensor/SensorProviderProxy.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698