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

Unified Diff: chrome/browser/content_settings/permission_context_uma_util.cc

Issue 1164073005: Allow script to request durable storage permission (chrome side) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebased onto content setting patch Created 5 years, 6 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: chrome/browser/content_settings/permission_context_uma_util.cc
diff --git a/chrome/browser/content_settings/permission_context_uma_util.cc b/chrome/browser/content_settings/permission_context_uma_util.cc
index cb2af3914f54879d57b0553bdedfc76ea0cd9d43..fe1c02a158394c3b76d62ac8c1a813b6eaa12206 100644
--- a/chrome/browser/content_settings/permission_context_uma_util.cc
+++ b/chrome/browser/content_settings/permission_context_uma_util.cc
@@ -128,6 +128,13 @@ void RecordPermissionAction(ContentSettingsType permission,
action);
break;
#endif
+ case CONTENT_SETTINGS_TYPE_DURABLE_STORAGE:
+ PERMISSION_ACTION_UMA( // Cargo culted
+ secure_origin, "ContentSettings.PermissionActions_DurableStorage",
+ "ContentSettings.PermissionActionsSecureOrigin_DurableStorage",
+ "ContentSettings.PermissionActionsInsecureOrigin_DurableStorage",
+ action);
+ break;
default:
NOTREACHED() << "PERMISSION " << permission << " not accounted for";
}
@@ -169,6 +176,9 @@ void RecordPermissionRequest(ContentSettingsType permission,
type = PermissionType::PROTECTED_MEDIA_IDENTIFIER;
break;
#endif
+ case CONTENT_SETTINGS_TYPE_DURABLE_STORAGE:
+ type = content::PermissionType::DURABLE_STORAGE;
+ break;
default:
NOTREACHED() << "PERMISSION " << permission << " not accounted for";
return;

Powered by Google App Engine
This is Rietveld 408576698