[webkit-changes] cvs commit: WebKit/WebView.subproj WebBaseResourceHandleDelegate.h WebBaseResourceHandleDelegate.m

Timothy thatcher at opensource.apple.com
Thu Sep 29 23:53:34 PDT 2005


thatcher    05/09/29 23:53:34

  Modified:    .        Tag: Safari-Den-branch ChangeLog
               WebCoreSupport.subproj Tag: Safari-Den-branch
                        WebSubresourceClient.h WebSubresourceClient.m
               WebView.subproj Tag: Safari-Den-branch
                        WebBaseResourceHandleDelegate.h
                        WebBaseResourceHandleDelegate.m
  Log:
          Merged fix from TOT to Safari-Den-branch
  
      2005-09-28  Justin Garcia  <justin.garcia at apple.com>
  
          Reviewed by geoff
  
          Fixed <rdar://problem/4276596> multipart/x-mixed-replace: saved inline images appear only partially loaded
          Fixed <rdar://problem/4265439> progress bar should look complete even if there is some more multipart content being loaded
  
          * WebCoreSupport.subproj/WebSubresourceLoader.h:
          * WebCoreSupport.subproj/WebSubresourceLoader.m:
          (-[WebSubresourceLoader didReceiveResponse:]):
          Now calls signalFinish and saveResource.
  
          (-[WebSubresourceLoader signalFinish]):
          Added.  Does the part of didFinishLoading that signals to the WebDataSource and load delegates that the load is finished.
  
          (-[WebSubresourceLoader didFinishLoading]):
          * WebView.subproj/WebLoader.h:
          * WebView.subproj/WebLoader.m:
          (-[NSURLProtocol signalFinish]):
          Similar to above
  
          (-[NSURLProtocol didFinishLoading]):
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.3118.4.67.2.3 +27 -0     WebKit/ChangeLog
  
  Index: ChangeLog
  ===================================================================
  RCS file: /cvs/root/WebKit/ChangeLog,v
  retrieving revision 1.3118.4.67.2.2
  retrieving revision 1.3118.4.67.2.3
  diff -u -r1.3118.4.67.2.2 -r1.3118.4.67.2.3
  --- ChangeLog	16 Sep 2005 22:13:54 -0000	1.3118.4.67.2.2
  +++ ChangeLog	30 Sep 2005 06:53:18 -0000	1.3118.4.67.2.3
  @@ -1,3 +1,30 @@
  +2005-09-29  Timothy Hatcher  <timothy at apple.com>
  +
  +        Merged fix from TOT to Safari-Den-branch
  +
  +    2005-09-28  Justin Garcia  <justin.garcia at apple.com>
  +
  +        Reviewed by geoff
  +        
  +        Fixed <rdar://problem/4276596> multipart/x-mixed-replace: saved inline images appear only partially loaded
  +        Fixed <rdar://problem/4265439> progress bar should look complete even if there is some more multipart content being loaded
  +
  +        * WebCoreSupport.subproj/WebSubresourceLoader.h:
  +        * WebCoreSupport.subproj/WebSubresourceLoader.m:
  +        (-[WebSubresourceLoader didReceiveResponse:]):
  +        Now calls signalFinish and saveResource.
  +        
  +        (-[WebSubresourceLoader signalFinish]): 
  +        Added.  Does the part of didFinishLoading that signals to the WebDataSource and load delegates that the load is finished.
  +        
  +        (-[WebSubresourceLoader didFinishLoading]):
  +        * WebView.subproj/WebLoader.h:
  +        * WebView.subproj/WebLoader.m:
  +        (-[NSURLProtocol signalFinish]):
  +        Similar to above
  +        
  +        (-[NSURLProtocol didFinishLoading]):
  +
   === Safari-416.8 ===
   
   2005-09-16  Timothy Hatcher  <timothy at apple.com>
  
  
  
  No                   revision
  
  
  No                   revision
  
  
  1.17.22.1 +2 -0      WebKit/WebCoreSupport.subproj/Attic/WebSubresourceClient.h
  
  Index: WebSubresourceClient.h
  ===================================================================
  RCS file: /cvs/root/WebKit/WebCoreSupport.subproj/Attic/WebSubresourceClient.h,v
  retrieving revision 1.17
  retrieving revision 1.17.22.1
  diff -u -r1.17 -r1.17.22.1
  --- WebSubresourceClient.h	30 Aug 2004 20:35:40 -0000	1.17
  +++ WebSubresourceClient.h	30 Sep 2005 06:53:32 -0000	1.17.22.1
  @@ -17,6 +17,8 @@
       id <WebCoreResourceLoader> loader;
   }
   
  +- (void)signalFinish;
  +
   + (WebSubresourceClient *)startLoadingResource:(id <WebCoreResourceLoader>)rLoader
                                          withURL:(NSURL *)URL 
                                    customHeaders:(NSDictionary *)customHeaders
  
  
  
  1.108.8.2.2.1 +17 -4     WebKit/WebCoreSupport.subproj/Attic/WebSubresourceClient.m
  
  Index: WebSubresourceClient.m
  ===================================================================
  RCS file: /cvs/root/WebKit/WebCoreSupport.subproj/Attic/WebSubresourceClient.m,v
  retrieving revision 1.108.8.2
  retrieving revision 1.108.8.2.2.1
  diff -u -r1.108.8.2 -r1.108.8.2.2.1
  --- WebSubresourceClient.m	9 Sep 2005 17:17:00 -0000	1.108.8.2
  +++ WebSubresourceClient.m	30 Sep 2005 06:53:32 -0000	1.108.8.2.2.1
  @@ -167,7 +167,14 @@
       if (loadingMultipartContent && [[self resourceData] length]) {
           // A subresource loader does not load multipart sections progressively, deliver the previously received data to the coreLoader all at once
           [loader addData:[self resourceData]];
  +        // Tells the dataSource to save the just completed section, necessary for saving/dragging multipart images
  +        [self saveResource];
  +        // Clears the data to make way for the next multipart section
           [self clearResourceData];
  +        
  +        // After the first multipart section is complete, signal to delegates that this load is "finished" 
  +        if (!signalledFinish)
  +            [self signalFinish];
       }
   }
   
  @@ -183,6 +190,13 @@
       [self release];
   }
   
  +- (void)signalFinish
  +{
  +    [dataSource _removeSubresourceClient:self];
  +    [[dataSource _webView] _finishedLoadingResourceFromDataSource:dataSource];
  +    [super signalFinish];
  +}
  +
   - (void)didFinishLoading
   {
       // Calling _removeSubresourceClient will likely result in a call to release, so we must retain.
  @@ -190,10 +204,9 @@
       
       [loader finishWithData:[self resourceData]];
       
  -    [dataSource _removeSubresourceClient:self];
  -    
  -    [[dataSource _webView] _finishedLoadingResourceFromDataSource:dataSource];
  -
  +    if (!signalledFinish)
  +        [self signalFinish];
  +        
       [super didFinishLoading];
   
       [self release];    
  
  
  
  No                   revision
  
  
  No                   revision
  
  
  1.38.10.4.2.1 +3 -0      WebKit/WebView.subproj/Attic/WebBaseResourceHandleDelegate.h
  
  Index: WebBaseResourceHandleDelegate.h
  ===================================================================
  RCS file: /cvs/root/WebKit/WebView.subproj/Attic/WebBaseResourceHandleDelegate.h,v
  retrieving revision 1.38.10.4
  retrieving revision 1.38.10.4.2.1
  diff -u -r1.38.10.4 -r1.38.10.4.2.1
  --- WebBaseResourceHandleDelegate.h	9 Sep 2005 17:17:01 -0000	1.38.10.4
  +++ WebBaseResourceHandleDelegate.h	30 Sep 2005 06:53:33 -0000	1.38.10.4.2.1
  @@ -27,6 +27,7 @@
       BOOL reachedTerminalState;
       BOOL loadingMultipartContent;
       BOOL supportsMultipartContent;
  +    BOOL signalledFinish;
   @private
       WebView *webView;
       NSURLResponse *response;
  @@ -48,6 +49,8 @@
   #endif
   }
   - (void)setSupportsMultipartContent:(BOOL)flag;
  +- (void)signalFinish;
  +- (void)saveResource;
   
   - (BOOL)loadWithRequest:(NSURLRequest *)request;
   
  
  
  
  1.83.4.4.2.1 +14 -6     WebKit/WebView.subproj/Attic/WebBaseResourceHandleDelegate.m
  
  Index: WebBaseResourceHandleDelegate.m
  ===================================================================
  RCS file: /cvs/root/WebKit/WebView.subproj/Attic/WebBaseResourceHandleDelegate.m,v
  retrieving revision 1.83.4.4
  retrieving revision 1.83.4.4.2.1
  diff -u -r1.83.4.4 -r1.83.4.4.2.1
  --- WebBaseResourceHandleDelegate.m	9 Sep 2005 17:17:01 -0000	1.83.4.4
  +++ WebBaseResourceHandleDelegate.m	30 Sep 2005 06:53:33 -0000	1.83.4.4.2.1
  @@ -524,6 +524,18 @@
       resourceData = [data mutableCopy];
   }
   
  +- (void)signalFinish
  +{
  +    signalledFinish = YES;
  +
  +    [webView _completeProgressForConnectionDelegate:self];    
  +    
  +    if (implementations.delegateImplementsDidFinishLoadingFromDataSource)
  +        [resourceLoadDelegate webView:webView resource:identifier didFinishLoadingFromDataSource:dataSource];
  +    else
  +        [[WebDefaultResourceLoadDelegate sharedResourceLoadDelegate] webView:webView resource:identifier didFinishLoadingFromDataSource:dataSource];
  +}
  +
   - (void)didFinishLoading
   {
       // If load has been cancelled after finishing (which could happen with a 
  @@ -536,12 +548,8 @@
   
       [self saveResource];
       
  -    [webView _completeProgressForConnectionDelegate:self];
  -
  -    if (implementations.delegateImplementsDidFinishLoadingFromDataSource)
  -        [resourceLoadDelegate webView:webView resource:identifier didFinishLoadingFromDataSource:dataSource];
  -    else
  -        [[WebDefaultResourceLoadDelegate sharedResourceLoadDelegate] webView:webView resource:identifier didFinishLoadingFromDataSource:dataSource];
  +    if (!signalledFinish)
  +        [self signalFinish];
   
       [self releaseResources];
   }
  
  
  



More information about the webkit-changes mailing list