Snapshot title bar

 Bug: 4982126

Change-Id: I67931d39e3a3ce535b38197ebeee1651241d1a60
diff --git a/src/com/android/browser/Tab.java b/src/com/android/browser/Tab.java
index 4558717..beac2ff 100644
--- a/src/com/android/browser/Tab.java
+++ b/src/com/android/browser/Tab.java
@@ -1457,6 +1457,8 @@
     void destroy() {
         if (mMainView != null) {
             dismissSubWindow();
+            // Make sure the embedded title bar isn't still attached
+            mMainView.setEmbeddedTitleBar(null);
             // save the WebView to call destroy() after detach it from the tab
             WebView webView = mMainView;
             setWebView(null);
@@ -1971,4 +1973,24 @@
         }
     }
 
+    public boolean canGoBack() {
+        return mMainView != null ? mMainView.canGoBack() : false;
+    }
+
+    public boolean canGoForward() {
+        return mMainView != null ? mMainView.canGoForward() : false;
+    }
+
+    public void goBack() {
+        if (mMainView != null) {
+            mMainView.goBack();
+        }
+    }
+
+    public void goForward() {
+        if (mMainView != null) {
+            mMainView.goForward();
+        }
+    }
+
 }