X-Mouse for WIndows Vista & Win 7 Doesn't Raise Window

Wednesday, February 03rd, 2010
Last Updated:
Friday, August 02nd, 2019

Disclaimer: Accessing the information on this page means you agree to the Sites Terms of Service

Updated Method (2019/08/02)
Windows is really stupid about overwriting the registry value outlined in the older method, which handles the delay. That frustration led me to a new program that works really well to set the proper delays for Windows 10 called X-Mouse Controls by Joel Purra so you don't have to edit the registry every time. It's super simple, sets the values and done. I moved the exe to a nice long term storage area on my drive and pinned it to start for easy access.

As a bonus, check out XMBC which gives you a ton of control over mouse buttons "per program": https://www.highrez.co.uk/downloads/xmousebuttoncontrol.htm

Older Registry Method
I can't take any credit for any of the following steps but hopefully this will provide you with some x-mouse capability. (credits are below) I mainly am posting this because I hate reloading windows, then waste time digging through a bunch of sites until I find the "right" x-mouse feature I want: Focus follows mouse, but doesn't raise window... ever... I am purely blogging this for my own records.

I love the way True X-Mouse works, where you HAVE to click the title bar to grab focus of the window, but it is no longer being maintained. (Why hasn't someone in the OpenSource community created something similar?!??) On the flip side, I never could stand the auto copy function... shut that crap off!! I'll press ctrl+c & ctrl+v when I need to!

Anywho, off my soapbox, the following steps are for a "follow mouse, but don't raise window" style of x-mouse:

Step #1:

  • Open regedit, go to HKEY_CURRENT_USER\Control Panel\Desktop
    Edit UserPreferenceMask value to be 9F 3E 07 80 12 00 00 00
    [You should only have to modify the first pair]

Step #2:

  • Also in HKEY_CURRENT_USER\Control Panel\Desktop
    Add ActiveWndTrkTimeout as a new DWORD value, edit the new value and change 'Base' to Decimal and put in 150 as the 'Value Data'.

    You will notice that by default, Windows has ActiveWndTrackTimeout as the default value. Changing this value won't do you any good. Other posts suggest renaming it, I recommend creating a new DWORD value with ActiveWndTrkTimeout and having them both.

    [Adding and setting this value is time in milliseconds that it takes for the focus to change. To avoid some issues with the taskbar I recommended using a value like 150 or so (75 works best, especially with windows 7), but if you'd like to have a different delay before the window loses focus, set it to whatever you like.]

Step #3:

  • Log off and log back in (or restart)

Update: 2011/12/02 Ok, honestly, the steps above are nice "start-to-finish" instructions, but what a pain in the butt... I came back to this the other day (don't have to re-install windows near as much these days) and got frustrated at my own instructions! Not that they are bad, just painfully annoying which is why I am posting the next piece of code. Copy and paste it into a new text document, renaming the file to a .reg instead of .txt and run it. ActiveWndTrkTimeout is set to 75, if you want to change it to 150, set the dword to: "ActiveWndTrkTimeout"=dword:00000096

Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Control Panel\Desktop]

Log off and log back in (or restart)

All credits for the above 3 steps go to: sevenforums.com

Another x-mouse post can be found on: www.jan-olof-lindqvist.se

And... yet another at: http://technotes.hdgconsulting.com

Note: Make sure you take note of ActiveWndTrkTimeout as opposed to ActiveWndTrackTimeout...

Post Comment


The most important unix window manager feature for me is the no raise on click but raise on titlebar click.

X-Mouse still works on Windows 7 for doing that!

I've always preferred focus follows mouse but without auto-raise. I've found a side effect at least for me on Win7 x64 is that in this config these settings prevent applications that 'need' to auto-raise from coming to the top. (My for instance is Office Communicator -- I need it to auto-raise so I can see that someone has IMed me, but it doesn't).

I suspect that the application is merely taking focus and expecting the OS windowing auto-raise to put it on top, but with auto-raise disabled the app window stays underneath. (And the focus it takes gets switched back the instant I move my mouse cursor 1 pixel, so even the focus shift doesn't get my attention).

I don't know if there's a way around this but I thought I'd mention it to those that will find this thread.

Thanks for consolidating this information - I've found it scattered about here and there.

One thing, though, the actual registry entry is "ActiveWndTrackTimeout" (note 'Track', not 'Trk').

I would love to sit here and say: "Here's the difference between ActiveWndTrkTimeout vs. ActiveWndTrackTimeout.", but the honest truth is, I don't know! I can't find ANYTHING online that points to what exactly the difference is between the two. (Either that or I don't have the patience to look for it...) regardless, the only conclusive speculation I've come up with, is that "Track" was used in Vista where-as "Trk" is used in Windows 7. Anybody know of any clarification between the two from the good ol' M$ on this one?

Moving on, I do know for a fact that using "Track" does absolutely nothing when it comes to focusing a window. Set Trk to 0 and the focus is instant. Set Trk to 1000 and it will take one second for the window to focus. Keep in mind, this is not "raising the window". ActiveWndTrkTimeout is the setting for how long it takes for the window to actually grab focus after the mouse has been placed over it.

Thanks for posting this! Especially the difference between "Track" and "Trk". I had originally changed the "Track" entry and was still having task bar problems. After reading your page I made "Trk", set it to 100 decimal, and all is right with the world.

Thanks for your post.
I downloaded UltimateTweaker (TweakUI for Win 7), and was shocked when it didn't have XMouse like the xp version of tweakui
Your post was awesome, and it works better than my xp system!
It even responds to xmouse across the multi-pane browsing in firefox. I still need to check on namoroka, but I see no reason why it wouldn't.