Index: kaddressbook/mainwidget.cpp =================================================================== --- kaddressbook/mainwidget.cpp +++ kaddressbook/mainwidget.cpp @@ -696,17 +696,18 @@ QPrintDialog printDialog(KdePrint::createPrintDialog(&printer)); + printDialog.setWindowTitle( i18n( "Print Contacts" ) ); - if ( !printDialog.exec() ) { //krazy:exclude=crashy + if (printDialog.exec() != QDialog::Accepted) { return; } - KABPrinting::PrintingWizard wizard( &printer, mItemView->selectionModel(), this ); + KABPrinting::PrintingWizard wizard( printDialog.printer(), mItemView->selectionModel(), this ); wizard.setDefaultAddressBook( currentAddressBook() ); wizard.exec(); //krazy:exclude=crashy - Settings::self()->setDefaultFileName( printer.outputFileName() ); + Settings::self()->setDefaultFileName( printDialog.printer()->outputFileName() ); Settings::self()->setPrintingStyle( wizard.printingStyle() ); Settings::self()->setSortOrder( wizard.sortOrder() ); }