Skip to content

Commit

Permalink
[Screen Capture] Remove Android screen capture.
Browse files Browse the repository at this point in the history
There is no way to activate this feature now, or in the near future,
so it is unused code.


Bug: 487935,1454640
Change-Id: I86a8efd6364a74ef56a3a7e01d887eda43d0c8fb
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4616386
Commit-Queue: Mark Foltz <mfoltz@chromium.org>
Reviewed-by: Ted Choc <tedchoc@chromium.org>
Reviewed-by: Alexander Cooper <alcooper@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1158226}
  • Loading branch information
mfoltzgoogle authored and Chromium LUCI CQ committed Jun 15, 2023
1 parent 80f4822 commit ed6e961
Show file tree
Hide file tree
Showing 14 changed files with 8 additions and 1,440 deletions.
1 change: 0 additions & 1 deletion chrome/android/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -561,7 +561,6 @@ if (current_toolchain == default_toolchain) {
"//content/public/common:common_java",
"//device/gamepad:java",
"//media/base/android:media_java",
"//media/capture/content/android:screen_capture_java",
"//media/capture/video/android:capture_java",
"//media/midi:midi_java",
"//mojo/public/java:bindings_java",
Expand Down
3 changes: 0 additions & 3 deletions content/browser/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -3091,8 +3091,6 @@ source_set("browser") {
"media/android/media_player_renderer_web_contents_observer.h",
"media/android/media_resource_getter_impl.cc",
"media/android/media_resource_getter_impl.h",
"media/capture/screen_capture_device_android.cc",
"media/capture/screen_capture_device_android.h",
"media/key_system_support_android.cc",
"media/key_system_support_android.h",
"media/session/audio_focus_delegate_android.cc",
Expand Down Expand Up @@ -3154,7 +3152,6 @@ source_set("browser") {
"//device/gamepad/public/mojom",
"//gpu/command_buffer/service:gles2",
"//media",
"//media/capture/content/android",
"//media/capture/video/android",
"//third_party/blink/public/common:font_unique_name_table_proto",
"//third_party/blink/public/mojom:mojom_platform_blink",
Expand Down
81 changes: 0 additions & 81 deletions content/browser/media/capture/screen_capture_device_android.cc

This file was deleted.

47 changes: 0 additions & 47 deletions content/browser/media/capture/screen_capture_device_android.h

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -38,14 +38,12 @@
#if BUILDFLAG(ENABLE_SCREEN_CAPTURE)
#include "content/browser/media/capture/desktop_capture_device_uma_types.h"
#include "content/browser/media/capture/web_contents_video_capture_device.h"
#if BUILDFLAG(IS_ANDROID)
#include "content/browser/media/capture/screen_capture_device_android.h"
#else
#if !BUILDFLAG(IS_ANDROID)
#if defined(USE_AURA)
#include "content/browser/media/capture/aura_window_video_capture_device.h"
#endif
#endif // defined(USE_AURA)
#include "content/browser/media/capture/desktop_capture_device.h"
#endif // BUILDFLAG(IS_ANDROID)
#endif // !BUILDFLAG(IS_ANDROID)
#if BUILDFLAG(IS_MAC)
#include "content/browser/media/capture/desktop_capture_device_mac.h"
#include "content/browser/media/capture/screen_capture_kit_device_mac.h"
Expand Down Expand Up @@ -183,10 +181,6 @@ DesktopCaptureImplementation CreatePlatformDependentVideoCaptureDevice(
const DesktopMediaID& desktop_id,
std::unique_ptr<media::VideoCaptureDevice>& device_out) {
DCHECK_EQ(device_out.get(), nullptr);
#if BUILDFLAG(IS_ANDROID)
if ((device_out = std::make_unique<ScreenCaptureDeviceAndroid>()))
return DesktopCaptureImplementation::kScreenCaptureDeviceAndroid;
#else
#if BUILDFLAG(IS_MAC)
// Prefer using ScreenCaptureKit. After that try DesktopCaptureDeviceMac, and
// if both fail, use the generic DesktopCaptureDevice.
Expand All @@ -199,11 +193,12 @@ DesktopCaptureImplementation CreatePlatformDependentVideoCaptureDevice(
if ((device_out = CreateDesktopCaptureDeviceMac(desktop_id))) {
return kDesktopCaptureDeviceMac;
}
#endif
#endif // BUILDFLAG(IS_MAC)
#if !BUILDFLAG(IS_ANDROID)
if ((device_out = DesktopCaptureDevice::Create(desktop_id))) {
return kLegacyDesktopCaptureDevice;
}
#endif
#endif // !BUILDFLAG(IS_ANDROID)
return kNoImplementation;
}
#endif // BUILDFLAG(ENABLE_SCREEN_CAPTURE)
Expand Down
2 changes: 0 additions & 2 deletions content/public/android/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,6 @@ android_library("content_full_java") {
"//device/bluetooth:java",
"//device/gamepad:java",
"//media/base/android:media_java",
"//media/capture/content/android:screen_capture_java",
"//media/capture/video/android:capture_java",
"//media/midi:midi_java",
"//media/mojo/mojom:mojom_java",
Expand Down Expand Up @@ -517,7 +516,6 @@ android_library("content_javatests") {
"//content/shell/android:content_shell_java",
"//content/shell/android:content_shell_test_java",
"//media/base/android:media_java",
"//media/capture/content/android:screen_capture_java",
"//media/capture/video/android:capture_java",
"//media/mojo/mojom:mojom_java",
"//mojo/public/interfaces/bindings/tests:test_interfaces_java",
Expand Down
11 changes: 2 additions & 9 deletions media/capture/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@ component("capture_base") {
source_set("capture_device_specific") {
visibility = [
":capture_lib",
"//media/capture/content/android",
"//media/capture/video/android",
]
defines = [ "CAPTURE_IMPLEMENTATION" ]
Expand Down Expand Up @@ -162,14 +161,8 @@ component("capture_lib") {
]

if (is_android) {
public_deps += [
"content/android",
"video/android",
]
deps += [
"content/android:screen_capture_jni_headers",
"video/android:capture_jni_headers",
]
public_deps += [ "video/android" ]
deps += [ "video/android:capture_jni_headers" ]
}

if (is_mac) {
Expand Down
45 changes: 0 additions & 45 deletions media/capture/content/android/BUILD.gn

This file was deleted.

0 comments on commit ed6e961

Please sign in to comment.