From 01db4c8321aee76ce432561ef492fecb833a6363 Mon Sep 17 00:00:00 2001 From: jrummell Date: Tue, 21 Apr 2015 15:28:34 -0700 Subject: Change enums in eme_constants.h to enum classes BUG=473830 TEST=media_unittests pass Review URL: https://codereview.chromium.org/1093253002 Cr-Commit-Position: refs/heads/master@{#326147} --- components/cdm/renderer/android_key_systems.cc | 45 ++++++++++++++------------ 1 file changed, 24 insertions(+), 21 deletions(-) (limited to 'components/cdm') diff --git a/components/cdm/renderer/android_key_systems.cc b/components/cdm/renderer/android_key_systems.cc index 8076a2a..28b45eb 100644 --- a/components/cdm/renderer/android_key_systems.cc +++ b/components/cdm/renderer/android_key_systems.cc @@ -62,18 +62,18 @@ void AddAndroidWidevine(std::vector* concrete_key_systems, // We are using MediaDrm API on Android and we cannot guarantee that API // doesn't use persistent storage on the device. Therefore always set - // persistent state to EME_FEATURE_ALWAYS_ENABLED to err on the safe side. + // persistent state to EmeFeatureSupport::ALWAYS_ENABLED to err on the + // safe side. if (codecs != media::EME_CODEC_NONE) { AddWidevineWithCodecs( - WIDEVINE, - codecs, - max_audio_robustness, - max_video_robustness, - media::EME_SESSION_TYPE_NOT_SUPPORTED, // persistent-license. - media::EME_SESSION_TYPE_NOT_SUPPORTED, // persistent-release-message. - media::EME_FEATURE_ALWAYS_ENABLED, // Persistent state. - media::EME_FEATURE_ALWAYS_ENABLED, // Distinctive identifier. + WIDEVINE, codecs, max_audio_robustness, max_video_robustness, + media::EmeSessionTypeSupport::NOT_SUPPORTED, // persistent-license. + media::EmeSessionTypeSupport:: + NOT_SUPPORTED, // persistent-release-message. + media::EmeFeatureSupport::ALWAYS_ENABLED, // Persistent state. + media::EmeFeatureSupport::ALWAYS_ENABLED, // Distinctive + // identifier. concrete_key_systems); } @@ -84,14 +84,15 @@ void AddAndroidWidevine(std::vector* concrete_key_systems, // TODO(ddorwin): Remove with unprefixed. http://crbug.com/249976 if (response.non_compositing_codecs != media::EME_CODEC_NONE) { AddWidevineWithCodecs( - WIDEVINE_HR_NON_COMPOSITING, - response.non_compositing_codecs, - EmeRobustness::HW_SECURE_CRYPTO, // Max audio robustness. - EmeRobustness::HW_SECURE_ALL, // Max video robustness. - media::EME_SESSION_TYPE_NOT_SUPPORTED, // persistent-license. - media::EME_SESSION_TYPE_NOT_SUPPORTED, // persistent-release-message. - media::EME_FEATURE_ALWAYS_ENABLED, // Persistent state. - media::EME_FEATURE_ALWAYS_ENABLED, // Distinctive identifier. + WIDEVINE_HR_NON_COMPOSITING, response.non_compositing_codecs, + EmeRobustness::HW_SECURE_CRYPTO, // Max audio robustness. + EmeRobustness::HW_SECURE_ALL, // Max video robustness. + media::EmeSessionTypeSupport::NOT_SUPPORTED, // persistent-license. + media::EmeSessionTypeSupport:: + NOT_SUPPORTED, // persistent-release-message. + media::EmeFeatureSupport::ALWAYS_ENABLED, // Persistent state. + media::EmeFeatureSupport::ALWAYS_ENABLED, // Distinctive + // identifier. concrete_key_systems); } } @@ -121,11 +122,13 @@ void AddAndroidPlatformKeySystems( info.max_audio_robustness = EmeRobustness::EMPTY; info.max_video_robustness = EmeRobustness::EMPTY; // Assume the worst case (from a user point of view). - info.persistent_license_support = media::EME_SESSION_TYPE_NOT_SUPPORTED; + info.persistent_license_support = + media::EmeSessionTypeSupport::NOT_SUPPORTED; info.persistent_release_message_support = - media::EME_SESSION_TYPE_NOT_SUPPORTED; - info.persistent_state_support = media::EME_FEATURE_ALWAYS_ENABLED; - info.distinctive_identifier_support = media::EME_FEATURE_ALWAYS_ENABLED; + media::EmeSessionTypeSupport::NOT_SUPPORTED; + info.persistent_state_support = media::EmeFeatureSupport::ALWAYS_ENABLED; + info.distinctive_identifier_support = + media::EmeFeatureSupport::ALWAYS_ENABLED; concrete_key_systems->push_back(info); } } -- cgit v1.1