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

Issue 667933003: Ensure existence of queried elements. (Closed)

Created:
6 years, 2 months ago by fukino
Modified:
6 years, 2 months ago
Reviewers:
hirono, Dan Beam
CC:
chromium-reviews, vitalyp+closure_chromium.org, rginda+watch_chromium.org, mtomasz+watch_chromium.org, yoshiki+watch_chromium.org, dbeam+watch-closure_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Project:
chromium
Visibility:
Public.

Description

Ensure existence of queried elements. Added util.querySelector(), which throws error if the query doesn't find an element. Using it and assert(), ensure the existence of elements which are queried in initialization process of FileManager. Some trivial fixes for type-check errors are also included. BUG=406995 TEST=run browser_tests Committed: https://crrev.com/a81e67c4da7b516aba7ed8202a51a948521a3cdf Cr-Commit-Position: refs/heads/master@{#300646}

Patch Set 1 #

Total comments: 2

Patch Set 2 : Add and use queryRequiredElement. #

Total comments: 12

Patch Set 3 : Make some parameters non-nullable. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+98 lines, -75 lines) Patch
M ui/file_manager/file_manager/foreground/js/directory_model.js View 1 chunk +2 lines, -1 line 0 comments Download
M ui/file_manager/file_manager/foreground/js/file_manager.js View 1 2 6 chunks +65 lines, -61 lines 0 comments Download
M ui/file_manager/file_manager/foreground/js/ui/commandbutton.js View 1 chunk +2 lines, -1 line 0 comments Download
M ui/file_manager/file_manager/foreground/js/ui/directory_tree.js View 2 chunks +2 lines, -2 lines 0 comments Download
M ui/file_manager/file_manager/foreground/js/ui/file_grid.js View 1 2 2 chunks +2 lines, -1 line 0 comments Download
M ui/file_manager/file_manager/foreground/js/ui/file_table.js View 1 2 2 chunks +3 lines, -2 lines 0 comments Download
M ui/file_manager/file_manager/foreground/js/ui/location_line.js View 1 2 1 chunk +2 lines, -2 lines 0 comments Download
M ui/file_manager/file_manager/foreground/js/ui/progress_center_panel.js View 1 2 2 chunks +5 lines, -5 lines 0 comments Download
M ui/webui/resources/js/util.js View 1 1 chunk +15 lines, -0 lines 0 comments Download

Messages

Total messages: 13 (3 generated)
fukino
PTAL the CL? Thank you!
6 years, 2 months ago (2014-10-21 10:36:24 UTC) #2
Dan Beam
https://codereview.chromium.org/667933003/diff/1/ui/file_manager/file_manager/common/js/util.js File ui/file_manager/file_manager/common/js/util.js (right): https://codereview.chromium.org/667933003/diff/1/ui/file_manager/file_manager/common/js/util.js#newcode1027 ui/file_manager/file_manager/common/js/util.js:1027: throw new Error('Element not found by ' + selector); ...
6 years, 2 months ago (2014-10-21 17:22:59 UTC) #3
fukino
https://codereview.chromium.org/667933003/diff/1/ui/file_manager/file_manager/common/js/util.js File ui/file_manager/file_manager/common/js/util.js (right): https://codereview.chromium.org/667933003/diff/1/ui/file_manager/file_manager/common/js/util.js#newcode1027 ui/file_manager/file_manager/common/js/util.js:1027: throw new Error('Element not found by ' + selector); ...
6 years, 2 months ago (2014-10-22 05:41:01 UTC) #5
Dan Beam
util.js lgtm
6 years, 2 months ago (2014-10-22 05:48:53 UTC) #6
hirono
https://codereview.chromium.org/667933003/diff/20001/ui/file_manager/file_manager/foreground/js/ui/file_grid.js File ui/file_manager/file_manager/foreground/js/ui/file_grid.js (right): https://codereview.chromium.org/667933003/diff/20001/ui/file_manager/file_manager/foreground/js/ui/file_grid.js#newcode35 ui/file_manager/file_manager/foreground/js/ui/file_grid.js:35: * @param {Element} self The grid to decorate. !Element ...
6 years, 2 months ago (2014-10-22 06:14:49 UTC) #7
fukino
https://codereview.chromium.org/667933003/diff/20001/ui/file_manager/file_manager/foreground/js/ui/file_grid.js File ui/file_manager/file_manager/foreground/js/ui/file_grid.js (right): https://codereview.chromium.org/667933003/diff/20001/ui/file_manager/file_manager/foreground/js/ui/file_grid.js#newcode35 ui/file_manager/file_manager/foreground/js/ui/file_grid.js:35: * @param {Element} self The grid to decorate. On ...
6 years, 2 months ago (2014-10-22 06:25:43 UTC) #8
hirono
lgtm! Thanks!
6 years, 2 months ago (2014-10-22 06:29:31 UTC) #9
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/667933003/40001
6 years, 2 months ago (2014-10-22 06:30:57 UTC) #11
commit-bot: I haz the power
Committed patchset #3 (id:40001)
6 years, 2 months ago (2014-10-22 07:22:49 UTC) #12
commit-bot: I haz the power
6 years, 2 months ago (2014-10-22 07:23:53 UTC) #13
Message was sent while issue was closed.
Patchset 3 (id:??) landed as
https://crrev.com/a81e67c4da7b516aba7ed8202a51a948521a3cdf
Cr-Commit-Position: refs/heads/master@{#300646}

Powered by Google App Engine
This is Rietveld 408576698