-
Notifications
You must be signed in to change notification settings - Fork 878
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use component for NTP Background images on desktop #10690
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
simonhong
changed the title
WIP: Use component for NTP Background images
WIP: Use component for NTP Background images on desktop
Oct 26, 2021
simonhong
force-pushed
the
ntp_background_crx_desktop
branch
5 times, most recently
from
October 28, 2021 03:17
d784ec3
to
c23760a
Compare
RegisterPageView() wiil be no-op if NTP SI/BI is not ready to use.
Existing NTPBackgroundImagesSource is renamed to NTPSponsoredImagesSource and NTPBackgroundImagesSource is newly implemented for serving NTP BI images. With this change, WebUI will get every bg images via chrome://background-wallpaper/wallpaper-x.webp url. When NTP BI component is ready, bg image is loaded in the tab by NTP BI url such as brave://background-wallpaper/wallpaper-10.webp.
simonhong
force-pushed
the
ntp_background_crx_desktop
branch
2 times, most recently
from
October 28, 2021 04:00
f9bba8f
to
8ce4908
Compare
simonhong
force-pushed
the
ntp_background_crx_desktop
branch
2 times, most recently
from
October 28, 2021 05:39
e11dc7d
to
a89ae80
Compare
NewTab's state will have below two struct. * NewTab.BackgroundWallpaper * NewTab.BrandedWallpaper NTP will display spencer-moore_lake.avif till NTP BI component is ready like android does.
simonhong
force-pushed
the
ntp_background_crx_desktop
branch
from
October 28, 2021 05:55
a89ae80
to
1e8a13a
Compare
For reducing complexity, ViewCounterModel is resseted whenever Component is updated or related prefs are changed. But ViewCounterModel::count_to_branded_wallpaper_ is not changed to show first branded wallpaper at 2nd NTP loading.
simonhong
changed the title
WIP: Use component for NTP Background images on desktop
Use component for NTP Background images on desktop
Oct 28, 2021
wchen342
reviewed
Oct 28, 2021
fmarier
approved these changes
Oct 28, 2021
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
script/generate_licenses.py
changes look good to me.
wchen342
approved these changes
Oct 29, 2021
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
++
Merged because pylint failure is not related with this PR's change. |
simonhong
added a commit
that referenced
this pull request
Oct 31, 2021
f/u PR for github.com//pull/10690 CI missed this because generated buildflag header isn't deleted if wipeout workspace.
24 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Resolves brave/brave-browser#10278
Use component for ntp background images on desktop.
Submitter Checklist:
QA/Yes
orQA/No
;release-notes/include
orrelease-notes/exclude
;OS/...
) to the associated issuenpm run test -- brave_browser_tests
,npm run test -- brave_unit_tests
,npm run lint
,npm run gn_check
,npm run tslint
git rebase master
(if needed)Reviewer Checklist:
gn
After-merge Checklist:
changes has landed on
Test Plan:
NTP Background Images
is loaded in brave://componentsShow Sponsored Images
orShow Background Images
option and check BG images are shown properly based on changed option