android 判断当前线程是否是主线程(UI线程)

来源:互联网 发布:信用卡 对比.知乎 编辑:程序博客网 时间:2024/05/17 08:25
if(Looper.myLooper() == Looper.getMainLooper()){    throw new RuntimeException("Can't do this from UI Thread.");}
阅读全文
0 0