Fixed auto-completion for paths contain spaces.
History UI is disabled when worker thread is running.