Chromium Code Reviews| Index: chrome/browser/ui/content_settings/content_setting_image_model.h |
| diff --git a/chrome/browser/ui/content_settings/content_setting_image_model.h b/chrome/browser/ui/content_settings/content_setting_image_model.h |
| index ded59c1681d84d78ee254c8a83433136f2e908d3..eb193adbfb89ad31ad36020e3eb502cf88091873 100644 |
| --- a/chrome/browser/ui/content_settings/content_setting_image_model.h |
| +++ b/chrome/browser/ui/content_settings/content_setting_image_model.h |
| @@ -64,6 +64,10 @@ class ContentSettingImageModel { |
| int explanatory_string_id() const { return explanatory_string_id_; } |
| const base::string16& get_tooltip() const { return tooltip_; } |
| + // For testing only. If this image model has a content type, it is returned |
| + // here. Otherwise, CONTENT_SETTINGS_TYPE_DEFAULT is returned. |
| + virtual ContentSettingsType content_type(); |
|
Bernhard Bauer
2017/02/02 17:33:19
Name this method GetContentType()? It seems non-tr
kylix_rd
2017/02/02 19:07:16
Done.
|
| + |
| protected: |
| ContentSettingImageModel(); |
| @@ -102,13 +106,12 @@ class ContentSettingSimpleImageModel : public ContentSettingImageModel { |
| bool ShouldRunAnimation(content::WebContents* web_contents) override; |
| void SetAnimationHasRun(content::WebContents* web_contents) override; |
| + ContentSettingsType content_type() override; |
| + |
| // Factory method. Used only for testing. |
| static std::unique_ptr<ContentSettingImageModel> |
| CreateForContentTypeForTesting(ContentSettingsType content_type); |
| - protected: |
| - ContentSettingsType content_type() { return content_type_; } |
| - |
| private: |
| ContentSettingsType content_type_; |