Added threading to improve UI performance and loading times, added loading message