Bug 36049

Summary: PrintContext.end() not called from PrintContext::pageNumberForElement()
Product: WebKit Reporter: Yuzo Fujishima <yuzo>
Component: Tools / TestsAssignee: Yuzo Fujishima <yuzo>
Status: RESOLVED FIXED    
Severity: Normal CC: hamaji, hayato, peter.linss, tkent
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Attachments:
Description Flags
Always call PrintContext.end() from PrintContext::pageNumberForElement().
none
Always call PrintContext.end() from PrintContext::pageNumberForElement(). hamaji: review+

Description Yuzo Fujishima 2010-03-11 22:51:06 PST
This will leave the frame in printing mode, which is not desirable.
Please see the patch for details.
Comment 1 Yuzo Fujishima 2010-03-11 22:54:06 PST
Created attachment 50578 [details]
Always call PrintContext.end() from PrintContext::pageNumberForElement().
Comment 2 Shinichiro Hamaji 2010-03-11 23:51:35 PST
Comment on attachment 50578 [details]
Always call PrintContext.end() from PrintContext::pageNumberForElement().

Thanks for the nice catch!

> +        Always call PrintContext.end() from PrintContext::pageNumberForElement().
> +        https://bugs.webkit.org/show_bug.cgi?id=36049
> +

We usually write why we don't need new tests.
Comment 3 Yuzo Fujishima 2010-03-12 01:22:13 PST
Thank you for the review.
I'll commit the change after fixing the Changelog.
Comment 4 Yuzo Fujishima 2010-03-14 23:32:14 PDT
Created attachment 50685 [details]
Always call PrintContext.end() from PrintContext::pageNumberForElement().
Comment 5 Yuzo Fujishima 2010-03-14 23:34:34 PDT
I've added a test instead of changing the log.

Can you take another look?
Comment 6 Shinichiro Hamaji 2010-03-15 00:05:50 PDT
Comment on attachment 50685 [details]
Always call PrintContext.end() from PrintContext::pageNumberForElement().

Looks good. It's unfortunate we cannot test this without images though.
Comment 7 Yuzo Fujishima 2010-03-15 01:33:32 PDT
Committed r55988: <http://trac.webkit.org/changeset/55988>