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

Issue 2957153003: MD Settings: remove unsupported routes from guest-mode. (Closed)

Created:
3 years, 5 months ago by scottchen
Modified:
3 years, 5 months ago
Reviewers:
stevenjb, dpapad
CC:
arv+watch_chromium.org, chromium-reviews, michaelpg+watch-md-settings_chromium.org, michaelpg+watch-md-ui_chromium.org, stevenjb+watch-md-settings_chromium.org
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

MD Settings: remove unsupported routes from guest-mode. Currently in guest mode, there are valid routes that are not visible, which leads to odd behavior when directly visiting those routes. This CL aims to prevent those kinds of routes from being added into settings.Route during initialization. BUG=733511 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:closure_compilation Review-Url: https://codereview.chromium.org/2957153003 Cr-Commit-Position: refs/heads/master@{#485353} Committed: https://chromium.googlesource.com/chromium/src/+/c31781b0a4f7137b4b51919086092404594bce24

Patch Set 1 #

Patch Set 2 : merge #

Patch Set 3 : fix compile error #

Total comments: 2

Patch Set 4 : move import into this CL #

Patch Set 5 : DO NOT MERGE: refactor routing code (todo: change actual usage) #

Patch Set 6 : DO NOT MERGE: add page visibility test. (todo: still need to /settings.Route/settings.routes) #

