在星期天,我实际上已在侧面加载了我的第一个应用程序!!! 简单,未完成的几个bug,但是可以。
我的打开屏幕(XML:“ event_list.xml”)是一个滚动列表-选择一个获取详细信息屏幕。 XML看起来像:(此代码仍然是片段。)
<?xml version="1.0" encoding="utf-8"?>
<fragment
xmlns:android="http://schemas.android.com/apk/res/android"
android:name="com.dummies.android.taskreminder.EventListFragment"
android:layout_width="fill_parent"
android:layout_height="fill_parent" />
该行(XML“ event_row.xml”)如下所示:
<TextView xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/text1"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:textSize="12dp"
android:padding="2dip" />
我想在滚动上方的顶部有几个按钮。 我能做的最好的事情是:
<?xml version="1.0" encoding="utf-8"?>
<fragment
xmlns:android="http://schemas.android.com/apk/res/android"
android:name="com.dummies.android.taskreminder.EventListFragment"
android:layout_width="fill_parent"
android:layout_height="fill_parent" >
<Button
android:id="@+id/btn_Add"
android:text="@string/add"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
</fragment>
但是按钮覆盖了第一个条目! 是什么将行与列表屏幕联系在一起,如何在滚动条上方获得两个按钮(行)?