diff options
author | jochen@chromium.org <jochen@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-07-12 09:12:59 +0000 |
---|---|---|
committer | jochen@chromium.org <jochen@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-07-12 09:12:59 +0000 |
commit | 5c7d598adfc690fe676c54f62cd733d25ee20fa8 (patch) | |
tree | ab138d9c44fde00390e5f5cc203f292d7aa80815 /chrome/browser/tab_contents | |
parent | ca10046545d16cfd705fbfc356d97710f47cedee (diff) | |
download | chromium_src-5c7d598adfc690fe676c54f62cd733d25ee20fa8.zip chromium_src-5c7d598adfc690fe676c54f62cd733d25ee20fa8.tar.gz chromium_src-5c7d598adfc690fe676c54f62cd733d25ee20fa8.tar.bz2 |
Reland r52072. Pass notifications to the browser on access to the appcache main resource manifest.
BUG=45230
TEST=browser_tests
TBR=vandebo
Review URL: http://codereview.chromium.org/2980001
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@52074 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/tab_contents')
-rw-r--r-- | chrome/browser/tab_contents/tab_specific_content_settings.cc | 10 | ||||
-rw-r--r-- | chrome/browser/tab_contents/tab_specific_content_settings.h | 2 |
2 files changed, 12 insertions, 0 deletions
diff --git a/chrome/browser/tab_contents/tab_specific_content_settings.cc b/chrome/browser/tab_contents/tab_specific_content_settings.cc index 891debd..21aaa3f 100644 --- a/chrome/browser/tab_contents/tab_specific_content_settings.cc +++ b/chrome/browser/tab_contents/tab_specific_content_settings.cc @@ -73,6 +73,16 @@ void TabSpecificContentSettings::OnWebDatabaseAccessed( } } +void TabSpecificContentSettings::OnAppCacheAccessed( + const GURL& manifest_url, bool blocked_by_policy) { + if (blocked_by_policy) { + blocked_local_shared_objects_.appcaches()->AddAppCache(manifest_url); + OnContentBlocked(CONTENT_SETTINGS_TYPE_COOKIES); + } else { + allowed_local_shared_objects_.appcaches()->AddAppCache(manifest_url); + } +} + void TabSpecificContentSettings::OnGeolocationPermissionSet( const GURL& requesting_origin, bool allowed) { diff --git a/chrome/browser/tab_contents/tab_specific_content_settings.h b/chrome/browser/tab_contents/tab_specific_content_settings.h index 8613b1a..648841e 100644 --- a/chrome/browser/tab_contents/tab_specific_content_settings.h +++ b/chrome/browser/tab_contents/tab_specific_content_settings.h @@ -65,6 +65,8 @@ class TabSpecificContentSettings const string16& display_name, unsigned long estimated_size, bool blocked_by_policy); + virtual void OnAppCacheAccessed(const GURL& manifest_url, + bool blocked_by_policy); virtual void OnGeolocationPermissionSet(const GURL& requesting_frame, bool allowed); |