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

Side by Side Diff: chrome/browser/password_manager/chrome_password_manager_client.cc

Issue 276523003: Password bubble: Explicitly disable on non-Aura platforms. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/password_manager/chrome_password_manager_client.h" 5 #include "chrome/browser/password_manager/chrome_password_manager_client.h"
6 6
7 #include "base/bind_helpers.h" 7 #include "base/bind_helpers.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/memory/singleton.h" 9 #include "base/memory/singleton.h"
10 #include "base/metrics/histogram.h" 10 #include "base/metrics/histogram.h"
(...skipping 18 matching lines...) Expand all
29 #include "content/public/browser/render_view_host.h" 29 #include "content/public/browser/render_view_host.h"
30 #include "content/public/browser/web_contents.h" 30 #include "content/public/browser/web_contents.h"
31 31
32 #if defined(OS_ANDROID) 32 #if defined(OS_ANDROID)
33 #include "chrome/browser/android/password_authentication_manager.h" 33 #include "chrome/browser/android/password_authentication_manager.h"
34 #endif // OS_ANDROID 34 #endif // OS_ANDROID
35 35
36 namespace { 36 namespace {
37 37
38 bool IsTheHotNewBubbleUIEnabled() { 38 bool IsTheHotNewBubbleUIEnabled() {
39 std::string group_name = 39 #if !defined(USE_AURA)
40 base::FieldTrialList::FindFullName("PasswordManagerUI"); 40 return false;
41 41 #endif
42 CommandLine* command_line = CommandLine::ForCurrentProcess(); 42 CommandLine* command_line = CommandLine::ForCurrentProcess();
43 if (command_line->HasSwitch(switches::kDisableSavePasswordBubble)) 43 if (command_line->HasSwitch(switches::kDisableSavePasswordBubble))
44 return false; 44 return false;
45 45
46 if (command_line->HasSwitch(switches::kEnableSavePasswordBubble)) 46 if (command_line->HasSwitch(switches::kEnableSavePasswordBubble))
47 return true; 47 return true;
48 48
49 std::string group_name =
50 base::FieldTrialList::FindFullName("PasswordManagerUI");
49 return group_name == "Bubble"; 51 return group_name == "Bubble";
50 } 52 }
51 53
52 } // namespace 54 } // namespace
53 55
54 DEFINE_WEB_CONTENTS_USER_DATA_KEY(ChromePasswordManagerClient); 56 DEFINE_WEB_CONTENTS_USER_DATA_KEY(ChromePasswordManagerClient);
55 57
56 // static 58 // static
57 void 59 void
58 ChromePasswordManagerClient::CreateForWebContentsWithAutofillManagerDelegate( 60 ChromePasswordManagerClient::CreateForWebContentsWithAutofillManagerDelegate(
(...skipping 249 matching lines...) Expand 10 before | Expand all | Expand 10 after
308 web_contents(), 310 web_contents(),
309 web_contents()->GetNativeView()); 311 web_contents()->GetNativeView());
310 popup_controller_->Show(false /* display_password */); 312 popup_controller_->Show(false /* display_password */);
311 #endif // #if defined(USE_AURA) 313 #endif // #if defined(USE_AURA)
312 } 314 }
313 315
314 void ChromePasswordManagerClient::CommitFillPasswordForm( 316 void ChromePasswordManagerClient::CommitFillPasswordForm(
315 autofill::PasswordFormFillData* data) { 317 autofill::PasswordFormFillData* data) {
316 driver_.FillPasswordForm(*data); 318 driver_.FillPasswordForm(*data);
317 } 319 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698