New issue
Advanced search Search tips

Issue 674959 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Mar 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 1
Type: Bug

Blocking:
issue 669257



Sign in to add a comment

Inconsistent UI for Android screensharing

Project Member Reported by niklase@chromium.org, Dec 16 2016

Issue description

Chrome Version: 57
OS: Android

Start screensharing from android for the first time. When the Android system pops up to allow Media Projection API the Chrome infobar looks like screen sharing already has started. See attached screenshot



 
is-sharing-will-start-sharing.png
105 KB View Download
Project Member

Comment 1 by bugdroid1@chromium.org, Feb 27 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/a18b95669ed38c0931818534ce17f131a006e476

commit a18b95669ed38c0931818534ce17f131a006e476
Author: braveyao <braveyao@chromium.org>
Date: Mon Feb 27 23:29:08 2017

getUserMeida: report device starting states

Chromium used to report device started immediately at requesting user media,
despite the device operation results. This causes several kinds of problems.
 - Notification of capture starting is shown before device starts.
 - gUM gets successful callback even if the device fails to start.
So we decide to make gUM return the real device starting states
(here we focus on the video capturing).
This is the first part of the complete modification.
The design doc is here, https://goo.gl/WTZkEl
The complete CL is here, https://codereview.chromium.org/2658643002

This CL implements the device-started-state reporting part. Each device will
report OnStarted event all the way back to VideoCaptureImpl when it's started
successfully(Error report has been done already).
This CL also includes all the necessary modifications due to the interface
change.
This CL will take no effect to getUserMedia behavior at present until another
CL which will handle the OnStarted event is landed.

BUG= 674959 ,  651910 

