diff options
author | Kenny Root <kroot@google.com> | 2011-01-10 11:38:08 -0800 |
---|---|---|
committer | Kenny Root <kroot@google.com> | 2011-01-10 13:20:54 -0800 |
commit | 9fb403beef24339913ce0e0d545a83fd102caf5b (patch) | |
tree | e6a9577741abab68644dae439f5386b552f9fa30 /res/layout/install_confirm.xml | |
parent | 2244205c4fdda49f0ff6f2e16f4cbb6678e20c48 (diff) | |
download | android_packages_apps_PackageInstaller-9fb403beef24339913ce0e0d545a83fd102caf5b.tar.gz android_packages_apps_PackageInstaller-9fb403beef24339913ce0e0d545a83fd102caf5b.tar.bz2 android_packages_apps_PackageInstaller-9fb403beef24339913ce0e0d545a83fd102caf5b.zip |
Change theme to DialogWhenLarge
Fix some layouts to correctly display as dialogs when using a large
screen device. Still needs the WeightedLinearLayout trick.
Bug: 3298362
Change-Id: I76ad192ca8c27a0d9f4ce106dc4e1e922c01c02b
Diffstat (limited to 'res/layout/install_confirm.xml')
-rwxr-xr-x | res/layout/install_confirm.xml | 136 |
1 files changed, 85 insertions, 51 deletions
diff --git a/res/layout/install_confirm.xml b/res/layout/install_confirm.xml index 268a744e..026116c1 100755 --- a/res/layout/install_confirm.xml +++ b/res/layout/install_confirm.xml @@ -22,73 +22,107 @@ --> <LinearLayout - xmlns:android="http://schemas.android.com/apk/res/android" - android:orientation="vertical" - android:layout_weight="1" - android:layout_width="match_parent" - android:layout_height="wrap_content"> + xmlns:android="http://schemas.android.com/apk/res/android" + style="@style/padded" + android:orientation="vertical" + android:layout_weight="1" + android:layout_width="match_parent" + android:layout_height="wrap_content"> <TextView - android:id="@+id/install_confirm_question" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:text="@string/install_confirm_question" - android:textAppearance="?android:attr/textAppearanceMedium" - android:paddingTop="20dip" - android:paddingLeft="20dip" - android:paddingBottom="20dip"/> + android:id="@+id/install_confirm_question" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:text="@string/install_confirm_question" + android:textAppearance="?android:attr/textAppearanceMedium" + android:paddingTop="16dip" + android:paddingLeft="16dip" + android:paddingBottom="16dip"/> <ScrollView - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:fillViewport="true" - android:layout_weight="1"> + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:fillViewport="true" + android:layout_weight="1"> <!-- Security settings description. --> <LinearLayout - android:id="@+id/permissions_section" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:layout_marginRight = "2dip" - android:orientation="vertical"> - <TextView - android:id="@+id/security_settings_desc" - android:text="@string/security_settings_desc" - android:layout_width="wrap_content" + android:id="@+id/permissions_section" + android:layout_width="match_parent" android:layout_height="wrap_content" - android:textAppearance="?android:attr/textAppearanceMedium" - android:paddingTop="20dip" - android:paddingLeft="20dip" - android:paddingBottom="20dip"/> + android:layout_marginRight = "2dip" + android:orientation="vertical"> + <TextView + android:id="@+id/security_settings_desc" + android:text="@string/security_settings_desc" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:textAppearance="?android:attr/textAppearanceMedium" + android:paddingTop="20dip" + android:paddingLeft="20dip" + android:paddingBottom="20dip"/> <LinearLayout - android:id="@+id/security_settings_list" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:layout_weight="1.0" - android:orientation="vertical"/> + android:id="@+id/security_settings_list" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:layout_weight="1.0" + android:orientation="vertical"/> </LinearLayout> </ScrollView> <!-- OK confirm and cancel buttons. --> <LinearLayout - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:orientation="horizontal" - style="@android:style/ButtonBar" - > - <Button android:id="@+id/ok_button" - android:layout_width="0dip" + android:layout_width="match_parent" android:layout_height="wrap_content" - android:layout_weight="1" - android:text="@string/install" - /> + android:minHeight="54dip" + android:orientation="vertical" + android:divider="?android:attr/dividerHorizontal" + android:showDividers="beginning" + android:dividerPadding="16dip" + android:paddingTop="16dip"> - <Button android:id="@+id/cancel_button" - android:layout_width="0dip" - android:layout_height="wrap_content" - android:layout_weight="1" - android:text="@string/cancel" - /> + <LinearLayout + style="?android:attr/buttonBarStyle" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:orientation="horizontal" + android:paddingLeft="2dip" + android:paddingRight="2dip" + android:measureWithLargestChild="true"> + + <LinearLayout android:id="@+id/leftSpacer" + android:layout_weight="0.25" + android:layout_width="0dip" + android:layout_height="wrap_content" + android:orientation="horizontal" + android:visibility="gone" /> + + <Button android:id="@+id/ok_button" + android:layout_width="0dip" + android:layout_height="wrap_content" + android:layout_gravity="left" + android:layout_weight="1" + android:text="@string/install" + android:maxLines="2" + style="?android:attr/buttonBarButtonStyle" /> + + <Button android:id="@+id/cancel_button" + android:layout_width="0dip" + android:layout_height="wrap_content" + android:layout_gravity="right" + android:layout_weight="1" + android:text="@string/cancel" + android:maxLines="2" + style="?android:attr/buttonBarButtonStyle" /> + + <LinearLayout android:id="@+id/rightSpacer" + android:layout_width="0dip" + android:layout_weight="0.25" + android:layout_height="wrap_content" + android:orientation="horizontal" + android:visibility="gone" /> + + </LinearLayout> </LinearLayout> </LinearLayout> |