Summary: | Use is<>() / downcast<>() for CachedResource subclasses | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Chris Dumez <cdumez> | ||||||
Component: | Page Loading | Assignee: | Chris Dumez <cdumez> | ||||||
Status: | RESOLVED FIXED | ||||||||
Severity: | Normal | CC: | benjamin, commit-queue, darin, japhet, kling, rniwa | ||||||
Priority: | P2 | ||||||||
Version: | 528+ (Nightly build) | ||||||||
Hardware: | Unspecified | ||||||||
OS: | Unspecified | ||||||||
Bug Depends on: | 137056 | ||||||||
Bug Blocks: | |||||||||
Attachments: |
|
Description
Chris Dumez
2014-10-04 22:48:02 PDT
Created attachment 239293 [details]
Patch
Comment on attachment 239293 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=239293&action=review > Source/WebCore/loader/cache/CachedResourceLoader.cpp:708 > + CachedImage& image = downcast<CachedImage>(*resource); > + image.load(this, defaultCachedResourceOptions()); Darin would probably prefer this on one line. Personally I like the named temporary here. Your call. > Source/WebKit/mac/Misc/WebCache.mm:205 > if (!cachedResource || !cachedResource->isImage()) Why keep this? Comment on attachment 239293 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=239293&action=review >> Source/WebCore/loader/cache/CachedResourceLoader.cpp:708 >> + image.load(this, defaultCachedResourceOptions()); > > Darin would probably prefer this on one line. Personally I like the named temporary here. > > Your call. Will drop the variable. >> Source/WebKit/mac/Misc/WebCache.mm:205 >> if (!cachedResource || !cachedResource->isImage()) > > Why keep this? I missed it, will use is<>() Created attachment 239304 [details]
Patch
Comment on attachment 239304 [details] Patch Clearing flags on attachment: 239304 Committed r174333: <http://trac.webkit.org/changeset/174333> All reviewed patches have been landed. Closing bug. |