How can I prevent other apps from stealing the focus?

前端 未结 3 376
失恋的感觉
失恋的感觉 2021-01-13 17:59

I have a fullscreen window with the Topmost property set to true. Whenever an application changes its WindowState property, my window is automatically minimized even though

3条回答
  •  死守一世寂寞
    2021-01-13 18:11

    If this is a kiosk application and you are the only program running on the computer then fine. Otherwise this is a really bad idea and that's why there is not a documented way of doing it. As Raymund Chen says this kind of question should be followed with the thought experiment "what if two programs did this?":

    http://blogs.msdn.com/oldnewthing/archive/2005/06/07/426294.aspx

提交回复
热议问题