summaryrefslogtreecommitdiffstats
path: root/src/com/android/browser/CombinedBookmarkHistoryActivity.java
diff options
context:
space:
mode:
authorLeon Scroggins <scroggo@google.com>2009-09-08 14:55:19 -0400
committerLeon Scroggins <scroggo@google.com>2009-09-08 14:55:19 -0400
commit241cfc2942a48a8da198a16ac14df2f4e10b93fa (patch)
tree0aa6d21e0fa1f96c48175883042e048321b91063 /src/com/android/browser/CombinedBookmarkHistoryActivity.java
parent3aa8204dffd85a291305cc5fbf133c05cc6fbc91 (diff)
downloadpackages_apps_browser-241cfc2942a48a8da198a16ac14df2f4e10b93fa.zip
packages_apps_browser-241cfc2942a48a8da198a16ac14df2f4e10b93fa.tar.gz
packages_apps_browser-241cfc2942a48a8da198a16ac14df2f4e10b93fa.tar.bz2
Adjust the height of the mini-tabs to account for density.
Fix for http://b/issue?id=2098612 Change-Id: Ieb905a35f0205e9bffe8cd790f01aa6b061f8bdc
Diffstat (limited to 'src/com/android/browser/CombinedBookmarkHistoryActivity.java')
-rw-r--r--src/com/android/browser/CombinedBookmarkHistoryActivity.java7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/com/android/browser/CombinedBookmarkHistoryActivity.java b/src/com/android/browser/CombinedBookmarkHistoryActivity.java
index bed926e..d0cf5af 100644
--- a/src/com/android/browser/CombinedBookmarkHistoryActivity.java
+++ b/src/com/android/browser/CombinedBookmarkHistoryActivity.java
@@ -187,8 +187,13 @@ public class CombinedBookmarkHistoryActivity extends TabActivity
if (defaultTab != null) {
getTabHost().setCurrentTab(2);
}
+
// For each of our tabs, reduce its height by setting the icon
// view to gone, and setting a height.
+ // The minitabs are intended to be smaller than normal tabs.
+ // Arbitrarily choose 30, which is tall enough to account for the
+ // text, and scale it appropriately for the screen's density.
+ int height = (int)(30*getResources().getDisplayMetrics().density);
TabWidget widget = getTabWidget();
int count = widget.getTabCount();
for (int i = 0; i < count; i++) {
@@ -199,7 +204,7 @@ public class CombinedBookmarkHistoryActivity extends TabActivity
icon.setVisibility(View.GONE);
LinearLayout.LayoutParams lp
= (LinearLayout.LayoutParams) header.getLayoutParams();
- lp.height = 30;
+ lp.height = height;
}
widget.requestLayout();
}