tweak to how activateWindow() is called after dialog boxes