2011-01-23 Alexey Proskuryakov <ap@apple.com>
authorap@apple.com <ap@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 23 Jan 2011 22:28:01 +0000 (22:28 +0000)
committerap@apple.com <ap@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 23 Jan 2011 22:28:01 +0000 (22:28 +0000)
commit8a2c781de45beaa287ad37971adc8d6fe83c5a22
tree0de0d7545ac7d629b81a67b2733e2e869b1d4ab4
parent9862e93c9b17502e13d9d709f07152198fcd6896
2011-01-23  Alexey Proskuryakov  <ap@apple.com>

        Reviewed by Dan Bernstein.

        https://bugs.webkit.org/show_bug.cgi?id=52968
        Use a separate NSView for printing

        Also addresses <rdar://problem/8900148> Improper check for
        -[NSGraphicsContext currentContextDrawingToScreen]

        * UIProcess/API/mac/WKPrintingView.h: Added.
        * UIProcess/API/mac/WKPrintingView.mm: Added.
        (-[WKPrintingView initWithFrameProxy:]):
        (-[WKPrintingView isFlipped]):
        (-[WKPrintingView _adjustPrintingMarginsForHeaderAndFooter]):
        (-[WKPrintingView knowsPageRange:]):
        (-[WKPrintingView _recursiveDisplayRectIfNeededIgnoringOpacity:isVisibleRect:rectIsVisibleRectForView:topView:]):
        (-[WKPrintingView drawPageBorderWithSize:]):
        (-[WKPrintingView _provideTotalScaleFactorForPrintOperation:]):
        (-[WKPrintingView rectForPage:]):
        * UIProcess/API/mac/WKView.mm:
        (-[WKView drawRect:]):
        (-[WKView canChangeFrameLayout:]):
        (-[WKView printOperationWithPrintInfo:forFrame:]):
        * WebKit2.xcodeproj/project.pbxproj:
        Moved printing code to a separate view, simplifying as appropriate. The view is currently not
        referenced by anything in WebKit2 directly, being owned by NSPrintOperation.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@76470 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebKit2/ChangeLog
Source/WebKit2/UIProcess/API/mac/WKPrintingView.h [new file with mode: 0644]
Source/WebKit2/UIProcess/API/mac/WKPrintingView.mm [new file with mode: 0644]
Source/WebKit2/UIProcess/API/mac/WKView.mm
Source/WebKit2/WebKit2.xcodeproj/project.pbxproj