Chromium Code Reviews| Index: chrome/browser/android/tab_web_contents_delegate_android.cc |
| diff --git a/chrome/browser/android/tab_web_contents_delegate_android.cc b/chrome/browser/android/tab_web_contents_delegate_android.cc |
| index d27dd7bbfd39f78f1d91b7096e4e9fd5c653fb31..d6db0cb0f4f5d1efb6ecef82456ad7321d04a708 100644 |
| --- a/chrome/browser/android/tab_web_contents_delegate_android.cc |
| +++ b/chrome/browser/android/tab_web_contents_delegate_android.cc |
| @@ -469,8 +469,8 @@ jboolean IsCapturingAudio(JNIEnv* env, |
| content::WebContents* web_contents = |
| content::WebContents::FromJavaWebContents(java_web_contents); |
| scoped_refptr<MediaStreamCaptureIndicator> indicator = |
| - MediaCaptureDevicesDispatcher::GetInstance()-> |
| - GetMediaStreamCaptureIndicator(); |
| + MediaCaptureDevicesDispatcher::GetInstance() |
| + ->GetMediaStreamCaptureIndicator(); |
| return indicator->IsCapturingAudio(web_contents); |
| } |
| @@ -480,7 +480,29 @@ jboolean IsCapturingVideo(JNIEnv* env, |
| content::WebContents* web_contents = |
| content::WebContents::FromJavaWebContents(java_web_contents); |
| scoped_refptr<MediaStreamCaptureIndicator> indicator = |
| - MediaCaptureDevicesDispatcher::GetInstance()-> |
| - GetMediaStreamCaptureIndicator(); |
| + MediaCaptureDevicesDispatcher::GetInstance() |
| + ->GetMediaStreamCaptureIndicator(); |
| return indicator->IsCapturingVideo(web_contents); |
| } |
| + |
| +jboolean IsCapturingScreen(JNIEnv* env, |
| + const JavaParamRef<jclass>& clazz, |
| + const JavaParamRef<jobject>& java_web_contents) { |
| + content::WebContents* web_contents = |
| + content::WebContents::FromJavaWebContents(java_web_contents); |
| + scoped_refptr<MediaStreamCaptureIndicator> indicator = |
| + MediaCaptureDevicesDispatcher::GetInstance() |
| + ->GetMediaStreamCaptureIndicator(); |
| + return indicator->IsBeingMirrored(web_contents); |
| +} |
| + |
| +void NotifyStopped(JNIEnv* env, |
| + const JavaParamRef<jclass>& clazz, |
| + const JavaParamRef<jobject>& java_web_contents) { |
| + content::WebContents* web_contents = |
| + content::WebContents::FromJavaWebContents(java_web_contents); |
|
Ted C
2016/08/16 00:19:19
Any chance (in a follow up), you can pull these fo
braveyao
2016/08/16 23:05:49
Sure.
|
| + scoped_refptr<MediaStreamCaptureIndicator> indicator = |
| + MediaCaptureDevicesDispatcher::GetInstance() |
| + ->GetMediaStreamCaptureIndicator(); |
| + indicator->NotifyStopped(web_contents); |
| +} |