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

Issue 965103004: Stop using the MEDIASTREAM content setting. (Closed)

Created:
5 years, 9 months ago by msramek
Modified:
5 years, 9 months ago
CC:
chromium-reviews, dbeam+watch-options_chromium.org, feature-media-reviews_chromium.org, mcasas+watch_chromium.org, michaelpg+watch-options_chromium.org, posciak+watch_chromium.org, wjia+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Stop using the MEDIASTREAM content setting. While the exceptions of the deprecated MEDIASTREAM are no longer used (and were migrated to MEDIASTREAM_MIC and MEDIASTREAM_CAMERA exceptions), the default value is still used. This CL: 1. Replaces MEDIASTREAM default checks with MIC or CAMERA checks in contexts where only one of the two permissions is required. 2. Replaces MEDIASTREAM default checks with both MIC and CAMERA in contexts where both of the permissions are required. 3. Replaces any write of MEDIASTREAM default with write of both MIC and CAMERA. This CL does not get rid of the MEDIASTREAM content setting entirely. This is because: 1. There is a mapping between content settings and sections in chrome://settings/content. The media part is mapped to MEDIASTREAM. 2. There is a mapping between content settings and icons shown in the omnibox when the content settings are queried. The icon shown for both camera and microphone is mapped to MEDIASTREAM. However, after this CL is applied, the MEDIASTREAM content setting will only be used in the above circumstances, never to set or get a value. To avoid complicated syncing between MEDIASTREAM value on old versions and MEDIASTREAM_MIC, MEDIASTREAM_CAMERA on new versions of Chrome, this CL will not land until crbug.com/452388 is resolved. TESTED=UI,policy BUG=464382 Committed: https://crrev.com/f90963538b234e2bad01b2f182ba8d98b179b1a5 Cr-Commit-Position: refs/heads/master@{#322364}

Patch Set 1 #

Patch Set 2 : Fixed tests. #

Patch Set 3 : Updated policy #

Total comments: 4

Patch Set 4 : Migration code added. #

Total comments: 6

Patch Set 5 : Fixes. #

Total comments: 2

Patch Set 6 : Added braces. #

Patch Set 7 : Rebase over 1004733003. #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+192 lines, -61 lines) Patch
M chrome/browser/android/preferences/pref_service_bridge.cc View 1 2 3 4 5 6 2 chunks +14 lines, -4 lines 0 comments Download
M chrome/browser/content_settings/host_content_settings_map_unittest.cc View 1 chunk +10 lines, -0 lines 0 comments Download
M chrome/browser/media/media_capture_devices_dispatcher.cc View 1 2 3 4 5 4 chunks +18 lines, -8 lines 0 comments Download
M chrome/browser/media/media_stream_device_permissions.h View 2 chunks +4 lines, -1 line 0 comments Download
M chrome/browser/media/media_stream_device_permissions.cc View 1 chunk +5 lines, -5 lines 0 comments Download
M chrome/browser/media/media_stream_devices_controller.cc View 1 2 3 4 2 chunks +12 lines, -9 lines 0 comments Download
M chrome/browser/ui/webui/options/content_settings_handler.h View 1 chunk +3 lines, -2 lines 0 comments Download
M chrome/browser/ui/webui/options/content_settings_handler.cc View 1 2 3 4 5 6 10 chunks +44 lines, -18 lines 0 comments Download
M chrome/browser/ui/webui/options/pepper_flash_content_settings_utils.h View 1 chunk +4 lines, -2 lines 0 comments Download
M chrome/browser/ui/webui/options/pepper_flash_content_settings_utils.cc View 2 chunks +8 lines, -6 lines 0 comments Download
M chrome/browser/ui/webui/options/pepper_flash_content_settings_utils_unittest.cc View 1 5 chunks +20 lines, -0 lines 0 comments Download
M components/content_settings/core/browser/content_settings_default_provider.h View 1 2 3 4 5 6 1 chunk +4 lines, -0 lines 0 comments Download
M components/content_settings/core/browser/content_settings_default_provider.cc View 1 2 3 4 5 6 3 chunks +25 lines, -0 lines 1 comment Download
M components/content_settings/core/browser/content_settings_policy_provider.cc View 1 2 2 chunks +4 lines, -3 lines 0 comments Download
M components/content_settings/core/browser/host_content_settings_map.cc View 1 2 3 4 5 6 3 chunks +10 lines, -3 lines 0 comments Download
M components/content_settings/core/common/pref_names.h View 1 2 3 4 5 6 1 chunk +2 lines, -0 lines 0 comments Download
M components/content_settings/core/common/pref_names.cc View 1 2 3 4 5 6 1 chunk +5 lines, -0 lines 0 comments Download

Messages

