Updates to the add bookmark dialog.

AddBookmarkPage:
Use BreadCrumbView in the dialog.
Set  better dimensions so the dialog stays consistent.

BreadCrumbView:
Provide an option to disallow going back from a
particular crumb.
Limit the width of a crumb.

Bug:2953515

Change-Id: Iadd68b89b9b43f9645d7c4dee483f66edb3f3c93
diff --git a/res/layout/browser_add_bookmark.xml b/res/layout/browser_add_bookmark.xml
index 604bda8..e5f164f 100644
--- a/res/layout/browser_add_bookmark.xml
+++ b/res/layout/browser_add_bookmark.xml
@@ -15,11 +15,34 @@
 -->
 
 <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="match_parent"
+    android:layout_width="@dimen/add_bookmark_width"
     android:layout_height="wrap_content"
     android:orientation="vertical"
     >
 
+    <com.android.browser.BreadCrumbView android:id="@+id/crumbs"
+        android:layout_width="match_parent"
+        android:layout_height="wrap_content"
+        android:visibility="gone"
+        />
+    <LinearLayout android:id="@+id/fake_title_bar"
+        android:layout_width="match_parent"
+        android:layout_height="wrap_content"
+        android:orientation="horizontal"
+        >
+        <ImageView
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:src="@drawable/ic_list_bookmark"
+            />
+        <TextView android:id="@+id/fake_title"
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:text="@string/bookmark_this_page"
+            android:layout_gravity="center_horizontal"
+            android:textAppearance="?android:attr/textAppearanceMedium" />
+    </LinearLayout>
+
     <ImageView android:id="@+id/titleDivider"
         android:layout_width="match_parent"
         android:layout_height="1dip"
@@ -29,6 +52,7 @@
         android:layout_marginLeft="10dip"
         android:layout_marginRight="10dip"/>
 
+    <!-- XXX Use a TableLayout instead -->
     <RelativeLayout android:id="@+id/default_view"
         android:layout_width="match_parent"
         android:layout_height="wrap_content"
@@ -53,7 +77,7 @@
         <EditText
             android:id="@+id/title"
             android:layout_height="wrap_content"
-            android:layout_width="250dip"
+            android:layout_width="325dip"
             android:gravity="fill_horizontal"
             android:layout_alignBaseline="@+id/titleText"
             android:layout_toRightOf="@+id/titleText"
@@ -79,7 +103,7 @@
         <EditText
             android:id="@+id/address"
             android:layout_height="wrap_content"
-            android:layout_width="250dip"
+            android:layout_width="325dip"
             android:hint="@string/http"
             android:layout_alignBaseline="@+id/addressText"
             android:layout_alignLeft="@+id/title"
@@ -113,25 +137,12 @@
     </RelativeLayout>
 
     <LinearLayout android:id="@+id/folder_selector"
-        android:layout_width="500dip"
-        android:layout_height="wrap_content"
+        android:layout_width="match_parent"
+        android:layout_height="@dimen/folder_selector_height"
         android:orientation="vertical"
         android:visibility="gone"
         >
 
-        <TextView
-            android:id="@+id/path"
-            android:layout_marginTop="4dip"
-            android:layout_marginLeft="16dip"
-            android:layout_marginRight="16dip"
-            android:layout_marginBottom="4dip"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:singleLine="true"
-            android:ellipsize="start"
-            android:text="@string/bookmarks"
-            android:textAppearance="?android:attr/textAppearanceLarge" />
-
         <ListView
             android:id="@+id/list"
             android:layout_marginLeft="16dip"
diff --git a/res/values/dimensions.xml b/res/values/dimensions.xml
index 4d19a9f..f550cf7 100644
--- a/res/values/dimensions.xml
+++ b/res/values/dimensions.xml
@@ -21,4 +21,6 @@
 
     <dimen name="bookmarkThumbnailWidth">90dip</dimen>
     <dimen name="bookmarkThumbnailHeight">80dip</dimen>
-</resources>
\ No newline at end of file
+    <dimen name="add_bookmark_width">500dip</dimen>
+    <dimen name="folder_selector_height">300dip</dimen>
+</resources>
diff --git a/res/values/integers.xml b/res/values/integers.xml
index 7508e00..c923805 100644
--- a/res/values/integers.xml
+++ b/res/values/integers.xml
@@ -20,4 +20,5 @@
     <integer name="max_tabs">16</integer>
     <!--  The duration of the tab animations in millisecs  -->
     <integer name="tab_animation_duration">500</integer>
-</resources>
\ No newline at end of file
+    <integer name="max_width_crumb">200</integer>
+</resources>