System Info: Windows 10 Pro x64 10.0.19041 running on Lenovo L540
Visusal Studio 2019 V16.8.2
Windows SDK: 10.0.19041.0
Platform Toolset: VS 2019 (v142)
Microsoft.Windows.CppWinRT nuget package v2.0.201217.4
Laptop has 2 external displays plugged in.
Repro Steps:
- Get and build Win32CaptureSample-master
- Start the app and press "Open Picker" to show the GraphicsCapturePicker popup
- Unplug one of the external displays
- Press cancel on the GraphicsCapturePicker popup
At this point Windows Explorer is in a bad state. Clicking Windows Icon in the task bar does not bring up the start menu. Right clicking any of the app icons in the task bar does not bring up the context menu. Clicking the "Open Picker" button on the Win32CaptureSample app brings up a blank window instead of the GraphicsCapturePicker. It was necessary to restart Windows Explorer from the Task Manager in order to recover.
Running the same steps as above with only 1 external display will result in Win32CaptureSample throwing an exception when the display is unplugged.