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

Issue 2643533003: MD History: Use one-way binding for history query state. (Closed)

Created:
3 years, 11 months ago by tsergeant
Modified:
3 years, 11 months ago
Reviewers:
calamity
CC:
chromium-reviews, chrome-apps-syd-reviews_chromium.org, Patrick Dubroy, michaelpg+watch-md-ui_chromium.org, dbeam+watch-history_chromium.org, pam+watch_chromium.org, arv+watch_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

MD History: Use one-way binding for history query state. Instead of changing query state anywhere within the history code, elements now fire an event containing the changes they want to make. This is picked up by the query-manager and used to modify the page state as needed. Any UI changes will then flow down through the page using one-way binding. This pattern further centralises the querying logic, decoupling it from the UI state. It also adds the capability to make multiple changes to the query state at once, which is necessary to support routing for Grouped History. BUG=675841 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:closure_compilation Review-Url: https://codereview.chromium.org/2643533003 Cr-Commit-Position: refs/heads/master@{#445526} Committed: https://chromium.googlesource.com/chromium/src/+/b82ab87dd4f38c3c7ca5d6d2e8e3a96220772222

Patch Set 1 #

Patch Set 2 : Cleanup #

Patch Set 3 : Rebase #

Total comments: 4

Patch Set 4 : Remove wrapper function #

Unified diffs Side-by-side diffs Delta from patch set Stats (+130 lines, -116 lines) Patch
M chrome/browser/resources/md_history/app.html View 1 2 2 chunks +7 lines, -7 lines 0 comments Download
M chrome/browser/resources/md_history/app.crisper.js View 1 2 3 2 chunks +4 lines, -4 lines 0 comments Download
M chrome/browser/resources/md_history/app.vulcanized.html View 1 2 4 chunks +5 lines, -5 lines 0 comments Download
M chrome/browser/resources/md_history/history_toolbar.html View 1 2 1 chunk +2 lines, -1 line 0 comments Download
M chrome/browser/resources/md_history/history_toolbar.js View 1 2 4 chunks +23 lines, -13 lines 0 comments Download
M chrome/browser/resources/md_history/list_container.html View 1 2 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/md_history/list_container.js View 2 chunks +2 lines, -8 lines 0 comments Download
M chrome/browser/resources/md_history/query_manager.js View 1 2 3 3 chunks +63 lines, -31 lines 0 comments Download
M chrome/browser/resources/md_history/router.js View 2 chunks +4 lines, -27 lines 0 comments Download
M chrome/test/data/webui/md_history/history_grouped_list_test.js View 1 2 6 chunks +9 lines, -9 lines 0 comments Download
M chrome/test/data/webui/md_history/history_list_test.js View 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/test/data/webui/md_history/history_metrics_test.js View 2 chunks +3 lines, -3 lines 0 comments Download
M chrome/test/data/webui/md_history/history_routing_test.js View 1 chunk +1 line, -1 line 0 comments Download
M chrome/test/data/webui/md_history/history_toolbar_test.js View 1 chunk +1 line, -1 line 0 comments Download
M chrome/test/data/webui/md_history/test_util.js View 1 2 1 chunk +3 lines, -3 lines 0 comments Download

Messages

Total messages: 26 (19 generated)
tsergeant
Part two!
3 years, 11 months ago (2017-01-18 06:22:15 UTC) #8
calamity
I am a fan of this CL. lgtm. https://codereview.chromium.org/2643533003/diff/40001/chrome/browser/resources/md_history/history_toolbar.js File chrome/browser/resources/md_history/history_toolbar.js (right): https://codereview.chromium.org/2643533003/diff/40001/chrome/browser/resources/md_history/history_toolbar.js#newcode159 chrome/browser/resources/md_history/history_toolbar.js:159: 'change-query', ...
3 years, 11 months ago (2017-01-23 03:03:56 UTC) #13
tsergeant
https://codereview.chromium.org/2643533003/diff/40001/chrome/browser/resources/md_history/history_toolbar.js File chrome/browser/resources/md_history/history_toolbar.js (right): https://codereview.chromium.org/2643533003/diff/40001/chrome/browser/resources/md_history/history_toolbar.js#newcode159 chrome/browser/resources/md_history/history_toolbar.js:159: 'change-query', {range: Number(e.detail.item.getAttribute('value'))}); On 2017/01/23 03:03:56, calamity wrote: > ...
3 years, 11 months ago (2017-01-23 04:18:27 UTC) #16
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/2643533003/60001
3 years, 11 months ago (2017-01-23 05:02:59 UTC) #19
commit-bot: I haz the power
Try jobs failed on following builders: linux_chromium_rel_ng on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_rel_ng/builds/375752)
3 years, 11 months ago (2017-01-23 06:46:06 UTC) #21
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/2643533003/60001
3 years, 11 months ago (2017-01-23 21:41:53 UTC) #23
commit-bot: I haz the power
3 years, 11 months ago (2017-01-23 22:56:59 UTC) #26
Message was sent while issue was closed.
Committed patchset #4 (id:60001) as
https://chromium.googlesource.com/chromium/src/+/b82ab87dd4f38c3c7ca5d6d2e8e3...

Powered by Google App Engine
This is Rietveld 408576698