Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(122)

Issue 2878543003: Hook up Reader Mode InfoBar (Closed)

Created:
3 years, 7 months ago by mdjones
Modified:
3 years, 6 months ago
Reviewers:
Ted C, Theresa, jwd, wychen
CC:
chromium-reviews, mdjones+watch_chromium.org, donnd+watch_chromium.org, lizeb+watch-custom-tabs_chromium.org, asvitkine+watch_chromium.org, dfalcantara+watch_chromium.org, agrieve+watch_chromium.org
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

Hook up Reader Mode InfoBar This change replaces the OverlayPanel UI for Reader Mode in favor of the InfoBar UI. Some notable changes associated with the UI switch: - Navigations to distilled content are not retained in history. This means a backward navigation will skip distilled content and bring the user to the original page. - The UI no longer animates or sits on top of the original web page. - Since Reader Mode is now an infobar, it interacts nicely with other infobars that may appear. - All operations in the overflow menu use the base page URL. - The "Appearance" overflow item is once again available. - Code complexity has been considerably reduced. BUG=710014, 624009 Review-Url: https://codereview.chromium.org/2878543003 Cr-Commit-Position: refs/heads/master@{#479229} Committed: https://chromium.googlesource.com/chromium/src/+/75af3a8ba9bd8724e83d99db0113bc8836b472ae

Patch Set 1 #

Patch Set 2 : remove obsolete tests #

Patch Set 3 : fix disabled test #

Total comments: 14

Patch Set 4 : address comments #

Patch Set 5 : rebase past junit conversion #

Total comments: 4

Patch Set 6 : add new read-time metric and clean up some state #

Total comments: 4

Patch Set 7 : address comments #

Total comments: 4

Patch Set 8 : rebase #

Patch Set 9 : replace uses of 'panel' where relevant #

Total comments: 2

Patch Set 10 : remove custom hide code #

Patch Set 11 : fix tests #

Unified diffs Side-by-side diffs Delta from patch set Stats (+233 lines, -625 lines) Patch
M chrome/android/java/src/org/chromium/chrome/browser/ChromeActivity.java View 1 2 3 4 5 6 7 8 9 10 3 chunks +3 lines, -11 lines 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/compositor/CompositorViewHolder.java View 1 2 3 4 5 6 7 8 9 10 2 chunks +2 lines, -5 lines 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/readermode/ReaderModePanel.java View 2 chunks +0 lines, -8 lines 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/compositor/layouts/LayoutManager.java View 2 chunks +0 lines, -3 lines 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/compositor/layouts/LayoutManagerChrome.java View 3 chunks +1 line, -3 lines 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/compositor/layouts/LayoutManagerChromePhone.java View 1 2 3 4 5 6 7 8 9 2 chunks +1 line, -3 lines 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/compositor/layouts/LayoutManagerChromeTablet.java View 2 chunks +1 line, -3 lines 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/compositor/layouts/LayoutManagerDocument.java View 8 chunks +1 line, -14 lines 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/customtabs/CustomTabLayoutManager.java View 2 chunks +1 line, -3 lines 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/dom_distiller/ReaderModeManager.java View 1 2 3 4 5 6 7 8 9 10 22 chunks +127 lines, -244 lines 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/dom_distiller/ReaderModeManagerDelegate.java View 6 7 8 9 10 3 chunks +0 lines, -16 lines 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/dom_distiller/ReaderModeTabInfo.java View 1 2 3 4 5 6 7 8 9 10 6 chunks +43 lines, -10 lines 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/infobar/ReaderModeInfoBar.java View 1 2 3 4 5 6 7 8 9 2 chunks +5 lines, -3 lines 0 comments Download
M chrome/android/java_sources.gni View 1 2 3 4 5 6 7 8 9 10 1 chunk +0 lines, -1 line 0 comments Download
M chrome/android/javatests/src/org/chromium/chrome/browser/compositor/layouts/LayoutManagerTest.java View 1 2 1 chunk +1 line, -1 line 0 comments Download
M chrome/android/javatests/src/org/chromium/chrome/browser/dom_distiller/DistillabilityServiceTest.java View 1 2 3 4 3 chunks +26 lines, -9 lines 0 comments Download
D chrome/android/javatests/src/org/chromium/chrome/browser/dom_distiller/ReaderModeManagerTest.java View 1 1 chunk +0 lines, -288 lines 0 comments Download
M tools/metrics/histograms/histograms.xml View 1 2 3 4 5 6 7 8 9 10 4 chunks +21 lines, -0 lines 0 comments Download

