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

Side by Side Diff: chrome/browser/content_settings/content_settings_mock_provider.cc

Issue 7218073: Explicitly ShutdownOnUIThread the HostContentSettingsMap when destroying the Profile. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: review Created 9 years, 5 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
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 #include "chrome/browser/content_settings/content_settings_mock_provider.h" 5 #include "chrome/browser/content_settings/content_settings_mock_provider.h"
6 6
7 namespace content_settings { 7 namespace content_settings {
8 8
9 MockDefaultProvider::MockDefaultProvider( 9 MockDefaultProvider::MockDefaultProvider(
10 ContentSettingsType content_type, 10 ContentSettingsType content_type,
(...skipping 19 matching lines...) Expand all
30 ContentSetting setting) { 30 ContentSetting setting) {
31 if (can_override_ && content_type == content_type_) 31 if (can_override_ && content_type == content_type_)
32 setting_ = setting; 32 setting_ = setting;
33 } 33 }
34 34
35 bool MockDefaultProvider::DefaultSettingIsManaged( 35 bool MockDefaultProvider::DefaultSettingIsManaged(
36 ContentSettingsType content_type) const { 36 ContentSettingsType content_type) const {
37 return content_type == content_type_ && is_managed_; 37 return content_type == content_type_ && is_managed_;
38 } 38 }
39 39
40 void MockDefaultProvider::ShutdownOnUIThread() {
41 }
42
40 MockProvider::MockProvider() 43 MockProvider::MockProvider()
41 : requesting_url_pattern_(ContentSettingsPattern()), 44 : requesting_url_pattern_(ContentSettingsPattern()),
42 embedding_url_pattern_(ContentSettingsPattern()), 45 embedding_url_pattern_(ContentSettingsPattern()),
43 content_type_(CONTENT_SETTINGS_TYPE_COOKIES), 46 content_type_(CONTENT_SETTINGS_TYPE_COOKIES),
44 resource_identifier_(""), 47 resource_identifier_(""),
45 setting_(CONTENT_SETTING_DEFAULT), 48 setting_(CONTENT_SETTING_DEFAULT),
46 read_only_(false) {} 49 read_only_(false) {}
47 50
48 MockProvider::MockProvider(ContentSettingsPattern requesting_url_pattern, 51 MockProvider::MockProvider(ContentSettingsPattern requesting_url_pattern,
49 ContentSettingsPattern embedding_url_pattern, 52 ContentSettingsPattern embedding_url_pattern,
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 if (read_only_) 86 if (read_only_)
84 return; 87 return;
85 requesting_url_pattern_ = ContentSettingsPattern(requesting_url_pattern); 88 requesting_url_pattern_ = ContentSettingsPattern(requesting_url_pattern);
86 embedding_url_pattern_ = ContentSettingsPattern(embedding_url_pattern); 89 embedding_url_pattern_ = ContentSettingsPattern(embedding_url_pattern);
87 content_type_ = content_type; 90 content_type_ = content_type;
88 resource_identifier_ = resource_identifier; 91 resource_identifier_ = resource_identifier;
89 setting_ = content_setting; 92 setting_ = content_setting;
90 } 93 }
91 94
92 } // namespace content_settings 95 } // namespace content_settings
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698