How to edit Chromium source code to block all videos and images on web pages

493 views
Skip to first unread message

Sergii

unread,
Jun 1, 2021, 11:31:40 AM6/1/21
to blink-dev
I need to edit Chromium source code in order to block displaying of all videos and images on web pages including the img tags and backgrounds in css. I've fetched the source code for Windows and installed Visual Studio 2019. What should I do next?

K. Moon

unread,
Jun 1, 2021, 12:32:34 PM6/1/21
to Sergii, blink-dev
"I've downloaded the source code and installed Visual Studio 2019" is probably too early a point to ask a good question, and you're unlikely to get a useful response here.

If you haven't built the source code into a working browser yet, that would be the next step. After that, you should try to accomplish your task on your own. You'll inevitably hit some specific roadblock at some point, which is a good time to ask a question with more context and details.

Code Search (https://source.chromium.org/) is also a great place to explore the code base.

On Tue, Jun 1, 2021 at 8:31 AM Sergii <sergii...@gmail.com> wrote:
I need to edit Chromium source code in order to block displaying of all videos and images on web pages including the img tags and backgrounds in css. I've fetched the source code for Windows and installed Visual Studio 2019. What should I do next?

--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/6b1719d6-8bb3-420a-b319-d8cc631a230fn%40chromium.org.

K. Moon

unread,
Jun 1, 2021, 12:34:29 PM6/1/21
to Sergii, blink-dev
One more thing: I suspect something like this could be accomplished with a Chrome extension, rather than modifying the browser, so that may be another approach to explore, too.

Sergii

unread,
Jun 1, 2021, 3:03:39 PM6/1/21
to blink-dev, km...@chromium.org, blink-dev, Sergii
Yes, I thought about an extension, but there are two problems:
1) I need a way that can be canceled only by administrator OR by reinstalling Windows; therefore an extension would be the way if I can hide the Extensions item in the Chrome/Chromium settings menu so that standard user could not remove or turn off the extension (and maybe it can be done via editing compiled file(s), but I don't know how)
2) an image on a web page is cached before the extension on the client hides it

вівторок, 1 червня 2021 р. о 19:34:29 UTC+3 km...@chromium.org пише:

Kai Ninomiya

unread,
Jun 1, 2021, 5:25:00 PM6/1/21
to blink-dev, Sergii, K. Moon, blink-dev
Most likely you should not fork Chromium to enforce a policy like this. Instead, consider using the existing Chrome Enterprise policy options:
I believe it is equivalent to forcing the user settings in: chrome://settings/content/images

However, unfortunately, this policy does not appear to apply to videos. You should file a feature request to either make DefaultImagesSetting apply to videos as well, or add a new setting/policy option for videos.

Sergii

unread,
Jul 22, 2021, 12:16:08 PM7/22/21
to blink-dev, kai...@chromium.org, Sergii, km...@chromium.org, blink-dev
Thanks. Could you post a link to the page where I can "file a feature request to either make DefaultImagesSetting apply to videos as well, or add a new setting/policy option for videos" ?

середа, 2 червня 2021 р. о 00:25:00 UTC+3 kai...@chromium.org пише:

Kai Ninomiya

unread,
Jul 22, 2021, 9:26:51 PM7/22/21
to blink-dev, Sergii, Kai Ninomiya, K. Moon, blink-dev
https://crbug.com/ and click New issue
Reply all
Reply to author
Forward
0 new messages