Rubber stamped by Maciej.
authordarin <darin@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 8 Oct 2006 21:28:53 +0000 (21:28 +0000)
committerdarin <darin@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 8 Oct 2006 21:28:53 +0000 (21:28 +0000)
        - changed "document load state" to "document loader"

        * Loader/WebDocumentLoadState.h: Removed.
        * Loader/WebDocumentLoadState.m: Removed.
        * Loader/WebDocumentLoader.h: Added.
        * Loader/WebDocumentLoader.m: Added.
        (-[WebDocumentLoader setMainDocumentError:]):
        (-[WebDocumentLoader mainReceivedError:complete:]):
        (-[WebDocumentLoader finishedLoading]):
        (-[WebDocumentLoader commitLoadWithData:]):
        (-[WebDocumentLoader setupForReplaceByMIMEType:]):
        (-[WebDocumentLoader updateLoading]):
        (-[WebDocumentLoader setTitle:]):
        * Loader/WebFrameLoader.h:
        * Loader/WebFrameLoader.m:
        (-[WebFrameLoader dealloc]):
        (-[WebFrameLoader activeDocumentLoader]):
        (-[WebFrameLoader activeDataSource]):
        (-[WebFrameLoader addPlugInStreamLoader:]):
        (-[WebFrameLoader removePlugInStreamLoader:]):
        (-[WebFrameLoader addSubresourceLoader:]):
        (-[WebFrameLoader removeSubresourceLoader:]):
        (-[WebFrameLoader dataSource]):
        (-[WebFrameLoader setDocumentLoader:]):
        (-[WebFrameLoader documentLoader]):
        (-[WebFrameLoader policyDataSource]):
        (-[WebFrameLoader setPolicyDocumentLoader:]):
        (-[WebFrameLoader clearDataSource]):
        (-[WebFrameLoader provisionalDataSource]):
        (-[WebFrameLoader provisionalDocumentLoader]):
        (-[WebFrameLoader setProvisionalDocumentLoader:]):
        (-[WebFrameLoader _clearProvisionalDataSource]):
        (-[WebFrameLoader _setState:]):
        (-[WebFrameLoader clearProvisionalLoad]):
        (-[WebFrameLoader commitProvisionalLoad]):
        (-[WebFrameLoader stopLoading]):
        (-[WebFrameLoader startLoading]):
        (-[WebFrameLoader startProvisionalLoad:]):
        (-[WebFrameLoader setupForReplace]):
        (-[WebFrameLoader _didReceiveResponse:forResource:]):
        (-[WebFrameLoader _originalRequest]):
        (-[WebFrameLoader _receivedMainResourceError:complete:]):
        (-[WebFrameLoader _receivedData:]):
        (-[WebFrameLoader _setRequest:]):
        (-[WebFrameLoader _isStopping]):
        (-[WebFrameLoader _setupForReplaceByMIMEType:]):
        (-[WebFrameLoader _setResponse:]):
        (-[WebFrameLoader _mainReceivedError:complete:]):
        (-[WebFrameLoader _finishedLoading]):
        (-[WebFrameLoader _checkContentPolicyForMIMEType:andCall:withSelector:]):
        (-[WebFrameLoader _loadRequest:archive:]):
        (-[WebFrameLoader _loadRequest:triggeringAction:loadType:formState:]):
        (-[WebFrameLoader _reloadAllowingStaleDataWithOverrideEncoding:]):
        (-[WebFrameLoader reload]):
        (-[WebFrameLoader finishedLoadingDocument:]):
        (-[WebFrameLoader committedLoadWithDocumentLoader:data:]):
        (-[WebFrameLoader revertToProvisionalWithDocumentLoader:]):
        (-[WebFrameLoader documentLoader:setMainDocumentError:]):
        (-[WebFrameLoader documentLoader:mainReceivedCompleteError:]):
        (-[WebFrameLoader finalSetupForReplaceWithDocumentLoader:]):
        (-[WebFrameLoader willChangeTitleForDocument:]):
        (-[WebFrameLoader didChangeTitleForDocument:]):
        (-[WebFrameLoader checkNavigationPolicyForRequest:dataSource:formState:andCall:withSelector:]):
        (-[WebFrameLoader continueLoadRequestAfterNavigationPolicy:formState:]):
        (-[WebFrameLoader loadDataSource:withLoadType:formState:]):
        * Plugins/WebPluginController.m:
        (-[WebPluginController pluginView:receivedResponse:]):
        * WebCoreSupport/WebFrameBridge.m:
        (-[WebFrameBridge setTitle:]):
        (-[WebFrameBridge receivedData:textEncodingName:]):
        * WebKit.xcodeproj/project.pbxproj:
        * WebView/WebDataSource.m:
        (-[WebDataSourcePrivate dealloc]):
        (-[WebDataSource _mainDocumentError]):
        (-[WebDataSource _loadFromPageCache:]):
        (-[WebDataSource _bridge]):
        (-[WebDataSource _webView]):
        (-[WebDataSource _URLForHistory]):
        (-[WebDataSource _documentLoader]):
        (-[WebDataSource _initWithDocumentLoader:]):
        (-[WebDataSource initWithRequest:]):
        (-[WebDataSource dealloc]):
        (-[WebDataSource data]):
        (-[WebDataSource webFrame]):
        (-[WebDataSource initialRequest]):
        (-[WebDataSource request]):
        (-[WebDataSource response]):
        (-[WebDataSource textEncodingName]):
        (-[WebDataSource isLoading]):
        (-[WebDataSource unreachableURL]):
        (-[WebDataSource webArchive]):
        * WebView/WebDataSourceInternal.h:
        * WebView/WebDocumentLoadStateMac.h: Removed.
        * WebView/WebDocumentLoadStateMac.m: Removed.
        * WebView/WebDocumentLoaderMac.h: Added.
        * WebView/WebDocumentLoaderMac.m: Added.
        * WebView/WebFrame.m:
        (-[WebFrame _createItem:]):
        (-[WebFrame _receivedMainResourceError:]):
        (-[WebFrame _transitionToCommitted:]):
        (-[WebFrame _opened]):
        (-[WebFrame _checkLoadCompleteForThisFrame]):
        (-[WebFrame _loadItem:withLoadType:]):
        (-[WebFrame _continueFragmentScrollAfterNavigationPolicy:formState:]):
        (-[WebFrame _loadURL:referrer:loadType:target:triggeringEvent:form:formValues:]):
        (-[WebFrame _addChild:]):
        (-[WebFrame _provisionalLoadStarted]):
        (-[WebFrame _dataSourceForDocumentLoader:]):
        (-[WebFrame _createDocumentLoaderWithRequest:]):
        * WebView/WebFrameInternal.h:
        * WebView/WebHTMLRepresentation.m:
        (-[WebHTMLRepresentation title]):
        * WebView/WebView.m:
        (-[WebView _mainFrameOverrideEncoding]):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@16892 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 files changed:
WebKit/ChangeLog
WebKit/Loader/WebDocumentLoader.h [moved from WebKit/Loader/WebDocumentLoadState.h with 99% similarity]
WebKit/Loader/WebDocumentLoader.m [moved from WebKit/Loader/WebDocumentLoadState.m with 93% similarity]
WebKit/Loader/WebFrameLoader.h
WebKit/Loader/WebFrameLoader.m
WebKit/Plugins/WebPluginController.m
WebKit/WebCoreSupport/WebFrameBridge.m
WebKit/WebKit.xcodeproj/project.pbxproj
WebKit/WebView/WebDataSource.m
WebKit/WebView/WebDataSourceInternal.h
WebKit/WebView/WebDocumentLoaderMac.h [moved from WebKit/WebView/WebDocumentLoadStateMac.h with 94% similarity]
WebKit/WebView/WebDocumentLoaderMac.m [moved from WebKit/WebView/WebDocumentLoadStateMac.m with 96% similarity]
WebKit/WebView/WebFrame.m
WebKit/WebView/WebFrameInternal.h
WebKit/WebView/WebHTMLRepresentation.m
WebKit/WebView/WebView.m

