OLD | NEW |
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/chromeos/policy/device_policy_decoder_chromeos.h" | 5 #include "chrome/browser/chromeos/policy/device_policy_decoder_chromeos.h" |
6 | 6 |
7 #include <limits> | 7 #include <limits> |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/callback.h" | 10 #include "base/callback.h" |
(...skipping 567 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
578 | 578 |
579 if (container.has_login_screen_default_screen_magnifier_type()) { | 579 if (container.has_login_screen_default_screen_magnifier_type()) { |
580 policies->Set( | 580 policies->Set( |
581 key::kDeviceLoginScreenDefaultScreenMagnifierType, | 581 key::kDeviceLoginScreenDefaultScreenMagnifierType, |
582 POLICY_LEVEL_MANDATORY, | 582 POLICY_LEVEL_MANDATORY, |
583 POLICY_SCOPE_MACHINE, | 583 POLICY_SCOPE_MACHINE, |
584 DecodeIntegerValue( | 584 DecodeIntegerValue( |
585 container.login_screen_default_screen_magnifier_type()).release(), | 585 container.login_screen_default_screen_magnifier_type()).release(), |
586 NULL); | 586 NULL); |
587 } | 587 } |
| 588 |
588 if (container.has_login_screen_default_virtual_keyboard_enabled()) { | 589 if (container.has_login_screen_default_virtual_keyboard_enabled()) { |
589 policies->Set( | 590 policies->Set( |
590 key::kDeviceLoginScreenDefaultVirtualKeyboardEnabled, | 591 key::kDeviceLoginScreenDefaultVirtualKeyboardEnabled, |
591 POLICY_LEVEL_MANDATORY, | 592 POLICY_LEVEL_MANDATORY, |
592 POLICY_SCOPE_MACHINE, | 593 POLICY_SCOPE_MACHINE, |
593 new base::FundamentalValue( | 594 new base::FundamentalValue( |
594 container.login_screen_default_virtual_keyboard_enabled()), | 595 container.login_screen_default_virtual_keyboard_enabled()), |
595 NULL); | 596 NULL); |
596 } | 597 } |
| 598 |
| 599 if (container.has_device_login_screen_domain_auto_complete()) { |
| 600 policies->Set(key::kDeviceLoginScreenDomainAutoComplete, |
| 601 POLICY_LEVEL_MANDATORY, POLICY_SCOPE_MACHINE, |
| 602 new base::StringValue( |
| 603 container.device_login_screen_domain_auto_complete()), |
| 604 nullptr); |
| 605 } |
597 } | 606 } |
598 } | 607 } |
599 | 608 |
600 void DecodeGenericPolicies(const em::ChromeDeviceSettingsProto& policy, | 609 void DecodeGenericPolicies(const em::ChromeDeviceSettingsProto& policy, |
601 PolicyMap* policies) { | 610 PolicyMap* policies) { |
602 if (policy.has_device_policy_refresh_rate()) { | 611 if (policy.has_device_policy_refresh_rate()) { |
603 const em::DevicePolicyRefreshRateProto& container( | 612 const em::DevicePolicyRefreshRateProto& container( |
604 policy.device_policy_refresh_rate()); | 613 policy.device_policy_refresh_rate()); |
605 if (container.has_device_policy_refresh_rate()) { | 614 if (container.has_device_policy_refresh_rate()) { |
606 policies->Set( | 615 policies->Set( |
(...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
769 // Decode the various groups of policies. | 778 // Decode the various groups of policies. |
770 DecodeLoginPolicies(policy, policies); | 779 DecodeLoginPolicies(policy, policies); |
771 DecodeNetworkPolicies(policy, policies); | 780 DecodeNetworkPolicies(policy, policies); |
772 DecodeReportingPolicies(policy, policies); | 781 DecodeReportingPolicies(policy, policies); |
773 DecodeAutoUpdatePolicies(policy, policies); | 782 DecodeAutoUpdatePolicies(policy, policies); |
774 DecodeAccessibilityPolicies(policy, policies); | 783 DecodeAccessibilityPolicies(policy, policies); |
775 DecodeGenericPolicies(policy, policies); | 784 DecodeGenericPolicies(policy, policies); |
776 } | 785 } |
777 | 786 |
778 } // namespace policy | 787 } // namespace policy |
OLD | NEW |