Index: chrome/browser/ui/webui/policy_ui.cc |
diff --git a/chrome/browser/ui/webui/policy_ui.cc b/chrome/browser/ui/webui/policy_ui.cc |
index d2e73e74be61fda360dd2c42cc5b626cb4339405..921bd87cd8b9910c16868155399fccfbb8ed216d 100644 |
--- a/chrome/browser/ui/webui/policy_ui.cc |
+++ b/chrome/browser/ui/webui/policy_ui.cc |
@@ -36,6 +36,7 @@ |
#include "components/policy/core/common/policy_namespace.h" |
#include "components/policy/core/common/policy_service.h" |
#include "components/policy/core/common/policy_types.h" |
+#include "components/policy/core/common/remote_commands/remote_commands_service.h" |
#include "components/policy/core/common/schema.h" |
#include "components/policy/core/common/schema_map.h" |
#include "components/policy/core/common/schema_registry.h" |
@@ -807,6 +808,18 @@ void PolicyUIHandler::HandleInitialized(const base::ListValue* args) { |
} |
void PolicyUIHandler::HandleReloadPolicies(const base::ListValue* args) { |
+#if defined(OS_CHROMEOS) |
+ // Allow user to manually fetch remote commands, in case invalidation |
+ // service is not working properly. |
+ // TODO(binjin): evaluate and possibly remove this after invalidation |
bartfab (slow)
2015/04/29 15:21:38
Nit: Please reference a bug number.
binjin
2015/04/29 17:24:42
Done.
|
+ // service is landed and tested. |
+ policy::BrowserPolicyConnectorChromeOS* connector = |
bartfab (slow)
2015/04/29 15:21:38
Nit: #include "chrome/browser/chromeos/policy/brow
binjin
2015/04/29 17:24:42
It's already included, inside defined(OS_CHROMEOS)
|
+ g_browser_process->platform_part()->browser_policy_connector_chromeos(); |
bartfab (slow)
2015/04/29 15:21:38
Nit: #include "chrome/browser/browser_process_plat
binjin
2015/04/29 17:24:42
Done.
|
+ connector->GetDeviceCloudPolicyManager() |
+ ->core() |
+ ->remote_commands_service() |
+ ->FetchRemoteCommands(); |
+#endif |
GetPolicyService()->RefreshPolicies( |
base::Bind(&PolicyUIHandler::OnRefreshPoliciesDone, |
weak_factory_.GetWeakPtr())); |