New issue
Advanced search Search tips

Issue 781756 link

Starred by 1 user

Issue metadata

Status: Closed
Owner:
Closed: Aug 14
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Windows , Chrome , Mac
Pri: 3
Type: Bug
Team-Security-UX



Sign in to add a comment

Remove mixed-script and protocol-handler content settings

Project Member Reported by dullweber@chromium.org, Nov 6 2017

Issue description

CONTENT_SETTINGS_TYPE_MIXEDSCRIPT and CONTENT_SETTINGS_TYPE_PROTOCOL_HANDLERS only exist to show a ContentSettingsBubble. 
They are not actual content settings, so they should be removed as it is possible to show bubbles without having a content setting.
 
Owner: hkamila@chromium.org
While you're at this, it would be great if you could also rename ContentSettingImageModel and ContentSettingBubbleModel. Originally, they really corresponded to a content setting  (which is why this bug exists; things like MIXED_SCRIPT had to be added as a content setting to use the icon and the bubble). But they aren't anymore.

They each still have a subclass that is tied to a content setting (ContentSettingSimpleImageModel, ContentSettingSimpleBubbleModel). There's nothing inherently simple about these classes, it was just a better name than ContentSettingButThisTimeReallyImageModel. So those should be renamed too.
Components: UI>Browser>Permissions>Indicators
Labels: OS-Chrome OS-Linux OS-Mac OS-Windows
Status: Assigned (was: Available)
@msramek Since ContentSettingSimpleImageModel, ContentSettingSimpleBubbleModel are tied to a content setting, should the class-subclass be renamed to 
ImageModel - ContentSettingImageModel
BubbleModel - ContentSettingBubbleModel ?

--
To my understanding, even the classes inheriting from the current ContentSettingBubbleModel class, appear to be content settings, like ContentSettingMediaStreamBubbleModel, and ContentSettingDownloadsBubbleModel. MixedScript seems to be the only non content setting (and maybe "SubresourceFilter", not sure).
I'd suggest renaming the base class to something like "OmniboxImageModel", "OmniboxBubbleModel", since that's what they are - an image and bubble in the omnibox. Though the ui/ code owners may have better suggestions.

SubresourceFilter was added before it was a content setting, but later became one. MediaStream is indeed related to content settings, but to two of them.

Nevertheless, I still think renaming is a good idea. The current approach makes people think that they need a content setting, and one unnecessarily. The icons and bubbles in omnibox don't have anything to do inherently with content settings, they just happen to be used mostly for that.

Ideally, we would also clean up the base classes away from the content_settings/ codebase.
Status: Closed (was: Assigned)
It appears that CONTENT_SETTINGS_TYPE_PROTOCOL_HANDLERS is a permission also showed in chrome://settings/handlers. CONTENT_SETTINGS_TYPE_MIXEDSCRIPT, despite not being a content setting, it is treated as a content setting by the renderer.

I'm closing this issue about removing them, and I opened a new issue for tracking renaming the base classes and moving them out of the content_settings/ repository: https://bugs.chromium.org/p/chromium/issues/detail?id=874019

Sign in to add a comment