Skip to content
  • darin's avatar
    LayoutTests: · 77ba6954
    darin authored
            Reviewed by Justin.
    
            - test for http://bugs.webkit.org/show_bug.cgi?id=8928
              <rdar://problem/5045708> REPRODUCIBLE ASSERT: Cannot paste HTML into a
              contenteditable region in an XHTML document (8928)
    
            * editing/pasteboard/paste-xml-expected.checksum: Added.
            * editing/pasteboard/paste-xml-expected.png: Added.
            * editing/pasteboard/paste-xml-expected.txt: Added.
            * editing/pasteboard/paste-xml.xhtml: Added.
    
    WebCore:
    
            Reviewed by Justin.
    
            - fix http://bugs.webkit.org/show_bug.cgi?id=8928
              <rdar://problem/5045708> REPRODUCIBLE ASSERT: Cannot paste HTML into a
              contenteditable region in an XHTML document (8928)
    
            Test: editing/pasteboard/paste-xml.xhtml
    
            * editing/markup.cpp: (WebCore::createFragmentFromMarkup): Added a check for 0
            here, since createContextualFragment can return 0 for XML documents that fail
            to parse. In my testing, callers all seem equipped to handle 0.
    
    WebKit:
    
            Reviewed by Justin.
    
            - fix http://bugs.webkit.org/show_bug.cgi?id=8928
              <rdar://problem/5045708> REPRODUCIBLE ASSERT: Cannot paste HTML into a
              contenteditable region in an XHTML document (8928)
    
            * WebView/WebHTMLView.mm:
            (-[WebHTMLView _hasHTMLDocument]): Added.
            (-[WebHTMLView _documentFragmentFromPasteboard:forType:inContext:subresources:]):
            Don't call AppKit's conversion from the DOM to an attributed string if the document
            is not an HTML document, to work around an AppKit limitation (Radar 5052390).
    
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@20092 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    77ba6954