1Thread thread = new Thread() {
2 @Override
3 public void run() {
4 try { Thread.sleep(2000); }
5 catch (InterruptedException e) {}
6
7 runOnUiThread(new Runnable() {
8 @Override
9 public void run() {
10 textView.setText("OK");
11 }
12 });
13 }
14};
15thread.start();
16