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

Unified Diff: chrome/browser/resources/gaia_auth_host/saml_handler.js

Issue 1936903002: Allow SAML logins to use the webcam (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: add comment to JS re: C++ permission check Created 4 years, 8 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/resources/gaia_auth_host/saml_handler.js
diff --git a/chrome/browser/resources/gaia_auth_host/saml_handler.js b/chrome/browser/resources/gaia_auth_host/saml_handler.js
index 9b6ceb94c001034cff1594c0687406de6c1657c9..70486c7e06457057d120cda06897182f992da68a 100644
--- a/chrome/browser/resources/gaia_auth_host/saml_handler.js
+++ b/chrome/browser/resources/gaia_auth_host/saml_handler.js
@@ -147,6 +147,14 @@ cr.define('cr.login', function() {
'loadabort', this.onLoadAbort_.bind(this));
this.webview_.addEventListener(
'loadcommit', this.onLoadCommit_.bind(this));
+ this.webview_.addEventListener(
+ 'permissionrequest', function(e) {
+ if (e.permission === 'media') {
+ // The actual permission check happens in
+ // WebUILoginView::RequestMediaAccessPermission().
+ e.request.allow();
+ }
+ });
this.webview_.request.onBeforeRequest.addListener(
this.onInsecureRequest.bind(this),
« no previous file with comments | « chrome/browser/chromeos/settings/device_settings_provider.cc ('k') | chrome/test/data/policy/policy_test_cases.json » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698