index 4ca4a74d78c782247f2c78493ea1035999fcad8e..c8de48c9311123b14c78f78b67dcf28ac0dacfa3 100644 (file)
@@ -1,3 +1,122 @@
+2006-10-08  Darin Adler  <darin@apple.com>
+
+        Rubber stamped by Maciej.
+
+        - changed "document load state" to "document loader"
+
+        * Loader/WebDocumentLoadState.h: Removed.
+        * Loader/WebDocumentLoadState.m: Removed.
+        * Loader/WebDocumentLoader.h: Added.
+        * Loader/WebDocumentLoader.m: Added.
+        (-[WebDocumentLoader setMainDocumentError:]):
+        (-[WebDocumentLoader mainReceivedError:complete:]):
+        (-[WebDocumentLoader finishedLoading]):
+        (-[WebDocumentLoader commitLoadWithData:]):
+        (-[WebDocumentLoader setupForReplaceByMIMEType:]):
+        (-[WebDocumentLoader updateLoading]):
+        (-[WebDocumentLoader setTitle:]):
+        * Loader/WebFrameLoader.h:
+        * Loader/WebFrameLoader.m:
+        (-[WebFrameLoader dealloc]):
+        (-[WebFrameLoader activeDocumentLoader]):
+        (-[WebFrameLoader activeDataSource]):
+        (-[WebFrameLoader addPlugInStreamLoader:]):
+        (-[WebFrameLoader removePlugInStreamLoader:]):
+        (-[WebFrameLoader addSubresourceLoader:]):
+        (-[WebFrameLoader removeSubresourceLoader:]):
+        (-[WebFrameLoader dataSource]):
+        (-[WebFrameLoader setDocumentLoader:]):
+        (-[WebFrameLoader documentLoader]):
+        (-[WebFrameLoader policyDataSource]):
+        (-[WebFrameLoader setPolicyDocumentLoader:]):
+        (-[WebFrameLoader clearDataSource]):
+        (-[WebFrameLoader provisionalDataSource]):
+        (-[WebFrameLoader provisionalDocumentLoader]):
+        (-[WebFrameLoader setProvisionalDocumentLoader:]):
+        (-[WebFrameLoader _clearProvisionalDataSource]):
+        (-[WebFrameLoader _setState:]):
+        (-[WebFrameLoader clearProvisionalLoad]):
+        (-[WebFrameLoader commitProvisionalLoad]):
+        (-[WebFrameLoader stopLoading]):
+        (-[WebFrameLoader startLoading]):
+        (-[WebFrameLoader startProvisionalLoad:]):
+        (-[WebFrameLoader setupForReplace]):
+        (-[WebFrameLoader _didReceiveResponse:forResource:]):
+        (-[WebFrameLoader _originalRequest]):
+        (-[WebFrameLoader _receivedMainResourceError:complete:]):
+        (-[WebFrameLoader _receivedData:]):
+        (-[WebFrameLoader _setRequest:]):
+        (-[WebFrameLoader _isStopping]):
+        (-[WebFrameLoader _setupForReplaceByMIMEType:]):
+        (-[WebFrameLoader _setResponse:]):
+        (-[WebFrameLoader _mainReceivedError:complete:]):
+        (-[WebFrameLoader _finishedLoading]):
+        (-[WebFrameLoader _checkContentPolicyForMIMEType:andCall:withSelector:]):
+        (-[WebFrameLoader _loadRequest:archive:]):
+        (-[WebFrameLoader _loadRequest:triggeringAction:loadType:formState:]):
+        (-[WebFrameLoader _reloadAllowingStaleDataWithOverrideEncoding:]):
+        (-[WebFrameLoader reload]):
+        (-[WebFrameLoader finishedLoadingDocument:]):
+        (-[WebFrameLoader committedLoadWithDocumentLoader:data:]):
+        (-[WebFrameLoader revertToProvisionalWithDocumentLoader:]):
+        (-[WebFrameLoader documentLoader:setMainDocumentError:]):
+        (-[WebFrameLoader documentLoader:mainReceivedCompleteError:]):
+        (-[WebFrameLoader finalSetupForReplaceWithDocumentLoader:]):
+        (-[WebFrameLoader willChangeTitleForDocument:]):
+        (-[WebFrameLoader didChangeTitleForDocument:]):
+        (-[WebFrameLoader checkNavigationPolicyForRequest:dataSource:formState:andCall:withSelector:]):
+        (-[WebFrameLoader continueLoadRequestAfterNavigationPolicy:formState:]):
+        (-[WebFrameLoader loadDataSource:withLoadType:formState:]):
+        * Plugins/WebPluginController.m:
+        (-[WebPluginController pluginView:receivedResponse:]):
+        * WebCoreSupport/WebFrameBridge.m:
+        (-[WebFrameBridge setTitle:]):
+        (-[WebFrameBridge receivedData:textEncodingName:]):
+        * WebKit.xcodeproj/project.pbxproj:
+        * WebView/WebDataSource.m:
+        (-[WebDataSourcePrivate dealloc]):
+        (-[WebDataSource _mainDocumentError]):
+        (-[WebDataSource _loadFromPageCache:]):
+        (-[WebDataSource _bridge]):
+        (-[WebDataSource _webView]):
+        (-[WebDataSource _URLForHistory]):
+        (-[WebDataSource _documentLoader]):
+        (-[WebDataSource _initWithDocumentLoader:]):
+        (-[WebDataSource initWithRequest:]):
+        (-[WebDataSource dealloc]):
+        (-[WebDataSource data]):
+        (-[WebDataSource webFrame]):
+        (-[WebDataSource initialRequest]):
+        (-[WebDataSource request]):
+        (-[WebDataSource response]):
+        (-[WebDataSource textEncodingName]):
+        (-[WebDataSource isLoading]):
+        (-[WebDataSource unreachableURL]):
+        (-[WebDataSource webArchive]):
+        * WebView/WebDataSourceInternal.h:
+        * WebView/WebDocumentLoadStateMac.h: Removed.
+        * WebView/WebDocumentLoadStateMac.m: Removed.
+        * WebView/WebDocumentLoaderMac.h: Added.
+        * WebView/WebDocumentLoaderMac.m: Added.
+        * WebView/WebFrame.m:
+        (-[WebFrame _createItem:]):
+        (-[WebFrame _receivedMainResourceError:]):
+        (-[WebFrame _transitionToCommitted:]):
+        (-[WebFrame _opened]):
+        (-[WebFrame _checkLoadCompleteForThisFrame]):
+        (-[WebFrame _loadItem:withLoadType:]):
+        (-[WebFrame _continueFragmentScrollAfterNavigationPolicy:formState:]):
+        (-[WebFrame _loadURL:referrer:loadType:target:triggeringEvent:form:formValues:]):
+        (-[WebFrame _addChild:]):
+        (-[WebFrame _provisionalLoadStarted]):
+        (-[WebFrame _dataSourceForDocumentLoader:]):
+        (-[WebFrame _createDocumentLoaderWithRequest:]):
+        * WebView/WebFrameInternal.h:
+        * WebView/WebHTMLRepresentation.m:
+        (-[WebHTMLRepresentation title]):
+        * WebView/WebView.m:
+        (-[WebView _mainFrameOverrideEncoding]):
+
 2006-10-08  Darin Adler  <darin@apple.com>
 
         Reviewed by Mitz.
similarity index 99%
rename from WebKit/Loader/WebDocumentLoadState.h
rename to WebKit/Loader/WebDocumentLoader.h
index f654a43705618cbb6765053360bab6d5a89625f8..0edd6cf5628bd559aeb8e66c4cbd60ab9cbb939e 100644 (file)
@@ -31,7 +31,7 @@
 @class WebFrameLoader;
 
 // To be renamed to WebDocumentLoader
-@interface WebDocumentLoadState : NSObject
+@interface WebDocumentLoader : NSObject
 {
 @public
     WebFrameLoader *frameLoader;
similarity index 93%
rename from WebKit/Loader/WebDocumentLoadState.m
rename to WebKit/Loader/WebDocumentLoader.m
index d2fdc554a9c99d78cd01ebb33e1cd9c09b492011..60fc75ab814e8112920ce97a39a660288dba687f 100644 (file)
@@ -26,7 +26,7 @@
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
 
-#import "WebDocumentLoadState.h"
+#import "WebDocumentLoader.h"
 
 #import <JavaScriptCore/Assertions.h>
 #import "WebFrameLoader.h"
@@ -35,7 +35,7 @@
 
 #import <WebKitSystemInterface.h>
 
-@implementation WebDocumentLoadState
+@implementation WebDocumentLoader
 
 - (id)initWithRequest:(NSURLRequest *)req
 {
     [mainDocumentError release];
     mainDocumentError = error;
     
-    [frameLoader documentLoadState:self setMainDocumentError:error];
+    [frameLoader documentLoader:self setMainDocumentError:error];
  }
 
 - (NSError *)mainDocumentError
     [self setMainDocumentError:error];
     
     if (isComplete) {
-        [frameLoader documentLoadState:self mainReceivedCompleteError:error];
+        [frameLoader documentLoader:self mainReceivedCompleteError:error];
     }
 }
 
 {
     gotFirstByte = YES;   
     [self commitIfReady];
-    [frameLoader finishedLoadingDocumentLoadState:self];
+    [frameLoader finishedLoadingDocument:self];
     [[self bridge] end];
 }
 
     [self retain];
     [self commitIfReady];
     
-    [frameLoader committedLoadWithDocumentLoadState:self data:data];
+    [frameLoader committedLoadWithDocumentLoader:self data:data];
 
     [self release];
 }
     NSString *oldMIMEType = [response MIMEType];
     
     if (![self doesProgressiveLoadWithMIMEType:oldMIMEType]) {
-        [frameLoader revertToProvisionalWithDocumentLoadState:self];
+        [frameLoader revertToProvisionalWithDocumentLoader:self];
         [self setupForReplace];
         [self commitLoadWithData:[self mainResourceData]];
     }
     
-    [frameLoader finishedLoadingDocumentLoadState:self];
+    [frameLoader finishedLoadingDocument:self];
     [[self bridge] end];
     
     [frameLoader setReplacing];
     gotFirstByte = NO;
     
     if ([self doesProgressiveLoadWithMIMEType:newMIMEType]) {
-        [frameLoader revertToProvisionalWithDocumentLoadState:self];
+        [frameLoader revertToProvisionalWithDocumentLoader:self];
         [self setupForReplace];
     }
     
     [frameLoader stopLoadingSubresources];
     [frameLoader stopLoadingPlugIns];
 
-    [frameLoader finalSetupForReplaceWithDocumentLoadState:self];
+    [frameLoader finalSetupForReplaceWithDocumentLoader:self];
 }
 
 - (void)updateLoading
 {
-    ASSERT(self == [frameLoader activeDocumentLoadState]);
+    ASSERT(self == [frameLoader activeDocumentLoader]);
     
     [self setLoading:[frameLoader isLoading]];
 }
     CFStringTrimWhitespace((CFMutableStringRef)trimmed);
 
     if ([trimmed length] != 0 && ![pageTitle isEqualToString:trimmed]) {
-        [frameLoader willChangeTitleForDocumentLoadState:self];
+        [frameLoader willChangeTitleForDocument:self];
         [pageTitle release];
         pageTitle = [trimmed copy];
-        [frameLoader didChangeTitleForDocumentLoadState:self];
+        [frameLoader didChangeTitleForDocument:self];
     }
 
     [trimmed release];
index 34ffa81005568fc7eeb38d9dfead9c2f98887185..ad41390da187fe57db2acf7b65f8e827a3a553e9 100644 (file)
@@ -28,7 +28,7 @@
 
 #import <Cocoa/Cocoa.h>
 
-#import "WebDocumentLoadState.h"
+#import "WebDocumentLoader.h"
 #import "WebFrameLoaderClient.h"
 #import "WebFramePrivate.h"
 
