diff options
Diffstat (limited to 'src/com/android/browser/Controller.java')
-rw-r--r-- | src/com/android/browser/Controller.java | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/com/android/browser/Controller.java b/src/com/android/browser/Controller.java index 5c6a9b8d..63372370 100644 --- a/src/com/android/browser/Controller.java +++ b/src/com/android/browser/Controller.java @@ -261,6 +261,8 @@ public class Controller private PowerConnectionReceiver mLowPowerReceiver; private PowerConnectionReceiver mPowerChangeReceiver; + private boolean mCurrentPageBookmarked; + public Controller(Activity browser) { mActivity = browser; mSettings = BrowserSettings.getInstance(); @@ -1947,7 +1949,8 @@ public class Controller String title = w.getTitle(); String url = w.getUrl(); - if (title != null && url != null && lookupBookmark(title, url) > 0) { + mCurrentPageBookmarked = (lookupBookmark(title, url) > 0); + if (title != null && url != null && mCurrentPageBookmarked) { bookmark_icon.setChecked(true); } else { bookmark_icon.setChecked(false); @@ -2348,7 +2351,7 @@ public class Controller WebView w = getCurrentTopWebView(); if (w == null) return; - final Intent i = createBookmarkCurrentPageIntent(false); + final Intent i = createBookmarkCurrentPageIntent(mCurrentPageBookmarked); mActivity.startActivity(i); } } |