Bug 109971

Summary: Hide MainResourceLoader from the outside world
Product: WebKit Reporter: Nate Chapin <japhet>
Component: WebCore Misc.Assignee: Nate Chapin <japhet>
Status: RESOLVED FIXED    
Severity: Normal CC: abarth, eric.carlson, esprehn+autocc, feature-media-reviews, gyuyoung.kim, jer.noble, mifenton, ojan.autocc, rakuco, rwlbuis, tonikitoo, webkit.review.bot
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 104969    
Attachments:
Description Flags
patch none

Nate Chapin
Reported 2013-02-15 14:12:21 PST
Currently, the class MainResourceLoader is accessible via DocumentLoader::mainResourceLoader(). As a part of merging MainResourceLoader into DocumentLoader, we need to do something with this function. Many of the uses of DocumentLoader::mainResourceLoader() would be satisfied by making it return the ResourceLoader that is loading the main resource, rather than the MainResourceLoader (see why we want to delete MainResourceLoader?) However, at least temporarily, PluginDocument and MediaDocument need to be able to access the main resource's CachedResource so that they can disable buffering in the cache layer, so we'll need to expose that, too. In addition, the class MainResourceLoader is exposed to the WebKit layer via FrameLoaderClient::convertMainResourceLoadToDownload. This should probably take a DocumentLoader* instead.
Attachments
patch (45.07 KB, patch)
2013-03-14 15:17 PDT, Nate Chapin
no flags
Nate Chapin
Comment 1 2013-03-14 15:17:24 PDT
Adam Barth
Comment 2 2013-03-15 10:33:20 PDT
Comment on attachment 193195 [details] patch View in context: https://bugs.webkit.org/attachment.cgi?id=193195&action=review > Source/WebCore/loader/DocumentLoader.cpp:126 > +ResourceLoader* DocumentLoader::mainResourceLoader() const > +{ > + return m_mainResourceLoader ? m_mainResourceLoader->loader() : 0; > +} Nate tells me this slight nuttiness is going to be short-lived.
Nate Chapin
Comment 3 2013-03-15 10:35:07 PDT
(In reply to comment #2) > (From update of attachment 193195 [details]) > View in context: https://bugs.webkit.org/attachment.cgi?id=193195&action=review > > > Source/WebCore/loader/DocumentLoader.cpp:126 > > +ResourceLoader* DocumentLoader::mainResourceLoader() const > > +{ > > + return m_mainResourceLoader ? m_mainResourceLoader->loader() : 0; > > +} > > Nate tells me this slight nuttiness is going to be short-lived. Yeah, sadly it has going to be there temporarily unless I did this merger as a 150KB monster patch. Hopefully a week or less, we'll see.
WebKit Review Bot
Comment 4 2013-03-15 10:47:25 PDT
Comment on attachment 193195 [details] patch Clearing flags on attachment: 193195 Committed r145914: <http://trac.webkit.org/changeset/145914>
WebKit Review Bot
Comment 5 2013-03-15 10:47:29 PDT
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.