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

Unified Diff: chrome/browser/permissions/permission_request_manager.cc

Issue 2868783002: Move requests from Show() argument to PermissionPrompt::Delegate (Closed)
Patch Set: tweak comment Created 3 years, 7 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/permissions/permission_request_manager.cc
diff --git a/chrome/browser/permissions/permission_request_manager.cc b/chrome/browser/permissions/permission_request_manager.cc
index ad680b86634f0aca91738da65fd14e760997d0b8..51fe1baeb4634a09154be5a89f38abc737956e32 100644
--- a/chrome/browser/permissions/permission_request_manager.cc
+++ b/chrome/browser/permissions/permission_request_manager.cc
@@ -313,6 +313,14 @@ void PermissionRequestManager::WebContentsDestroyed() {
// returning from this function is the only safe thing to do.
}
+const std::vector<PermissionRequest*>& PermissionRequestManager::Requests() {
+ return requests_;
+}
+
+const std::vector<bool>& PermissionRequestManager::AcceptStates() {
+ return accept_states_;
+}
+
void PermissionRequestManager::ToggleAccept(int request_index, bool new_value) {
DCHECK(request_index < static_cast<int>(accept_states_.size()));
accept_states_[request_index] = new_value;
@@ -400,7 +408,7 @@ void PermissionRequestManager::ShowBubble() {
DCHECK(!requests_.empty());
DCHECK(main_frame_has_fully_loaded_);
- view_->Show(requests_, accept_states_);
+ view_->Show();
PermissionUmaUtil::PermissionPromptShown(requests_);
NotifyBubbleAdded();

Powered by Google App Engine
This is Rietveld 408576698