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

Side by Side Diff: chrome/browser/ui/webui/options/content_settings_handler.cc

Issue 2679723003: Settings: Make Enable DRM checkbox available on all platforms (Closed)
Patch Set: make ui available on all platforms 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 unified diff | Download patch
« no previous file with comments | « chrome/browser/resources/options/content_settings.html ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/ui/webui/options/content_settings_handler.h" 5 #include "chrome/browser/ui/webui/options/content_settings_handler.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <algorithm> 9 #include <algorithm>
10 #include <map> 10 #include <map>
(...skipping 401 matching lines...) Expand 10 before | Expand all | Expand 10 after
412 {"locationAllow", IDS_GEOLOCATION_ALLOW_RADIO}, 412 {"locationAllow", IDS_GEOLOCATION_ALLOW_RADIO},
413 {"locationAsk", IDS_GEOLOCATION_ASK_RADIO}, 413 {"locationAsk", IDS_GEOLOCATION_ASK_RADIO},
414 {"locationBlock", IDS_GEOLOCATION_BLOCK_RADIO}, 414 {"locationBlock", IDS_GEOLOCATION_BLOCK_RADIO},
415 {"setBy", IDS_GEOLOCATION_SET_BY_HOVER}, 415 {"setBy", IDS_GEOLOCATION_SET_BY_HOVER},
416 // Notifications filter. 416 // Notifications filter.
417 {"notificationsTabLabel", IDS_NOTIFICATIONS_TAB_LABEL}, 417 {"notificationsTabLabel", IDS_NOTIFICATIONS_TAB_LABEL},
418 {"notificationsHeader", IDS_NOTIFICATIONS_HEADER}, 418 {"notificationsHeader", IDS_NOTIFICATIONS_HEADER},
419 {"notificationsAllow", IDS_NOTIFICATIONS_ALLOW_RADIO}, 419 {"notificationsAllow", IDS_NOTIFICATIONS_ALLOW_RADIO},
420 {"notificationsAsk", IDS_NOTIFICATIONS_ASK_RADIO}, 420 {"notificationsAsk", IDS_NOTIFICATIONS_ASK_RADIO},
421 {"notificationsBlock", IDS_NOTIFICATIONS_BLOCK_RADIO}, 421 {"notificationsBlock", IDS_NOTIFICATIONS_BLOCK_RADIO},
422 #if defined(OS_CHROMEOS) || defined(OS_WIN)
423 // Protected Content filter 422 // Protected Content filter
424 {"protectedContentTabLabel", IDS_PROTECTED_CONTENT_TAB_LABEL}, 423 {"protectedContentTabLabel", IDS_PROTECTED_CONTENT_TAB_LABEL},
425 {"protectedContentInfo", IDS_PROTECTED_CONTENT_INFO}, 424 {"protectedContentInfo", IDS_PROTECTED_CONTENT_INFO},
426 {"protectedContentEnable", IDS_PROTECTED_CONTENT_ENABLE}, 425 {"protectedContentEnable", IDS_PROTECTED_CONTENT_ENABLE},
426 #if defined(OS_CHROMEOS)
427 {"protectedContentHeader", IDS_PROTECTED_CONTENT_HEADER}, 427 {"protectedContentHeader", IDS_PROTECTED_CONTENT_HEADER},
stevenjb 2017/02/07 21:43:52 This appears to be unused in the code, as does the
tommycli 2017/02/07 22:11:44 Hey, it's used here: https://cs.chromium.org/chrom
stevenjb 2017/02/07 22:15:05 Oh, ugh. That's the problem with generated ids. An
tommycli 2017/02/07 22:19:50 Sure. I made the string crossplatform as well.
428 #endif // defined(OS_CHROMEOS) || defined(OS_WIN) 428 #endif // defined(OS_CHROMEOS) || defined(OS_WIN)
429 // Microphone filter. 429 // Microphone filter.
430 {"mediaStreamMicTabLabel", IDS_MEDIA_STREAM_MIC_TAB_LABEL}, 430 {"mediaStreamMicTabLabel", IDS_MEDIA_STREAM_MIC_TAB_LABEL},
431 {"mediaStreamMicHeader", IDS_MEDIA_STREAM_MIC_HEADER}, 431 {"mediaStreamMicHeader", IDS_MEDIA_STREAM_MIC_HEADER},
432 {"mediaStreamMicAsk", IDS_MEDIA_STREAM_ASK_AUDIO_ONLY_RADIO}, 432 {"mediaStreamMicAsk", IDS_MEDIA_STREAM_ASK_AUDIO_ONLY_RADIO},
433 {"mediaStreamMicBlock", IDS_MEDIA_STREAM_BLOCK_AUDIO_ONLY_RADIO}, 433 {"mediaStreamMicBlock", IDS_MEDIA_STREAM_BLOCK_AUDIO_ONLY_RADIO},
434 // Camera filter. 434 // Camera filter.
435 {"mediaStreamCameraTabLabel", IDS_MEDIA_STREAM_CAMERA_TAB_LABEL}, 435 {"mediaStreamCameraTabLabel", IDS_MEDIA_STREAM_CAMERA_TAB_LABEL},
436 {"mediaStreamCameraHeader", IDS_MEDIA_STREAM_CAMERA_HEADER}, 436 {"mediaStreamCameraHeader", IDS_MEDIA_STREAM_CAMERA_HEADER},
437 {"mediaStreamCameraAsk", IDS_MEDIA_STREAM_ASK_VIDEO_ONLY_RADIO}, 437 {"mediaStreamCameraAsk", IDS_MEDIA_STREAM_ASK_VIDEO_ONLY_RADIO},
(...skipping 1053 matching lines...) Expand 10 before | Expand all | Expand 10 after
1491 1491
1492 // Exceptions apply only when the feature is enabled. 1492 // Exceptions apply only when the feature is enabled.
1493 PrefService* prefs = user_prefs::UserPrefs::Get(GetBrowserContext(web_ui())); 1493 PrefService* prefs = user_prefs::UserPrefs::Get(GetBrowserContext(web_ui()));
1494 bool enable_exceptions = prefs->GetBoolean(prefs::kEnableDRM); 1494 bool enable_exceptions = prefs->GetBoolean(prefs::kEnableDRM);
1495 web_ui()->CallJavascriptFunctionUnsafe( 1495 web_ui()->CallJavascriptFunctionUnsafe(
1496 "ContentSettings.enableProtectedContentExceptions", 1496 "ContentSettings.enableProtectedContentExceptions",
1497 base::FundamentalValue(enable_exceptions)); 1497 base::FundamentalValue(enable_exceptions));
1498 } 1498 }
1499 1499
1500 } // namespace options 1500 } // namespace options
OLDNEW
« no previous file with comments | « chrome/browser/resources/options/content_settings.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698