@@ -67,9 +67,9 @@ typedef enum {
     NSMutableArray *plugInStreamLoaders;
     
     WebFrame <WebFrameLoaderClient> *client;
-    WebDocumentLoadState *documentLoadState;
-    WebDocumentLoadState *provisionalDocumentLoadState;
-    WebDocumentLoadState *policyDocumentLoadState;
+    WebDocumentLoader *documentLoader;
+    WebDocumentLoader *provisionalDocumentLoader;
+    WebDocumentLoader *policyDocumentLoader;
         
     WebFrameState state;
     
@@ -120,9 +120,9 @@ typedef enum {
 - (WebDataSource *)provisionalDataSource;
 - (WebDataSource *)policyDataSource;
 - (WebDataSource *)activeDataSource;
-- (WebDocumentLoadState *)activeDocumentLoadState;
-- (WebDocumentLoadState *)documentLoadState;
-- (WebDocumentLoadState *)provisionalDocumentLoadState;
+- (WebDocumentLoader *)activeDocumentLoader;
+- (WebDocumentLoader *)documentLoader;
+- (WebDocumentLoader *)provisionalDocumentLoader;
 - (WebFrameState)state;
 - (void)clearDataSource;
 - (void)setupForReplace;
@@ -186,19 +186,19 @@ typedef enum {
 
 - (void)didReceiveServerRedirectForProvisionalLoadForFrame;
 - (WebFrameBridge *)bridge;
-- (void)finishedLoadingDocumentLoadState:(WebDocumentLoadState *)loadState;
+- (void)finishedLoadingDocument:(WebDocumentLoader *)loader;
 - (void)commitProvisitionalLoad;
-- (void)committedLoadWithDocumentLoadState:(WebDocumentLoadState *)loadState data:(NSData *)data;
+- (void)committedLoadWithDocumentLoader:(WebDocumentLoader *)loader data:(NSData *)data;
 - (BOOL)isReplacing;
 - (void)setReplacing;
-- (void)revertToProvisionalWithDocumentLoadState:(WebDocumentLoadState *)loadState;
-- (void)documentLoadState:(WebDocumentLoadState *)loadState setMainDocumentError:(NSError *)error;
-- (void)documentLoadState:(WebDocumentLoadState *)loadState mainReceivedCompleteError:(NSError *)error;
-- (void)finalSetupForReplaceWithDocumentLoadState:(WebDocumentLoadState *)loadState;
+- (void)revertToProvisionalWithDocumentLoader:(WebDocumentLoader *)loader;
+- (void)documentLoader:(WebDocumentLoader *)loader setMainDocumentError:(NSError *)error;
+- (void)documentLoader:(WebDocumentLoader *)loader mainReceivedCompleteError:(NSError *)error;
+- (void)finalSetupForReplaceWithDocumentLoader:(WebDocumentLoader *)loader;
 - (void)prepareForLoadStart;
 - (BOOL)subframeIsLoading;
-- (void)willChangeTitleForDocumentLoadState:(WebDocumentLoadState *)loadState;
-- (void)didChangeTitleForDocumentLoadState:(WebDocumentLoadState *)loadState;
+- (void)willChangeTitleForDocument:(WebDocumentLoader *)loader;
+- (void)didChangeTitleForDocument:(WebDocumentLoader *)loader;
 
 - (WebFrameLoadType)loadType;
 - (void)setLoadType:(WebFrameLoadType)type;
index 7fef1e7f64df8b2e7be364604f7b3cd5edf9a8b3..ab46ff03d9d4fab780560474cdd565837e07ebc0 100644 (file)
@@ -30,7 +30,7 @@
 
 #import "WebDataProtocol.h"
 #import "WebDataSourceInternal.h"
-#import "WebDocumentLoadStateMac.h"
+#import "WebDocumentLoaderMac.h"
 #import "WebDownloadInternal.h"
 #import "WebFrameBridge.h"
 #import "WebFrameInternal.h"
     [mainResourceLoader release];
     [subresourceLoaders release];
     [plugInStreamLoaders release];
-    [documentLoadState release];
-    [provisionalDocumentLoadState release];
+    [documentLoader release];
+    [provisionalDocumentLoader release];
  
-    ASSERT(!policyDocumentLoadState);
+    ASSERT(!policyDocumentLoader);
     
     [super dealloc];
 }
 
-- (WebDocumentLoadState *)activeDocumentLoadState
+- (WebDocumentLoader *)activeDocumentLoader
 {
     if (state == WebFrameStateProvisional)
-        return provisionalDocumentLoadState;
+        return provisionalDocumentLoader;
     
-    return documentLoadState;    
+    return documentLoader;    
 }
 
 - (WebDataSource *)activeDataSource
 {
-    return [client _dataSourceForDocumentLoadState:[self activeDocumentLoadState]];
+    return [client _dataSourceForDocumentLoader:[self activeDocumentLoader]];
 }
 
 - (WebResource *)_archivedSubresourceForURL:(NSURL *)URL
     if (!plugInStreamLoaders)
         plugInStreamLoaders = [[NSMutableArray alloc] init];
     [plugInStreamLoaders addObject:loader];
-    [[self activeDocumentLoadState] setLoading:YES];
+    [[self activeDocumentLoader] setLoading:YES];
 }
 
 - (void)removePlugInStreamLoader:(WebLoader *)loader
 {
     [plugInStreamLoaders removeObject:loader];
-    [[self activeDocumentLoadState] updateLoading];
+    [[self activeDocumentLoader] updateLoading];
 }    
 
 - (void)defersCallbacksChanged
 
 - (void)addSubresourceLoader:(WebLoader *)loader
 {
-    ASSERT(!provisionalDocumentLoadState);
+    ASSERT(!provisionalDocumentLoader);
     if (subresourceLoaders == nil)
         subresourceLoaders = [[NSMutableArray alloc] init];
     [subresourceLoaders addObject:loader];
-    [[self activeDocumentLoadState] setLoading:YES];
+    [[self activeDocumentLoader] setLoading:YES];
 }
 
 - (void)removeSubresourceLoader:(WebLoader *)loader
 {
     [subresourceLoaders removeObject:loader];
-    [[self activeDocumentLoadState] updateLoading];
+    [[self activeDocumentLoader] updateLoading];
 }
 
 - (NSData *)mainResourceData
 
 - (WebDataSource *)dataSource
 {
-    return [client _dataSourceForDocumentLoadState:documentLoadState]; 
+    return [client _dataSourceForDocumentLoader:documentLoader]; 
 }
 
-- (void)_setDocumentLoadState:(WebDocumentLoadState *)loadState
+- (void)setDocumentLoader:(WebDocumentLoader *)loader
 {
-    if (loadState == nil && documentLoadState == nil)
+    if (loader == nil && documentLoader == nil)
         return;
     
-    ASSERT(loadState != documentLoadState);
+    ASSERT(loader != documentLoader);
     
     [client _prepareForDataSourceReplacement];
-    [documentLoadState detachFromFrameLoader];
+    [documentLoader detachFromFrameLoader];
     
-    [loadState retain];
-    [documentLoadState release];
-    documentLoadState = loadState;
+    [loader retain];
+    [documentLoader release];
+    documentLoader = loader;
 }
 
-- (WebDocumentLoadState *)documentLoadState
+- (WebDocumentLoader *)documentLoader
 {
-    return documentLoadState;
+    return documentLoader;
 }
 
 - (WebDataSource *)policyDataSource
 {
-    return [client _dataSourceForDocumentLoadState:policyDocumentLoadState];     
+    return [client _dataSourceForDocumentLoader:policyDocumentLoader];     
 }
 
-- (void)_setPolicyDocumentLoadState:(WebDocumentLoadState *)loadState
+- (void)setPolicyDocumentLoader:(WebDocumentLoader *)loader
 {
-    if (policyDocumentLoadState == loadState)
+    if (policyDocumentLoader == loader)
         return;
 
-    if (policyDocumentLoadState != provisionalDocumentLoadState && policyDocumentLoadState != documentLoadState)
-        [policyDocumentLoadState detachFromFrameLoader];
+    if (policyDocumentLoader != provisionalDocumentLoader && policyDocumentLoader != documentLoader)
+        [policyDocumentLoader detachFromFrameLoader];
 
-    [policyDocumentLoadState release];
-    [loadState retain];
-    policyDocumentLoadState = loadState;
+    [policyDocumentLoader release];
+    [loader retain];
+    policyDocumentLoader = loader;
 }
    
 - (void)clearDataSource
 {
-    [self _setDocumentLoadState:nil];
+    [self setDocumentLoader:nil];
 }
 
 - (WebDataSource *)provisionalDataSource 
 {
-    return [client _dataSourceForDocumentLoadState:provisionalDocumentLoadState]; 
+    return [client _dataSourceForDocumentLoader:provisionalDocumentLoader]; 
 }
 
-- (WebDocumentLoadState *)provisionalDocumentLoadState
+- (WebDocumentLoader *)provisionalDocumentLoader
 {
-    return provisionalDocumentLoadState;
+    return provisionalDocumentLoader;
 }
 
-- (void)_setProvisionalDocumentLoadState:(WebDocumentLoadState *)loadState
+- (void)setProvisionalDocumentLoader:(WebDocumentLoader *)loader
 {
-    ASSERT(!loadState || !provisionalDocumentLoadState);
+    ASSERT(!loader || !provisionalDocumentLoader);
 
-    if (provisionalDocumentLoadState != documentLoadState)
-        [provisionalDocumentLoadState detachFromFrameLoader];
+    if (provisionalDocumentLoader != documentLoader)
+        [provisionalDocumentLoader detachFromFrameLoader];
 
-    [loadState retain];
-    [provisionalDocumentLoadState release];
-    provisionalDocumentLoadState = loadState;
+    [loader retain];
+    [provisionalDocumentLoader release];
+    provisionalDocumentLoader = loader;
 }
 
 - (void)_clearProvisionalDataSource
 {
-    [self _setProvisionalDocumentLoadState:nil];
+    [self setProvisionalDocumentLoader:nil];
 }
 
 - (WebFrameState)state
@@ -323,10 +323,10 @@ static CFAbsoluteTime _timeOfLastCompletedLoad;
 {
     LOG(Loading, "%@:  transition from %s to %s", [client name], stateNames[state], stateNames[newState]);
     if ([client webView])
-        LOG(Timing, "%@:  transition from %s to %s, %f seconds since start of document load", [client name], stateNames[state], stateNames[newState], CFAbsoluteTimeGetCurrent() - [[[[[client webView] mainFrame] dataSource] _documentLoadState] loadingStartedTime]);
+        LOG(Timing, "%@:  transition from %s to %s, %f seconds since start of document load", [client name], stateNames[state], stateNames[newState], CFAbsoluteTimeGetCurrent() - [[[[[client webView] mainFrame] dataSource] _documentLoader] loadingStartedTime]);
     
     if (newState == WebFrameStateComplete && client == [[client webView] mainFrame])
-        LOG(DocumentLoad, "completed %@ (%f seconds)", [[[self dataSource] request] URL], CFAbsoluteTimeGetCurrent() - [[[self dataSource] _documentLoadState] loadingStartedTime]);
+        LOG(DocumentLoad, "completed %@ (%f seconds)", [[[self dataSource] request] URL], CFAbsoluteTimeGetCurrent() - [[[self dataSource] _documentLoader] loadingStartedTime]);
     
     state = newState;
     
@@ -335,13 +335,13 @@ static CFAbsoluteTime _timeOfLastCompletedLoad;
     else if (state == WebFrameStateComplete) {
         [client _frameLoadCompleted];
         _timeOfLastCompletedLoad = CFAbsoluteTimeGetCurrent();
-        [[self documentLoadState] stopRecordingResponses];
+        [[self documentLoader] stopRecordingResponses];
     }
 }
 
 - (void)clearProvisionalLoad
 {
-    [self _setProvisionalDocumentLoadState:nil];
+    [self setProvisionalDocumentLoader:nil];
     [[client webView] _progressCompleted:client];
     [self _setState:WebFrameStateComplete];
 }
@@ -356,15 +356,15 @@ static CFAbsoluteTime _timeOfLastCompletedLoad;
     [self stopLoadingSubresources];
     [self stopLoadingPlugIns];
 
-    [self _setDocumentLoadState:provisionalDocumentLoadState];
-    [self _setProvisionalDocumentLoadState:nil];
+    [self setDocumentLoader:provisionalDocumentLoader];
+    [self setProvisionalDocumentLoader:nil];
     [self _setState:WebFrameStateCommittedPage];
 }
 
 - (void)stopLoading
 {
-    [[self provisionalDocumentLoadState] stopLoading];
-    [[self documentLoadState] stopLoading];
+    [[self provisionalDocumentLoader] stopLoading];
+    [[self documentLoader] stopLoading];
     [self _clearProvisionalDataSource];
     [self clearArchivedResources];
 }
