BookmarkManager: Fix 'new folder text field size changes on clicking it' issue.
[chromium-blink-merge.git] / chrome / browser / ui / passwords / manage_passwords_view_utils_desktop.cc
blobde4fed4123862157390e68b2273b972322f57d2b
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #include "chrome/browser/ui/passwords/manage_passwords_view_utils_desktop.h"
7 #include "chrome/grit/chromium_strings.h"
8 #include "chrome/grit/generated_resources.h"
9 #include "components/password_manager/core/browser/password_bubble_experiment.h"
10 #include "components/password_manager/core/browser/password_manager_settings_migration_experiment.h"
12 int GetPasswordManagerSettingsStringId(
13 const sync_driver::SyncService* sync_service) {
14 int smart_lock_users_ids;
15 int non_smart_lock_users_ids;
17 if (password_manager::IsSettingsBehaviorChangeActive()) {
18 smart_lock_users_ids =
19 IDS_OPTIONS_PASSWORD_MANAGER_SMART_LOCK_REMEMBER_ENABLE;
20 non_smart_lock_users_ids = IDS_OPTIONS_PASSWORD_MANAGER_REMEMBER_ENABLE;
21 } else {
22 smart_lock_users_ids = IDS_OPTIONS_PASSWORD_MANAGER_SMART_LOCK_ENABLE;
23 non_smart_lock_users_ids = IDS_OPTIONS_PASSWORD_MANAGER_ENABLE;
25 if (password_bubble_experiment::IsSmartLockBrandingEnabled(sync_service))
26 return smart_lock_users_ids;
27 if (password_bubble_experiment::IsSmartLockUser(sync_service) &&
28 password_manager::IsSettingsMigrationActive()) {
29 return smart_lock_users_ids;
31 return non_smart_lock_users_ids;