diff options
Diffstat (limited to 'src/com/android/browser')
-rw-r--r-- | src/com/android/browser/Controller.java | 4 | ||||
-rw-r--r-- | src/com/android/browser/Tab.java | 7 |
2 files changed, 9 insertions, 2 deletions
diff --git a/src/com/android/browser/Controller.java b/src/com/android/browser/Controller.java index e4b0a0c..9f614b0 100644 --- a/src/com/android/browser/Controller.java +++ b/src/com/android/browser/Controller.java @@ -858,7 +858,7 @@ public class Controller @Override public void onReceivedTitle(Tab tab, final String title) { mUi.onTabDataChanged(tab); - final String pageUrl = tab.getUrl(); + final String pageUrl = tab.getOriginalUrl(); if (TextUtils.isEmpty(pageUrl) || pageUrl.length() >= SQLiteDatabase.SQLITE_MAX_LIKE_PATTERN_LENGTH) { return; @@ -906,7 +906,7 @@ public class Controller public void doUpdateVisitedHistory(Tab tab, boolean isReload) { // Don't save anything in private browsing mode if (tab.isPrivateBrowsingEnabled()) return; - String url = tab.getUrl(); + String url = tab.getOriginalUrl(); if (TextUtils.isEmpty(url) || url.regionMatches(true, 0, "about:", 0, 6)) { diff --git a/src/com/android/browser/Tab.java b/src/com/android/browser/Tab.java index c4897f2..47cefbc 100644 --- a/src/com/android/browser/Tab.java +++ b/src/com/android/browser/Tab.java @@ -1583,6 +1583,13 @@ class Tab { return UrlUtils.filteredUrl(mCurrentState.mUrl); } + String getOriginalUrl() { + if (mMainView == null) { + return ""; + } + return UrlUtils.filteredUrl(mMainView.getOriginalUrl()); + } + /** * Get the title of this tab. */ |