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

Issue 2877583002: Refactor ImageLoader::UpdateFromElement(kUpdateForcedReload) (Closed)

Created:
3 years, 7 months ago by hiroshige
Modified:
3 years, 7 months ago
CC:
chromium-reviews, blink-reviews
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

Refactor ImageLoader::UpdateFromElement(kUpdateForcedReload) Previously, there were two cases when |loading_image_document_| is true: Case 1. Initial ImageDocument loading. |image_| is not associated with ResourceLoader, and the response/data are supplied by ImageDocument instead. Case 2. Reloading. |image_| is created normally via ResourceFetcher and thus is associated with ResourceLoader. This is same as non-ImageDocument image loading. This CL clears |loading_image_document_| and |image_resource_for_image_document_| in the second case, to - Make |image_| always under control of ImageDocument if |loading_image_document_| is true. - Avoid |image_| from being controlled by both of ImageDocument and ResourceLoader when |loading_image_document_| is false. - Simplify the invariants and make the assertion in [1] hold. [1] https://codereview.chromium.org/2859383002/ BUG=624697, 719759, 485295 Review-Url: https://codereview.chromium.org/2877583002 Cr-Commit-Position: refs/heads/master@{#471455} Committed: https://chromium.googlesource.com/chromium/src/+/e263cd1373b7f330054bc1b252c19abf1ac9ba09

Patch Set 1 #

Patch Set 2 : Rebase #

Patch Set 3 : Rebase #

Patch Set 4 : Rebase #

Total comments: 2

Patch Set 5 : Rebase #

Unified diffs Side-by-side diffs Delta from patch set Stats (+23 lines, -4 lines) Patch
M third_party/WebKit/Source/core/loader/ImageLoader.h View 1 2 chunks +13 lines, -3 lines 0 comments Download
M third_party/WebKit/Source/core/loader/ImageLoader.cpp View 1 1 chunk +10 lines, -1 line 0 comments Download

Depends on Patchset:

Dependent Patchsets:

Messages

Total messages: 30 (23 generated)
hiroshige
PTAL. (bot failures look irrelevant)
3 years, 7 months ago (2017-05-11 16:12:06 UTC) #13
kinuko
lgtm https://codereview.chromium.org/2877583002/diff/60001/third_party/WebKit/Source/core/loader/ImageLoader.cpp File third_party/WebKit/Source/core/loader/ImageLoader.cpp (right): https://codereview.chromium.org/2877583002/diff/60001/third_party/WebKit/Source/core/loader/ImageLoader.cpp#newcode429 third_party/WebKit/Source/core/loader/ImageLoader.cpp:429: // Prepares for reloading ImageDocument. nit: I think ...
3 years, 7 months ago (2017-05-12 08:28:34 UTC) #18
kinuko
lgtm
3 years, 7 months ago (2017-05-12 08:28:34 UTC) #19
yhirano
lgtm
3 years, 7 months ago (2017-05-12 10:38:11 UTC) #20
kouhei (in TOK)
lgtm
3 years, 7 months ago (2017-05-12 13:05:52 UTC) #21
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/2877583002/80001
3 years, 7 months ago (2017-05-12 20:00:50 UTC) #27
commit-bot: I haz the power
3 years, 7 months ago (2017-05-12 21:52:38 UTC) #30
Message was sent while issue was closed.
Committed patchset #5 (id:80001) as
https://chromium.googlesource.com/chromium/src/+/e263cd1373b7f330054bc1b252c1...

Powered by Google App Engine
This is Rietveld 408576698