更新时间:2023-11-19 12:34:40
假设你的主要观点是的的ViewGroup ,你已经拥有它的实例的code会是这个样子:
Assuming that your main view is a ViewGroup and you already have an instance of it the code would look something like this:
TextView textView = new TextView(getContext());
textView.setText("Processing...");
mainView.addView(textView);