@@ -372,7 +372,7 @@ static CFAbsoluteTime _timeOfLastCompletedLoad;
 // FIXME: poor method name; also why is this not part of startProvisionalLoad:?
 - (void)startLoading
 {
-    [provisionalDocumentLoadState prepareForLoadStart];
+    [provisionalDocumentLoader prepareForLoadStart];
         
     if ([self isLoadingMainResource])
         return;
@@ -382,26 +382,26 @@ static CFAbsoluteTime _timeOfLastCompletedLoad;
     id identifier;
     id resourceLoadDelegate = [[client webView] resourceLoadDelegate];
     if ([resourceLoadDelegate respondsToSelector:@selector(webView:identifierForInitialRequest:fromDataSource:)])
-        identifier = [resourceLoadDelegate webView:[client webView] identifierForInitialRequest:[provisionalDocumentLoadState originalRequest] fromDataSource:[self provisionalDataSource]];
+        identifier = [resourceLoadDelegate webView:[client webView] identifierForInitialRequest:[provisionalDocumentLoader originalRequest] fromDataSource:[self provisionalDataSource]];
     else
-        identifier = [[WebDefaultResourceLoadDelegate sharedResourceLoadDelegate] webView:[client webView] identifierForInitialRequest:[provisionalDocumentLoadState originalRequest] fromDataSource:[self provisionalDataSource]];
+        identifier = [[WebDefaultResourceLoadDelegate sharedResourceLoadDelegate] webView:[client webView] identifierForInitialRequest:[provisionalDocumentLoader originalRequest] fromDataSource:[self provisionalDataSource]];
     
-    if (![[provisionalDocumentLoadState frameLoader] startLoadingMainResourceWithRequest:[provisionalDocumentLoadState actualRequest] identifier:identifier])
-        [provisionalDocumentLoadState updateLoading];
+    if (![[provisionalDocumentLoader frameLoader] startLoadingMainResourceWithRequest:[provisionalDocumentLoader actualRequest] identifier:identifier])
+        [provisionalDocumentLoader updateLoading];
 }
 
 - (void)startProvisionalLoad:(WebDataSource *)ds
 {
-    [self _setProvisionalDocumentLoadState:[ds _documentLoadState]];
+    [self setProvisionalDocumentLoader:[ds _documentLoader]];
     [self _setState:WebFrameStateProvisional];
 }
 
 - (void)setupForReplace
 {
     [self _setState:WebFrameStateProvisional];
-    WebDocumentLoadState *old = provisionalDocumentLoadState;
-    provisionalDocumentLoadState = documentLoadState;
-    documentLoadState = nil;
+    WebDocumentLoader *old = provisionalDocumentLoader;
+    provisionalDocumentLoader = documentLoader;
+    documentLoader = nil;
     [old release];
     
     [client _detachChildren];
@@ -456,7 +456,7 @@ static CFAbsoluteTime _timeOfLastCompletedLoad;
 {
     WebView *webView = [client webView];
     
-    [[self activeDocumentLoadState] addResponse:r];
+    [[self activeDocumentLoader] addResponse:r];
     
     [webView _incrementProgressForIdentifier:identifier response:r];
     
@@ -517,7 +517,7 @@ static CFAbsoluteTime _timeOfLastCompletedLoad;
 
 - (NSURLRequest *)_originalRequest
 {
-    return [[self activeDocumentLoadState] originalRequestCopy];
+    return [[self activeDocumentLoader] originalRequestCopy];
 }
 
 - (WebFrame *)webFrame
@@ -527,8 +527,8 @@ static CFAbsoluteTime _timeOfLastCompletedLoad;
 
 - (void)_receivedMainResourceError:(NSError *)error complete:(BOOL)isComplete
 {
-    WebDocumentLoadState *loadState = [self activeDocumentLoadState];
-    [loadState retain];
+    WebDocumentLoader *loader = [self activeDocumentLoader];
+    [loader retain];
     
     WebFrameBridge *bridge = [client _bridge];
     
@@ -550,11 +550,11 @@ static CFAbsoluteTime _timeOfLastCompletedLoad;
     [bridge release];
     
     [cli _receivedMainResourceError:error];
-    [loadState mainReceivedError:error complete:isComplete];
+    [loader mainReceivedError:error complete:isComplete];
 
     [cli release];
 
-    [loadState release];
+    [loader release];
 }
 
 - (NSURLRequest *)initialRequest
@@ -564,12 +564,12 @@ static CFAbsoluteTime _timeOfLastCompletedLoad;
 
 - (void)_receivedData:(NSData *)data
 {
-    [[self activeDocumentLoadState] receivedData:data];
+    [[self activeDocumentLoader] receivedData:data];
 }
 
 - (void)_setRequest:(NSURLRequest *)request
 {
-    [[self activeDocumentLoadState] setRequest:request];
+    [[self activeDocumentLoader] setRequest:request];
 }
 
 - (void)_downloadWithLoadingConnection:(NSURLConnection *)connection request:(NSURLRequest *)request response:(NSURLResponse *)r proxy:(id)proxy
@@ -593,22 +593,22 @@ static CFAbsoluteTime _timeOfLastCompletedLoad;
 
 - (BOOL)_isStopping
 {
-    return [[self activeDocumentLoadState] isStopping];
+    return [[self activeDocumentLoader] isStopping];
 }
 
 - (void)_setupForReplaceByMIMEType:(NSString *)newMIMEType
 {
-    [[self activeDocumentLoadState] setupForReplaceByMIMEType:newMIMEType];
+    [[self activeDocumentLoader] setupForReplaceByMIMEType:newMIMEType];
 }
 
 - (void)_setResponse:(NSURLResponse *)response
 {
-    [[self activeDocumentLoadState] setResponse:response];
+    [[self activeDocumentLoader] setResponse:response];
 }
 
 - (void)_mainReceivedError:(NSError *)error complete:(BOOL)isComplete
 {
-    [[self activeDocumentLoadState] mainReceivedError:error complete:isComplete];
+    [[self activeDocumentLoader] mainReceivedError:error complete:isComplete];
 }
 
 - (void)_finishedLoading
@@ -616,14 +616,14 @@ static CFAbsoluteTime _timeOfLastCompletedLoad;
     WebDataSource *ds = [self activeDataSource];
     
     [self retain];
-    [[self activeDocumentLoadState] finishedLoading];
+    [[self activeDocumentLoader] finishedLoading];
 
     if ([ds _mainDocumentError] || ![ds webFrame]) {
         [self release];
         return;
     }
 
-    [[self activeDocumentLoadState] setPrimaryLoadComplete:YES];
+    [[self activeDocumentLoader] setPrimaryLoadComplete:YES];
     if ([WebScriptDebugServer listenerCount])
         [[WebScriptDebugServer sharedScriptDebugServer] webView:[client webView] didLoadMainResourceForDataSource:[self activeDataSource]];
     [client _checkLoadComplete];
@@ -835,7 +835,7 @@ static BOOL isCaseInsensitiveEqual(NSString *a, NSString *b)
     [l retain];
 
     [[[client webView] _policyDelegateForwarder] webView:[client webView] decidePolicyForMIMEType:MIMEType
-                                                 request:[[self activeDocumentLoadState] request]
+                                                 request:[[self activeDocumentLoader] request]
                                                    frame:client
                                         decisionListener:listener];
     [l release];
@@ -894,9 +894,9 @@ static inline BOOL isBackForwardLoadType(WebFrameLoadType type)
 {
     WebFrameLoadType type;
     
-    ASSERT(!policyDocumentLoadState);
-    policyDocumentLoadState = [client _createDocumentLoadStateWithRequest:request];
-    WebDataSource *newDataSource = [client _dataSourceForDocumentLoadState:policyDocumentLoadState];
+    ASSERT(!policyDocumentLoader);
+    policyDocumentLoader = [client _createDocumentLoaderWithRequest:request];
+    WebDataSource *newDataSource = [client _dataSourceForDocumentLoader:policyDocumentLoader];
 
     NSMutableURLRequest *r = [newDataSource request];
     [client _addExtraFieldsToRequest:r mainResource:YES alwaysFromRequest:NO];
@@ -906,7 +906,7 @@ static inline BOOL isBackForwardLoadType(WebFrameLoadType type)
     } else
         type = WebFrameLoadTypeStandard;
     
-    [policyDocumentLoadState setOverrideEncoding:[[self documentLoadState] overrideEncoding]];
+    [policyDocumentLoader setOverrideEncoding:[[self documentLoader] overrideEncoding]];
     [newDataSource _addToUnarchiveState:archive];
     
     // When we loading alternate content for an unreachable URL that we're
@@ -922,12 +922,12 @@ static inline BOOL isBackForwardLoadType(WebFrameLoadType type)
 
 - (void)_loadRequest:(NSURLRequest *)request triggeringAction:(NSDictionary *)action loadType:(WebFrameLoadType)type formState:(WebFormState *)formState
 {
-    ASSERT(!policyDocumentLoadState);
-    policyDocumentLoadState = [client _createDocumentLoadStateWithRequest:request];
-    WebDataSource *newDataSource = [client _dataSourceForDocumentLoadState:policyDocumentLoadState];
+    ASSERT(!policyDocumentLoader);
+    policyDocumentLoader = [client _createDocumentLoaderWithRequest:request];
+    WebDataSource *newDataSource = [client _dataSourceForDocumentLoader:policyDocumentLoader];
 
-    [policyDocumentLoadState setTriggeringAction:action];
-    [policyDocumentLoadState setOverrideEncoding:[[self documentLoadState] overrideEncoding]];
+    [policyDocumentLoader setTriggeringAction:action];
+    [policyDocumentLoader setOverrideEncoding:[[self documentLoader] overrideEncoding]];
 
     [self loadDataSource:newDataSource withLoadType:type formState:formState];
 }
@@ -944,12 +944,12 @@ static inline BOOL isBackForwardLoadType(WebFrameLoadType type)
         [request setURL:unreachableURL];
 
     [request setCachePolicy:NSURLRequestReturnCacheDataElseLoad];
-    ASSERT(!policyDocumentLoadState);
-    policyDocumentLoadState = [client _createDocumentLoadStateWithRequest:request];
-    WebDataSource *newDataSource = [client _dataSourceForDocumentLoadState:policyDocumentLoadState];
+    ASSERT(!policyDocumentLoader);
+    policyDocumentLoader = [client _createDocumentLoaderWithRequest:request];
+    WebDataSource *newDataSource = [client _dataSourceForDocumentLoader:policyDocumentLoader];
     [request release];
     
-    [policyDocumentLoadState setOverrideEncoding:encoding];
+    [policyDocumentLoader setOverrideEncoding:encoding];
 
     [self loadDataSource:newDataSource withLoadType:WebFrameLoadTypeReloadAllowingStaleData formState:nil];
 }
@@ -972,9 +972,9 @@ static inline BOOL isBackForwardLoadType(WebFrameLoadType type)
     if (unreachableURL != nil)
         initialRequest = [NSURLRequest requestWithURL:unreachableURL];
     
-    ASSERT(!policyDocumentLoadState);
-    policyDocumentLoadState = [client _createDocumentLoadStateWithRequest:initialRequest];
-    WebDataSource *newDataSource = [client _dataSourceForDocumentLoadState:policyDocumentLoadState];
+    ASSERT(!policyDocumentLoader);
+    policyDocumentLoader = [client _createDocumentLoaderWithRequest:initialRequest];
+    WebDataSource *newDataSource = [client _dataSourceForDocumentLoader:policyDocumentLoader];
     NSMutableURLRequest *request = [newDataSource request];
 
     [request setCachePolicy:NSURLRequestReloadIgnoringCacheData];
@@ -982,10 +982,10 @@ static inline BOOL isBackForwardLoadType(WebFrameLoadType type)
     // If we're about to rePOST, set up action so the app can warn the user
     if ([[request HTTPMethod] _webkit_isCaseInsensitiveEqualToString:@"POST"]) {
         NSDictionary *action = [client _actionInformationForNavigationType:WebNavigationTypeFormResubmitted event:nil originalURL:[request URL]];
-        [policyDocumentLoadState setTriggeringAction:action];
+        [policyDocumentLoader setTriggeringAction:action];
     }
 
-    [policyDocumentLoadState setOverrideEncoding:[[ds _documentLoadState] overrideEncoding]];
+    [policyDocumentLoader setOverrideEncoding:[[ds _documentLoader] overrideEncoding]];
     
     [self loadDataSource:newDataSource withLoadType:WebFrameLoadTypeReload formState:nil];
 }
@@ -995,9 +995,9 @@ static inline BOOL isBackForwardLoadType(WebFrameLoadType type)
     [client _didReceiveServerRedirectForProvisionalLoadForFrame];
 }
 
-- (void)finishedLoadingDocumentLoadState:(WebDocumentLoadState *)loadState
+- (void)finishedLoadingDocument:(WebDocumentLoader *)loader
 {
-    [[client _dataSourceForDocumentLoadState:loadState] _finishedLoading];
+    [[client _dataSourceForDocumentLoader:loader] _finishedLoading];
 }
 
 - (void)commitProvisitionalLoad
