Avoid application grabbing focus windows

Source: Internet
Author: User

Recently, I encountered a Focus attack on the current window, but I don't know which program grabbed the focus. I found this article:


Avoid application grabbing focus windows
 
[7/15/2004 10:19:52] [Serdar yegulalkaline] [techtarget]
 

Focus is used to describe applications that are currently enabled that can enter or select menus on the keyboard. When you switch to a window, the window is the focus window.

Some applications like to snatch the focus of the program. If you are eager to finish your work, but there is an application that keeps getting the focus from the window you need to work on, this is really annoying.

To solve this problem, you can edit the Registry to change the way the system processes the application focus. Run regedt32 and go to hkey_current_usercontrol paneldesktop. Edit (or add, if not exist) the following REG_DWORD key:

Foregroundlocktimeout: This key controls how long the application needs to wait for focus. If the key value is set to 0 (the default status), any program can use focus. Set the key value to 20000 or 200 seconds in decimal format. This will make the application wait for such a long time before taking up the focus.

Foregroundflashcount: When an application tries to occupy the focus, this key controls the duration of the icon flashing on the taskbar. By default, this key value is 3, set it to 0 in decimal format, so that the icon on the taskbar will flash continuously until it is clicked.

These modifications to the registry will take effect immediately.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.