Handy class for starting a new thread that has a looper. The looper can then be used to create handler classes. Note that start() must still be called.
通过以上三步我们就成功创建HandlerThread。通过handler发送消息,就会在子线程中执行。
如果想让HandlerThread退出,则需要调用handlerThread.quit();。