| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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_setting_image_model.h" | 5 #include "chrome/browser/content_setting_image_model.h" |
| 6 | 6 |
| 7 #include "app/l10n_util.h" | 7 #include "app/l10n_util.h" |
| 8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
| 9 #include "chrome/browser/content_settings/host_content_settings_map.h" | 9 #include "chrome/browser/content_settings/host_content_settings_map.h" |
| 10 #include "chrome/browser/profiles/profile.h" | 10 #include "chrome/browser/profiles/profile.h" |
| 11 #include "chrome/browser/tab_contents/tab_contents.h" | 11 #include "chrome/browser/tab_contents/tab_contents.h" |
| 12 #include "chrome/common/chrome_switches.h" | |
| 13 #include "grit/generated_resources.h" | 12 #include "grit/generated_resources.h" |
| 14 #include "grit/theme_resources.h" | 13 #include "grit/theme_resources.h" |
| 15 | 14 |
| 16 class ContentSettingBlockedImageModel : public ContentSettingImageModel { | 15 class ContentSettingBlockedImageModel : public ContentSettingImageModel { |
| 17 public: | 16 public: |
| 18 explicit ContentSettingBlockedImageModel( | 17 explicit ContentSettingBlockedImageModel( |
| 19 ContentSettingsType content_settings_type); | 18 ContentSettingsType content_settings_type); |
| 20 | 19 |
| 21 virtual void UpdateFromTabContents(TabContents* tab_contents); | 20 virtual void UpdateFromTabContents(TabContents* tab_contents); |
| 22 | 21 |
| (...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 187 // static | 186 // static |
| 188 ContentSettingImageModel* | 187 ContentSettingImageModel* |
| 189 ContentSettingImageModel::CreateContentSettingImageModel( | 188 ContentSettingImageModel::CreateContentSettingImageModel( |
| 190 ContentSettingsType content_settings_type) { | 189 ContentSettingsType content_settings_type) { |
| 191 if (content_settings_type == CONTENT_SETTINGS_TYPE_GEOLOCATION) | 190 if (content_settings_type == CONTENT_SETTINGS_TYPE_GEOLOCATION) |
| 192 return new ContentSettingGeolocationImageModel(); | 191 return new ContentSettingGeolocationImageModel(); |
| 193 if (content_settings_type == CONTENT_SETTINGS_TYPE_NOTIFICATIONS) | 192 if (content_settings_type == CONTENT_SETTINGS_TYPE_NOTIFICATIONS) |
| 194 return new ContentSettingNotificationsImageModel(); | 193 return new ContentSettingNotificationsImageModel(); |
| 195 return new ContentSettingBlockedImageModel(content_settings_type); | 194 return new ContentSettingBlockedImageModel(content_settings_type); |
| 196 } | 195 } |
| OLD | NEW |