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

Side by Side Diff: chrome/browser/ui/webui/options/browser_options_handler.cc

Issue 2691943005: fix quick unlock config in options (Closed)
Patch Set: Incorporate comments Created 3 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/webui/options/browser_options_handler.h" 5 #include "chrome/browser/ui/webui/options/browser_options_handler.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <set> 9 #include <set>
10 #include <utility> 10 #include <utility>
(...skipping 801 matching lines...) Expand 10 before | Expand all | Expand 10 after
812 812
813 chromeos::CrosSettings* cros_settings = chromeos::CrosSettings::Get(); 813 chromeos::CrosSettings* cros_settings = chromeos::CrosSettings::Get();
814 bool allow_bluetooth = true; 814 bool allow_bluetooth = true;
815 cros_settings->GetBoolean(chromeos::kAllowBluetooth, &allow_bluetooth); 815 cros_settings->GetBoolean(chromeos::kAllowBluetooth, &allow_bluetooth);
816 values->SetBoolean("allowBluetooth", allow_bluetooth); 816 values->SetBoolean("allowBluetooth", allow_bluetooth);
817 817
818 values->SetBoolean("showQuickUnlockSettings", 818 values->SetBoolean("showQuickUnlockSettings",
819 chromeos::IsPinUnlockEnabled(profile->GetPrefs())); 819 chromeos::IsPinUnlockEnabled(profile->GetPrefs()));
820 values->SetBoolean("fingerprintUnlockEnabled", 820 values->SetBoolean("fingerprintUnlockEnabled",
821 chromeos::IsFingerprintUnlockEnabled()); 821 chromeos::IsFingerprintUnlockEnabled());
822 values->SetBoolean("pinUnlockEnabled",
823 chromeos::IsPinUnlockEnabled(profile->GetPrefs()));
822 if (chromeos::IsPinUnlockEnabled(profile->GetPrefs())) { 824 if (chromeos::IsPinUnlockEnabled(profile->GetPrefs())) {
823 values->SetString( 825 values->SetString(
824 "enableScreenlock", 826 "enableScreenlock",
825 l10n_util::GetStringUTF16( 827 l10n_util::GetStringUTF16(
826 IDS_OPTIONS_ENABLE_SCREENLOCKER_CHECKBOX_WITH_QUICK_UNLOCK)); 828 IDS_OPTIONS_ENABLE_SCREENLOCKER_CHECKBOX_WITH_QUICK_UNLOCK));
827 } else { 829 } else {
828 values->SetString( 830 values->SetString(
829 "enableScreenlock", 831 "enableScreenlock",
830 l10n_util::GetStringUTF16(IDS_OPTIONS_ENABLE_SCREENLOCKER_CHECKBOX)); 832 l10n_util::GetStringUTF16(IDS_OPTIONS_ENABLE_SCREENLOCKER_CHECKBOX));
831 } 833 }
(...skipping 1534 matching lines...) Expand 10 before | Expand all | Expand 10 after
2366 2368
2367 bool BrowserOptionsHandler::IsDeviceOwnerProfile() { 2369 bool BrowserOptionsHandler::IsDeviceOwnerProfile() {
2368 #if defined(OS_CHROMEOS) 2370 #if defined(OS_CHROMEOS)
2369 return chromeos::ProfileHelper::IsOwnerProfile(Profile::FromWebUI(web_ui())); 2371 return chromeos::ProfileHelper::IsOwnerProfile(Profile::FromWebUI(web_ui()));
2370 #else 2372 #else
2371 return true; 2373 return true;
2372 #endif 2374 #endif
2373 } 2375 }
2374 2376
2375 } // namespace options 2377 } // namespace options
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698