handler.postDelayed(new Runnable(){public void run(){handler.postDelayed(this,1000);}}, 1000);
上面代码有什么用?
每隔1s中 执行run里面的方法一次,无限循环执行