Closed Bug 766942 Opened 12 years ago Closed 12 years ago

Reader Mode: Unable to add an article to the reading list from within Reader Mode

Categories

(Firefox for Android Graveyard :: Reader View, defect)

ARM
Android
defect
Not set
normal

Tracking

(firefox16 verified, firefox17 verified, fennec16+)

VERIFIED FIXED
Firefox 17
Tracking Status
firefox16 --- verified
firefox17 --- verified
fennec 16+ ---

People

(Reporter: aaronmt, Assigned: lucasr)

References

Details

Attachments

(11 files)

146.00 KB, image/png
Details
115.24 KB, application/zip
Details
2.30 KB, patch
wesj
: review+
Details | Diff | Splinter Review
2.84 KB, patch
Margaret
: review+
Details | Diff | Splinter Review
5.16 KB, patch
Margaret
: review+
Details | Diff | Splinter Review
2.02 KB, patch
mfinkle
: review+
Details | Diff | Splinter Review
1.00 KB, patch
mfinkle
: review+
Details | Diff | Splinter Review
3.39 KB, patch
mfinkle
: review+
Details | Diff | Splinter Review
991 bytes, patch
mfinkle
: review+
Details | Diff | Splinter Review
139.88 KB, patch
mfinkle
: review+
Details | Diff | Splinter Review
4.36 KB, patch
wesj
: review+
Details | Diff | Splinter Review
Currently when one opens an article; there is no way to 'Add to Reading List'. I open the menu and 'Reading List' is greyed out.
(In reply to Aaron Train [:aaronmt] from comment #0) > Currently when one opens an article; there is no way to 'Add to Reading > List'. I open the menu and 'Reading List' is greyed out. The Reading List menu item should only be enabled when you see the reader icon in the toolbar. If it's greyed out, this probably means the current page is not convertible to reader mode. If you think the specific page where this happens should to be convertible but reader mode is not available, please file a separate bug for that. I'm sure we'll have to refine the way we do the readability check on pages.
Blocks: reader
This bug is exactly in reference to articles viewed from within reading-mode (i.e, I am sitting in reader mode, and I can't find a way to 'Add to reading list'). Perhaps not all the patches landed, as I recall this working on your personal build a few days ago? URL I am using: http://www.thestar.com/iphone
Summary: Reader Mode: Unable to add an article to the reading list → Reader Mode: Unable to add an article to the reading list from within Reader Mode
This bug has two parts: 1. The menu item for toggling the page on and off reading list is always disabled while in reader mode. 2. There's no way directly in the Reader UI to add/remove the page to/from the reading list. This part slightly overlaps with bug 750678 (reading list navigation in Reader) but it's more about how to add/remove reading list items in Reader Mode. Madhava, Ian, any decision on the part 2 here?
Keywords: uiwanted
Madhava, Ian: Ping!
tracking-fennec: ? → 16+
Assignee: nobody → lucasr.at.mozilla
Attached image toolbar mockup
Attached is a revised cut of the Reader Mode toolbar, that now supports a couple of cases that should make interacting with the Reading List a little more comfortable. 1. Support for Adding / Removing items from your Reading List (as Lucas mentioned above) * If an article is not in your Reading List, the toolbar should show a "Add to Reading List" icon. When tapping the icon, a toast that reads "Added to Reading List" should appear. * If an article is in your Reading List, the toolbar should show a "Remove" icon. When tapping the icon, a toast that reads "Removed from Reading List" should appear. 2. A quick way to open your Reading List Tapping the List icon should display your full Reading List. Currently this exists as a folder in the Bookmarks tab in the Awesomebar, so this is what it should open. We are currently exploring other possible placements for this list, so if it changes, this icon will have to be mapped to whichever new location we determine to be more appropriate.
(In reply to Ian Barlow (:ibarlow) from comment #5) > Created attachment 647270 [details] > toolbar mockup > > Attached is a revised cut of the Reader Mode toolbar, that now supports a > couple of cases that should make interacting with the Reading List a little > more comfortable. > > 1. Support for Adding / Removing items from your Reading List (as Lucas > mentioned above) > > * If an article is not in your Reading List, the toolbar should show a "Add > to Reading List" icon. When tapping the icon, a toast that reads "Added to > Reading List" should appear. > * If an article is in your Reading List, the toolbar should show a "Remove" > icon. When tapping the icon, a toast that reads "Removed from Reading List" > should appear. > > > 2. A quick way to open your Reading List > > Tapping the List icon should display your full Reading List. Currently this > exists as a folder in the Bookmarks tab in the Awesomebar, so this is what > it should open. We are currently exploring other possible placements for > this list, so if it changes, this icon will have to be mapped to whichever > new location we determine to be more appropriate. Are we going to remove the reading list item from the app menu? If not, are you ok with having different icons for the reading list toggling on reader toolbar and app menu? How should those button align on bigger screens (i.e. tablets)? Align left (or right) I guess? What is the background colour when the toolbar buttons are pressed? Orange? It's a shade of grey/blue right now. Also, assets, please :-)
(In reply to Lucas Rocha (:lucasr) from comment #6) > Are we going to remove the reading list item from the app menu? If not, are > you ok with having different icons for the reading list toggling on reader > toolbar and app menu? It would be great if, before we ship "add to reading list", we resolve bug 769239 (manage down our menu list), which groups the Add to Reading List option into a bookmarking submenu. In that case, we probably wouldn't show icons in that submenu. > How should those button align on bigger screens (i.e. tablets)? Align left > (or right) I guess? Align right, please. > What is the background colour when the toolbar buttons are pressed? Orange? > It's a shade of grey/blue right now. Orange > Also, assets, please :-) Coming soon :)
Assignee: lucasr.at.mozilla → nobody
Component: General → Reader Mode
Attachment #648808 - Flags: review?(margaret.leibovic)
Attachment #648809 - Flags: review?(margaret.leibovic)
Attachment #648811 - Flags: review?(mfinkle) → review+
Attachment #648810 - Flags: review?(mfinkle) → review+
Attachment #648815 - Flags: review?(mfinkle)
Attachment #648813 - Flags: review?(mfinkle) → review+
Comment on attachment 648812 [details] [diff] [review] Change Tabs to handle Reader:Removed message from Gecko >+ void handleReaderRemoved(final String url) { >+ GeckoAppShell.getHandler().post(new Runnable() { >+ public void run() { >+ BrowserDB.removeReadingListItemWithURL(mResolver, url); >+ mActivity.showToast(R.string.reading_list_removed, Toast.LENGTH_SHORT); >+ } >+ }); >+ } Looks good and we don't need to fire any TabChanged events for this (just like we don't for handleReaderAdded)
Attachment #648812 - Flags: review?(mfinkle) → review+
Comment on attachment 648815 [details] [diff] [review] Implement new reader toolbar More images :( Oh well.
Attachment #648815 - Flags: review?(mfinkle) → review+
Comment on attachment 648807 [details] [diff] [review] Change bookmarks tab to support reading list as initial folder This looks okay to me, but I'm not as familiar with this code after it got refactored into BookmarksTab, so maybe Wes should take a look as well, since I see his name all over that file.
Attachment #648807 - Flags: review?(wjohnston)
Attachment #648807 - Flags: review?(margaret.leibovic)
Attachment #648807 - Flags: review+
Attachment #648808 - Flags: review?(margaret.leibovic) → review+
Attachment #648809 - Flags: review?(margaret.leibovic) → review+
Comment on attachment 648807 [details] [diff] [review] Change bookmarks tab to support reading list as initial folder Actually, thinking about this more, does this mean that you won't be able to navigate outside of the reading list as long as mShowReadingList is true? I'm not confident about how all this code works, so I think Wes should take a look. Does pressing the back button exit the AwesomeBar activity? Also, what happens if you switch to a different AwesomeBarTab and then back to Bookmarks?
Attachment #648807 - Flags: review+
Comment on attachment 648807 [details] [diff] [review] Change bookmarks tab to support reading list as initial folder Review of attachment 648807 [details] [diff] [review]: ----------------------------------------------------------------- Heh. I didn't write this either. Just copy-pasted it, but I'm gonna comment anyway. Tell me if I'm nuts. ::: mobile/android/base/awesomebar/BookmarksTab.java @@ +38,5 @@ > private int mFolderId; > private String mFolderTitle; > private BookmarksListAdapter mCursorAdapter = null; > private BookmarksQueryTask mQueryTask = null; > + private boolean mShowReadingList = false; I don't really like this name, but then I don't really like this variable existing at all. We already have mInReadingList which seems kinda silly too. At the very least, I'd rather store some info than have a boolean for just this one folder. i.e. BookmarksTab bookmarksTab = mAwesomeTabs.getBookmarksTab(); bookmarksTab.moveToChildFolder(Bookmarks.FIXED_READING_LIST_ID, ...) // the same code below can run except slightly more generic? or // refreshCurrentFolder can just bail if there's no mView. The getQueryTask() // call below can be made more generic and could automatically get a queryTask // for the current folder if nothing was passed to it and mQueryTask == null. // Not sure if that will work or not, but in my head it feels a little cleaner? mAwesomeTabs.setCurrentTabByTag(bookmarksTab.getTag()); That may give issues if the folder was a few levels deep.... I'd rather put those off and come back to them later. @@ +79,5 @@ > list.setAdapter(null); > list.setAdapter(getCursorAdapter()); > > + if (mShowReadingList) { > + String title = getResources().getString(R.string.bookmarks_folder_reading_list); We should put a helper method in Bookmarks for this stuff. Get Name for Folder or something? I don't like having it in here...
Attachment #648807 - Flags: review?(wjohnston) → review-
(In reply to Wesley Johnston (:wesj) from comment #21) > Comment on attachment 648807 [details] [diff] [review] > Change bookmarks tab to support reading list as initial folder > > Review of attachment 648807 [details] [diff] [review]: > ----------------------------------------------------------------- > > Heh. I didn't write this either. Just copy-pasted it, but I'm gonna comment > anyway. Tell me if I'm nuts. > > ::: mobile/android/base/awesomebar/BookmarksTab.java > @@ +38,5 @@ > > private int mFolderId; > > private String mFolderTitle; > > private BookmarksListAdapter mCursorAdapter = null; > > private BookmarksQueryTask mQueryTask = null; > > + private boolean mShowReadingList = false; > > I don't really like this name, but then I don't really like this variable > existing at all. We already have mInReadingList which seems kinda silly too. > At the very least, I'd rather store some info than have a boolean for just > this one folder. i.e. You're right, the mInReadingList property is not strictly needed anymore. I'm posting a patch now to remove it. > BookmarksTab bookmarksTab = mAwesomeTabs.getBookmarksTab(); > bookmarksTab.moveToChildFolder(Bookmarks.FIXED_READING_LIST_ID, ...) > // the same code below can run except slightly more generic? or > // refreshCurrentFolder can just bail if there's no mView. The > getQueryTask() > // call below can be made more generic and could automatically get a > queryTask > // for the current folder if nothing was passed to it and mQueryTask == > null. > // Not sure if that will work or not, but in my head it feels a little > cleaner? > mAwesomeTabs.setCurrentTabByTag(bookmarksTab.getTag()); > > That may give issues if the folder was a few levels deep.... I'd rather put > those off and come back to them later. I explicitly decided to not make this look too generic exactly because supporting awesomescreen startups for any sub-folder requires handling multiple number of navigation levels, which is a) a non-trivial change b) not needed for any of our real use cases. We can worry about this if/once we need it. I'd rather not pretend we're doing the generic solution while we're not. And, as I said, we don't need to be generic here. > @@ +79,5 @@ > > list.setAdapter(null); > > list.setAdapter(getCursorAdapter()); > > > > + if (mShowReadingList) { > > + String title = getResources().getString(R.string.bookmarks_folder_reading_list); > > We should put a helper method in Bookmarks for this stuff. Get Name for > Folder or something? I don't like having it in here... Again, I feel like this would be generalizing too much for a use case that is very specific. We only need to handle reading list because it's a very special case.
(In reply to Margaret Leibovic [:margaret] from comment #20) > Comment on attachment 648807 [details] [diff] [review] > Change bookmarks tab to support reading list as initial folder > > Actually, thinking about this more, does this mean that you won't be able to > navigate outside of the reading list as long as mShowReadingList is true? > I'm not confident about how all this code works, so I think Wes should take > a look. mShowReadingList only affects the initial folder to be shown on startup. > Does pressing the back button exit the AwesomeBar activity? Also, what > happens if you switch to a different AwesomeBarTab and then back to > Bookmarks? Folder navigation will work exactly as it usually works: pressing back will go up to the bookmarks root folder. Tab switching behavior will remain unchanged. The bookmarks tab is only created once and mShowReadingList only defines the initial folder in the tab.
Attachment #649229 - Flags: review?(wjohnston) → review+
Comment on attachment 648807 [details] [diff] [review] Change bookmarks tab to support reading list as initial folder Review of attachment 648807 [details] [diff] [review]: ----------------------------------------------------------------- I get the point about the subfolder thing. I still think I'd be willing to overlook that in favour of a more general solution and a documentation note/todo. I don't think this code should know anything about ReadingList. BUT, I don't want to hold this entire feature up waiting for it either. Can you file a bug about getting rid of it at least?
Attachment #648807 - Flags: review- → review+
(In reply to Wesley Johnston (:wesj) from comment #25) > Comment on attachment 648807 [details] [diff] [review] > Change bookmarks tab to support reading list as initial folder > > Review of attachment 648807 [details] [diff] [review]: > ----------------------------------------------------------------- > > I get the point about the subfolder thing. I still think I'd be willing to > overlook that in favour of a more general solution and a documentation > note/todo. I don't think this code should know anything about ReadingList. > > BUT, I don't want to hold this entire feature up waiting for it either. Can > you file a bug about getting rid of it at least? Fair enough. I filed bug 780865 to track this.
Comment on attachment 648807 [details] [diff] [review] Change bookmarks tab to support reading list as initial folder Reader mode final UI implementation. No strings added or changed. Reader mode is on the Firefox 16 roadmap.
Attachment #648807 - Flags: approval-mozilla-aurora?
Comment on attachment 648808 [details] [diff] [review] Support showing reading list directly on awesomebar startup Reader mode final UI implementation. No strings added or changed. Reader mode is on the Firefox 16 roadmap.
Attachment #648808 - Flags: approval-mozilla-aurora?
Comment on attachment 648809 [details] [diff] [review] Add Reader:GoToReadingList bits to GeckoApp Reader mode final UI implementation. No strings added or changed. Reader mode is on the Firefox 16 roadmap.
Attachment #648809 - Flags: approval-mozilla-aurora?
Comment on attachment 648810 [details] [diff] [review] Set query argument with initial reading list state Reader mode final UI implementation. No strings added or changed. Reader mode is on the Firefox 16 roadmap.
Attachment #648810 - Flags: approval-mozilla-aurora?
Comment on attachment 648811 [details] [diff] [review] Fix GeckoApp's showToast() to actually show the notification Reader mode final UI implementation. No strings added or changed. Reader mode is on the Firefox 16 roadmap.
Attachment #648811 - Flags: approval-mozilla-aurora?
Comment on attachment 648812 [details] [diff] [review] Change Tabs to handle Reader:Removed message from Gecko Reader mode final UI implementation. No strings added or changed. Reader mode is on the Firefox 16 roadmap.
Attachment #648812 - Flags: approval-mozilla-aurora?
Comment on attachment 648813 [details] [diff] [review] Stop prograpation on clicks in toolbar buttons Reader mode final UI implementation. No strings added or changed. Reader mode is on the Firefox 16 roadmap.
Attachment #648813 - Flags: approval-mozilla-aurora?
Comment on attachment 648815 [details] [diff] [review] Implement new reader toolbar Reader mode final UI implementation. No strings added or changed. Reader mode is on the Firefox 16 roadmap.
Attachment #648815 - Flags: approval-mozilla-aurora?
Comment on attachment 649229 [details] [diff] [review] Get rid of mInReadingList property in BookmarksTab Reader mode final UI implementation. No strings added or changed. Reader mode is on the Firefox 16 roadmap.
Attachment #649229 - Flags: approval-mozilla-aurora?
The 4 icons in the new toolbar arrangement are very blurry on my 800x480 ICS device. Does it use the right resources, are additional ones needed (followup bug)?
(In reply to Thomas Stache from comment #38) > The 4 icons in the new toolbar arrangement are very blurry on my 800x480 ICS > device. See bug 776903.
Attachment #648807 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
Attachment #648808 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
Attachment #648809 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
Attachment #648810 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
Attachment #648811 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
Attachment #648812 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
Attachment #648813 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
Attachment #648815 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
Attachment #649229 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
This issue is fixed on the latest Nightly. I will leave this bug open until the patches will land on m-a. -- Firefox 17.a1 (2012-08-12) Device: Galaxy Nexus OS: Android 4.1.1
Assignee: nobody → lucasr.at.mozilla
Verified fix on: Firefox Mobile 16 beta 2, Nightly 18.0a1 2012-09-04 and Aurora 17.0a2 2012-09-05 on Samsung Galaxy Tab 2 7.0 (Android 4.0.4) Any article opened in Reading Mode can be added to the Reading List. Also if Reader Mode is available the article can be added to the reading list from the Custom Menu.
Status: RESOLVED → VERIFIED
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: