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

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

Issue 1572743002: Make sure bubbles in Views default to close before their RenderFrameHosts. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@lkcr
Patch Set: Move DCHECK string into longer comment Created 4 years, 10 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/browser.cc
diff --git a/chrome/browser/ui/browser.cc b/chrome/browser/ui/browser.cc
index 1790b0672d5759e3ce07341e6f3e998d8a835bb4..99e4a6daf7247461355ffd7479dd02ce0b1539c1 100644
--- a/chrome/browser/ui/browser.cc
+++ b/chrome/browser/ui/browser.cc
@@ -1429,9 +1429,8 @@ scoped_ptr<content::BluetoothChooser> Browser::RunBluetoothChooser(
const url::Origin& origin) {
scoped_ptr<BluetoothChooserDesktop> bluetooth_chooser_desktop(
new BluetoothChooserDesktop(event_handler));
- Browser* browser = chrome::FindBrowserWithWebContents(web_contents);
scoped_ptr<BluetoothChooserBubbleDelegate> bubble_delegate(
- new BluetoothChooserBubbleDelegate(browser));
+ new BluetoothChooserBubbleDelegate(web_contents->GetMainFrame()));
BluetoothChooserBubbleDelegate* bubble_delegate_ptr = bubble_delegate.get();
// Wire the ChooserBubbleDelegate to the BluetoothChooser.
@@ -1439,6 +1438,7 @@ scoped_ptr<content::BluetoothChooser> Browser::RunBluetoothChooser(
bubble_delegate_ptr);
bubble_delegate->set_bluetooth_chooser(bluetooth_chooser_desktop.get());
+ Browser* browser = chrome::FindBrowserWithWebContents(web_contents);
BubbleReference bubble_controller =
browser->GetBubbleManager()->ShowBubble(std::move(bubble_delegate));
bubble_delegate_ptr->set_bubble_controller(bubble_controller);
« no previous file with comments | « chrome/browser/ui/bluetooth/bluetooth_chooser_bubble_delegate.cc ('k') | chrome/browser/ui/chrome_bubble_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698