Setting tab bar widths automatically

- will make launcher adapt better to different screen sizes
- also, moved customization tray tab setup code from Launcher to CustomizeTrayTabHost
diff --git a/src/com/android/launcher2/CustomizePagedView.java b/src/com/android/launcher2/CustomizePagedView.java
index 5c61b0b..36a638b 100644
--- a/src/com/android/launcher2/CustomizePagedView.java
+++ b/src/com/android/launcher2/CustomizePagedView.java
@@ -140,6 +140,8 @@
 
     private int[] mDragViewOrigin = new int[2];
 
+    private int mPageContentWidth;
+
     public CustomizePagedView(Context context) {
         this(context, null, 0);
     }
@@ -172,6 +174,11 @@
                 r.getInteger(R.integer.config_customizationDrawerDragSlopeThreshold) / 100.0f);
         mMinPageWidth = r.getDimensionPixelSize(R.dimen.customization_drawer_content_min_width);
 
+        // Create a dummy page and set it up to find out the content width (used by our parent)
+        PagedViewCellLayout layout = new PagedViewCellLayout(getContext());
+        setupPage(layout);
+        mPageContentWidth = layout.getContentWidth();
+
         setVisibility(View.GONE);
         setSoundEffectsEnabled(false);
         setupWorkspaceLayout();
@@ -1161,6 +1168,10 @@
         }
     }
 
+    int getPageContentWidth() {
+        return mPageContentWidth;
+    }
+
     @Override
     protected int getAssociatedLowerPageBound(int page) {
         return 0;