[quote=引用 5 楼 JT19940923 的回复:] LayoutInflater.from(this).inflate(resource, root, attachToRoot);
LayoutInflater.from(this).inflate(resource, root, attachToRoot);
直接setcontentview()就行了啊
LayoutInflater factorys = LayoutInflater.from(当前类.this); final View textEntryView = factorys.inflate(R.layout.你要获取的另一个XML, null); TextView y_type = (TextView) textEntryView.findViewById(R.id.控件ID);
80,352
社区成员
91,287
社区内容
加载中
试试用AI创作助手写篇文章吧