@@ -1005,9 +1005,9 @@ static inline BOOL isBackForwardLoadType(WebFrameLoadType type)
     [client _commitProvisionalLoad:nil];
 }
 
-- (void)committedLoadWithDocumentLoadState:(WebDocumentLoadState *)loadState data:(NSData *)data
+- (void)committedLoadWithDocumentLoader:(WebDocumentLoader *)loader data:(NSData *)data
 {
-    [[client _dataSourceForDocumentLoadState:loadState] _receivedData:data];
+    [[client _dataSourceForDocumentLoader:loader] _receivedData:data];
 }
 
 - (BOOL)isReplacing
@@ -1020,27 +1020,27 @@ static inline BOOL isBackForwardLoadType(WebFrameLoadType type)
     loadType = WebFrameLoadTypeReplace;
 }
 
-- (void)revertToProvisionalWithDocumentLoadState:(WebDocumentLoadState *)loadState
+- (void)revertToProvisionalWithDocumentLoader:(WebDocumentLoader *)loader
 {
-    [[client _dataSourceForDocumentLoadState:loadState] _revertToProvisionalState];
+    [[client _dataSourceForDocumentLoader:loader] _revertToProvisionalState];
 }
 
-- (void)documentLoadState:(WebDocumentLoadState *)loadState setMainDocumentError:(NSError *)error
+- (void)documentLoader:(WebDocumentLoader *)loader setMainDocumentError:(NSError *)error
 {
-    [[client _dataSourceForDocumentLoadState:loadState] _setMainDocumentError:error];
+    [[client _dataSourceForDocumentLoader:loader] _setMainDocumentError:error];
 }
 
-- (void)documentLoadState:(WebDocumentLoadState *)loadState mainReceivedCompleteError:(NSError *)error
+- (void)documentLoader:(WebDocumentLoader *)loader mainReceivedCompleteError:(NSError *)error
 {
-    [loadState setPrimaryLoadComplete:YES];
+    [loader setPrimaryLoadComplete:YES];
     if ([WebScriptDebugServer listenerCount])
         [[WebScriptDebugServer sharedScriptDebugServer] webView:[client webView] didLoadMainResourceForDataSource:[self activeDataSource]];
     [client _checkLoadComplete];
 }
 
-- (void)finalSetupForReplaceWithDocumentLoadState:(WebDocumentLoadState *)loadState
+- (void)finalSetupForReplaceWithDocumentLoader:(WebDocumentLoader *)loader
 {
-    [[client _dataSourceForDocumentLoadState:loadState] _clearUnarchivingState];
+    [[client _dataSourceForDocumentLoader:loader] _clearUnarchivingState];
 }
 
 - (void)prepareForLoadStart
@@ -1056,31 +1056,31 @@ static inline BOOL isBackForwardLoadType(WebFrameLoadType type)
     return [client _subframeIsLoading];
 }
 
-- (void)willChangeTitleForDocumentLoadState:(WebDocumentLoadState *)loadState
+- (void)willChangeTitleForDocument:(WebDocumentLoader *)loader
 {
     // FIXME: should do this only in main frame case, right?
     [[client webView] _willChangeValueForKey:_WebMainFrameTitleKey];
 }
 