Review-Url: https://codereview.chromium.org/2673373003
Cr-Commit-Position: refs/heads/master@{#453388}

[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/content/browser/media/capture/desktop_capture_device.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/content/browser/media/capture/desktop_capture_device_aura_unittest.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/content/browser/media/capture/desktop_capture_device_unittest.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/content/browser/media/capture/screen_capture_device_android_unittest.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/content/browser/media/capture/web_contents_video_capture_device_unittest.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/content/browser/renderer_host/media/video_capture_controller.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/content/browser/renderer_host/media/video_capture_controller.h
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/content/browser/renderer_host/media/video_capture_controller_event_handler.h
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/content/browser/renderer_host/media/video_capture_controller_unittest.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/content/browser/renderer_host/media/video_capture_host.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/content/browser/renderer_host/media/video_capture_host.h
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/content/browser/renderer_host/media/video_capture_manager_unittest.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/content/browser/renderer_host/media/video_capture_unittest.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/content/browser/renderer_host/media/video_frame_receiver_on_io_thread.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/content/browser/renderer_host/media/video_frame_receiver_on_io_thread.h
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/content/renderer/media/video_capture_impl.h
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/content/android/java/src/org/chromium/media/ScreenCapture.java
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/content/android/screen_capture_machine_android.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/content/screen_capture_device_core.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/content/thread_safe_capture_oracle.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/content/thread_safe_capture_oracle.h
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/video/android/java/src/org/chromium/media/VideoCapture.java
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/video/android/java/src/org/chromium/media/VideoCaptureCamera.java
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/video/android/java/src/org/chromium/media/VideoCaptureCamera2.java
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/video/android/video_capture_device_android.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/video/android/video_capture_device_android.h
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/video/fake_video_capture_device.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/video/fake_video_capture_device_unittest.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/video/file_video_capture_device.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/video/linux/v4l2_capture_delegate.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/video/linux/v4l2_capture_delegate_unittest.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/video/mac/video_capture_device_decklink_mac.h
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/video/mac/video_capture_device_decklink_mac.mm
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/video/mac/video_capture_device_mac.mm
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/video/video_capture_device.h
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/video/video_capture_device_client.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/video/video_capture_device_client.h
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/video/video_capture_device_client_unittest.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/video/video_capture_device_unittest.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/video/video_frame_receiver.h
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/video/win/video_capture_device_mf_win.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/media/capture/video/win/video_capture_device_win.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/services/video_capture/public/interfaces/receiver.mojom
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/services/video_capture/receiver_mojo_to_media_adapter.cc
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/services/video_capture/receiver_mojo_to_media_adapter.h
[modify] https://crrev.com/a18b95669ed38c0931818534ce17f131a006e476/services/video_capture/test/mock_receiver.h

Project Member

Comment 2 by bugdroid1@chromium.org, Mar 14 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/1941549656951c9dbd61984b3fd7f8414a3536a6

commit 1941549656951c9dbd61984b3fd7f8414a3536a6
Author: braveyao <braveyao@chromium.org>
Date: Tue Mar 14 23:50:07 2017

getUserMedia: handle the device starting status report.

Chromium used to report device started immediately at requesting user media,
despite the device operation results. This causes several kinds of problems.
 - Notification of capture starting is shown before device starts.
 - gUM gets successful callback even if the device fails to start.
So we decide to make gUM return the real device starting states
(here we focus on the video capturing).
This is the second part of the complete modification.
The design doc is here, https://goo.gl/WTZkEl
The previous CL is here, https://codereview.chromium.org/2673373003/

This CL does severals things when a OnStarted event from device arrives
- VideoCaptureImpl calls the state_update_cb, informing the track is completed.
- When all tracks are completed, return gUM with successful callback and send
  a message to browser process to show the notification in UI.
- Other related changes due to the asynchronous OnStarted event.
- Remove some test cases of desktop_capture, which tests nothing before
(due to the always-successful gUM callback) and fails after this cl
(gUM will get errorcallback if stream can't be started successfully).

BUG= 674959 ,  651910 

Review-Url: https://codereview.chromium.org/2721113002
Cr-Commit-Position: refs/heads/master@{#456895}

[modify] https://crrev.com/1941549656951c9dbd61984b3fd7f8414a3536a6/chrome/browser/extensions/api/desktop_capture/desktop_capture_apitest.cc
[modify] https://crrev.com/1941549656951c9dbd61984b3fd7f8414a3536a6/chrome/test/data/extensions/api_test/desktop_capture/test.js
[modify] https://crrev.com/1941549656951c9dbd61984b3fd7f8414a3536a6/content/browser/media/capture/web_contents_video_capture_device_unittest.cc
[modify] https://crrev.com/1941549656951c9dbd61984b3fd7f8414a3536a6/content/browser/renderer_host/media/media_stream_dispatcher_host.cc
[modify] https://crrev.com/1941549656951c9dbd61984b3fd7f8414a3536a6/content/browser/renderer_host/media/media_stream_dispatcher_host.h
[modify] https://crrev.com/1941549656951c9dbd61984b3fd7f8414a3536a6/content/browser/renderer_host/media/media_stream_dispatcher_host_unittest.cc
[modify] https://crrev.com/1941549656951c9dbd61984b3fd7f8414a3536a6/content/browser/renderer_host/media/media_stream_manager.cc
[modify] https://crrev.com/1941549656951c9dbd61984b3fd7f8414a3536a6/content/browser/renderer_host/media/media_stream_manager.h
[modify] https://crrev.com/1941549656951c9dbd61984b3fd7f8414a3536a6/content/browser/renderer_host/media/video_capture_controller.cc
[modify] https://crrev.com/1941549656951c9dbd61984b3fd7f8414a3536a6/content/browser/renderer_host/media/video_capture_controller.h
[modify] https://crrev.com/1941549656951c9dbd61984b3fd7f8414a3536a6/content/browser/renderer_host/media/video_capture_controller_unittest.cc
[modify] https://crrev.com/1941549656951c9dbd61984b3fd7f8414a3536a6/content/browser/renderer_host/media/video_capture_manager_unittest.cc
[modify] https://crrev.com/1941549656951c9dbd61984b3fd7f8414a3536a6/content/common/media/media_stream_messages.h
[modify] https://crrev.com/1941549656951c9dbd61984b3fd7f8414a3536a6/content/common/media/video_capture.h
[modify] https://crrev.com/1941549656951c9dbd61984b3fd7f8414a3536a6/content/renderer/media/media_stream_dispatcher.cc
[modify] https://crrev.com/1941549656951c9dbd61984b3fd7f8414a3536a6/content/renderer/media/media_stream_dispatcher.h
[modify] https://crrev.com/1941549656951c9dbd61984b3fd7f8414a3536a6/content/renderer/media/media_stream_video_capturer_source.cc
[modify] https://crrev.com/1941549656951c9dbd61984b3fd7f8414a3536a6/content/renderer/media/user_media_client_impl.cc
[modify] https://crrev.com/1941549656951c9dbd61984b3fd7f8414a3536a6/content/renderer/media/user_media_client_impl.h
[modify] https://crrev.com/1941549656951c9dbd61984b3fd7f8414a3536a6/content/renderer/media/video_capture_impl.cc
[modify] https://crrev.com/1941549656951c9dbd61984b3fd7f8414a3536a6/content/renderer/media/video_capture_impl_manager_unittest.cc
[modify] https://crrev.com/1941549656951c9dbd61984b3fd7f8414a3536a6/content/renderer/media/video_capture_impl_unittest.cc
[modify] https://crrev.com/1941549656951c9dbd61984b3fd7f8414a3536a6/media/capture/video/fake_video_capture_device_unittest.cc

Labels: M-59
Status: Fixed (was: Assigned)

Sign in to add a comment