Skip to content

Commit 67ed3a2

Browse files
committed
Reviewed by John Sullivan.
https://bugs.webkit.org/show_bug.cgi?id=52590 Should pass a frame into -[WKView canPrintHeadersAndFooters] * UIProcess/API/mac/WKView.h: * UIProcess/API/mac/WKView.mm: (-[WKView canChangeFrameLayout:]): Also, renamed the method to canChangeFrameLayout. Canonical link: https://commits.webkit.org/66201@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@75959 268f45cc-cd09-0410-ab3c-d52691b4dbfc
1 parent 574359a commit 67ed3a2

3 files changed

Lines changed: 14 additions & 3 deletions

File tree

Source/WebKit2/ChangeLog

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,14 @@
1+
2011-01-17 Alexey Proskuryakov <ap@apple.com>
2+
3+
Reviewed by John Sullivan.
4+
5+
https://bugs.webkit.org/show_bug.cgi?id=52590
6+
Should pass a frame into -[WKView canPrintHeadersAndFooters]
7+
8+
* UIProcess/API/mac/WKView.h:
9+
* UIProcess/API/mac/WKView.mm: (-[WKView canChangeFrameLayout:]): Also, renamed the method
10+
to canChangeFrameLayout.
11+
112
2011-01-17 Anders Carlsson <andersca@apple.com>
213

314
Reviewed by Sam Weinig.

Source/WebKit2/UIProcess/API/mac/WKView.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ WK_EXPORT
3737
- (id)initWithFrame:(NSRect)frame contextRef:(WKContextRef)contextRef pageGroupRef:(WKPageGroupRef)pageGroupRef;
3838

3939
- (NSPrintOperation *)printOperationWithPrintInfo:(NSPrintInfo *)printInfo forFrame:(WKFrameRef)frameRef;
40-
- (BOOL)canPrintHeadersAndFooters;
40+
- (BOOL)canChangeFrameLayout:(WKFrameRef)frameRef;
4141

4242
@property(readonly) WKPageRef pageRef;
4343

Source/WebKit2/UIProcess/API/mac/WKView.mm

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1292,10 +1292,10 @@ - (NSPrintOperation *)printOperationWithPrintInfo:(NSPrintInfo *)printInfo forFr
12921292
return [NSPrintOperation printOperationWithView:self printInfo:printInfo];
12931293
}
12941294

1295-
- (BOOL)canPrintHeadersAndFooters
1295+
- (BOOL)canChangeFrameLayout:(WKFrameRef)frameRef
12961296
{
12971297
// PDF documents are already paginated, so we can't change them to add headers and footers.
1298-
return !_data->_pdfViewController;
1298+
return !toImpl(frameRef)->isMainFrame() || _data->_pdfViewController;
12991299
}
13001300

13011301
@end

0 commit comments

Comments
 (0)