base.xml视图:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="horizontal" >
<TextView
android:id="@+id/shown_path"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text=" Test" />
</LinearLayout>
我想创建两个新视图:
带有TextView的view1.xml和带有Button的view2.xml(两个都扩展于base.xml)
只能include,不能extend
自定义View吗,具体在一个xml中添加一个自定义view的方法
请见此贴
http://ask.csdn.net/questions/653#answer_1196