Commit 7e5b0e6c authored by Gayane Petrosyan's avatar Gayane Petrosyan Committed by Commit Bot

[Themes] GenerateMissingNtpColors should be called after theme images are prepared.

It will still hit some DCHECKS when trying to decode jpg.

Bug: 991182
Change-Id: Ia899c85378992dd3b14bbf722499069b011d00e7
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1742783Reviewed-by: default avatarPeter Kotwicz <pkotwicz@chromium.org>
Commit-Queue: Gayane Petrosyan <gayane@chromium.org>
Cr-Commit-Position: refs/heads/master@{#685368}
parent 34dbc982
...@@ -1009,9 +1009,6 @@ void BrowserThemePack::AdjustThemePack() { ...@@ -1009,9 +1009,6 @@ void BrowserThemePack::AdjustThemePack() {
// with the frame/tab behind them. // with the frame/tab behind them.
GenerateMissingTextColors(); GenerateMissingTextColors();
// Generates missing NTP related colors.
GenerateMissingNtpColors();
// Make sure the |images_on_file_thread_| has bitmaps for supported // Make sure the |images_on_file_thread_| has bitmaps for supported
// scale factors before passing to FILE thread. // scale factors before passing to FILE thread.
images_on_file_thread_ = images_; images_on_file_thread_ = images_;
...@@ -1038,6 +1035,10 @@ void BrowserThemePack::AdjustThemePack() { ...@@ -1038,6 +1035,10 @@ void BrowserThemePack::AdjustThemePack() {
for (size_t i = 0; i < base::size(kPreloadIDs); ++i) { for (size_t i = 0; i < base::size(kPreloadIDs); ++i) {
GenerateRawImageForAllSupportedScales(kPreloadIDs[i]); GenerateRawImageForAllSupportedScales(kPreloadIDs[i]);
} }
// Generates missing NTP related colors. Should be called after theme images
// are prepared.
GenerateMissingNtpColors();
} }
void BrowserThemePack::InitEmptyPack() { void BrowserThemePack::InitEmptyPack() {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment