diff options
Diffstat (limited to 'chrome/browser/content_setting_image_model.cc')
-rw-r--r-- | chrome/browser/content_setting_image_model.cc | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/chrome/browser/content_setting_image_model.cc b/chrome/browser/content_setting_image_model.cc index b1a0a53..26e349ac 100644 --- a/chrome/browser/content_setting_image_model.cc +++ b/chrome/browser/content_setting_image_model.cc @@ -59,8 +59,10 @@ ContentSettingBlockedImageModel::ContentSettingBlockedImageModel( void ContentSettingBlockedImageModel::UpdateFromTabContents( const TabContents* tab_contents) { - if (!tab_contents || - !tab_contents->IsContentBlocked(get_content_settings_type())) { + TabSpecificContentSettings* content_settings = tab_contents ? + tab_contents->GetTabSpecificContentSettings() : NULL; + if (!content_settings || + !content_settings->IsContentBlocked(get_content_settings_type())) { set_visible(false); return; } @@ -80,8 +82,10 @@ void ContentSettingGeolocationImageModel::UpdateFromTabContents( set_visible(false); return; } + TabSpecificContentSettings* content_settings = + tab_contents->GetTabSpecificContentSettings(); const GeolocationSettingsState& settings_state = - tab_contents->geolocation_settings_state(); + content_settings->geolocation_settings_state(); if (settings_state.state_map().empty()) { set_visible(false); return; |