Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3355)

Unified Diff: chrome/browser/ui/content_settings/content_setting_image_model.h

Issue 2668833003: DialogBrowserTest implementation to invoke Content settings bubble dialogs. (Closed)
Patch Set: Merge fix from https://codereview.chromium.org/2663163004. This is temporary Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
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..8db43357afda75df66aa7f02594cc892dd9fdb4c 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 GetContentType();
tapted 2017/02/03 23:07:02 This still violates https://chromium.googlesource.
+
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 GetContentType() 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_;

Powered by Google App Engine
This is Rietveld 408576698