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

Side by Side Diff: chrome/browser/policy/configuration_policy_provider.h

Issue 7064033: Virtual destructors should have virtual keyword. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Created 9 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « chrome/browser/plugin_observer.h ('k') | chrome/browser/policy/profile_policy_connector.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_POLICY_CONFIGURATION_POLICY_PROVIDER_H_ 5 #ifndef CHROME_BROWSER_POLICY_CONFIGURATION_POLICY_PROVIDER_H_
6 #define CHROME_BROWSER_POLICY_CONFIGURATION_POLICY_PROVIDER_H_ 6 #define CHROME_BROWSER_POLICY_CONFIGURATION_POLICY_PROVIDER_H_
7 #pragma once 7 #pragma once
8 8
9 #include <map> 9 #include <map>
10 #include <string> 10 #include <string>
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 96
97 // Manages observers for a ConfigurationPolicyProvider. Is used to register 97 // Manages observers for a ConfigurationPolicyProvider. Is used to register
98 // observers, and automatically removes them upon destruction. 98 // observers, and automatically removes them upon destruction.
99 // Implementation detail: to avoid duplicate bookkeeping of registered 99 // Implementation detail: to avoid duplicate bookkeeping of registered
100 // observers, this registrar class acts as a proxy for notifications (since it 100 // observers, this registrar class acts as a proxy for notifications (since it
101 // needs to register itself anyway to get OnProviderGoingAway notifications). 101 // needs to register itself anyway to get OnProviderGoingAway notifications).
102 class ConfigurationPolicyObserverRegistrar 102 class ConfigurationPolicyObserverRegistrar
103 : ConfigurationPolicyProvider::Observer { 103 : ConfigurationPolicyProvider::Observer {
104 public: 104 public:
105 ConfigurationPolicyObserverRegistrar(); 105 ConfigurationPolicyObserverRegistrar();
106 ~ConfigurationPolicyObserverRegistrar(); 106 virtual ~ConfigurationPolicyObserverRegistrar();
107 void Init(ConfigurationPolicyProvider* provider, 107 void Init(ConfigurationPolicyProvider* provider,
108 ConfigurationPolicyProvider::Observer* observer); 108 ConfigurationPolicyProvider::Observer* observer);
109 109
110 // ConfigurationPolicyProvider::Observer implementation: 110 // ConfigurationPolicyProvider::Observer implementation:
111 virtual void OnUpdatePolicy(); 111 virtual void OnUpdatePolicy();
112 virtual void OnProviderGoingAway(); 112 virtual void OnProviderGoingAway();
113 113
114 private: 114 private:
115 ConfigurationPolicyProvider* provider_; 115 ConfigurationPolicyProvider* provider_;
116 ConfigurationPolicyProvider::Observer* observer_; 116 ConfigurationPolicyProvider::Observer* observer_;
117 117
118 DISALLOW_COPY_AND_ASSIGN(ConfigurationPolicyObserverRegistrar); 118 DISALLOW_COPY_AND_ASSIGN(ConfigurationPolicyObserverRegistrar);
119 }; 119 };
120 120
121 } // namespace policy 121 } // namespace policy
122 122
123 #endif // CHROME_BROWSER_POLICY_CONFIGURATION_POLICY_PROVIDER_H_ 123 #endif // CHROME_BROWSER_POLICY_CONFIGURATION_POLICY_PROVIDER_H_
OLDNEW
« no previous file with comments | « chrome/browser/plugin_observer.h ('k') | chrome/browser/policy/profile_policy_connector.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698