summaryrefslogtreecommitdiff
path: root/vcl/source/gdi/print3.cxx
diff options
context:
space:
mode:
authorPhilipp Lohmann <pl@openoffice.org>2009-08-05 15:46:46 +0000
committerPhilipp Lohmann <pl@openoffice.org>2009-08-05 15:46:46 +0000
commit712176f85a73d77d7cfef92350ebfaa3d30ef79f (patch)
tree8c689fa68a5909434f1965b30dd45aa70ec1c865 /vcl/source/gdi/print3.cxx
parent4bcda09aeec59e01797f96a163f408b642491a46 (diff)
get rid of old cruft
Diffstat (limited to 'vcl/source/gdi/print3.cxx')
-rw-r--r--vcl/source/gdi/print3.cxx21
1 files changed, 15 insertions, 6 deletions
diff --git a/vcl/source/gdi/print3.cxx b/vcl/source/gdi/print3.cxx
index c7ad36a48d7c..1888fbdcad49 100644
--- a/vcl/source/gdi/print3.cxx
+++ b/vcl/source/gdi/print3.cxx
@@ -327,10 +327,8 @@ void Printer::ImplPrintJob( const boost::shared_ptr<PrinterController>& i_pContr
// check if the printer brings up its own dialog
// in that case leave the work to that dialog
- const String& rQuick( i_rInitSetup.GetValue( String( RTL_CONSTASCII_USTRINGPARAM( "IsQuickJob" ) ) ) );
- bool bIsQuick = rQuick.Len() && rQuick.EqualsIgnoreCaseAscii( "true" );
if( ! pController->getPrinter()->GetCapabilities( PRINTER_CAPABILITIES_EXTERNALDIALOG ) &&
- ! bIsQuick &&
+ ! pController->isDirectPrint() &&
pController->isShowDialogs()
)
{
@@ -382,8 +380,8 @@ bool Printer::StartJob( const rtl::OUString& i_rJobName, boost::shared_ptr<vcl::
return FALSE;
ULONG nCopies = mnCopyCount;
- BOOL bCollateCopy = mbCollateCopy;
- BOOL bUserCopy = FALSE;
+ bool bCollateCopy = mbCollateCopy;
+ bool bUserCopy = FALSE;
if ( nCopies > 1 )
{
@@ -475,7 +473,9 @@ bool Printer::StartJob( const rtl::OUString& i_rJobName, boost::shared_ptr<vcl::
if( mpPrinter->StartJob( pPrintFile,
i_rJobName,
Application::GetDisplayName(),
- nCopies, bCollateCopy,
+ nCopies,
+ bCollateCopy,
+ i_pController->isDirectPrint(),
maJobSetup.ImplGetConstData() ) )
{
mbJobActive = TRUE;
@@ -1152,6 +1152,15 @@ bool PrinterController::isShowDialogs() const
return ! bApi && ! Application::IsHeadlessModeEnabled();
}
+bool PrinterController::isDirectPrint() const
+{
+ sal_Bool bDirect = sal_False;
+ const com::sun::star::beans::PropertyValue* pVal = getValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "IsDirect" ) ) );
+ if( pVal )
+ pVal->Value >>= bDirect;
+ return bDirect == sal_True;
+}
+
/*
* PrinterOptionsHelper
**/