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 // Most of this code is copied from various classes in | 5 // Most of this code is copied from various classes in |
6 // src/chrome/browser/policy. In particular, look at | 6 // src/chrome/browser/policy. In particular, look at |
7 // | 7 // |
8 // file_based_policy_loader.{h,cc} | 8 // file_based_policy_loader.{h,cc} |
9 // config_dir_policy_provider.{h,cc} | 9 // config_dir_policy_provider.{h,cc} |
10 // | 10 // |
(...skipping 226 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
237 // wall clock times come from the same source, just in case there is some | 237 // wall clock times come from the same source, just in case there is some |
238 // non-local filesystem involved. | 238 // non-local filesystem involved. |
239 base::Time last_modification_clock_; | 239 base::Time last_modification_clock_; |
240 | 240 |
241 const base::FilePath config_dir_; | 241 const base::FilePath config_dir_; |
242 | 242 |
243 // Allows us to cancel any inflight FileWatcher events or scheduled reloads. | 243 // Allows us to cancel any inflight FileWatcher events or scheduled reloads. |
244 base::WeakPtrFactory<PolicyWatcherLinux> weak_factory_; | 244 base::WeakPtrFactory<PolicyWatcherLinux> weak_factory_; |
245 }; | 245 }; |
246 | 246 |
247 PolicyWatcher* PolicyWatcher::Create( | 247 scoped_ptr<PolicyWatcher> PolicyWatcher::Create( |
| 248 policy::PolicyService* policy_service, |
248 scoped_refptr<base::SingleThreadTaskRunner> task_runner) { | 249 scoped_refptr<base::SingleThreadTaskRunner> task_runner) { |
249 base::FilePath policy_dir(kPolicyDir); | 250 base::FilePath policy_dir(kPolicyDir); |
250 return new PolicyWatcherLinux(task_runner, policy_dir); | 251 return make_scoped_ptr(new PolicyWatcherLinux(task_runner, policy_dir)); |
251 } | 252 } |
252 | 253 |
253 } // namespace policy_hack | 254 } // namespace policy_hack |
254 } // namespace remoting | 255 } // namespace remoting |
OLD | NEW |