This also sort of broke using ESC to close, because that's what
users try next, but after clicking on the desktop the dialog no
longer has focus.
I examined the revision that introduced this change (e635931e4)
but saw no good reason for it. It was likely accidental.