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

Issue 2280853002: Slightly nicer icon.js APIs. (Closed)

Created:
4 years, 3 months ago by Peter Kasting
Modified:
4 years, 3 months ago
CC:
chromium-reviews, dbeam+watch-options_chromium.org, extensions-reviews_chromium.org, michaelpg+watch-options_chromium.org, dbeam+watch-elements_chromium.org, vabr+watchlistpasswordmanager_chromium.org, michaelpg+watch-md-settings_chromium.org, tfarina, Patrick Dubroy, michaelpg+watch-md-ui_chromium.org, dbeam+watch-history_chromium.org, noyau+watch_chromium.org, arv+watch_chromium.org, oshima+watch_chromium.org, chromium-apps-reviews_chromium.org, pam+watch_chromium.org, gcasto+watchlist_chromium.org, michaelpg+watch-elements_chromium.org, stevenjb+watch-md-settings_chromium.org, dbeam+watch-settings_chromium.org, sdefresne+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Slightly nicer icon.js APIs. Eliminate getSupportedScaleFactors() from the publicly-exposed list. The lone external caller of this is in iOS-specific code where just using window.devicePixelRatio directly is currently equivalent. Arguably, if it weren't necessarily equivalent, the calling code that unconditionally used the 0th returned element would have been wrong anyway. getProfileAvatarIcon() isn't really profile-avatar-specific; it's general fixup for any URL that could be a chrome://theme/ URL, and I want to use it outside profile avatars. Rename to the more generic GetImage(). (I couldn't think of a more specific name that was any good.) Rename getFaviconImageSet() to getFavicon(), partly to be more parallel with the above, partly because calling out ImageSet didn't seem to make the callers clearer, just more verbose. BUG=none TEST=none CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:closure_compilation TBR=dbeam Committed: https://crrev.com/574fb00df48b99dde0ccc1a81447416e730647d6 Cr-Commit-Position: refs/heads/master@{#416370}

Patch Set 1 #

Total comments: 3
Unified diffs Side-by-side diffs Delta from patch set Stats (+50 lines, -59 lines) Patch
M chrome/browser/resources/bookmark_manager/js/bmm/bookmark_list.js View 1 chunk +1 line, -2 lines 0 comments Download
M chrome/browser/resources/history/history.js View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/history/other_devices.js View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/md_history/grouped_list.js View 1 chunk +1 line, -2 lines 0 comments Download
M chrome/browser/resources/md_history/history_item.js View 1 chunk +1 line, -2 lines 0 comments Download
M chrome/browser/resources/md_history/synced_device_card.js View 1 chunk +1 line, -2 lines 0 comments Download
M chrome/browser/resources/options/browser_options_profile_list.js View 1 chunk +1 line, -2 lines 0 comments Download
M chrome/browser/resources/options/browser_options_startup_page_list.js View 1 chunk +1 line, -2 lines 0 comments Download
M chrome/browser/resources/options/home_page_overlay.js View 1 chunk +1 line, -2 lines 0 comments Download
M chrome/browser/resources/options/manage_profile_overlay.js View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/options/password_manager_list.js View 1 chunk +1 line, -2 lines 0 comments Download
M chrome/browser/resources/options/profiles_icon_grid.js View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/options/search_engine_manager_engine_list.js View 1 chunk +3 lines, -3 lines 0 comments Download
M chrome/browser/resources/options/supervised_user_list.js View 1 chunk +1 line, -2 lines 0 comments Download
M chrome/browser/resources/settings/on_startup_page/startup_url_entry.js View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/settings/people_page/people_page.js View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/settings/search_engines_page/omnibox_extension_entry.js View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/settings/search_engines_page/search_engine_entry.js View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/settings/site_settings/site_settings_behavior.js View 1 chunk +1 line, -1 line 0 comments Download
M chrome/test/data/webui/icon_test.html View 3 chunks +4 lines, -4 lines 0 comments Download
M ios/chrome/app/resources/history/history.js View 1 chunk +1 line, -1 line 0 comments Download
M ios/chrome/app/resources/history/other_devices.js View 1 chunk +1 line, -1 line 0 comments Download
M ios/web/webui/resources/web_ui_favicons.js View 1 chunk +1 line, -1 line 2 comments Download
M ui/webui/resources/cr_elements/cr_profile_avatar_selector/cr_profile_avatar_selector.js View 1 chunk +1 line, -1 line 0 comments Download
M ui/webui/resources/js/icon.js View 5 chunks +21 lines, -21 lines 1 comment Download

Messages

Total messages: 28 (15 generated)
Peter Kasting
jyquinn: ios/chrome/app/resources/history/ OWNERS eugenebut: ios/web/ OWNERS dpapad: rest
4 years, 3 months ago (2016-08-26 06:59:59 UTC) #6
Eugene But (OOO till 7-30)
ios/web lgtm I tested window.devicePixelRatio on iOS9 Simulator and it return 2 for iPhone5S and ...
4 years, 3 months ago (2016-08-26 13:03:33 UTC) #9
Jackie Quinn
On 2016/08/26 13:03:33, Eugene But wrote: > ios/web lgtm > > I tested window.devicePixelRatio on ...
4 years, 3 months ago (2016-08-29 18:15:58 UTC) #10
Peter Kasting
ping dpapad
4 years, 3 months ago (2016-09-01 22:13:52 UTC) #11
Peter Kasting
Thanks for letting me know! Changing reviewer to michaelpg.
4 years, 3 months ago (2016-09-01 22:37:06 UTC) #13
michaelpg
nice! lgtm https://codereview.chromium.org/2280853002/diff/1/ios/web/webui/resources/web_ui_favicons.js File ios/web/webui/resources/web_ui_favicons.js (right): https://codereview.chromium.org/2280853002/diff/1/ios/web/webui/resources/web_ui_favicons.js#newcode13 ios/web/webui/resources/web_ui_favicons.js:13: goog.provide('__crWeb.webUIFavicons'); unfamiliar with ios and goog/Closure, so ...
4 years, 3 months ago (2016-09-02 20:00:38 UTC) #14
Peter Kasting
https://codereview.chromium.org/2280853002/diff/1/ios/web/webui/resources/web_ui_favicons.js File ios/web/webui/resources/web_ui_favicons.js (right): https://codereview.chromium.org/2280853002/diff/1/ios/web/webui/resources/web_ui_favicons.js#newcode13 ios/web/webui/resources/web_ui_favicons.js:13: goog.provide('__crWeb.webUIFavicons'); (For posterity, we discussed this offline and concluded ...
4 years, 3 months ago (2016-09-02 20:21:42 UTC) #15
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/2280853002/1
4 years, 3 months ago (2016-09-02 20:22:14 UTC) #17
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/252393)
4 years, 3 months ago (2016-09-02 20:32:51 UTC) #19
Peter Kasting
TBR=dbeam for mechanical changes in chrome/browser/resources/{history,options}/
4 years, 3 months ago (2016-09-02 20:37:08 UTC) #22
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/2280853002/1
4 years, 3 months ago (2016-09-02 20:37:46 UTC) #24
commit-bot: I haz the power
Committed patchset #1 (id:1)
4 years, 3 months ago (2016-09-02 22:36:14 UTC) #26
commit-bot: I haz the power
4 years, 3 months ago (2016-09-02 22:37:43 UTC) #28
Message was sent while issue was closed.
Patchset 1 (id:??) landed as
https://crrev.com/574fb00df48b99dde0ccc1a81447416e730647d6
Cr-Commit-Position: refs/heads/master@{#416370}

Powered by Google App Engine
This is Rietveld 408576698