| Index: chrome/browser/chromeos/login/ui/login_web_dialog.cc
|
| diff --git a/chrome/browser/chromeos/login/ui/login_web_dialog.cc b/chrome/browser/chromeos/login/ui/login_web_dialog.cc
|
| index 9e1a215b67b74e718b45710c10ecfd7073b456a8..4c3a0dd8dec2707ef47a96a8085164235aa12875 100644
|
| --- a/chrome/browser/chromeos/login/ui/login_web_dialog.cc
|
| +++ b/chrome/browser/chromeos/login/ui/login_web_dialog.cc
|
| @@ -10,6 +10,7 @@
|
| #include "base/strings/utf_string_conversions.h"
|
| #include "chrome/browser/chromeos/login/helper.h"
|
| #include "chrome/browser/ui/browser_dialogs.h"
|
| +#include "chrome/browser/ui/browser_finder.h"
|
| #include "content/public/browser/browser_context.h"
|
| #include "content/public/browser/notification_source.h"
|
| #include "content/public/browser/notification_types.h"
|
| @@ -157,6 +158,23 @@ bool LoginWebDialog::HandleContextMenu(
|
| return true;
|
| }
|
|
|
| +bool LoginWebDialog::HandleOpenURLFromTab(
|
| + content::WebContents* source,
|
| + const content::OpenURLParams& params,
|
| + content::WebContents** out_new_contents) {
|
| + // On a login screen, if a missing extension is trying to show in a web
|
| + // dialog, a NetErrorHelper is displayed instead (hence we have a |source|),
|
| + // but there is no browser window associated with it. A helper screen will
|
| + // fire an auto-reload, which in turn leads to opening a new browser window,
|
| + // so we must suppress it.
|
| + // http://crbug.com/443096
|
| + return (source && !chrome::FindBrowserWithWebContents(source));
|
| +}
|
| +
|
| +bool LoginWebDialog::HandleShouldCreateWebContents() {
|
| + return false;
|
| +}
|
| +
|
| void LoginWebDialog::Observe(int type,
|
| const content::NotificationSource& source,
|
| const content::NotificationDetails& details) {
|
|
|