Patch Set 7 : DO NOT MERGE: convert some code to new structure (todo: safeguard settings.routes.BLAH.dereference … #

Patch Set 8 : fix compiler, test, code #

Patch Set 9 : safeguard all settings.routes.[ROUTE]. dereferencing #

Total comments: 19

Patch Set 10 : feedback #

Patch Set 11 : fix tests #

Total comments: 2

Patch Set 12 : feedback #

Patch Set 13 : fix compiler error #

Total comments: 2

Patch Set 14 : merge #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1127 lines, -831 lines) Patch
M chrome/browser/resources/chromeos/compiled_resources2.gyp View 1 2 3 4 5 2 chunks +2 lines, -0 lines 0 comments Download
M chrome/browser/resources/help/compiled_resources2.gyp View 1 2 3 4 5 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/resources/options/compiled_resources2.gyp View 1 2 3 4 5 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/resources/settings/a11y_page/a11y_page.js View 1 2 3 4 5 6 7 8 2 chunks +6 lines, -4 lines 0 comments Download
M chrome/browser/resources/settings/a11y_page/manage_a11y_page.js View 1 2 3 4 5 6 1 chunk +4 lines, -4 lines 0 comments Download
M chrome/browser/resources/settings/about_page/about_page.js View 1 2 3 4 5 6 7 8 2 chunks +6 lines, -4 lines 0 comments Download
M chrome/browser/resources/settings/android_apps_page/android_apps_page.js View 1 2 3 4 5 6 7 8 9 2 chunks +6 lines, -4 lines 0 comments Download
M chrome/browser/resources/settings/appearance_page/appearance_page.js View 1 2 3 4 5 6 7 8 2 chunks +6 lines, -4 lines 0 comments Download
M chrome/browser/resources/settings/basic_page/basic_page.js View 1 2 3 4 5 6 3 chunks +6 lines, -4 lines 0 comments Download
M chrome/browser/resources/settings/bluetooth_page/bluetooth_page.js View 1 2 3 4 5 6 7 8 9 2 chunks +6 lines, -4 lines 0 comments Download
M chrome/browser/resources/settings/bluetooth_page/bluetooth_subpage.js View 1 2 3 4 5 6 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/settings/compiled_resources2.gyp View 1 2 3 4 5 6 7 8 9 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/resources/settings/device_page/device_page.js View 1 2 3 4 5 6 7 8 8 chunks +20 lines, -14 lines 0 comments Download
M chrome/browser/resources/settings/device_page/keyboard.js View 1 2 3 4 5 6 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/settings/device_page/storage.js View 1 2 3 4 5 6 4 chunks +4 lines, -4 lines 0 comments Download
M chrome/browser/resources/settings/internet_page/internet_config.js View 1 2 3 4 5 6 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/browser/resources/settings/internet_page/internet_detail_page.js View 1 2 3 4 5 6 7 8 9 10 11 12 13 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/browser/resources/settings/internet_page/internet_page.js View 1 2 3 4 5 6 7 8 9 10 11 12 13 7 chunks +11 lines, -10 lines 0 comments Download
M chrome/browser/resources/settings/internet_page/internet_subpage.js View 1 2 3 4 5 6 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/settings/internet_page/network_proxy.js View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/settings/languages_page/edit_dictionary_page.js View 1 2 3 4 5 6 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/settings/languages_page/languages_page.js View 1 2 3 4 5 6 7 8 3 chunks +12 lines, -8 lines 0 comments Download
M chrome/browser/resources/settings/on_startup_page/on_startup_page.js View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/settings/page_visibility.js View 1 2 3 4 5 6 7 2 chunks +2 lines, -3 lines 0 comments Download
M chrome/browser/resources/settings/passwords_and_forms_page/passwords_and_forms_page.js View 1 2 3 4 5 6 7 8 3 chunks +12 lines, -7 lines 0 comments Download
M chrome/browser/resources/settings/passwords_and_forms_page/passwords_section.js View 1 2 3 4 5 6 7 8 9 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/settings/people_page/change_picture.js View 1 2 3 4 5 6 7 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/settings/people_page/fingerprint_list.js View 1 2 3 4 5 6 2 chunks +3 lines, -3 lines 0 comments Download
M chrome/browser/resources/settings/people_page/lock_screen.js View 1 2 3 4 5 6 4 chunks +5 lines, -5 lines 0 comments Download
M chrome/browser/resources/settings/people_page/manage_profile.js View 1 2 3 4 5 6 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/settings/people_page/people_page.js View 1 2 3 4 5 6 7 8 9 chunks +35 lines, -26 lines 0 comments Download
M chrome/browser/resources/settings/people_page/sync_page.js View 1 2 3 4 5 6 7 8 9 3 chunks +6 lines, -6 lines 0 comments Download
M chrome/browser/resources/settings/people_page/user_list.js View 1 2 3 4 5 6 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/settings/printing_page/printing_page.js View 1 2 3 4 5 6 7 8 2 chunks +13 lines, -8 lines 0 comments Download
M chrome/browser/resources/settings/privacy_page/privacy_page.js View 1 2 3 4 5 6 7 8 9 4 chunks +14 lines, -10 lines 0 comments Download
M chrome/browser/resources/settings/reset_page/reset_page.js View 1 2 3 4 5 6 1 chunk +3 lines, -3 lines 0 comments Download
M chrome/browser/resources/settings/reset_page/reset_profile_banner.js View 1 2 3 4 5 6 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/settings/reset_page/reset_profile_dialog.js View 1 2 3 4 5 6 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/settings/route.html View 1 2 3 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/resources/settings/route.js View 1 2 3 4 5 6 7 8 9 10 11 12 13 6 chunks +506 lines, -324 lines 0 comments Download
M chrome/browser/resources/settings/search_engines_page/search_engines_page.js View 1 2 3 4 5 6 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/settings/search_page/search_page.js View 1 2 3 4 5 6 7 8 9 2 chunks +6 lines, -3 lines 0 comments Download
M chrome/browser/resources/settings/settings_main/settings_main.js View 1 2 3 4 5 6 3 chunks +6 lines, -5 lines 0 comments Download
M chrome/browser/resources/settings/settings_page/main_page_behavior.js View 1 2 3 4 5 6 4 chunks +7 lines, -7 lines 0 comments Download
M chrome/browser/resources/settings/settings_page/settings_animated_pages.js View 1 2 3 4 5 6 7 8 1 chunk +10 lines, -5 lines 0 comments Download
M chrome/browser/resources/settings/settings_ui/settings_ui.js View 1 2 3 4 5 6 7 8 9 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/settings/site_settings/all_sites.js View 1 2 3 4 5 6 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/settings/site_settings/site_data.js View 1 2 3 4 5 6 7 8 2 chunks +6 lines, -4 lines 0 comments Download
M chrome/browser/resources/settings/site_settings/site_data_details_subpage.js View 1 2 3 4 5 6 1 chunk +2 lines, -1 line 0 comments Download
M chrome/browser/resources/settings/site_settings/site_list.js View 1 2 3 4 5 6 7 8 9 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/settings/site_settings_page/site_settings_page.js View 1 2 3 4 5 6 7 8 9 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/test/data/webui/settings/about_page_tests.js View 1 2 3 4 5 6 7 8 9 10 1 chunk +1 line, -1 line 0 comments Download
M chrome/test/data/webui/settings/android_apps_page_test.js View 1 2 3 4 5 6 7 8 9 10 11 12 13 2 chunks +4 lines, -5 lines 0 comments Download
M chrome/test/data/webui/settings/basic_page_browsertest.js View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +10 lines, -9 lines 0 comments Download
M chrome/test/data/webui/settings/cr_settings_browsertest.js View 1 2 3 4 5 6 7 8 9 10 2 chunks +5 lines, -5 lines 0 comments Download
M chrome/test/data/webui/settings/device_page_tests.js View 1 2 3 4 5 6 7 8 9 10 11 12 7 chunks +216 lines, -194 lines 0 comments Download
M chrome/test/data/webui/settings/people_page_change_picture_test.js View 1 2 3 4 5 6 7 8 9 10 3 chunks +4 lines, -4 lines 0 comments Download
M chrome/test/data/webui/settings/people_page_manage_profile_test.js View 1 2 3 4 5 6 7 8 9 10 4 chunks +4 lines, -4 lines 0 comments Download
M chrome/test/data/webui/settings/people_page_sync_page_test.js View 1 2 3 4 5 6 7 8 9 10 3 chunks +4 lines, -4 lines 0 comments Download
M chrome/test/data/webui/settings/people_page_test.js View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +25 lines, -20 lines 0 comments Download
M chrome/test/data/webui/settings/reset_page_test.js View 1 2 3 4 5 6 7 8 9 10 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/test/data/webui/settings/reset_profile_banner_test.js View 1 2 3 4 5 6 7 8 9 10 1 chunk +2 lines, -2 lines 0 comments Download
M chrome/test/data/webui/settings/route_tests.js View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +70 lines, -46 lines 0 comments Download
M chrome/test/data/webui/settings/settings_animated_pages_test.js View 1 2 3 4 5 6 7 8 9 10 2 chunks +5 lines, -5 lines 0 comments Download
M chrome/test/data/webui/settings/settings_main_test.js View 1 2 3 4 5 6 7 8 9 10 6 chunks +10 lines, -10 lines 0 comments Download
M chrome/test/data/webui/settings/settings_menu_test.js View 1 2 3 4 5 6 7 8 9 10 4 chunks +4 lines, -4 lines 0 comments Download
M chrome/test/data/webui/settings/settings_subpage_test.js View 1 2 3 4 5 6 7 8 9 10 2 chunks +7 lines, -7 lines 0 comments Download
M chrome/test/data/webui/settings/settings_ui_browsertest.js View 1 2 3 4 5 6 7 8 9 10 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/test/data/webui/settings/site_data_details_subpage_tests.js View 1 2 3 4 5 6 7 8 9 10 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 45 (31 generated)
scottchen
3 years, 5 months ago (2017-06-28 01:10:34 UTC) #5
dpapad
https://codereview.chromium.org/2957153003/diff/40001/chrome/browser/resources/settings/route.js File chrome/browser/resources/settings/route.js (right): https://codereview.chromium.org/2957153003/diff/40001/chrome/browser/resources/settings/route.js#newcode118 chrome/browser/resources/settings/route.js:118: if (settings.pageVisibility.appearance !== false) { Can we add some ...
3 years, 5 months ago (2017-06-29 00:57:32 UTC) #12
scottchen
Based on offline discussions, I refactored how routes were setup to have better test-ability and ...
3 years, 5 months ago (2017-07-06 01:02:24 UTC) #16
dpapad
Mostly nits. https://codereview.chromium.org/2957153003/diff/180001/chrome/browser/resources/settings/route.js File chrome/browser/resources/settings/route.js (right): https://codereview.chromium.org/2957153003/diff/180001/chrome/browser/resources/settings/route.js#newcode6 chrome/browser/resources/settings/route.js:6: * Specifies available routes in settings. Nit: ...
3 years, 5 months ago (2017-07-06 02:07:06 UTC) #19
scottchen
https://codereview.chromium.org/2957153003/diff/180001/chrome/browser/resources/settings/route.js File chrome/browser/resources/settings/route.js (right): https://codereview.chromium.org/2957153003/diff/180001/chrome/browser/resources/settings/route.js#newcode6 chrome/browser/resources/settings/route.js:6: * Specifies available routes in settings. On 2017/07/06 02:07:06, ...
3 years, 5 months ago (2017-07-07 20:58:45 UTC) #21
dpapad
LGTM https://codereview.chromium.org/2957153003/diff/180001/chrome/browser/resources/settings/route.js File chrome/browser/resources/settings/route.js (right): https://codereview.chromium.org/2957153003/diff/180001/chrome/browser/resources/settings/route.js#newcode187 chrome/browser/resources/settings/route.js:187: this.routes_ = {}; On 2017/07/07 at 20:58:44, scottchen ...
3 years, 5 months ago (2017-07-07 21:19:30 UTC) #23
scottchen
https://codereview.chromium.org/2957153003/diff/220001/chrome/test/data/webui/settings/route_tests.js File chrome/test/data/webui/settings/route_tests.js (right): https://codereview.chromium.org/2957153003/diff/220001/chrome/test/data/webui/settings/route_tests.js#newcode218 chrome/test/data/webui/settings/route_tests.js:218: var router = new settings.Router(); On 2017/07/07 21:19:30, dpapad ...
3 years, 5 months ago (2017-07-07 22:15:30 UTC) #27
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/2957153003/260001
3 years, 5 months ago (2017-07-08 00:06:18 UTC) #33
commit-bot: I haz the power
Try jobs failed on following builders: chromium_presubmit on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/chromium_presubmit/builds/483837)
3 years, 5 months ago (2017-07-08 00:19:00 UTC) #35
scottchen
+ stevenjb@, needs owner LG for "chrome/browser/resources/options/compiled_resources2.gyp".
3 years, 5 months ago (2017-07-10 17:49:47 UTC) #37
stevenjb
chromeos/compiled_resources2.gyp lgtm https://codereview.chromium.org/2957153003/diff/260001/chrome/browser/resources/settings/route.js File chrome/browser/resources/settings/route.js (right): https://codereview.chromium.org/2957153003/diff/260001/chrome/browser/resources/settings/route.js#newcode612 chrome/browser/resources/settings/route.js:612: Router: Router, // The class definition. tiny ...
3 years, 5 months ago (2017-07-10 18:01:25 UTC) #38
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/2957153003/280001
3 years, 5 months ago (2017-07-10 18:19:43 UTC) #41
commit-bot: I haz the power
Committed patchset #14 (id:280001) as https://chromium.googlesource.com/chromium/src/+/c31781b0a4f7137b4b51919086092404594bce24
3 years, 5 months ago (2017-07-10 19:53:00 UTC) #44
scottchen
3 years, 5 months ago (2017-07-10 20:54:36 UTC) #45
Message was sent while issue was closed.
https://codereview.chromium.org/2957153003/diff/260001/chrome/browser/resourc...
File chrome/browser/resources/settings/route.js (right):

https://codereview.chromium.org/2957153003/diff/260001/chrome/browser/resourc...
chrome/browser/resources/settings/route.js:612: Router: Router,          // The
class definition.
On 2017/07/10 18:01:25, stevenjb wrote:
> tiny nit: S/The class/Class/ for both of these since there is more than one
> class?

Acknowledged.

Powered by Google App Engine
This is Rietveld 408576698