| Index: chrome/browser/chromeos/policy/policy_util.cc
|
| diff --git a/chrome/browser/chromeos/policy/policy_util.cc b/chrome/browser/chromeos/policy/policy_util.cc
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..d980e9e26f51cb5a9b196a752066d84385cd074b
|
| --- /dev/null
|
| +++ b/chrome/browser/chromeos/policy/policy_util.cc
|
| @@ -0,0 +1,20 @@
|
| +// Copyright 2014 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#include "chrome/browser/chromeos/policy/policy_util.h"
|
| +
|
| +namespace em = enterprise_management;
|
| +
|
| +namespace policy {
|
| +
|
| +em::PolicyData::ManagementMode GetManagementMode(
|
| + const em::PolicyData& policy_data) {
|
| + if (policy_data.has_management_mode())
|
| + return policy_data.management_mode();
|
| + if (policy_data.has_request_token())
|
| + return em::PolicyData::ENTERPRISE_MANAGED;
|
| + return em::PolicyData::LOCAL_OWNER;
|
| +}
|
| +
|
| +} // namespace policy
|
|
|