WindowsAppSDK icon indicating copy to clipboard operation
WindowsAppSDK copied to clipboard

GraphicsCaptureSession for specific window can't capture context menus

Open FrayxRulez opened this issue 4 years ago • 5 comments

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:

  1. Pick a window using GraphicsCapturePicker.
  2. Record the opening of a context menu.
  3. 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

FrayxRulez avatar May 18 '21 09:05 FrayxRulez

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).

jaigak avatar May 19 '21 05:05 jaigak

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.

MarcAnt01 avatar May 19 '21 15:05 MarcAnt01

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.

sylveon avatar May 19 '21 15:05 sylveon

Thanks @sylveon, I was pretty sure about UWP ones, but not really about Win32!

FrayxRulez avatar May 19 '21 18:05 FrayxRulez

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.

fredemmott avatar Sep 21 '24 12:09 fredemmott

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

barryjamesclement avatar Mar 28 '25 16:03 barryjamesclement

/external

ssparach avatar Nov 05 '25 19:11 ssparach

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!