-- (void)didChangeTitleForDocumentLoadState:(WebDocumentLoadState *)loadState
+- (void)didChangeTitleForDocument:(WebDocumentLoader *)loader
 {
     // FIXME: should do this only in main frame case, right?
     [[client webView] _didChangeValueForKey:_WebMainFrameTitleKey];
 
     // The title doesn't get communicated to the WebView until we are committed.
-    if ([loadState isCommitted]) {
-        NSURL *URLForHistory = [[client _dataSourceForDocumentLoadState:loadState] _URLForHistory];
+    if ([loader isCommitted]) {
+        NSURL *URLForHistory = [[client _dataSourceForDocumentLoader:loader] _URLForHistory];
         if (URLForHistory != nil) {
             WebHistoryItem *entry = [[WebHistory optionalSharedHistory] itemForURL:URLForHistory];
-            [entry setTitle:[loadState title]];
+            [entry setTitle:[loader title]];
         
             // Must update the entries in the back-forward list too.  This must go through the WebFrame because
             // it has the right notion of the current b/f item.
-            [client _setTitle:[loadState title]];
+            [client _setTitle:[loader title]];
         
             [[client webView] setMainFrameDocumentReady:YES];    // update observers with new DOMDocument
             [[[client webView] _frameLoadDelegateForwarder] webView:[client webView]
-                                                      didReceiveTitle:[loadState title]
+                                                      didReceiveTitle:[loader title]
                                                              forFrame:client];
         }
     }
@@ -1185,15 +1185,15 @@ static inline BOOL isBackForwardLoadType(WebFrameLoadType type)
                                 andCall:(id)target
                            withSelector:(SEL)selector
 {
-    NSDictionary *action = [[dataSource _documentLoadState] triggeringAction];
+    NSDictionary *action = [[dataSource _documentLoader] triggeringAction];
     if (action == nil) {
         action = [client _actionInformationForNavigationType:WebNavigationTypeOther event:nil originalURL:[request URL]];
-        [[dataSource _documentLoadState]  setTriggeringAction:action];
+        [[dataSource _documentLoader]  setTriggeringAction:action];
     }
         
     // Don't ask more than once for the same request or if we are loading an empty URL.
     // This avoids confusion on the part of the client.
-    if ([request isEqual:[[dataSource _documentLoadState] lastCheckedRequest]] || [[request URL] _web_isEmpty]) {
+    if ([request isEqual:[[dataSource _documentLoader] lastCheckedRequest]] || [[request URL] _web_isEmpty]) {
         [target performSelector:selector withObject:request withObject:nil];
         return;
     }
@@ -1207,7 +1207,7 @@ static inline BOOL isBackForwardLoadType(WebFrameLoadType type)
         return;
     }
     
-    [[dataSource _documentLoadState] setLastCheckedRequest:request];
+    [[dataSource _documentLoader] setLastCheckedRequest:request];
 
     WebPolicyDecisionListener *decisionListener = [[WebPolicyDecisionListener alloc] _initWithTarget:self action:@selector(continueAfterNavigationPolicy:)];
     
@@ -1299,7 +1299,7 @@ static inline BOOL isBackForwardLoadType(WebFrameLoadType type)
         if ([client _quickRedirectComing])
             [client _clientRedirectCancelledOrFinished:NO];
 
-        [self _setPolicyDocumentLoadState:nil];
+        [self setPolicyDocumentLoader:nil];
 
         // If the navigation request came from the back/forward menu, and we punt on it, we have the 
         // problem that we have optimistically moved the b/f cursor already, so move it back.  For sanity, 
@@ -1319,7 +1319,7 @@ static inline BOOL isBackForwardLoadType(WebFrameLoadType type)
     [self startProvisionalLoad:dataSource];
 
     [dataSource release];
-    [self _setPolicyDocumentLoadState:nil];
+    [self setPolicyDocumentLoader:nil];
     
     if (client == [[client webView] mainFrame])
         LOG(DocumentLoad, "loading %@", [[[self provisionalDataSource] request] URL]);
@@ -1351,18 +1351,18 @@ static inline BOOL isBackForwardLoadType(WebFrameLoadType type)
 
     policyLoadType = type;
 
-    WebDocumentLoadStateMac *loadState = (WebDocumentLoadStateMac *)[newDataSource _documentLoadState];
+    WebDocumentLoaderMac *loader = (WebDocumentLoaderMac *)[newDataSource _documentLoader];
 
     WebFrame *parentFrame = [client parentFrame];
     if (parentFrame)
-        [loadState setOverrideEncoding:[[[parentFrame dataSource] _documentLoadState] overrideEncoding]];
+        [loader setOverrideEncoding:[[[parentFrame dataSource] _documentLoader] overrideEncoding]];
 
-    [loadState setFrameLoader:self];
-    [loadState setDataSource:newDataSource];
+    [loader setFrameLoader:self];
+    [loader setDataSource:newDataSource];
 
     [self invalidatePendingPolicyDecisionCallingDefaultAction:YES];
 
-    [self _setPolicyDocumentLoadState:loadState];
+    [self setPolicyDocumentLoader:loader];
 
     [self checkNavigationPolicyForRequest:[newDataSource request]
                                dataSource:newDataSource
index 9a6eeab7b92d304474218ac93783cf1ff9e41c61..6663552866914ee182b7489ada73b9231e05f163 100644 (file)
@@ -374,7 +374,7 @@ static void cancelOutstandingCheck(const void *item, void *context)
                                                      pluginPageURL:nil
                                                         pluginName:nil // FIXME: Get this from somewhere
                                                           MIMEType:[response MIMEType]];
-        [[[_dataSource _documentLoadState] frameLoader] stopLoadingWithError:error];
+        [[[_dataSource _documentLoader] frameLoader] stopLoadingWithError:error];
         [error release];
     }        
 }
index d972e8cd417f99302f4a54164053a7df96e84783..cff5915148723da32ba2e1f2d5977091a192b2ea 100644 (file)
@@ -478,7 +478,7 @@ NSString *WebPluginContainerKey =   @"WebPluginContainer";
 
 - (void)setTitle:(NSString *)title
 {
-    [[[_frame _frameLoader] documentLoadState] setTitle:[title _webkit_stringByCollapsingNonPrintingCharacters]];
+    [[[_frame _frameLoader] documentLoader] setTitle:[title _webkit_stringByCollapsingNonPrintingCharacters]];
 }
 
 - (void)setStatusText:(NSString *)status
@@ -491,7 +491,7 @@ NSString *WebPluginContainerKey =   @"WebPluginContainer";
 - (void)receivedData:(NSData *)data textEncodingName:(NSString *)textEncodingName
 {
     // Set the encoding. This only needs to be done once, but it's harmless to do it again later.
-    NSString *encoding = [[[_frame _frameLoader] documentLoadState] overrideEncoding];
+    NSString *encoding = [[[_frame _frameLoader] documentLoader] overrideEncoding];
     BOOL userChosen = encoding != nil;
     if (encoding == nil) {
         encoding = textEncodingName;
index eec1cf1fb20f7a6723bbd871bea4f339e9708db4..55454aad916bef89551257f87429f71d70f9cd3c 100644 (file)
@@ -57,8 +57,8 @@
                6550B7C7099EFAE90090D781 /* WebArchiver.h in Headers */ = {isa = PBXBuildFile; fileRef = 6550B7C5099EFAE90090D781 /* WebArchiver.h */; };
                6550B7C8099EFAE90090D781 /* WebArchiver.m in Sources */ = {isa = PBXBuildFile; fileRef = 6550B7C6099EFAE90090D781 /* WebArchiver.m */; };
                658A40960A14853B005E6987 /* WebDataSourceInternal.h in Headers */ = {isa = PBXBuildFile; fileRef = 658A40950A14853B005E6987 /* WebDataSourceInternal.h */; };
-               659044280A9D3B4200E89459 /* WebDocumentLoadState.h in Headers */ = {isa = PBXBuildFile; fileRef = 659044260A9D3B4200E89459 /* WebDocumentLoadState.h */; };
-               659044290A9D3B4200E89459 /* WebDocumentLoadState.m in Sources */ = {isa = PBXBuildFile; fileRef = 659044270A9D3B4200E89459 /* WebDocumentLoadState.m */; };
+               659044280A9D3B4200E89459 /* WebDocumentLoader.h in Headers */ = {isa = PBXBuildFile; fileRef = 659044260A9D3B4200E89459 /* WebDocumentLoader.h */; };
+               659044290A9D3B4200E89459 /* WebDocumentLoader.m in Sources */ = {isa = PBXBuildFile; fileRef = 659044270A9D3B4200E89459 /* WebDocumentLoader.m */; };
                65A0006908527D1A005620FA /* libWebKitSystemInterface.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 65A0006808527D1A005620FA /* libWebKitSystemInterface.a */; };
                65A734610A923948001B57E8 /* WebPlugInStreamLoaderDelegate.h in Headers */ = {isa = PBXBuildFile; fileRef = 65A734600A923948001B57E8 /* WebPlugInStreamLoaderDelegate.h */; };
                65C7F42C0979DE640022E453 /* WebPageBridge.h in Headers */ = {isa = PBXBuildFile; fileRef = 65C7F42A0979DE640022E453 /* WebPageBridge.h */; };
@@ -71,8 +71,8 @@
                65EEDE54084FFB920002DB25 /* WebNSCalendarDateExtras.m in Sources */ = {isa = PBXBuildFile; fileRef = 65EEDE52084FFB920002DB25 /* WebNSCalendarDateExtras.m */; };
                65EEDE57084FFC9E0002DB25 /* WebNSFileManagerExtras.h in Headers */ = {isa = PBXBuildFile; fileRef = 65EEDE55084FFC9E0002DB25 /* WebNSFileManagerExtras.h */; };
                65EEDE58084FFC9E0002DB25 /* WebNSFileManagerExtras.m in Sources */ = {isa = PBXBuildFile; fileRef = 65EEDE56084FFC9E0002DB25 /* WebNSFileManagerExtras.m */; };
-               65FFB7FC0AD0B7D30048CD05 /* WebDocumentLoadStateMac.h in Headers */ = {isa = PBXBuildFile; fileRef = 65FFB7FA0AD0B7D30048CD05 /* WebDocumentLoadStateMac.h */; };
-               65FFB7FD0AD0B7D30048CD05 /* WebDocumentLoadStateMac.m in Sources */ = {isa = PBXBuildFile; fileRef = 65FFB7FB0AD0B7D30048CD05 /* WebDocumentLoadStateMac.m */; };
+               65FFB7FC0AD0B7D30048CD05 /* WebDocumentLoaderMac.h in Headers */ = {isa = PBXBuildFile; fileRef = 65FFB7FA0AD0B7D30048CD05 /* WebDocumentLoaderMac.h */; };
+               65FFB7FD0AD0B7D30048CD05 /* WebDocumentLoaderMac.m in Sources */ = {isa = PBXBuildFile; fileRef = 65FFB7FB0AD0B7D30048CD05 /* WebDocumentLoaderMac.m */; };
                7E6FEF0108985A3E00C44C3F /* WebDefaultScriptDebugDelegate.h in Headers */ = {isa = PBXBuildFile; fileRef = 7E6FEEFF08985A3E00C44C3F /* WebDefaultScriptDebugDelegate.h */; };
                7E6FEF0208985A3E00C44C3F /* WebDefaultScriptDebugDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 7E6FEF0008985A3E00C44C3F /* WebDefaultScriptDebugDelegate.m */; };
                7E6FEF0808985A7200C44C3F /* WebScriptDebugDelegate.h in Headers */ = {isa = PBXBuildFile; fileRef = 7E6FEF0508985A7200C44C3F /* WebScriptDebugDelegate.h */; settings = {ATTRIBUTES = (Private, ); }; };
                6578F5DF045F817400000128 /* WebDownload.m */ = {isa = PBXFileReference; fileEncoding = 30; indentWidth = 4; lastKnownFileType = sourcecode.c.objc; path = WebDownload.m; sourceTree = "<group>"; tabWidth = 8; usesTabs = 0; };
                65836F5E07EE425900682F95 /* WebPluginContainerPrivate.h */ = {isa = PBXFileReference; fileEncoding = 30; indentWidth = 4; lastKnownFileType = sourcecode.c.h; path = WebPluginContainerPrivate.h; sourceTree = "<group>"; tabWidth = 8; usesTabs = 0; };
                658A40950A14853B005E6987 /* WebDataSourceInternal.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = WebDataSourceInternal.h; sourceTree = "<group>"; };
-               659044260A9D3B4200E89459 /* WebDocumentLoadState.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = WebDocumentLoadState.h; sourceTree = "<group>"; };
-               659044270A9D3B4200E89459 /* WebDocumentLoadState.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = WebDocumentLoadState.m; sourceTree = "<group>"; };
+               659044260A9D3B4200E89459 /* WebDocumentLoader.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = WebDocumentLoader.h; sourceTree = "<group>"; };
+               659044270A9D3B4200E89459 /* WebDocumentLoader.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = WebDocumentLoader.m; sourceTree = "<group>"; };
                65A0006808527D1A005620FA /* libWebKitSystemInterface.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; path = libWebKitSystemInterface.a; sourceTree = BUILT_PRODUCTS_DIR; };
                65A734600A923948001B57E8 /* WebPlugInStreamLoaderDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebPlugInStreamLoaderDelegate.h; sourceTree = "<group>"; };
                65A7D44A0568AB2600E70EF6 /* WebUIDelegatePrivate.h */ = {isa = PBXFileReference; fileEncoding = 30; indentWidth = 4; lastKnownFileType = sourcecode.c.h; path = WebUIDelegatePrivate.h; sourceTree = "<group>"; tabWidth = 8; usesTabs = 0; };
                65EEDE52084FFB920002DB25 /* WebNSCalendarDateExtras.m */ = {isa = PBXFileReference; fileEncoding = 30; indentWidth = 4; lastKnownFileType = sourcecode.c.objc; path = WebNSCalendarDateExtras.m; sourceTree = "<group>"; tabWidth = 8; usesTabs = 0; };
                65EEDE55084FFC9E0002DB25 /* WebNSFileManagerExtras.h */ = {isa = PBXFileReference; fileEncoding = 30; indentWidth = 4; lastKnownFileType = sourcecode.c.h; path = WebNSFileManagerExtras.h; sourceTree = "<group>"; tabWidth = 8; usesTabs = 0; };
                65EEDE56084FFC9E0002DB25 /* WebNSFileManagerExtras.m */ = {isa = PBXFileReference; fileEncoding = 30; indentWidth = 4; lastKnownFileType = sourcecode.c.objc; path = WebNSFileManagerExtras.m; sourceTree = "<group>"; tabWidth = 8; usesTabs = 0; };
-               65FFB7FA0AD0B7D30048CD05 /* WebDocumentLoadStateMac.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = WebDocumentLoadStateMac.h; sourceTree = "<group>"; };
-               65FFB7FB0AD0B7D30048CD05 /* WebDocumentLoadStateMac.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = WebDocumentLoadStateMac.m; sourceTree = "<group>"; };
+               65FFB7FA0AD0B7D30048CD05 /* WebDocumentLoaderMac.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = WebDocumentLoaderMac.h; sourceTree = "<group>"; };
+               65FFB7FB0AD0B7D30048CD05 /* WebDocumentLoaderMac.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = WebDocumentLoaderMac.m; sourceTree = "<group>"; };
                700BC50B04144DA100A80182 /* WebDefaultResourceLoadDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; indentWidth = 4; lastKnownFileType = sourcecode.c.h; path = WebDefaultResourceLoadDelegate.h; sourceTree = "<group>"; tabWidth = 8; usesTabs = 0; };
                700BC50C04144DA100A80182 /* WebDefaultResourceLoadDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; indentWidth = 4; lastKnownFileType = sourcecode.c.objc; path = WebDefaultResourceLoadDelegate.m; sourceTree = "<group>"; tabWidth = 8; usesTabs = 0; };
                7082F56F038EADAA00A80180 /* WebKitNSStringExtras.h */ = {isa = PBXFileReference; fileEncoding = 30; indentWidth = 4; lastKnownFileType = sourcecode.c.h; path = WebKitNSStringExtras.h; sourceTree = "<group>"; tabWidth = 8; usesTabs = 0; };
                        children = (
                                651A93850A83F883007FEDF0 /* WebDataProtocol.h */,
                                651A93860A83F883007FEDF0 /* WebDataProtocol.m */,
-                               659044260A9D3B4200E89459 /* WebDocumentLoadState.h */,
-                               659044270A9D3B4200E89459 /* WebDocumentLoadState.m */,
+                               659044260A9D3B4200E89459 /* WebDocumentLoader.h */,
+                               659044270A9D3B4200E89459 /* WebDocumentLoader.m */,
                                6538B1C60A90596D00A07522 /* WebFormDataStream.h */,
                                6538B1C70A90596D00A07522 /* WebFormDataStream.m */,
                                654B3C290A82C47200E1AE3D /* WebFrameLoader.h */,
                9C7CABBB0190A37C0ECA16EA /* WebView */ = {
                        isa = PBXGroup;
                        children = (
-                               65FFB7FA0AD0B7D30048CD05 /* WebDocumentLoadStateMac.h */,
-                               65FFB7FB0AD0B7D30048CD05 /* WebDocumentLoadStateMac.m */,
+                               65FFB7FA0AD0B7D30048CD05 /* WebDocumentLoaderMac.h */,
+                               65FFB7FB0AD0B7D30048CD05 /* WebDocumentLoaderMac.m */,
                                F52CA6BD02DF9D0F018635CA /* HTML */,
                                51E94C0706C02CA300A9B09E /* PDF */,
                                8373435A0624EE0D00F3B289 /* WebArchive.h */,
                                51E4D3990A886B5E00ECEE2C /* WebIconDatabaseBridge.h in Headers */,
                                6538B1C80A90596D00A07522 /* WebFormDataStream.h in Headers */,
                                65A734610A923948001B57E8 /* WebPlugInStreamLoaderDelegate.h in Headers */,
-                               659044280A9D3B4200E89459 /* WebDocumentLoadState.h in Headers */,
+                               659044280A9D3B4200E89459 /* WebDocumentLoader.h in Headers */,
                                1C0D40870AC1C8F40009C113 /* WebKitVersionChecks.h in Headers */,
-                               65FFB7FC0AD0B7D30048CD05 /* WebDocumentLoadStateMac.h in Headers */,
+                               65FFB7FC0AD0B7D30048CD05 /* WebDocumentLoaderMac.h in Headers */,
                                930653940AD6FEF6008E969A /* WebFrameLoaderClient.h in Headers */,
                        );
                        runOnlyForDeploymentPostprocessing = 0;
                                651A93880A83F883007FEDF0 /* WebDataProtocol.m in Sources */,
                                51E4D39A0A886B5E00ECEE2C /* WebIconDatabaseBridge.m in Sources */,
                                6538B1C90A90596E00A07522 /* WebFormDataStream.m in Sources */,
-                               659044290A9D3B4200E89459 /* WebDocumentLoadState.m in Sources */,
+                               659044290A9D3B4200E89459 /* WebDocumentLoader.m in Sources */,
                                1C0D40880AC1C8F40009C113 /* WebKitVersionChecks.m in Sources */,
-                               65FFB7FD0AD0B7D30048CD05 /* WebDocumentLoadStateMac.m in Sources */,
+                               65FFB7FD0AD0B7D30048CD05 /* WebDocumentLoaderMac.m in Sources */,
                        );
                        runOnlyForDeploymentPostprocessing = 0;
                };
index bd2523fbbec42287fce77c7246e9dd73a3f0ea97..d6e76a82f83d868730104a56af1a48bac29942f5 100644 (file)
 #import <WebKit/DOMHTML.h>
 #import <WebKit/DOMPrivate.h>
 #import <WebKitSystemInterface.h>
-#import "WebDocumentLoadStateMac.h"
+#import "WebDocumentLoaderMac.h"
 
 @interface WebDataSourcePrivate : NSObject
 {
     @public
     
-    WebDocumentLoadStateMac *loadState;
+    WebDocumentLoaderMac *loader;
    
     id <WebDocumentRepresentation> representation;
     
@@ -75,9 +75,9 @@
 
 - (void)dealloc
 {
-    ASSERT(![loadState isLoading]);
+    ASSERT(![loader isLoading]);
 
-    [loadState release];
+    [loader release];
     
     [representation release];
     [unarchivingState release];
@@ -123,7 +123,7 @@ static inline void addTypesFromClass(NSMutableDictionary *allTypes, Class class,
 
 - (NSError *)_mainDocumentError
 {
-    return [_private->loadState mainDocumentError];
+    return [_private->loader mainDocumentError];
 }
 
 - (void)_addSubframeArchives:(NSArray *)subframeArchives
@@ -285,9 +285,9 @@ static inline void addTypesFromClass(NSMutableDictionary *allTypes, Class class,
 
 - (void)_loadFromPageCache:(NSDictionary *)pageCache
 {
-    [_private->loadState prepareForLoadStart];
+    [_private->loader prepareForLoadStart];
     _private->loadingFromPageCache = YES;
-    [_private->loadState setCommitted:YES];
+    [_private->loader setCommitted:YES];
     [[self webFrame] _commitProvisionalLoad:pageCache];
 }
 
@@ -298,13 +298,13 @@ static inline void addTypesFromClass(NSMutableDictionary *allTypes, Class class,
 
 - (WebFrameBridge *)_bridge
 {
-    ASSERT([_private->loadState isCommitted]);
+    ASSERT([_private->loader isCommitted]);
     return [[self webFrame] _bridge];
 }
 
 - (WebView *)_webView
 {
-    return [[[_private->loadState frameLoader] webFrame] webView];
+    return [[[_private->loader frameLoader] webFrame] webView];
 }
 
 - (BOOL)_isDocumentHTML
@@ -337,9 +337,9 @@ static inline void addTypesFromClass(NSMutableDictionary *allTypes, Class class,
     // Return the URL to be used for history and B/F list.
     // Returns nil for WebDataProtocol URLs that aren't alternates 
     // for unreachable URLs, because these can't be stored in history.
-    NSURL *URL = [[_private->loadState originalRequestCopy] URL];
+    NSURL *URL = [[_private->loader originalRequestCopy] URL];
     if ([WebDataProtocol _webIsDataProtocolURL:URL])
-        URL = [[_private->loadState originalRequestCopy] _webDataRequestUnreachableURL];
+        URL = [[_private->loader originalRequestCopy] _webDataRequestUnreachableURL];
     
     return [URL _webkit_canonicalize];
 }
@@ -351,12 +351,12 @@ static inline void addTypesFromClass(NSMutableDictionary *allTypes, Class class,
     [_private->unarchivingState addArchive:archive];
 }
 
-- (WebDocumentLoadState *)_documentLoadState
+- (WebDocumentLoader *)_documentLoader
 {
-    return _private->loadState;
+    return _private->loader;
 }
 
-- (id)_initWithDocumentLoadState:(WebDocumentLoadStateMac *)loadState
+- (id)_initWithDocumentLoader:(WebDocumentLoaderMac *)loader
 {
     self = [super init];
     if (!self) {
@@ -365,10 +365,10 @@ static inline void addTypesFromClass(NSMutableDictionary *allTypes, Class class,
     
     _private = [[WebDataSourcePrivate alloc] init];
     
-    _private->loadState = [loadState retain];
+    _private->loader = [loader retain];
         
-    LOG(Loading, "creating datasource for %@", [[_private->loadState request] URL]);
-    WKSupportsMultipartXMixedReplace([_private->loadState request]);
+    LOG(Loading, "creating datasource for %@", [[_private->loader request] URL]);
+    WKSupportsMultipartXMixedReplace([_private->loader request]);
     
     ++WebDataSourceCount;
     
@@ -382,12 +382,12 @@ static inline void addTypesFromClass(NSMutableDictionary *allTypes, Class class,
 
 -(id)initWithRequest:(NSURLRequest *)request
 {
-    return [self _initWithDocumentLoadState:[[WebDocumentLoadState alloc] initWithRequest:request]];
+    return [self _initWithDocumentLoader:[[WebDocumentLoader alloc] initWithRequest:request]];
 }
 
 - (void)dealloc
 {
-    ASSERT([[_private->loadState frameLoader] activeDataSource] != self || ![[_private->loadState frameLoader] isLoading]);
+    ASSERT([[_private->loader frameLoader] activeDataSource] != self || ![[_private->loader frameLoader] isLoading]);
 
     --WebDataSourceCount;
     
@@ -405,7 +405,7 @@ static inline void addTypesFromClass(NSMutableDictionary *allTypes, Class class,
 
 - (NSData *)data
 {
-    return [_private->loadState mainResourceData];
+    return [_private->loader mainResourceData];
 }
 
 - (id <WebDocumentRepresentation>)representation
@@ -415,30 +415,30 @@ static inline void addTypesFromClass(NSMutableDictionary *allTypes, Class class,
 
 - (WebFrame *)webFrame
 {
-    return [[_private->loadState frameLoader] webFrame];
+    return [[_private->loader frameLoader] webFrame];
 }
 
 -(NSURLRequest *)initialRequest
 {
-    NSURLRequest *clientRequest = [[_private->loadState originalRequest] _webDataRequestExternalRequest];
+    NSURLRequest *clientRequest = [[_private->loader originalRequest] _webDataRequestExternalRequest];
     if (!clientRequest)
-        clientRequest = [_private->loadState originalRequest];
+        clientRequest = [_private->loader originalRequest];
     return clientRequest;
 }
 
 -(NSMutableURLRequest *)request
 {
-    return [_private->loadState request];
+    return [_private->loader request];
 }
 
 - (NSURLResponse *)response
 {
-    return [_private->loadState response];
+    return [_private->loader response];
 }
 
 - (NSString *)textEncodingName
 {
-    NSString *textEncodingName = [_private->loadState overrideEncoding];
+    NSString *textEncodingName = [_private->loader overrideEncoding];
 
     if (!textEncodingName)
         textEncodingName = [[self response] textEncodingName];
@@ -448,7 +448,7 @@ static inline void addTypesFromClass(NSMutableDictionary *allTypes, Class class,
 
 - (BOOL)isLoading
 {
-    return [_private->loadState isLoadingInAPISense];
+    return [_private->loader isLoadingInAPISense];
 }
 
 // Returns nil or the page title.
@@ -459,13 +459,13 @@ static inline void addTypesFromClass(NSMutableDictionary *allTypes, Class class,
 
 - (NSURL *)unreachableURL
 {
-    return [[_private->loadState originalRequest] _webDataRequestUnreachableURL];
+    return [[_private->loader originalRequest] _webDataRequestUnreachableURL];
 }
 
 - (WebArchive *)webArchive
 {
     // it makes no sense to grab a WebArchive from an uncommitted document.
-    if (![_private->loadState isCommitted])
+    if (![_private->loader isCommitted])
         return nil;
 
     return [WebArchiver archiveFrame:[self webFrame]];
index a566312a9b0f814884e2081d03264a59baa7c7b1..b9e0e9637b97f1bbfc4214bc7274fe14c5f38583 100644 (file)
@@ -46,8 +46,8 @@
 @class WebResource;
 @class WebUnarchivingState;
 @class WebView;
-@class WebDocumentLoadState;
-@class WebDocumentLoadStateMac;
+@class WebDocumentLoader;
+@class WebDocumentLoaderMac;
 
 @protocol WebDocumentRepresentation;
 
 - (void)_replaceSelectionWithArchive:(WebArchive *)archive selectReplacement:(BOOL)selectReplacement;
 - (WebResource *)_archivedSubresourceForURL:(NSURL *)URL;
 - (WebResource *)_archivedSubresourceForURL:(NSURL *)URL;
-- (id)_initWithDocumentLoadState:(WebDocumentLoadStateMac *)loadState;
+- (id)_initWithDocumentLoader:(WebDocumentLoaderMac *)loader;
 - (void)_finishedLoading;
 - (void)_receivedData:(NSData *)data;
 - (void)_revertToProvisionalState;
 - (void)_setMainDocumentError:(NSError *)error;
 - (void)_clearUnarchivingState;
-- (WebDocumentLoadState *)_documentLoadState;
+- (WebDocumentLoader *)_documentLoader;
 
 @end
similarity index 94%
rename from WebKit/WebView/WebDocumentLoadStateMac.h
rename to WebKit/WebView/WebDocumentLoaderMac.h
index f8b32401df4e6345c05b1b0a34dd57d65f77df50..8043f3a60f083f0674aab9c1ef0682775ea5f21f 100644 (file)
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
 
-#import <WebKit/WebDocumentLoadState.h>
+#import <WebKit/WebDocumentLoader.h>
 
 @class WebDataSource;
 
-@interface WebDocumentLoadStateMac : WebDocumentLoadState
+@interface WebDocumentLoaderMac : WebDocumentLoader
 {
     @public
     WebDataSource *dataSource;
similarity index 96%
rename from WebKit/WebView/WebDocumentLoadStateMac.m
rename to WebKit/WebView/WebDocumentLoaderMac.m
index 72fe3a05c41b9b044b0deafbc86e87e4ade87989..d976ff63c6655a4860e93a81ed8081f42a857b71 100644 (file)
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
 
-#import "WebDocumentLoadStateMac.h"
+#import "WebDocumentLoaderMac.h"
 
 #import <JavaScriptCore/Assertions.h>
 
 #import <WebKitSystemInterface.h>
 
-@implementation WebDocumentLoadStateMac
+@implementation WebDocumentLoaderMac
 
 
 - (id)initWithRequest:(NSURLRequest *)req
index b8f28f6f36224e92108746d6e21520a310b75a4b..c5a7329b112a72f731149c406de57d91ece0107a 100644 (file)
@@ -35,7 +35,7 @@
 #import "WebDefaultResourceLoadDelegate.h"
 #import "WebDefaultUIDelegate.h"
 #import "WebDocumentInternal.h"
-#import "WebDocumentLoadStateMac.h"
+#import "WebDocumentLoaderMac.h"
 #import "WebFormDataStream.h"
 #import "WebFrameBridge.h"
 #import "WebFrameLoadDelegate.h"
@@ -294,7 +294,7 @@ static inline WebFrame *Frame(WebCoreFrameBridge *bridge)
     WebHistoryItem *bfItem;
 
     if (useOriginal)
-        request = [[dataSrc _documentLoadState] originalRequestCopy];
+        request = [[dataSrc _documentLoader] originalRequestCopy];
     else
         request = [dataSrc request];
 
@@ -303,7 +303,7 @@ static inline WebFrame *Frame(WebCoreFrameBridge *bridge)
         originalURL = unreachableURL;
     } else {
         URL = [request URL];
-        originalURL = [[[dataSrc _documentLoadState] originalRequestCopy] URL];
+        originalURL = [[[dataSrc _documentLoader] originalRequestCopy] URL];
     }
 
     LOG (History, "creating item for %@", request);
@@ -432,7 +432,7 @@ static inline WebFrame *Frame(WebCoreFrameBridge *bridge)
 - (void)_receivedMainResourceError:(NSError *)error
 {
     if ([_private->frameLoader state] == WebFrameStateProvisional) {
-        NSURL *failedURL = [[[_private->frameLoader provisionalDocumentLoadState] originalRequestCopy] URL];
+        NSURL *failedURL = [[[_private->frameLoader provisionalDocumentLoader] originalRequestCopy] URL];
         // When we are pre-commit, the currentItem is where the pageCache data resides
         NSDictionary *pageCache = [[_private currentItem] pageCache];
         [[self _bridge] didNotOpenURL:failedURL pageCache:pageCache];
@@ -524,7 +524,7 @@ static inline WebFrame *Frame(WebCoreFrameBridge *bridge)
                 }
                 // Update the last visited time.  Mostly interesting for URL autocompletion
                 // statistics.
-                NSURL *URL = [[[[ds _documentLoadState] originalRequestCopy] URL] _webkit_canonicalize];
+                NSURL *URL = [[[[ds _documentLoader] originalRequestCopy] URL] _webkit_canonicalize];
                 WebHistory *sharedHistory = [WebHistory optionalSharedHistory];
                 WebHistoryItem *oldItem = [sharedHistory itemForURL:URL];
                 if (oldItem)
@@ -540,7 +540,7 @@ static inline WebFrame *Frame(WebCoreFrameBridge *bridge)
                 break;
                 
             case WebFrameLoadTypeStandard:
-                if (![[ds _documentLoadState] isClientRedirect]) {
+                if (![[ds _documentLoader] isClientRedirect]) {
                     // Add item to history and BF list
                     NSURL *URL = [ds _URLForHistory];
                     if (URL && ![URL _web_isEmpty]){
@@ -575,7 +575,7 @@ static inline WebFrame *Frame(WebCoreFrameBridge *bridge)
                 
             case WebFrameLoadTypeInternal:
                 // Add an item to the item tree for this frame
-                ASSERT(![[ds _documentLoadState] isClientRedirect]);
+                ASSERT(![[ds _documentLoader] isClientRedirect]);
                 WebFrame *parentFrame = [self parentFrame];
                 if (parentFrame) {
                     WebHistoryItem *parentItem = [parentFrame->_private currentItem];
@@ -725,7 +725,7 @@ static inline WebFrame *Frame(WebCoreFrameBridge *bridge)
 // Called after we send an openURL:... down to WebCore.
 - (void)_opened
 {
-    if ([_private->frameLoader loadType] == WebFrameLoadTypeStandard && [[[self dataSource] _documentLoadState] isClientRedirect]) {
+    if ([_private->frameLoader loadType] == WebFrameLoadTypeStandard && [[[self dataSource] _documentLoader] isClientRedirect]) {
         // Clear out form data so we don't try to restore it into the incoming page.  Must happen after
         // khtml has closed the URL and saved away the form state.
         WebHistoryItem *item = [_private currentItem];
@@ -742,7 +742,7 @@ static inline WebFrame *Frame(WebCoreFrameBridge *bridge)
         [view setNeedsLayout: YES];
         [view layout];
 
-        NSArray *responses = [[_private->frameLoader documentLoadState] responses];
+        NSArray *responses = [[_private->frameLoader documentLoader] responses];
         NSURLResponse *response;
         int i, count = [responses count];
         for (i = 0; i < count; i++){
@@ -762,7 +762,7 @@ static inline WebFrame *Frame(WebCoreFrameBridge *bridge)
         // premature release.
         [[_private currentItem] setHasPageCache:NO];
 
-        [[_private->frameLoader documentLoadState] setPrimaryLoadComplete:YES];
+        [[_private->frameLoader documentLoader] setPrimaryLoadComplete:YES];
         // why only this frame and not parent frames?
         [self _checkLoadCompleteForThisFrame];
     }
@@ -804,7 +804,7 @@ static inline WebFrame *Frame(WebCoreFrameBridge *bridge)
                     // must be, to be in this branch of the if? And is it ok to just do 
                     // a full-on stopLoading?
                     [self _stopLoadingSubframes];
-                    [[pd _documentLoadState] stopLoading];
+                    [[pd _documentLoader] stopLoading];
 
                     // Finish resetting the load state, but only if another load hasn't been started by the
                     // delegate callback.
@@ -1021,7 +1021,7 @@ static inline WebFrame *Frame(WebCoreFrameBridge *bridge)
 
         // Fake the URL change by updating the data source's request.  This will no longer
         // be necessary if we do the better fix described above.
-        [[_private->frameLoader documentLoadState] replaceRequestURLForAnchorScrollWithURL:itemURL];
+        [[_private->frameLoader documentLoader] replaceRequestURLForAnchorScrollWithURL:itemURL];
         
         [[[self webView] _frameLoadDelegateForwarder] webView:[self webView]
                                didChangeLocationWithinPageForFrame:self];
@@ -1262,7 +1262,7 @@ static inline WebFrame *Frame(WebCoreFrameBridge *bridge)
     LOG(Redirect, "%@(%p) _private->quickRedirectComing = %d", [self name], self, (int)_private->quickRedirectComing);
     _private->quickRedirectComing = NO;
 
-    [[_private->frameLoader documentLoadState] replaceRequestURLForAnchorScrollWithURL:URL];
+    [[_private->frameLoader documentLoader] replaceRequestURLForAnchorScrollWithURL:URL];
     if (!isRedirect && ![self _shouldTreatURLAsSameAsCurrent:URL]) {
         // NB: must happen after _setURL, since we add based on the current request.
         // Must also happen before we openURL and displace the scroll position, since
@@ -1390,7 +1390,7 @@ exit:
 
         // FIXME: What about load types other than Standard and Reload?
 
-        [[oldDataSource _documentLoadState] setTriggeringAction:action];
+        [[oldDataSource _documentLoader] setTriggeringAction:action];
         [_private->frameLoader invalidatePendingPolicyDecisionCallingDefaultAction:YES];
         [_private->frameLoader checkNavigationPolicyForRequest:request
             dataSource:oldDataSource formState:formState
@@ -1402,7 +1402,7 @@ exit:
         if (isRedirect) {
             LOG(Redirect, "%@(%p) _private->quickRedirectComing was %d", [self name], self, (int)isRedirect);
             _private->quickRedirectComing = NO;
-            [[[self provisionalDataSource] _documentLoadState] setIsClientRedirect:YES];
+            [[[self provisionalDataSource] _documentLoader] setIsClientRedirect:YES];
         } else if (sameURL) {
             // Example of this case are sites that reload the same URL with a different cookie
             // driving the generated content, or a master frame with links that drive a target
@@ -1598,7 +1598,7 @@ exit:
 - (void)_addChild:(WebFrame *)child
 {
     [[self _bridge] appendChild:[child _bridge]];
-    [[[child dataSource] _documentLoadState] setOverrideEncoding:[[[self dataSource] _documentLoadState] overrideEncoding]];  
+    [[[child dataSource] _documentLoader] setOverrideEncoding:[[[self dataSource] _documentLoader] overrideEncoding]];  
 }
 
 // If we bailed out of a b/f navigation, we might need to set the b/f cursor back to the current
@@ -2093,7 +2093,7 @@ exit:
             && loadType != WebFrameLoadTypeReloadAllowingStaleData
             && loadType != WebFrameLoadTypeSame
             && ![[self dataSource] isLoading]
-            && ![[_private->frameLoader documentLoadState] isStopping]) {
+            && ![[_private->frameLoader documentLoader] isStopping]) {
         if ([[[self dataSource] representation] isKindOfClass: [WebHTMLRepresentation class]]) {
             if (![item pageCache]){
                 // Add the items to this page's cache.
@@ -2154,20 +2154,20 @@ exit:
     [_private->frameLoader frameLoadCompleted];
 }
 
-- (WebDataSource *)_dataSourceForDocumentLoadState:(WebDocumentLoadState *)loadState
+- (WebDataSource *)_dataSourceForDocumentLoader:(WebDocumentLoader *)loader
 {
-    return [(WebDocumentLoadStateMac *)loadState dataSource];
+    return [(WebDocumentLoaderMac *)loader dataSource];
 }
 
-- (WebDocumentLoadState *)_createDocumentLoadStateWithRequest:(NSURLRequest *)request
+- (WebDocumentLoader *)_createDocumentLoaderWithRequest:(NSURLRequest *)request
 {
-    WebDocumentLoadStateMac *loadState = [[WebDocumentLoadStateMac alloc] initWithRequest:request];
+    WebDocumentLoaderMac *loader = [[WebDocumentLoaderMac alloc] initWithRequest:request];
     
-    WebDataSource *dataSource = [[WebDataSource alloc] _initWithDocumentLoadState:loadState];
-    [loadState setDataSource:dataSource];
+    WebDataSource *dataSource = [[WebDataSource alloc] _initWithDocumentLoader:loader];
+    [loader setDataSource:dataSource];
     [dataSource release];
 
-    return loadState;
+    return loader;
 }
 
 /*
index 740a3418a7d4997862b5ed201bff21b905bb726e..8eaa939dd9f41482420a52b5d62add0a6fc7c837 100644 (file)
@@ -31,7 +31,7 @@
 #import <WebKit/WebFramePrivate.h>
 #import "WebPolicyDelegatePrivate.h"
 
-@class WebDocumentLoadState;
+@class WebDocumentLoader;
 @class WebInspector;
 @class WebFrameLoader;
 @class WebFrameView;
@@ -90,8 +90,8 @@
 - (void)_provisionalLoadStarted;
 - (void)_prepareForDataSourceReplacement;
 - (void)_frameLoadCompleted;
-- (WebDataSource *)_dataSourceForDocumentLoadState:(WebDocumentLoadState *)loadState;
-- (WebDocumentLoadState *)_createDocumentLoadStateWithRequest:(NSURLRequest *)request;
+- (WebDataSource *)_dataSourceForDocumentLoader:(WebDocumentLoader *)loader;
+- (WebDocumentLoader *)_createDocumentLoaderWithRequest:(NSURLRequest *)request;
 - (void)_didReceiveServerRedirectForProvisionalLoadForFrame;
 
 - (NSURLRequest *)_webDataRequestForData:(NSData *)data MIMEType:(NSString *)MIMEType textEncodingName:(NSString *)encodingName baseURL:(NSURL *)URL unreachableURL:(NSURL *)unreachableURL;
index 020c77481fe3cf7e91b4d35941823073fd60d4da..765ead26fb17cc2ad46b1f230e5a7ed1a49d3743 100644 (file)
 
 - (NSString *)title
 {
-    return [[_private->dataSource _documentLoadState] title];
+    return [[_private->dataSource _documentLoader] title];
 }
 
 - (DOMDocument *)DOMDocument
index a119ad09122785148313d4b249e0e4529113733b..94edb8cdde44341e3f4f598c9be8766d6bd78f80 100644 (file)
@@ -2192,7 +2192,7 @@ NS_ENDHANDLER
     if (dataSource == nil) {
         return nil;
     }
-    return [[dataSource _documentLoadState] overrideEncoding];
+    return [[dataSource _documentLoader] overrideEncoding];
 }
 
 - (NSString *)customTextEncodingName