[desktopCapture] stop capture when screen is locked.
To support the implementation of getDisplayMedia() API in chromium, it's
required to stop screensharing when screen is locked on desktop platforms.
This cl is to add an interface to observe the screen lock event into
content/browser and let VideoCaptureManager stop desktopCapture sessions
on screenlock event.
Note: It's done on Win/OSX/CrOS at present. Still tring to find a solid
way on Linux.
Bug: 887585
Change-Id: Ibe65d51c68e07f632a851f22d2ba6777a527204d
Reviewed-on: https://chromium-review.googlesource.com/1241160
Reviewed-by: Christian Fremerey <[email protected]>
Reviewed-by: Dan Erat <[email protected]>
Reviewed-by: Xiyuan Xia <[email protected]>
Reviewed-by: Avi Drissman <[email protected]>
Commit-Queue: Weiyong Yao <[email protected]>
Cr-Commit-Position: refs/heads/master@{#596273}
diff --git a/content/browser/BUILD.gn b/content/browser/BUILD.gn
index df70575..cfb622a 100644
--- a/content/browser/BUILD.gn
+++ b/content/browser/BUILD.gn
@@ -1558,6 +1558,15 @@
"scoped_active_url.h",
"screen_orientation/screen_orientation_provider.cc",
"screen_orientation/screen_orientation_provider.h",
+ "screenlock_monitor/screenlock_monitor.cc",
+ "screenlock_monitor/screenlock_monitor.h",
+ "screenlock_monitor/screenlock_monitor_device_source.cc",
+ "screenlock_monitor/screenlock_monitor_device_source.h",
+ "screenlock_monitor/screenlock_monitor_device_source_chromeos.cc",
+ "screenlock_monitor/screenlock_monitor_device_source_mac.mm",
+ "screenlock_monitor/screenlock_monitor_device_source_win.cc",
+ "screenlock_monitor/screenlock_monitor_source.cc",
+ "screenlock_monitor/screenlock_monitor_source.h",
"service_manager/common_browser_interfaces.cc",
"service_manager/common_browser_interfaces.h",
"service_manager/service_manager_context.cc",
@@ -1995,6 +2004,7 @@
"imm32.lib",
"oleacc.lib",
"portabledeviceguids.lib",
+ "wtsapi32.lib",
]
}
@@ -2370,6 +2380,7 @@
"//chromeos",
"//chromeos:power_manager_proto",
"//chromeos/assistant:buildflags",
+ "//components/session_manager/core",
]
}