From 542366042e6e15a9dfacd537535ae58a4450fd13 Mon Sep 17 00:00:00 2001 From: Lucas Rocha Date: Tue, 7 Aug 2012 15:23:20 +0100 Subject: [PATCH] Bug 766942 - Set query argument with initial reading list state (r=mfinkle) --- mobile/android/base/Tab.java | 3 ++- mobile/android/base/awesomebar/AwesomeBarTab.java | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/mobile/android/base/Tab.java b/mobile/android/base/Tab.java index 8038329aee1..d87bdd40dad 100644 --- a/mobile/android/base/Tab.java +++ b/mobile/android/base/Tab.java @@ -449,7 +449,8 @@ public final class Tab { if (!mReaderEnabled) return; - GeckoApp.mAppContext.loadUrl("about:reader?url=" + Uri.encode(getURL())); + GeckoApp.mAppContext.loadUrl("about:reader?url=" + Uri.encode(getURL()) + + "&readingList=" + (mReadingListItem ? 1 : 0)); } public void doReload() { diff --git a/mobile/android/base/awesomebar/AwesomeBarTab.java b/mobile/android/base/awesomebar/AwesomeBarTab.java index 0803dfc0b8d..f38c54d4f6b 100644 --- a/mobile/android/base/awesomebar/AwesomeBarTab.java +++ b/mobile/android/base/awesomebar/AwesomeBarTab.java @@ -92,7 +92,7 @@ abstract public class AwesomeBarTab { protected String getReaderForUrl(String url) { // FIXME: still need to define the final way to open items from // reading list. For now, we're using an about:reader page. - return "about:reader?url=" + Uri.encode(url); + return "about:reader?url=" + Uri.encode(url) + "&readingList=1"; } protected void updateFavicon(ImageView faviconView, Cursor cursor) {