Android中的Handler注意事项

一:Handler的作用 1.实现线程之间的通信:在非UI线程(子线程)中完成耗时操作,在UI线程(主线程)中更新UI操作。 2.通过postDelayed(Runnable r,millies m)方法在主线程中发送延迟消息。   二:Handler、Looper、Message、MessageQueue 1.在一个线程中只能创建一个Looper,一个Looper只能创建一个MessageQue
相关文章
相关标签/搜索