Fix interaction with wx ProgressDialog.