我有一个 C++ 进程,我希望该进程始终保持在前台,请指导我如何实现它?
最佳答案
这是不可能的,因为用户总是可以选择切换到另一个应用程序。这是设计使然。
良好的链接来自 Billy ONeal :
How do I create a window that is never covered by any other windows, not even other topmost windows?
Imagine if this were possible and imagine if two programs did this. Program A creates a window that is "super-topmost" and so does Program B. Now the user drags the two windows so that they overlap. What happens? You've created yourself a logical impossibility. One of those two windows must be above the other, contradicting the imaginary "super-topmost" feature.
关于c++进程始终在窗口操作系统的前台,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/2605099/