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

Unified Diff: chrome/browser/ui/webui/cookies_tree_model_util.cc

Issue 2359393002: Adds media license nodes to cookie tree model and cookies view. (Closed)
Patch Set: rebase Created 4 years, 2 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/ui/webui/cookies_tree_model_util.cc
diff --git a/chrome/browser/ui/webui/cookies_tree_model_util.cc b/chrome/browser/ui/webui/cookies_tree_model_util.cc
index 82611ad3bf9832f29ba7f00dff0e65a348b00a21..9e237826c845bdcf0df5d736a9b3bf27b7e3b64c 100644
--- a/chrome/browser/ui/webui/cookies_tree_model_util.cc
+++ b/chrome/browser/ui/webui/cookies_tree_model_util.cc
@@ -299,6 +299,19 @@ bool CookiesTreeModelUtil::GetCookieTreeNodeDictionary(
dict->SetString(kKeyDomain, node.GetDetailedInfo().flash_lso_domain);
break;
}
+ case CookieTreeNode::DetailedInfo::TYPE_MEDIA_LICENSE: {
+ dict->SetString(kKeyType, "media_license");
+ dict->SetString(kKeyIcon, "chrome://theme/IDR_COOKIE_STORAGE_ICON");
+
+ const BrowsingDataMediaLicenseHelper::MediaLicenseInfo&
+ media_license_info = *node.GetDetailedInfo().media_license_info;
+ dict->SetString(kKeyOrigin, media_license_info.origin.spec());
+ dict->SetString(kKeySize, ui::FormatBytes(media_license_info.size));
+ dict->SetString(kKeyModified,
+ base::UTF16ToUTF8(base::TimeFormatFriendlyDateAndTime(
+ media_license_info.last_modified_time)));
+ break;
+ }
default:
#if defined(OS_MACOSX)
dict->SetString(kKeyIcon, "chrome://theme/IDR_BOOKMARK_BAR_FOLDER");

Powered by Google App Engine
This is Rietveld 408576698