Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(72)

Side by Side Diff: chrome/browser/chromeos/policy/device_local_account_policy_provider.h

Issue 1304843004: Add source column to chrome://policy showing the origins of policies. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed browsertest and removed unnecessary string for default values. Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 #ifndef CHROME_BROWSER_CHROMEOS_POLICY_DEVICE_LOCAL_ACCOUNT_POLICY_PROVIDER_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_POLICY_DEVICE_LOCAL_ACCOUNT_POLICY_PROVIDER_H_
6 #define CHROME_BROWSER_CHROMEOS_POLICY_DEVICE_LOCAL_ACCOUNT_POLICY_PROVIDER_H_ 6 #define CHROME_BROWSER_CHROMEOS_POLICY_DEVICE_LOCAL_ACCOUNT_POLICY_PROVIDER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 28 matching lines...) Expand all
39 // Factory function to create and initialize a provider for |user_id|. Returns 39 // Factory function to create and initialize a provider for |user_id|. Returns
40 // NULL if |user_id| is not a device-local account or user policy isn't 40 // NULL if |user_id| is not a device-local account or user policy isn't
41 // applicable for user_id's user type. 41 // applicable for user_id's user type.
42 static scoped_ptr<DeviceLocalAccountPolicyProvider> Create( 42 static scoped_ptr<DeviceLocalAccountPolicyProvider> Create(
43 const std::string& user_id, 43 const std::string& user_id,
44 DeviceLocalAccountPolicyService* service); 44 DeviceLocalAccountPolicyService* service);
45 45
46 // ConfigurationPolicyProvider: 46 // ConfigurationPolicyProvider:
47 bool IsInitializationComplete(PolicyDomain domain) const override; 47 bool IsInitializationComplete(PolicyDomain domain) const override;
48 void RefreshPolicies() override; 48 void RefreshPolicies() override;
49 PolicySource source() const override;
Thiemo Nagel 2015/09/01 17:40:35 Remove.
fhorschig 2015/09/04 06:53:53 Done.
49 50
50 // DeviceLocalAccountPolicyService::Observer: 51 // DeviceLocalAccountPolicyService::Observer:
51 void OnPolicyUpdated(const std::string& user_id) override; 52 void OnPolicyUpdated(const std::string& user_id) override;
52 void OnDeviceLocalAccountsChanged() override; 53 void OnDeviceLocalAccountsChanged() override;
53 54
54 private: 55 private:
55 // Returns the broker for |user_id_| or NULL if not available. 56 // Returns the broker for |user_id_| or NULL if not available.
56 DeviceLocalAccountPolicyBroker* GetBroker() const; 57 DeviceLocalAccountPolicyBroker* GetBroker() const;
57 58
58 // Handles completion of policy refreshes and triggers the update callback. 59 // Handles completion of policy refreshes and triggers the update callback.
(...skipping 18 matching lines...) Expand all
77 bool waiting_for_policy_refresh_; 78 bool waiting_for_policy_refresh_;
78 79
79 base::WeakPtrFactory<DeviceLocalAccountPolicyProvider> weak_factory_; 80 base::WeakPtrFactory<DeviceLocalAccountPolicyProvider> weak_factory_;
80 81
81 DISALLOW_COPY_AND_ASSIGN(DeviceLocalAccountPolicyProvider); 82 DISALLOW_COPY_AND_ASSIGN(DeviceLocalAccountPolicyProvider);
82 }; 83 };
83 84
84 } // namespace policy 85 } // namespace policy
85 86
86 #endif // CHROME_BROWSER_CHROMEOS_POLICY_DEVICE_LOCAL_ACCOUNT_POLICY_PROVIDER_H _ 87 #endif // CHROME_BROWSER_CHROMEOS_POLICY_DEVICE_LOCAL_ACCOUNT_POLICY_PROVIDER_H _
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698