Don't embed titlebar in WebView
Bug: 5032345
The titlebar gets attached to an overlay and tracks the scrolling
of the WebView at the top of the page.
Change-Id: I60b2163bb7a3642813823995278722455f566f36
diff --git a/src/com/android/browser/BaseUi.java b/src/com/android/browser/BaseUi.java
index ffb2928..f8a9414 100644
--- a/src/com/android/browser/BaseUi.java
+++ b/src/com/android/browser/BaseUi.java
@@ -250,6 +250,7 @@
WebView web = mActiveTab.getWebView();
updateUrlBarAutoShowManagerTarget();
attachTabToContentView(tab);
+ mTitleBar.bringToFront();
setShouldShowErrorConsole(tab, mUiController.shouldShowErrorConsole());
onTabDataChanged(tab);
onProgressChanged(tab);
@@ -345,7 +346,6 @@
// Remove the container from the content and then remove the
// WebView from the container. This will trigger a focus change
// needed by WebView.
- WebViewClassic.fromWebView(mainView).setEmbeddedTitleBar(null);
FrameLayout wrapper =
(FrameLayout) container.findViewById(R.id.webview_wrapper);
wrapper.removeView(mainView);
@@ -475,13 +475,6 @@
return mTitleBar;
}
- protected void setTitleGravity(int gravity) {
- WebView web = getWebView();
- if (web != null) {
- WebViewClassic.fromWebView(web).setTitleBarGravity(gravity);
- }
- }
-
@Override
public void showVoiceTitleBar(String title, List<String> results) {
mNavigationBar.setInVoiceMode(true, results);