[Webkit-unassigned] [Bug 36159] Move code related with printing defined in WebFrame.mm to WebCore::PrintContext
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Wed Mar 17 01:32:23 PDT 2010
https://bugs.webkit.org/show_bug.cgi?id=36159
Shinichiro Hamaji <hamaji at chromium.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #50880|review? |review-
Flag| |
--- Comment #5 from Shinichiro Hamaji <hamaji at chromium.org> 2010-03-17 01:32:23 PST ---
(From update of attachment 50880)
Basically, looks good. r- for a few style nitpicks.
> - RenderView* root = toRenderView(m_frame->document()->renderer());
> -
> - if (!root) {
> - LOG_ERROR("document to be printed has no renderer");
> + if (userScaleFactor <= 0) {
> + LOG_ERROR("userScaleFactor has bad value %.2f", userScaleFactor);
> return;
> }
>
> + RenderView* root = toRenderView(m_frame->document()->renderer());
> +
It seems like NULL check for root was gone. Is this OK?
> + const Vector<IntRect>& pageRects = printContext.pageRects();
> + const size_t pageCount = pageRects.size();
> + for (size_t pageNumber = 0; pageNumber < pageCount; ++pageNumber) {
> + const IntRect& pageRect = pageRects[pageNumber];
> + NSValue* val = [NSValue valueWithRect: NSMakeRect(pageRect.x(), pageRect.y(), pageRect.width(), pageRect.height())];
> + [pages addObject: val];
- Two more spaces for indent here.
- Cannot we use IntRect::operator NSRect() to create NSRect? (maybe it's not in
WebCore.base.exp?)
--
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
More information about the webkit-unassigned
mailing list