Index: chrome/android/java/src/org/chromium/chrome/browser/preferences/website/Website.java |
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/preferences/website/Website.java b/chrome/android/java/src/org/chromium/chrome/browser/preferences/website/Website.java |
index d5440545aa6c2d5a41c96c153a397d144b4a9b39..9b432b3359768885649bb47a3d870865a645b553 100644 |
--- a/chrome/android/java/src/org/chromium/chrome/browser/preferences/website/Website.java |
+++ b/chrome/android/java/src/org/chromium/chrome/browser/preferences/website/Website.java |
@@ -36,6 +36,7 @@ public class Website implements Serializable { |
private LocalStorageInfo mLocalStorageInfo; |
private MicrophoneInfo mMicrophoneInfo; |
private MidiInfo mMidiInfo; |
+ private SensorInfo mSensorInfo; |
private NotificationInfo mNotificationInfo; |
private ContentSettingException mPopupException; |
private ProtectedMediaIdentifierInfo mProtectedMediaIdentifierInfo; |
@@ -315,6 +316,31 @@ public class Website implements Serializable { |
} |
/** |
+ * Sets the SensorInfo object for this Website. |
+ */ |
+ public void setSensorInfo(SensorInfo info) { |
+ mSensorInfo = info; |
+ } |
+ |
+ public SensorInfo getSensorInfo() { |
+ return mSensorInfo; |
+ } |
+ /** |
+ * Returns what permission governs Sensors usage access. |
+ */ |
+ public ContentSetting getSensorsPermission() { |
+ return mSensorInfo != null ? mSensorInfo.getContentSetting() : null; |
+ } |
+ /** |
+ * Configure Sensors usage access setting for this site. |
+ */ |
+ public void setSensorsPermission(ContentSetting value) { |
+ if (mSensorInfo != null) { |
+ mSensorInfo.setContentSetting(value); |
+ } |
+ } |
+ |
+ /** |
* Sets Notification access permission information class. |
*/ |
public void setNotificationInfo(NotificationInfo info) { |