Activating the window with a single click triggers a double-click event

We’re having some issues with double-clicks in our code. We’re binding a double-click in our player controller like so:

InputComponent->BindAction( "MouseDoubleClick", IE_DoubleClick, this, &APrototypeOCPlayerController::OnMouseDoubleClick );

However, we’re finding that OnMouseDoubleClick() gets called if you click on an inactive window to activate it.

It also gets called if you simply click and move the mouse and quickly click somewhere else.