Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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 #ifndef MEDIA_BASE_ANDROID_MEDIA_DRM_BRIDGE_H_ | 5 #ifndef MEDIA_BASE_ANDROID_MEDIA_DRM_BRIDGE_H_ |
| 6 #define MEDIA_BASE_ANDROID_MEDIA_DRM_BRIDGE_H_ | 6 #define MEDIA_BASE_ANDROID_MEDIA_DRM_BRIDGE_H_ |
| 7 | 7 |
| 8 #include <jni.h> | 8 #include <jni.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 212 void OnSessionClosed( | 212 void OnSessionClosed( |
| 213 JNIEnv* env, | 213 JNIEnv* env, |
| 214 const base::android::JavaParamRef<jobject>& j_media_drm, | 214 const base::android::JavaParamRef<jobject>& j_media_drm, |
| 215 const base::android::JavaParamRef<jbyteArray>& j_session_id); | 215 const base::android::JavaParamRef<jbyteArray>& j_session_id); |
| 216 | 216 |
| 217 void OnSessionKeysChange( | 217 void OnSessionKeysChange( |
| 218 JNIEnv* env, | 218 JNIEnv* env, |
| 219 const base::android::JavaParamRef<jobject>& j_media_drm, | 219 const base::android::JavaParamRef<jobject>& j_media_drm, |
| 220 const base::android::JavaParamRef<jbyteArray>& j_session_id, | 220 const base::android::JavaParamRef<jbyteArray>& j_session_id, |
| 221 const base::android::JavaParamRef<jobjectArray>& j_keys_info, | 221 const base::android::JavaParamRef<jobjectArray>& j_keys_info, |
| 222 bool has_additional_usable_key); | 222 bool has_additional_usable_key, |
| 223 bool is_key_release); | |
|
xhwang
2017/04/05 18:31:50
Add a comment why "key_release" is special.
yucliu1
2017/04/05 23:04:07
Done.
| |
| 223 | 224 |
| 224 // |expiry_time_ms| is the new expiration time for the keys in the session. | 225 // |expiry_time_ms| is the new expiration time for the keys in the session. |
| 225 // The time is in milliseconds, relative to the Unix epoch. A time of 0 | 226 // The time is in milliseconds, relative to the Unix epoch. A time of 0 |
| 226 // indicates that the keys never expire. | 227 // indicates that the keys never expire. |
| 227 void OnSessionExpirationUpdate( | 228 void OnSessionExpirationUpdate( |
| 228 JNIEnv* env, | 229 JNIEnv* env, |
| 229 const base::android::JavaParamRef<jobject>& j_media_drm, | 230 const base::android::JavaParamRef<jobject>& j_media_drm, |
| 230 const base::android::JavaParamRef<jbyteArray>& j_session_id, | 231 const base::android::JavaParamRef<jbyteArray>& j_session_id, |
| 231 jlong expiry_time_ms); | 232 jlong expiry_time_ms); |
| 232 | 233 |
| (...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 334 | 335 |
| 335 // NOTE: Weak pointers must be invalidated before all other member variables. | 336 // NOTE: Weak pointers must be invalidated before all other member variables. |
| 336 base::WeakPtrFactory<MediaDrmBridge> weak_factory_; | 337 base::WeakPtrFactory<MediaDrmBridge> weak_factory_; |
| 337 | 338 |
| 338 DISALLOW_COPY_AND_ASSIGN(MediaDrmBridge); | 339 DISALLOW_COPY_AND_ASSIGN(MediaDrmBridge); |
| 339 }; | 340 }; |
| 340 | 341 |
| 341 } // namespace media | 342 } // namespace media |
| 342 | 343 |
| 343 #endif // MEDIA_BASE_ANDROID_MEDIA_DRM_BRIDGE_H_ | 344 #endif // MEDIA_BASE_ANDROID_MEDIA_DRM_BRIDGE_H_ |
| OLD | NEW |