the background thread runs indefinitely and perform some tasks so I cannot really disable controls and wait for the thread to complete