Added threading to avoid interface locking

The plugin was locking up the editor interface
while doing the API call. Using threading now
it does the call in the background.