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 #ifndef CHROME_BROWSER_UI_WEBSITE_SETTINGS_WEBSITE_SETTINGS_H_ | 5 #ifndef CHROME_BROWSER_UI_WEBSITE_SETTINGS_WEBSITE_SETTINGS_H_ |
6 #define CHROME_BROWSER_UI_WEBSITE_SETTINGS_WEBSITE_SETTINGS_H_ | 6 #define CHROME_BROWSER_UI_WEBSITE_SETTINGS_WEBSITE_SETTINGS_H_ |
7 | 7 |
8 #include "base/strings/string16.h" | 8 #include "base/strings/string16.h" |
9 #include "chrome/browser/content_settings/tab_specific_content_settings.h" | 9 #include "chrome/browser/content_settings/tab_specific_content_settings.h" |
10 #include "chrome/browser/ssl/security_state_model.h" | |
11 #include "components/content_settings/core/common/content_settings.h" | 10 #include "components/content_settings/core/common/content_settings.h" |
12 #include "components/content_settings/core/common/content_settings_types.h" | 11 #include "components/content_settings/core/common/content_settings_types.h" |
| 12 #include "components/security_state/security_state_model.h" |
13 #include "content/public/common/signed_certificate_timestamp_id_and_status.h" | 13 #include "content/public/common/signed_certificate_timestamp_id_and_status.h" |
14 #include "url/gurl.h" | 14 #include "url/gurl.h" |
15 | 15 |
16 namespace content { | 16 namespace content { |
17 class CertStore; | 17 class CertStore; |
18 class WebContents; | 18 class WebContents; |
19 } | 19 } |
20 | 20 |
21 class ChromeSSLHostStateDelegate; | 21 class ChromeSSLHostStateDelegate; |
22 class HostContentSettingsMap; | 22 class HostContentSettingsMap; |
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
93 }; | 93 }; |
94 | 94 |
95 // Creates a WebsiteSettings for the passed |url| using the given |ssl| status | 95 // Creates a WebsiteSettings for the passed |url| using the given |ssl| status |
96 // object to determine the status of the site's connection. The | 96 // object to determine the status of the site's connection. The |
97 // |WebsiteSettings| takes ownership of the |ui|. | 97 // |WebsiteSettings| takes ownership of the |ui|. |
98 WebsiteSettings(WebsiteSettingsUI* ui, | 98 WebsiteSettings(WebsiteSettingsUI* ui, |
99 Profile* profile, | 99 Profile* profile, |
100 TabSpecificContentSettings* tab_specific_content_settings, | 100 TabSpecificContentSettings* tab_specific_content_settings, |
101 content::WebContents* web_contents, | 101 content::WebContents* web_contents, |
102 const GURL& url, | 102 const GURL& url, |
103 const SecurityStateModel::SecurityInfo& security_info, | 103 const security_state::SecurityInfo& security_info, |
104 content::CertStore* cert_store); | 104 content::CertStore* cert_store); |
105 ~WebsiteSettings() override; | 105 ~WebsiteSettings() override; |
106 | 106 |
107 void RecordWebsiteSettingsAction(WebsiteSettingsAction action); | 107 void RecordWebsiteSettingsAction(WebsiteSettingsAction action); |
108 | 108 |
109 // This method is called when ever a permission setting is changed. | 109 // This method is called when ever a permission setting is changed. |
110 void OnSitePermissionChanged(ContentSettingsType type, | 110 void OnSitePermissionChanged(ContentSettingsType type, |
111 ContentSetting value); | 111 ContentSetting value); |
112 | 112 |
113 // This method is called by the UI when the UI is closing. | 113 // This method is called by the UI when the UI is closing. |
(...skipping 23 matching lines...) Expand all Loading... |
137 | 137 |
138 base::string16 organization_name() const { | 138 base::string16 organization_name() const { |
139 return organization_name_; | 139 return organization_name_; |
140 } | 140 } |
141 | 141 |
142 // SiteDataObserver implementation. | 142 // SiteDataObserver implementation. |
143 void OnSiteDataAccessed() override; | 143 void OnSiteDataAccessed() override; |
144 | 144 |
145 private: | 145 private: |
146 // Initializes the |WebsiteSettings|. | 146 // Initializes the |WebsiteSettings|. |
147 void Init(const GURL& url, | 147 void Init(const GURL& url, const security_state::SecurityInfo& security_info); |
148 const SecurityStateModel::SecurityInfo& security_info); | |
149 | 148 |
150 // Sets (presents) the information about the site's permissions in the |ui_|. | 149 // Sets (presents) the information about the site's permissions in the |ui_|. |
151 void PresentSitePermissions(); | 150 void PresentSitePermissions(); |
152 | 151 |
153 // Sets (presents) the information about the site's data in the |ui_|. | 152 // Sets (presents) the information about the site's data in the |ui_|. |
154 void PresentSiteData(); | 153 void PresentSiteData(); |
155 | 154 |
156 // Sets (presents) the information about the site's identity and connection | 155 // Sets (presents) the information about the site's identity and connection |
157 // in the |ui_|. | 156 // in the |ui_|. |
158 void PresentSiteIdentity(); | 157 void PresentSiteIdentity(); |
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
229 ChromeSSLHostStateDelegate* chrome_ssl_host_state_delegate_; | 228 ChromeSSLHostStateDelegate* chrome_ssl_host_state_delegate_; |
230 | 229 |
231 bool did_revoke_user_ssl_decisions_; | 230 bool did_revoke_user_ssl_decisions_; |
232 | 231 |
233 Profile* profile_; | 232 Profile* profile_; |
234 | 233 |
235 DISALLOW_COPY_AND_ASSIGN(WebsiteSettings); | 234 DISALLOW_COPY_AND_ASSIGN(WebsiteSettings); |
236 }; | 235 }; |
237 | 236 |
238 #endif // CHROME_BROWSER_UI_WEBSITE_SETTINGS_WEBSITE_SETTINGS_H_ | 237 #endif // CHROME_BROWSER_UI_WEBSITE_SETTINGS_WEBSITE_SETTINGS_H_ |
OLD | NEW |