]> git.pld-linux.org Git - packages/libreoffice.git/blame - openoffice-print-dialog.patch
- up
[packages/libreoffice.git] / openoffice-print-dialog.patch
CommitLineData
88411c4e 1Index: svtools/source/dialogs/printdlg.cxx
2===================================================================
3RCS file: /cvs/util/svtools/source/dialogs/printdlg.cxx,v
4retrieving revision 1.16
63358dee
AM
5--- svtools/source/dialogs/printdlg.cxx.orig 2004-03-30 19:47:51.000000000 +0000
6+++ svtools/source/dialogs/printdlg.cxx 2004-03-30 19:51:29.000000000 +0000
7@@ -431,6 +431,10 @@
cd99a028
AM
8 {
9 try
10 {
11+ INetURLObject aLocation( maFiPrintFile.GetText(), INET_PROT_FILE );
63358dee 12+
cd99a028
AM
13+ xFilePicker->setDefaultName( aLocation.GetLastName() );
14+ xFilePicker->setDisplayDirectory ( aLocation.GetPartBeforeLastName() );
88411c4e 15 #ifdef UNX
cd99a028
AM
16 // add PostScript and PDF
17 if( ! Application::IsRemoteServer() )
63358dee
AM
18@@ -449,6 +453,10 @@
19 xFilterMgr->appendFilter( OUString( RTL_CONSTASCII_USTRINGPARAM( "PostScript" ) ), OUString( RTL_CONSTASCII_USTRINGPARAM( "*.ps" ) ) );
20 if( bPDF )
21 xFilterMgr->appendFilter( OUString( RTL_CONSTASCII_USTRINGPARAM( "Portable Document Format" ) ), OUString( RTL_CONSTASCII_USTRINGPARAM( "*.pdf" ) ) );
88411c4e 22+
63358dee
AM
23+ String aFilter = pPrinter->GetJobValue( String::CreateFromAscii( "Filter#" ) );
24+ if (aFilter.Len())
25+ xFilterMgr->setCurrentFilter( aFilter );
26 }
27 #elif defined WNT
28 xFilterMgr->appendFilter( OUString( RTL_CONSTASCII_USTRINGPARAM( "*.PRN" ) ), OUString( RTL_CONSTASCII_USTRINGPARAM( "*.prn" ) ) );
29@@ -465,6 +473,12 @@
88411c4e 30 Sequence< OUString > aPathSeq( xFilePicker->getFiles() );
3d209426
AM
31 INetURLObject aObj( aPathSeq[0] );
32 maFiPrintFile.SetText( aObj.PathToFileName() );
88411c4e 33+#ifdef UNX
34+ Printer* pPrinter = TEMPPRINTER() ? TEMPPRINTER() : mpPrinter;
35+ if ( pPrinter )
36+ pPrinter->SetJobValue( String::CreateFromAscii( "Filter#" ),
cd99a028 37+ xFilterMgr->getCurrentFilter() );
88411c4e 38+#endif
39 return true;
40 }
cd99a028 41 return false;
This page took 0.066274 seconds and 4 git commands to generate.