Reviewed by John.
authorandersca <andersca@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 19 Apr 2007 16:47:51 +0000 (16:47 +0000)
committerandersca <andersca@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 19 Apr 2007 16:47:51 +0000 (16:47 +0000)
        <rdar://problem/5137002>
        REGRESSION (r20812): [WebFrame DOMDocument] is returning non-nil value in bookmarks view, causing trouble in Safari

        Put back the MIME type check as a workaround.
        * WebView/WebFrame.mm:
        (-[WebFrame DOMDocument]):

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

WebKit/ChangeLog
WebKit/WebKit.xcodeproj/project.pbxproj
WebKit/WebView/WebFrame.mm

index 5fe2eb9b1caa9558045a141b54c134bd06e1ce00..7576db783e81d58b0657da6b7140aa0a94befd9a 100644 (file)
@@ -1,3 +1,14 @@
+2007-04-19  Anders Carlsson  <andersca@apple.com>
+
+        Reviewed by John.
+
+        <rdar://problem/5137002>
+        REGRESSION (r20812): [WebFrame DOMDocument] is returning non-nil value in bookmarks view, causing trouble in Safari
+
+        Put back the MIME type check as a workaround.
+        * WebView/WebFrame.mm:
+        (-[WebFrame DOMDocument]):
+
 2007-04-19  Mark Rowe  <mrowe@apple.com>
 
         Reviewed by Oliver and Adam.
index d7aba35a4ebd7a811ec3a35f33810bc06b556948..8080ac8ec41f1a1cd80b0b592683d20856d9d91e 100644 (file)
                0867D690FE84028FC02AAC07 /* Project object */ = {
                        isa = PBXProject;
                        buildConfigurationList = 149C283208902B0F008A9EFC /* Build configuration list for PBXProject "WebKit" */;
-                       compatibilityVersion = "Xcode 2.4";
                        hasScannedForEncodings = 1;
                        knownRegions = (
                                English,
                        productRefGroup = 034768DFFF38A50411DB9C8B /* Products */;
                        projectDirPath = "";
                        projectRoot = "";
-                       shouldCheckCompatibility = 1;
                        targets = (
                                9398100A0824BF01008DF038 /* WebKit */,
                        );
index 6a8f7c3193691e33166cfd1c2d7e0567707e2e53..079fdc411afec481a4982e2146776da3d8296c77 100644 (file)
@@ -705,6 +705,12 @@ static inline WebDataSource *dataSource(DocumentLoader* loader)
     if (!coreFrame)
         return nil;
     
+    // FIXME: <rdar://problem/5145841> When loading a custom view/representation 
+    // into a web frame, the old document can still be around. This makes sure that
+    // we'll return nil in those cases.
+    if (![[self dataSource] _isDocumentHTML]) 
+        return nil; 
+
     Document* document = coreFrame->document();
     
     // According to the documentation, we should return nil if the frame doesn't have a document.