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/ui/webui/policy_ui_handler.h" | 5 #include "chrome/browser/ui/webui/policy_ui_handler.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include <utility> | 9 #include <utility> |
10 | 10 |
(...skipping 23 matching lines...) Expand all Loading... |
34 #include "components/policy/core/common/cloud/cloud_policy_constants.h" | 34 #include "components/policy/core/common/cloud/cloud_policy_constants.h" |
35 #include "components/policy/core/common/cloud/cloud_policy_core.h" | 35 #include "components/policy/core/common/cloud/cloud_policy_core.h" |
36 #include "components/policy/core/common/cloud/cloud_policy_refresh_scheduler.h" | 36 #include "components/policy/core/common/cloud/cloud_policy_refresh_scheduler.h" |
37 #include "components/policy/core/common/cloud/cloud_policy_store.h" | 37 #include "components/policy/core/common/cloud/cloud_policy_store.h" |
38 #include "components/policy/core/common/cloud/cloud_policy_validator.h" | 38 #include "components/policy/core/common/cloud/cloud_policy_validator.h" |
39 #include "components/policy/core/common/policy_details.h" | 39 #include "components/policy/core/common/policy_details.h" |
40 #include "components/policy/core/common/policy_types.h" | 40 #include "components/policy/core/common/policy_types.h" |
41 #include "components/policy/core/common/remote_commands/remote_commands_service.
h" | 41 #include "components/policy/core/common/remote_commands/remote_commands_service.
h" |
42 #include "components/policy/core/common/schema.h" | 42 #include "components/policy/core/common/schema.h" |
43 #include "components/policy/core/common/schema_map.h" | 43 #include "components/policy/core/common/schema_map.h" |
| 44 #include "components/policy/policy_constants.h" |
| 45 #include "components/policy/proto/device_management_backend.pb.h" |
44 #include "content/public/browser/web_contents.h" | 46 #include "content/public/browser/web_contents.h" |
45 #include "google_apis/gaia/gaia_auth_util.h" | 47 #include "google_apis/gaia/gaia_auth_util.h" |
46 #include "grit/components_strings.h" | 48 #include "grit/components_strings.h" |
47 #include "grit/policy_resources.h" | 49 #include "grit/policy_resources.h" |
48 #include "grit/policy_resources_map.h" | 50 #include "grit/policy_resources_map.h" |
49 #include "policy/policy_constants.h" | |
50 #include "policy/proto/device_management_backend.pb.h" | |
51 #include "ui/base/l10n/l10n_util.h" | 51 #include "ui/base/l10n/l10n_util.h" |
52 #include "ui/base/l10n/time_format.h" | 52 #include "ui/base/l10n/time_format.h" |
53 | 53 |
54 #if defined(OS_CHROMEOS) | 54 #if defined(OS_CHROMEOS) |
55 #include "chrome/browser/browser_process_platform_part.h" | 55 #include "chrome/browser/browser_process_platform_part.h" |
56 #include "chrome/browser/chromeos/policy/browser_policy_connector_chromeos.h" | 56 #include "chrome/browser/chromeos/policy/browser_policy_connector_chromeos.h" |
57 #include "chrome/browser/chromeos/policy/device_cloud_policy_manager_chromeos.h" | 57 #include "chrome/browser/chromeos/policy/device_cloud_policy_manager_chromeos.h" |
58 #include "chrome/browser/chromeos/policy/device_local_account_policy_service.h" | 58 #include "chrome/browser/chromeos/policy/device_local_account_policy_service.h" |
59 #include "chrome/browser/chromeos/policy/user_cloud_policy_manager_chromeos.h" | 59 #include "chrome/browser/chromeos/policy/user_cloud_policy_manager_chromeos.h" |
60 #include "chrome/browser/chromeos/policy/user_cloud_policy_manager_factory_chrom
eos.h" | 60 #include "chrome/browser/chromeos/policy/user_cloud_policy_manager_factory_chrom
eos.h" |
(...skipping 682 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
743 } | 743 } |
744 | 744 |
745 void PolicyUIHandler::OnRefreshPoliciesDone() const { | 745 void PolicyUIHandler::OnRefreshPoliciesDone() const { |
746 web_ui()->CallJavascriptFunctionUnsafe("policy.Page.reloadPoliciesDone"); | 746 web_ui()->CallJavascriptFunctionUnsafe("policy.Page.reloadPoliciesDone"); |
747 } | 747 } |
748 | 748 |
749 policy::PolicyService* PolicyUIHandler::GetPolicyService() const { | 749 policy::PolicyService* PolicyUIHandler::GetPolicyService() const { |
750 return policy::ProfilePolicyConnectorFactory::GetForBrowserContext( | 750 return policy::ProfilePolicyConnectorFactory::GetForBrowserContext( |
751 web_ui()->GetWebContents()->GetBrowserContext())->policy_service(); | 751 web_ui()->GetWebContents()->GetBrowserContext())->policy_service(); |
752 } | 752 } |
OLD | NEW |