Tell the thread to exit. This is usually called from the UI thread. The
call is synchronous and will only return once the thread has terminated
itself.
mQuit = true;
Log.d("ddms", "Waiting for BackgroundThread to quit");
try {
this.join();
} catch (InterruptedException ie) {
ie.printStackTrace();
}