Closed Bug 70946 Opened 24 years ago Closed 24 years ago

Need to report printing progress

Categories

(Core :: Printing: Output, defect)

defect
Not set
normal

Tracking

()

VERIFIED WORKSFORME
mozilla0.9

People

(Reporter: kmcclusk, Assigned: rods)

References

Details

Attachments

(3 files)

Need to be able to communicate what page number is currently printing to an embedded application.
Target Milestone: --- → mozilla0.9
Blocks: 61672
*** Bug 70948 has been marked as a duplicate of this bug. ***
Blocks: 64841
Reassigning to Rod since he is working on a fix for this.
Assignee: dcone → rods
accepting
Status: NEW → ASSIGNED
Attached patch patchSplinter Review
Attached file PrintProgressDialog.h
I'm reviewing all but the MFC code now - kinda large...
Review Comment (also in the bug): [nsDocumentViewer.cpp] * it looks like you added 12 new member variables that are used for printing only. Can these be popped into a separate structure and a pointer to that structure used inthe DocumentViewer instead? I hate to add so much bloat to the DocumentViewer for something that is rarely used. Also note that many (most?) of these are never initialized in the ctors for the DocumentViewer. * nsPagePrintTimer: the default delay value is 500 - is this ever used? should it be a constant, or initialized to a sentinal value instead? It looks like it HAS to be set by the caller anyway in the Start method, so initialization to a sentinal value is probably better (like 0 or MAX_PRUINT32) * nsPagePrintTimer ctor does not initialze all members - mPrintOptions and mDocViewer are missed. * typo in the comment on Notify - search for 'donoe' * nsPagePrintTimer::Stop: should the timer be destroyed after it is stopped? Also, the dtor calls mTimer->Cancel but it may already be cancelled - NBD but if you clear it this would be eliminated. * PrintContent: currently asserts and returns error - comment says may be needed - plans to test or what? * SetupToPrintContent: need to check for mPrintDocList being non-null after call to new nsVoidArray * StartPagePrintTimer: NS_NewUpdateTimer will return ERROR_NO_MEMORY if it returns null, so you can condense the error checking. the check for NS_FAILED just before the mPagePrintTimer->Start is unnecessary. Also, don't you want to return the result instead of NS_OK? [nsSimplePageSequence.cpp] * nsSimplePageSequenceFrame methods should check/ASSERT the out-params pointers (StartPrint does but none of the others do). * nsSimplePageSequenceFrame::StartPrint: check / ASSERT that dc, presShell, vm ar not null. When a failure-rv is handled anyway, it should be reset to NS_OK or you will end up returning an error when you actually handled it internally (mostly around the GetLocalizedString calls). * PrintNextPage: check/assert dc, presShell, vm I did NOT review the emebedding files or the gfx files.
Chak has given me the r=chak for the mfc changes - rods
Status: ASSIGNED → RESOLVED
Closed: 24 years ago
Resolution: --- → FIXED
fixed
I see printing progress on Mac, but not on Windows.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Using MfcEmbed with todays build on WINNT it shows a print progress dialog when printing www.cnn.com and www.yahoo.com. Marking WORKSFORME.
Status: REOPENED → RESOLVED
Closed: 24 years ago24 years ago
Resolution: --- → WORKSFORME
okay I guess it works if you have MfcEMbed on . I filed a new bug to wire it up to mozilla.
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: