Closed Bug 370852 Opened 18 years ago Closed 18 years ago

Misc nsPrintEngine fixes/cleanups

Categories

(Core :: Printing: Output, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: sharparrow1, Assigned: sharparrow1)

Details

Attachments

(1 file, 1 obsolete file)

Attached patch Patch (obsolete) — Splinter Review
Two bugs:

1. Top margin isn't set correctly for printing selection.

2. Crash with testcase data:text/html,<script>print();print();</script> if you cancel both times.

Plus a couple small cleanups (the first parameter to nsIDeviceContextSpec::Init is now unsused).
Attachment #255619 - Flags: review?(roc)
+  // Keep a pointer to this in case someone cancels the print job while this
+  // function is still executing
+  nsCOMPtr<nsPrintEngine> kungFuDeathGrip(this);

I believe kung-fu deathgrips on 'this' are unfashionable. We want the caller/owner to hold the death grip.
Oooh, I just figured out what's happening.  Yeah, that's not the right fix.  I'll take out that change and file another bug.
Attached patch Patch v2Splinter Review
Attachment #255619 - Attachment is obsolete: true
Attachment #255735 - Flags: review?(roc)
Attachment #255619 - Flags: review?(roc)
Status: NEW → RESOLVED
Closed: 18 years ago
Resolution: --- → FIXED
this also fixed bug 36590

You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: