| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 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 | 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/settings/md_settings_ui.h" | 5 #include "chrome/browser/ui/webui/settings/md_settings_ui.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 120 chromeos::settings::EasyUnlockSettingsHandler* easy_unlock_handler = | 120 chromeos::settings::EasyUnlockSettingsHandler* easy_unlock_handler = |
| 121 chromeos::settings::EasyUnlockSettingsHandler::Create(html_source, | 121 chromeos::settings::EasyUnlockSettingsHandler::Create(html_source, |
| 122 profile); | 122 profile); |
| 123 if (easy_unlock_handler) | 123 if (easy_unlock_handler) |
| 124 AddSettingsPageUIHandler(easy_unlock_handler); | 124 AddSettingsPageUIHandler(easy_unlock_handler); |
| 125 | 125 |
| 126 AddSettingsPageUIHandler( | 126 AddSettingsPageUIHandler( |
| 127 chromeos::settings::DateTimeHandler::Create(html_source)); | 127 chromeos::settings::DateTimeHandler::Create(html_source)); |
| 128 | 128 |
| 129 html_source->AddBoolean("stylusAllowed", ash::IsPaletteFeatureEnabled()); | 129 html_source->AddBoolean("stylusAllowed", ash::IsPaletteFeatureEnabled()); |
| 130 html_source->AddBoolean("quickUnlockEnabled", | 130 html_source->AddBoolean("pinUnlockEnabled", |
| 131 chromeos::IsQuickUnlockEnabled()); | 131 chromeos::IsPinUnlockEnabled(profile->GetPrefs())); |
| 132 #endif | 132 #endif |
| 133 | 133 |
| 134 AddSettingsPageUIHandler(AboutHandler::Create(html_source, profile)); | 134 AddSettingsPageUIHandler(AboutHandler::Create(html_source, profile)); |
| 135 AddSettingsPageUIHandler(ResetSettingsHandler::Create(html_source, profile)); | 135 AddSettingsPageUIHandler(ResetSettingsHandler::Create(html_source, profile)); |
| 136 | 136 |
| 137 // Add all settings resources. | 137 // Add all settings resources. |
| 138 for (size_t i = 0; i < kSettingsResourcesSize; ++i) { | 138 for (size_t i = 0; i < kSettingsResourcesSize; ++i) { |
| 139 html_source->AddResourcePath(kSettingsResources[i].name, | 139 html_source->AddResourcePath(kSettingsResources[i].name, |
| 140 kSettingsResources[i].value); | 140 kSettingsResources[i].value); |
| 141 } | 141 } |
| (...skipping 27 matching lines...) Expand all Loading... |
| 169 UMA_HISTOGRAM_TIMES("Settings.LoadDocumentTime.MD", | 169 UMA_HISTOGRAM_TIMES("Settings.LoadDocumentTime.MD", |
| 170 base::Time::Now() - load_start_time_); | 170 base::Time::Now() - load_start_time_); |
| 171 } | 171 } |
| 172 | 172 |
| 173 void MdSettingsUI::DocumentOnLoadCompletedInMainFrame() { | 173 void MdSettingsUI::DocumentOnLoadCompletedInMainFrame() { |
| 174 UMA_HISTOGRAM_TIMES("Settings.LoadCompletedTime.MD", | 174 UMA_HISTOGRAM_TIMES("Settings.LoadCompletedTime.MD", |
| 175 base::Time::Now() - load_start_time_); | 175 base::Time::Now() - load_start_time_); |
| 176 } | 176 } |
| 177 | 177 |
| 178 } // namespace settings | 178 } // namespace settings |
| OLD | NEW |