| Index: media/capture/content/android/screen_capture_machine_android.cc
|
| diff --git a/media/capture/content/android/screen_capture_machine_android.cc b/media/capture/content/android/screen_capture_machine_android.cc
|
| index f3b2ee90970949b4efd9156143c4c424757d8f7d..69c8906c4f1c94b1c48aa5de1bcedcbaa22e72b9 100644
|
| --- a/media/capture/content/android/screen_capture_machine_android.cc
|
| +++ b/media/capture/content/android/screen_capture_machine_android.cc
|
| @@ -21,7 +21,8 @@ bool ScreenCaptureMachineAndroid::RegisterScreenCaptureMachine(JNIEnv* env) {
|
| return RegisterNativesImpl(env);
|
| }
|
|
|
| -ScreenCaptureMachineAndroid::ScreenCaptureMachineAndroid() {}
|
| +ScreenCaptureMachineAndroid::ScreenCaptureMachineAndroid()
|
| + : suspend_frame_capture_(false) {}
|
|
|
| ScreenCaptureMachineAndroid::~ScreenCaptureMachineAndroid() {}
|
|
|
| @@ -43,6 +44,9 @@ void ScreenCaptureMachineAndroid::OnRGBAFrameAvailable(JNIEnv* env,
|
| jint width,
|
| jint height,
|
| jlong timestamp) {
|
| + if (suspend_frame_capture_)
|
| + return;
|
| +
|
| const VideoCaptureOracle::Event event = VideoCaptureOracle::kCompositorUpdate;
|
| const uint64_t absolute_micro =
|
| timestamp / base::Time::kNanosecondsPerMicrosecond;
|
| @@ -118,6 +122,9 @@ void ScreenCaptureMachineAndroid::OnI420FrameAvailable(JNIEnv* env,
|
| jint width,
|
| jint height,
|
| jlong timestamp) {
|
| + if (suspend_frame_capture_)
|
| + return;
|
| +
|
| const VideoCaptureOracle::Event event = VideoCaptureOracle::kCompositorUpdate;
|
| const uint64_t absolute_micro =
|
| timestamp / base::Time::kNanosecondsPerMicrosecond;
|
|
|