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

Side by Side Diff: chrome/browser/ui/android/infobars/auto_login_prompter.cc

Issue 257153003: We have a problem in the process on destroying WebContentsImpl because (Closed) Base URL: https://git.chromium.org/chromium/src.git@master
Patch Set: Rebased onto origin/master again, resolved conflicts Created 6 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/ui/android/infobars/auto_login_prompter.h" 5 #include "chrome/browser/ui/android/infobars/auto_login_prompter.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/prefs/pref_service.h" 10 #include "base/prefs/pref_service.h"
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
90 // relevant notifications; it will delete itself. 90 // relevant notifications; it will delete itself.
91 new AutoLoginPrompter(web_contents, params, url); 91 new AutoLoginPrompter(web_contents, params, url);
92 } 92 }
93 93
94 void AutoLoginPrompter::DidStopLoading( 94 void AutoLoginPrompter::DidStopLoading(
95 content::RenderViewHost* render_view_host) { 95 content::RenderViewHost* render_view_host) {
96 AddInfoBarToWebContents(); 96 AddInfoBarToWebContents();
97 delete this; 97 delete this;
98 } 98 }
99 99
100 void AutoLoginPrompter::WebContentsDestroyed(WebContents* web_contents) { 100 void AutoLoginPrompter::WebContentsDestroyed() {
101 // The WebContents was destroyed before the navigation completed. 101 // The WebContents was destroyed before the navigation completed.
102 delete this; 102 delete this;
103 } 103 }
104 104
105 void AutoLoginPrompter::AddInfoBarToWebContents() { 105 void AutoLoginPrompter::AddInfoBarToWebContents() {
106 if (!infobar_shown_) 106 if (!infobar_shown_)
107 infobar_shown_ = AutoLoginInfoBarDelegate::Create(web_contents(), params_); 107 infobar_shown_ = AutoLoginInfoBarDelegate::Create(web_contents(), params_);
108 } 108 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/android/infobars/auto_login_prompter.h ('k') | chrome/browser/ui/ash/launcher/browser_status_monitor.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698