diff options
author | Dianne Hackborn <hackbod@google.com> | 2012-10-11 17:54:22 -0700 |
---|---|---|
committer | Android Git Automerger <android-git-automerger@android.com> | 2012-10-11 17:54:22 -0700 |
commit | 47f7d0bed40f1928db116f532b40517ee9e3b317 (patch) | |
tree | ca3bf242839c0c6a90ae0403b905457cbae31f5b | |
parent | f30b22d3478f6af0237a63539a313fe3f2c20669 (diff) | |
parent | 79d0a884683389a7a57f88862bc2189c7b633e6f (diff) | |
download | android_packages_apps_PackageInstaller-47f7d0bed40f1928db116f532b40517ee9e3b317.tar.gz android_packages_apps_PackageInstaller-47f7d0bed40f1928db116f532b40517ee9e3b317.tar.bz2 android_packages_apps_PackageInstaller-47f7d0bed40f1928db116f532b40517ee9e3b317.zip |
am 79d0a884: am 6d449fe9: am 03347bac: Fix issue #7323256: permission dialog has bad layout
* commit '79d0a884683389a7a57f88862bc2189c7b633e6f':
Fix issue #7323256: permission dialog has bad layout
-rw-r--r-- | res/layout/install_confirm.xml | 8 | ||||
-rw-r--r-- | src/com/android/packageinstaller/PackageInstallerActivity.java | 23 |
2 files changed, 20 insertions, 11 deletions
diff --git a/res/layout/install_confirm.xml b/res/layout/install_confirm.xml index 9589e8ad..f9fb3591 100644 --- a/res/layout/install_confirm.xml +++ b/res/layout/install_confirm.xml @@ -44,6 +44,14 @@ android:background="?android:attr/dividerHorizontal" android:visibility="gone" /> + <FrameLayout + android:id="@+id/filler" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:layout_weight="1" + android:visibility="gone"> + </FrameLayout> + <TabHost android:id="@android:id/tabhost" android:layout_width="match_parent" diff --git a/src/com/android/packageinstaller/PackageInstallerActivity.java b/src/com/android/packageinstaller/PackageInstallerActivity.java index d0c50fc9..4a6db210 100644 --- a/src/com/android/packageinstaller/PackageInstallerActivity.java +++ b/src/com/android/packageinstaller/PackageInstallerActivity.java @@ -284,19 +284,20 @@ public class PackageInstallerActivity extends Activity implements OnCancelListen } } if (!permVisible) { - if (msg == 0) { - if (mAppInfo != null) { - // This is an update to an application, but there are no - // permissions at all. - msg = (mAppInfo.flags & ApplicationInfo.FLAG_SYSTEM) != 0 - ? R.string.install_confirm_question_update_system_no_perms - : R.string.install_confirm_question_update_no_perms; - } else { - // This is a new application with no permissions. - msg = R.string.install_confirm_question_no_perms; - } + if (mAppInfo != null) { + // This is an update to an application, but there are no + // permissions at all. + msg = (mAppInfo.flags & ApplicationInfo.FLAG_SYSTEM) != 0 + ? R.string.install_confirm_question_update_system_no_perms + : R.string.install_confirm_question_update_no_perms; + } else { + // This is a new application with no permissions. + msg = R.string.install_confirm_question_no_perms; } tabHost.setVisibility(View.GONE); + findViewById(R.id.filler).setVisibility(View.VISIBLE); + findViewById(R.id.divider).setVisibility(View.GONE); + mScrollView = null; } if (msg != 0) { ((TextView)findViewById(R.id.install_confirm_question)).setText(msg); |