Dependent Patchsets:

Messages

Total messages: 40 (17 generated)
mdjones
ptal
3 years, 7 months ago (2017-05-11 01:04:23 UTC) #2
Theresa
http://www.reactiongifs.us/wp-content/uploads/2013/06/cheering_minions.gif https://codereview.chromium.org/2878543003/diff/30001/chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/readermode/ReaderModePanel.java File chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/readermode/ReaderModePanel.java (right): https://codereview.chromium.org/2878543003/diff/30001/chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/readermode/ReaderModePanel.java#newcode37 chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/readermode/ReaderModePanel.java:37: public class ReaderModePanel extends OverlayPanel { Can we ...
3 years, 7 months ago (2017-05-11 22:31:19 UTC) #3
mdjones
https://codereview.chromium.org/2878543003/diff/30001/chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/readermode/ReaderModePanel.java File chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/readermode/ReaderModePanel.java (right): https://codereview.chromium.org/2878543003/diff/30001/chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/readermode/ReaderModePanel.java#newcode37 chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/readermode/ReaderModePanel.java:37: public class ReaderModePanel extends OverlayPanel { On 2017/05/11 22:31:18, ...
3 years, 7 months ago (2017-05-12 19:13:10 UTC) #4
Theresa
lgtm
3 years, 7 months ago (2017-05-12 20:52:51 UTC) #5
mdjones
+wychen ptal
3 years, 7 months ago (2017-05-12 21:37:58 UTC) #7
wychen
Awesome! Could you rebase it? I'd like to give it a try.
3 years, 7 months ago (2017-05-12 23:22:38 UTC) #8
mdjones
On 2017/05/12 23:22:38, wychen wrote: > Awesome! Could you rebase it? I'd like to give ...
3 years, 7 months ago (2017-05-15 16:36:51 UTC) #9
wychen
https://codereview.chromium.org/2878543003/diff/70001/chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/readermode/ReaderModePanel.java File chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/readermode/ReaderModePanel.java (right): https://codereview.chromium.org/2878543003/diff/70001/chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/readermode/ReaderModePanel.java#newcode37 chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/readermode/ReaderModePanel.java:37: public class ReaderModePanel extends OverlayPanel { Is ReaderModePanel needed ...
3 years, 7 months ago (2017-05-16 00:19:03 UTC) #10
mdjones
https://codereview.chromium.org/2878543003/diff/70001/chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/readermode/ReaderModePanel.java File chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/readermode/ReaderModePanel.java (right): https://codereview.chromium.org/2878543003/diff/70001/chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/readermode/ReaderModePanel.java#newcode37 chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/readermode/ReaderModePanel.java:37: public class ReaderModePanel extends OverlayPanel { On 2017/05/16 00:19:03, ...
3 years, 7 months ago (2017-05-16 23:29:35 UTC) #11
wychen
https://codereview.chromium.org/2878543003/diff/90001/chrome/android/java/src/org/chromium/chrome/browser/dom_distiller/ReaderModeManager.java File chrome/android/java/src/org/chromium/chrome/browser/dom_distiller/ReaderModeManager.java (right): https://codereview.chromium.org/2878543003/diff/90001/chrome/android/java/src/org/chromium/chrome/browser/dom_distiller/ReaderModeManager.java#newcode202 chrome/android/java/src/org/chromium/chrome/browser/dom_distiller/ReaderModeManager.java:202: if (!mTabStatusMap.containsKey(tab.getId())) { Is it safe to reuse tabInfo? ...
3 years, 7 months ago (2017-05-17 07:24:12 UTC) #12
mdjones
https://codereview.chromium.org/2878543003/diff/90001/chrome/android/java/src/org/chromium/chrome/browser/dom_distiller/ReaderModeManager.java File chrome/android/java/src/org/chromium/chrome/browser/dom_distiller/ReaderModeManager.java (right): https://codereview.chromium.org/2878543003/diff/90001/chrome/android/java/src/org/chromium/chrome/browser/dom_distiller/ReaderModeManager.java#newcode202 chrome/android/java/src/org/chromium/chrome/browser/dom_distiller/ReaderModeManager.java:202: if (!mTabStatusMap.containsKey(tab.getId())) { On 2017/05/17 07:24:12, wychen wrote: > ...
3 years, 7 months ago (2017-05-17 16:51:53 UTC) #13
mdjones
https://codereview.chromium.org/2878543003/diff/90001/chrome/android/java/src/org/chromium/chrome/browser/dom_distiller/ReaderModeTabInfo.java File chrome/android/java/src/org/chromium/chrome/browser/dom_distiller/ReaderModeTabInfo.java (right): https://codereview.chromium.org/2878543003/diff/90001/chrome/android/java/src/org/chromium/chrome/browser/dom_distiller/ReaderModeTabInfo.java#newcode58 chrome/android/java/src/org/chromium/chrome/browser/dom_distiller/ReaderModeTabInfo.java:58: mViewStartTimeMs = System.currentTimeMillis(); On 2017/05/17 07:24:12, wychen wrote: > ...
3 years, 7 months ago (2017-05-17 16:52:15 UTC) #14
wychen
lgtm
3 years, 7 months ago (2017-05-18 15:16:55 UTC) #15
wychen
https://codereview.chromium.org/2878543003/diff/110001/chrome/android/java/src/org/chromium/chrome/browser/dom_distiller/ReaderModeManager.java File chrome/android/java/src/org/chromium/chrome/browser/dom_distiller/ReaderModeManager.java (right): https://codereview.chromium.org/2878543003/diff/110001/chrome/android/java/src/org/chromium/chrome/browser/dom_distiller/ReaderModeManager.java#newcode63 chrome/android/java/src/org/chromium/chrome/browser/dom_distiller/ReaderModeManager.java:63: /** The ChromeActivity that this panel exists in. */ ...
3 years, 7 months ago (2017-05-18 15:26:22 UTC) #16
mdjones
https://codereview.chromium.org/2878543003/diff/110001/chrome/android/java/src/org/chromium/chrome/browser/dom_distiller/ReaderModeManager.java File chrome/android/java/src/org/chromium/chrome/browser/dom_distiller/ReaderModeManager.java (right): https://codereview.chromium.org/2878543003/diff/110001/chrome/android/java/src/org/chromium/chrome/browser/dom_distiller/ReaderModeManager.java#newcode63 chrome/android/java/src/org/chromium/chrome/browser/dom_distiller/ReaderModeManager.java:63: /** The ChromeActivity that this panel exists in. */ ...
3 years, 7 months ago (2017-05-18 16:45:55 UTC) #17
mdjones
+jwd for histograms.xml
3 years, 7 months ago (2017-05-18 16:46:38 UTC) #19
jwd
lgtm
3 years, 7 months ago (2017-05-19 19:48:03 UTC) #20
mdjones
+tedchoc ptal
3 years, 7 months ago (2017-05-19 20:28:47 UTC) #22
Ted C
https://codereview.chromium.org/2878543003/diff/150001/chrome/android/java/src/org/chromium/chrome/browser/infobar/ReaderModeInfoBar.java File chrome/android/java/src/org/chromium/chrome/browser/infobar/ReaderModeInfoBar.java (right): https://codereview.chromium.org/2878543003/diff/150001/chrome/android/java/src/org/chromium/chrome/browser/infobar/ReaderModeInfoBar.java#newcode60 chrome/android/java/src/org/chromium/chrome/browser/infobar/ReaderModeInfoBar.java:60: @Override per some offline discussion, infobars "should" delete themselves ...
3 years, 7 months ago (2017-05-19 23:19:07 UTC) #23
mdjones
https://codereview.chromium.org/2878543003/diff/150001/chrome/android/java/src/org/chromium/chrome/browser/infobar/ReaderModeInfoBar.java File chrome/android/java/src/org/chromium/chrome/browser/infobar/ReaderModeInfoBar.java (right): https://codereview.chromium.org/2878543003/diff/150001/chrome/android/java/src/org/chromium/chrome/browser/infobar/ReaderModeInfoBar.java#newcode60 chrome/android/java/src/org/chromium/chrome/browser/infobar/ReaderModeInfoBar.java:60: @Override On 2017/05/19 23:19:07, Ted C wrote: > per ...
3 years, 7 months ago (2017-05-22 21:11:03 UTC) #24
Ted C
lgtm
3 years, 7 months ago (2017-05-22 21:14:12 UTC) #25
commit-bot: I haz the power
CQ is trying da patch. Follow status at: https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2878543003/190001
3 years, 6 months ago (2017-06-14 00:34:45 UTC) #37
commit-bot: I haz the power
3 years, 6 months ago (2017-06-14 00:39:35 UTC) #40
Message was sent while issue was closed.
Committed patchset #11 (id:190001) as
https://chromium.googlesource.com/chromium/src/+/75af3a8ba9bd8724e83d99db0113...

Powered by Google App Engine
This is Rietveld 408576698