[[ Bug 12253 ]] Only attempt to update the cursor if the mouse window is...

... still valid.