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

Side by Side Diff: chrome/browser/content_settings/host_content_settings_map.h

Issue 356543003: Audit the last usage of Geolocation and Notification permissions. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 6 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 // Maps hostnames to custom content settings. Written on the UI thread and read 5 // Maps hostnames to custom content settings. Written on the UI thread and read
6 // on any thread. One instance per profile. 6 // on any thread. One instance per profile.
7 7
8 #ifndef CHROME_BROWSER_CONTENT_SETTINGS_HOST_CONTENT_SETTINGS_MAP_H_ 8 #ifndef CHROME_BROWSER_CONTENT_SETTINGS_HOST_CONTENT_SETTINGS_MAP_H_
9 #define CHROME_BROWSER_CONTENT_SETTINGS_HOST_CONTENT_SETTINGS_MAP_H_ 9 #define CHROME_BROWSER_CONTENT_SETTINGS_HOST_CONTENT_SETTINGS_MAP_H_
10 10
(...skipping 181 matching lines...) Expand 10 before | Expand all | Expand 10 after
192 // Returns the ProviderType associated with the given source string. 192 // Returns the ProviderType associated with the given source string.
193 // TODO(estade): I regret adding this. At the moment there are no legitimate 193 // TODO(estade): I regret adding this. At the moment there are no legitimate
194 // uses. We should stick to ProviderType rather than string so we don't have 194 // uses. We should stick to ProviderType rather than string so we don't have
195 // to convert backwards. 195 // to convert backwards.
196 static ProviderType GetProviderTypeFromSource(const std::string& source); 196 static ProviderType GetProviderTypeFromSource(const std::string& source);
197 197
198 bool is_off_the_record() const { 198 bool is_off_the_record() const {
199 return is_off_the_record_; 199 return is_off_the_record_;
200 } 200 }
201 201
202 void UpdateLastUsage(const GURL& primary_url,
dewittj 2014/06/26 15:56:51 needs comment
203 const GURL& secondary_url,
204 ContentSettingsType content_type);
205
202 private: 206 private:
203 friend class base::RefCountedThreadSafe<HostContentSettingsMap>; 207 friend class base::RefCountedThreadSafe<HostContentSettingsMap>;
204 friend class HostContentSettingsMapTest_NonDefaultSettings_Test; 208 friend class HostContentSettingsMapTest_NonDefaultSettings_Test;
205 209
206 typedef std::map<ProviderType, content_settings::ProviderInterface*> 210 typedef std::map<ProviderType, content_settings::ProviderInterface*>
207 ProviderMap; 211 ProviderMap;
208 typedef ProviderMap::iterator ProviderIterator; 212 typedef ProviderMap::iterator ProviderIterator;
209 typedef ProviderMap::const_iterator ConstProviderIterator; 213 typedef ProviderMap::const_iterator ConstProviderIterator;
210 214
211 virtual ~HostContentSettingsMap(); 215 virtual ~HostContentSettingsMap();
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
254 258
255 // Content setting providers. This is only modified at construction 259 // Content setting providers. This is only modified at construction
256 // time and by RegisterExtensionService, both of which should happen 260 // time and by RegisterExtensionService, both of which should happen
257 // before any other uses of it. 261 // before any other uses of it.
258 ProviderMap content_settings_providers_; 262 ProviderMap content_settings_providers_;
259 263
260 DISALLOW_COPY_AND_ASSIGN(HostContentSettingsMap); 264 DISALLOW_COPY_AND_ASSIGN(HostContentSettingsMap);
261 }; 265 };
262 266
263 #endif // CHROME_BROWSER_CONTENT_SETTINGS_HOST_CONTENT_SETTINGS_MAP_H_ 267 #endif // CHROME_BROWSER_CONTENT_SETTINGS_HOST_CONTENT_SETTINGS_MAP_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698