Here is the scenario.
Skin: Windows 10
Blend On Moving: True
Extended Borders: True
Draw Non-Client Area: True
Using your demo when you move the window, things disappear. Also if you click on the title bar, same thing happens – things disappear. Now, if you deactivate the demo (i.e., click on another application in the task bar), then reactivate the demo (i.e., click on the demo in the task bar), things are there. Weird.
If Blend On Moving is false or Extended Borders is false or Draw Non-Client Area is false, no problem. It is only when all 3 of these are set to true does this occur.
Have not fully investigated this with other skins, but it definitely occurs when using Windows 10.
Also, I cannot duplicate this problem on my project.