user5003554
user5003554

Reputation:

Dragging just after Gaining Window Focus

When a window gains focus via a mouse click (left, right, or middle button), and the button is held, Windows seems to automatically send a mouse released event to the newly focused window after about 0.5 seconds, regardless of whether or not the button is held for longer.

A very easy way to see this bug is to focus on another window (that is not your browser...), and then middle click on this window (it will gain focus), and scroll to the left or right without letting go. It will automatically stop scrolling for you after about 0.5 seconds, as you can tell by the cursor change.

It is annoying because oftentimes I don't realize that a window has lost focus, and I make mistakes by not dragging items as far as I intended, etc. Of course I can just click once to gain focus or alt-tab and then drag, but I'd rather not.

Is there a way such that:

  1. The mouse released event is sent immediately to the window, to stop the drag event from happening in the first place, or

  2. Windows doesn't automatically send a window a mouse released event?

Interestingly enough, Windows Explorer circumvents this issue by never gaining focus when you click on a draggable item. It seems that the folks over at Windows certainly know about it.

Upvotes: 1

Views: 354

Answers (1)

user5003554
user5003554

Reputation:

Well, I posted this same question on the Microsoft forums and the representative suggested I make a new user account. For whatever reason, this solved the problem.

EDIT: It had nothing to do with the user account, and everything to do with background processes stealing my window focus. In my case, it was the Logitech Gaming Software that came with my mouse, which stole the focus for a split second to determine what new window had been clicked on, and if necessary, change the mouse button profile. Pesky mouse.

Upvotes: 1

Related Questions