Closing last tab closes the browser
Bug: 3254181
Closing the last tab will now close the browser rather than creating a new
tab and then closing the old tab.
Change-Id: Iac458783eea4c4a893671281f2a631e0365f8697
diff --git a/src/com/android/browser/Controller.java b/src/com/android/browser/Controller.java
index 8483efa..4c17308 100644
--- a/src/com/android/browser/Controller.java
+++ b/src/com/android/browser/Controller.java
@@ -2152,10 +2152,7 @@
removeComboView();
final Tab current = mTabControl.getCurrentTab();
if (mTabControl.getTabCount() == 1) {
- // This is the last tab. Open a new one, with the home
- // page and close the current one.
- openTabToHomePage();
- closeTab(current);
+ mActivity.finish();
return;
}
final Tab parent = current.getParentTab();