Activities featuring buttons in a button bar on the bottom of the screen have
incorrectly sized buttons.
This happens at least in the Help activity, and in the Tracks list.
The standard way in Android when there are two buttons is to have them cover
the entire button bar, split in the middle.
A good example of this is the Edit Contact activity in standard Android
Contacts application.
The layout for that button bar looks like this:
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"
style="@android:style/ButtonBar"
>
<Button android:id="@+id/btn_done"
android:layout_width="0dip"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@string/menu_done"
/>
<Button android:id="@+id/btn_discard"
android:layout_width="0dip"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@string/menu_doNotSave"
/>
</LinearLayout>
Source:
http://android.git.kernel.org/?p=platform/packages/apps/Contacts.git;a=blob;f=re
s/layout/act_edit.xml
Original issue reported on code.google.com by cach...@gmail.com on 20 Jan 2011 at 10:03
Original issue reported on code.google.com by
cach...@gmail.com
on 20 Jan 2011 at 10:03