No error “Only the original thread that created a view hierarchy can touch its views” when the view is updated without delay
问题 I was faced with an interesting problem. If you write the following code in the onCreate/onStart/onResume method of activity: final Button myButton = (Button)findViewById(R.id.myButton); final TextView myTextView = (TextView)findViewById(R.id.myTextView); final Thread thread = new Thread(new Runnable() { @Override public void run() { myTextView.setText("Hello text"); } }); myButton.setOnClickListener(new OnClickListener() { @Override public void onClick(View v) { thread.start(); } }); or: