GraphicsCaptureSession for specific window can't capture context menus
Describe the bug
GraphicsCaptureSession currently doesn't seem able to capture context menus when selecting a specific window (using GraphicsCapturePicker and not interop if this makes a difference) as capture source.
Now, it's clear that this happens because context menus are windows on their own, but it would be cool if this issue could be addressed somehow (to say, by capturing also windows in the current window subtree).
Steps to reproduce the bug
Steps to reproduce the behavior:
- Pick a window using
GraphicsCapturePicker. - Record the opening of a context menu.
- Notice that the context menu wasn't captured.
Expected behavior
Context menus are captured by GraphicsCaptureSession.
Version Info
| Windows 10 version | Saw the problem? |
|---|---|
| Insider Build (xxxxx) | |
| May 2020 Update (19041) | Yes |
| November 2019 Update (18363) | |
| May 2019 Update (18362) | |
| October 2018 Update (17763) |
Additional context
It also doesn't capture tooltips in both video and image capture. It's also noticeable in many second-party/third-party screenshot utilities like OneDrive's print screen feature but it works fine in the built-in screenshot tool (Windows + Print screen).
I develop a screen recording app and a lot of users are complaining about this behavior, since they expect those menus to be recorded and they usually blame the app itself.
to say, by capturing also windows in the current window subtree
Capturing child windows does not resolve the issue here because UWP flyouts/tooltips and Win32 context menu/tooltips are not child windows, they are their own top-level windows.
Thanks @sylveon, I was pretty sure about UWP ones, but not really about Win32!
There's no documentation and the required windows version is still a preview, but the new https://learn.microsoft.com/en-us/uwp/api/windows.graphics.capture.graphicscapturesession.includesecondarywindows?view=winrt-26100 may help here.
There's no documentation and the required windows version is still a preview, but the new https://learn.microsoft.com/en-us/uwp/api/windows.graphics.capture.graphicscapturesession.includesecondarywindows?view=winrt-26100 may help here.
that will make tooltips and popup windows appear, but the context menus still wont
/external
Hi @@FrayxRulez, thank you for your contribution! This issue appears to be external to the WindowsAppSDK. To help route it appropriately, please submit your feedback via the Feedback Hub by pressing [Windows] + [F], and include detailed information and diagnostics. We appreciate your help in improving the platform!