Total messages: 29 (9 generated)
msramek
Hi Markus, could you have a preliminary look at this CL, before I send it ...
5 years, 9 months ago (2015-03-05 16:19:38 UTC) #2
msramek
I somehow forgot that even if we stop syncing the media settings, we still need ...
5 years, 9 months ago (2015-03-06 10:36:55 UTC) #3
markusheintz_
https://codereview.chromium.org/965103004/diff/60001/chrome/browser/media/media_stream_device_permissions.cc File chrome/browser/media/media_stream_device_permissions.cc (right): https://codereview.chromium.org/965103004/diff/60001/chrome/browser/media/media_stream_device_permissions.cc#newcode38 chrome/browser/media/media_stream_device_permissions.cc:38: bool CheckAllowAllMediaStreamContentForOrigin(Profile* profile, Do we actually need this method ...
5 years, 9 months ago (2015-03-06 16:05:33 UTC) #4
msramek
https://codereview.chromium.org/965103004/diff/60001/chrome/browser/media/media_stream_device_permissions.cc File chrome/browser/media/media_stream_device_permissions.cc (right): https://codereview.chromium.org/965103004/diff/60001/chrome/browser/media/media_stream_device_permissions.cc#newcode38 chrome/browser/media/media_stream_device_permissions.cc:38: bool CheckAllowAllMediaStreamContentForOrigin(Profile* profile, On 2015/03/06 16:05:33, markusheintz_ wrote: > ...
5 years, 9 months ago (2015-03-06 17:47:33 UTC) #6
msramek
Hi Bernhard and Jochen, could you please also have a look at this? Thanks, Martin
5 years, 9 months ago (2015-03-06 17:54:59 UTC) #8
jochen (gone - plz use gerrit)
Markus already started to do the review, no?
5 years, 9 months ago (2015-03-09 15:40:52 UTC) #9
Bernhard Bauer
LGTM if Markus is happy. https://codereview.chromium.org/965103004/diff/100001/chrome/browser/media/media_capture_devices_dispatcher.cc File chrome/browser/media/media_capture_devices_dispatcher.cc (right): https://codereview.chromium.org/965103004/diff/100001/chrome/browser/media/media_capture_devices_dispatcher.cc#newcode406 chrome/browser/media/media_capture_devices_dispatcher.cc:406: profile, security_origin, contentSettingsType)) Nit: ...
5 years, 9 months ago (2015-03-09 15:45:46 UTC) #10
msramek
Jochen: Yes, and Markus also knows the whole context of this change. I added you ...
5 years, 9 months ago (2015-03-09 16:20:46 UTC) #11
jochen (gone - plz use gerrit)
it's preferable to ask somebody from c/b/media/OWNERS to review this
5 years, 9 months ago (2015-03-09 16:22:31 UTC) #12
msramek
Ah. Sorry, didn't notice that git cl owners offered you from a higher file.
5 years, 9 months ago (2015-03-09 16:31:33 UTC) #13
msramek
tommi@, could you PTAL at this as a media/ owner?
5 years, 9 months ago (2015-03-09 16:32:23 UTC) #15
markusheintz_
On 2015/03/09 16:32:23, msramek wrote: > tommi@, could you PTAL at this as a media/ ...
5 years, 9 months ago (2015-03-10 21:51:41 UTC) #16
tommi (sloooow) - chröme
lgtm
5 years, 9 months ago (2015-03-13 22:11:21 UTC) #18
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/965103004/120001
5 years, 9 months ago (2015-03-13 22:11:52 UTC) #20
commit-bot: I haz the power
Try jobs failed on following builders: ios_dbg_simulator_ninja on tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/ios_dbg_simulator_ninja/builds/5377) ios_rel_device_ninja on tryserver.chromium.mac (JOB_FAILED, ...
5 years, 9 months ago (2015-03-13 22:15:11 UTC) #22
msramek
https://codereview.chromium.org/965103004/diff/140001/components/content_settings/core/browser/content_settings_default_provider.cc File components/content_settings/core/browser/content_settings_default_provider.cc (right): https://codereview.chromium.org/965103004/diff/140001/components/content_settings/core/browser/content_settings_default_provider.cc#newcode522 components/content_settings/core/browser/content_settings_default_provider.cc:522: return; I rebased over 1004733003 and forgot to split ...
5 years, 9 months ago (2015-03-25 10:45:08 UTC) #23
Bernhard Bauer
Still LGTM
5 years, 9 months ago (2015-03-26 10:12:57 UTC) #24
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/965103004/140001
5 years, 9 months ago (2015-03-26 11:22:59 UTC) #27
commit-bot: I haz the power
Committed patchset #7 (id:140001)
5 years, 9 months ago (2015-03-26 12:14:30 UTC) #28
commit-bot: I haz the power
5 years, 9 months ago (2015-03-26 12:15:04 UTC) #29
Message was sent while issue was closed.
Patchset 7 (id:??) landed as
https://crrev.com/f90963538b234e2bad01b2f182ba8d98b179b1a5
Cr-Commit-Position: refs/heads/master@{#322364}

Powered by Google App Engine
This is Rietveld 408576698