diff options
author | Philipp Lohmann [pl] <Philipp.Lohmann@Oracle.COM> | 2011-02-14 16:17:22 +0100 |
---|---|---|
committer | Philipp Lohmann [pl] <Philipp.Lohmann@Oracle.COM> | 2011-02-14 16:17:22 +0100 |
commit | 1fb042333fe6287756ff1fac11d18cd7c150730d (patch) | |
tree | 595de5d187177832ce656d7832af9dce9dce2d99 /sfx2/source/dialog/printopt.cxx | |
parent | 5b3e910e926c7dd1e8dcfe8e0a5c6cb5bd17480a (diff) | |
parent | cd0d6a5a6775f197fdb7e78b54c8133074a7a236 (diff) |
rebase to DEV300_m100
Diffstat (limited to 'sfx2/source/dialog/printopt.cxx')
-rw-r--r-- | sfx2/source/dialog/printopt.cxx | 50 |
1 files changed, 25 insertions, 25 deletions
diff --git a/sfx2/source/dialog/printopt.cxx b/sfx2/source/dialog/printopt.cxx index 6b26cf9fb504..e6182880b963 100644 --- a/sfx2/source/dialog/printopt.cxx +++ b/sfx2/source/dialog/printopt.cxx @@ -46,8 +46,8 @@ // - statics - // ----------- -static USHORT aDPIArray[] = { 72, 96, 150, 200, 300, 600 }; -static BOOL bOutputForPrinter = TRUE; +static sal_uInt16 aDPIArray[] = { 72, 96, 150, 200, 300, 600 }; +static sal_Bool bOutputForPrinter = sal_True; #define DPI_COUNT (sizeof(aDPIArray)/sizeof(aDPIArray[0 ])) @@ -88,12 +88,12 @@ SfxCommonPrintOptionsTabPage::SfxCommonPrintOptionsTabPage( Window* pParent, con if( bOutputForPrinter ) { - aPrinterOutputRB.Check( TRUE ); + aPrinterOutputRB.Check( sal_True ); aOutputGB.SetText( OutputDevice::GetNonMnemonicString( aPrinterOutputRB.GetText() ) ); } else { - aPrintFileOutputRB.Check( TRUE ); + aPrintFileOutputRB.Check( sal_True ); aOutputGB.SetText( OutputDevice::GetNonMnemonicString( aPrintFileOutputRB.GetText() ) ); } @@ -163,12 +163,12 @@ Window* SfxCommonPrintOptionsTabPage::GetParentLabelFor( const Window* pWindow ) // ----------------------------------------------------------------------------- -BOOL SfxCommonPrintOptionsTabPage::FillItemSet( SfxItemSet& /*rSet*/ ) +sal_Bool SfxCommonPrintOptionsTabPage::FillItemSet( SfxItemSet& /*rSet*/ ) { SvtPrintWarningOptions aWarnOptions; SvtPrinterOptions aPrinterOptions; SvtPrintFileOptions aPrintFileOptions; - BOOL bModified = FALSE; + sal_Bool bModified = sal_False; if( aPaperSizeCB.IsChecked() != aPaperSizeCB.GetSavedValue()) @@ -231,29 +231,29 @@ void SfxCommonPrintOptionsTabPage::ImplUpdateControls( const PrinterOptions* pCu aReduceTransparencyCB.Check( pCurrentOptions->IsReduceTransparency() ); if( pCurrentOptions->GetReducedTransparencyMode() == PRINTER_TRANSPARENCY_AUTO ) - aReduceTransparencyAutoRB.Check( TRUE ); + aReduceTransparencyAutoRB.Check( sal_True ); else - aReduceTransparencyNoneRB.Check( TRUE ); + aReduceTransparencyNoneRB.Check( sal_True ); aReduceGradientsCB.Check( pCurrentOptions->IsReduceGradients() ); if( pCurrentOptions->GetReducedGradientMode() == PRINTER_GRADIENT_STRIPES ) - aReduceGradientsStripesRB.Check( TRUE ); + aReduceGradientsStripesRB.Check( sal_True ); else - aReduceGradientsColorRB.Check( TRUE ); + aReduceGradientsColorRB.Check( sal_True ); aReduceGradientsStepCountNF.SetValue( pCurrentOptions->GetReducedGradientStepCount() ); aReduceBitmapsCB.Check( pCurrentOptions->IsReduceBitmaps() ); if( pCurrentOptions->GetReducedBitmapMode() == PRINTER_BITMAP_OPTIMAL ) - aReduceBitmapsOptimalRB.Check( TRUE ); + aReduceBitmapsOptimalRB.Check( sal_True ); else if( pCurrentOptions->GetReducedBitmapMode() == PRINTER_BITMAP_NORMAL ) - aReduceBitmapsNormalRB.Check( TRUE ); + aReduceBitmapsNormalRB.Check( sal_True ); else - aReduceBitmapsResolutionRB.Check( TRUE ); + aReduceBitmapsResolutionRB.Check( sal_True ); - const USHORT nDPI = pCurrentOptions->GetReducedBitmapResolution(); + const sal_uInt16 nDPI = pCurrentOptions->GetReducedBitmapResolution(); if( nDPI < aDPIArray[ 0 ] ) aReduceBitmapsResolutionLB.SelectEntryPos( 0 ); @@ -263,7 +263,7 @@ void SfxCommonPrintOptionsTabPage::ImplUpdateControls( const PrinterOptions* pCu { if( nDPI >= aDPIArray[ i ] ) { - aReduceBitmapsResolutionLB.SelectEntryPos( (USHORT) i ); + aReduceBitmapsResolutionLB.SelectEntryPos( (sal_uInt16) i ); i = -1; } } @@ -387,12 +387,12 @@ void SfxCommonPrintOptionsTabPage::ImplSaveControls( PrinterOptions* pCurrentOpt pCurrentOptions->SetReducedTransparencyMode( aReduceTransparencyAutoRB.IsChecked() ? PRINTER_TRANSPARENCY_AUTO : PRINTER_TRANSPARENCY_NONE ); pCurrentOptions->SetReduceGradients( aReduceGradientsCB.IsChecked() ); pCurrentOptions->SetReducedGradientMode( aReduceGradientsStripesRB.IsChecked() ? PRINTER_GRADIENT_STRIPES : PRINTER_GRADIENT_COLOR ); - pCurrentOptions->SetReducedGradientStepCount( (USHORT) aReduceGradientsStepCountNF.GetValue() ); + pCurrentOptions->SetReducedGradientStepCount( (sal_uInt16) aReduceGradientsStepCountNF.GetValue() ); pCurrentOptions->SetReduceBitmaps( aReduceBitmapsCB.IsChecked() ); pCurrentOptions->SetReducedBitmapMode( aReduceBitmapsOptimalRB.IsChecked() ? PRINTER_BITMAP_OPTIMAL : ( aReduceBitmapsNormalRB.IsChecked() ? PRINTER_BITMAP_NORMAL : PRINTER_BITMAP_RESOLUTION ) ); - pCurrentOptions->SetReducedBitmapResolution( aDPIArray[ Min( (USHORT) aReduceBitmapsResolutionLB.GetSelectEntryPos(), - (USHORT)( sizeof( aDPIArray ) / sizeof( aDPIArray[ 0 ] ) - 1 ) ) ] ); + pCurrentOptions->SetReducedBitmapResolution( aDPIArray[ Min( (sal_uInt16) aReduceBitmapsResolutionLB.GetSelectEntryPos(), + (sal_uInt16)( sizeof( aDPIArray ) / sizeof( aDPIArray[ 0 ] ) - 1 ) ) ] ); pCurrentOptions->SetReducedBitmapIncludesTransparency( aReduceBitmapsTransparencyCB.IsChecked() ); pCurrentOptions->SetConvertToGreyscales( aConvertToGreyscalesCB.IsChecked() ); } @@ -402,7 +402,7 @@ void SfxCommonPrintOptionsTabPage::ImplSaveControls( PrinterOptions* pCurrentOpt IMPL_LINK( SfxCommonPrintOptionsTabPage, ClickReduceTransparencyCBHdl, CheckBox*, pBox ) { (void)pBox; //unused - const BOOL bReduceTransparency = aReduceTransparencyCB.IsChecked(); + const sal_Bool bReduceTransparency = aReduceTransparencyCB.IsChecked(); aReduceTransparencyAutoRB.Enable( bReduceTransparency ); aReduceTransparencyNoneRB.Enable( bReduceTransparency ); @@ -417,7 +417,7 @@ IMPL_LINK( SfxCommonPrintOptionsTabPage, ClickReduceTransparencyCBHdl, CheckBox* IMPL_LINK( SfxCommonPrintOptionsTabPage, ClickReduceGradientsCBHdl, CheckBox*, pBox ) { (void)pBox; //unused - const BOOL bEnable = aReduceGradientsCB.IsChecked(); + const sal_Bool bEnable = aReduceGradientsCB.IsChecked(); aReduceGradientsStripesRB.Enable( bEnable ); aReduceGradientsColorRB.Enable( bEnable ); @@ -433,7 +433,7 @@ IMPL_LINK( SfxCommonPrintOptionsTabPage, ClickReduceGradientsCBHdl, CheckBox*, p IMPL_LINK( SfxCommonPrintOptionsTabPage, ClickReduceBitmapsCBHdl, CheckBox*, pBox ) { (void)pBox; //unused - const BOOL bEnable = aReduceBitmapsCB.IsChecked(); + const sal_Bool bEnable = aReduceBitmapsCB.IsChecked(); aReduceBitmapsOptimalRB.Enable( bEnable ); aReduceBitmapsNormalRB.Enable( bEnable ); @@ -451,7 +451,7 @@ IMPL_LINK( SfxCommonPrintOptionsTabPage, ClickReduceBitmapsCBHdl, CheckBox*, pBo IMPL_LINK( SfxCommonPrintOptionsTabPage, ToggleReduceGradientsStripesRBHdl, RadioButton*, pButton ) { (void)pButton; //unused - const BOOL bEnable = aReduceGradientsCB.IsChecked() && aReduceGradientsStripesRB.IsChecked(); + const sal_Bool bEnable = aReduceGradientsCB.IsChecked() && aReduceGradientsStripesRB.IsChecked(); aReduceGradientsStepCountNF.Enable( bEnable ); @@ -463,7 +463,7 @@ IMPL_LINK( SfxCommonPrintOptionsTabPage, ToggleReduceGradientsStripesRBHdl, Radi IMPL_LINK( SfxCommonPrintOptionsTabPage, ToggleReduceBitmapsResolutionRBHdl, RadioButton*, pButton ) { (void)pButton; //unused - const BOOL bEnable = aReduceBitmapsCB.IsChecked() && aReduceBitmapsResolutionRB.IsChecked(); + const sal_Bool bEnable = aReduceBitmapsCB.IsChecked() && aReduceBitmapsResolutionRB.IsChecked(); aReduceBitmapsResolutionLB.Enable( bEnable ); @@ -478,7 +478,7 @@ IMPL_LINK( SfxCommonPrintOptionsTabPage, ToggleOutputPrinterRBHdl, RadioButton*, { aOutputGB.SetText( OutputDevice::GetNonMnemonicString( pButton->GetText() ) ); ImplUpdateControls( &maPrinterOptions ); - bOutputForPrinter = TRUE; + bOutputForPrinter = sal_True; // --> OD 2008-06-25 #i63982# ImplSetAccessibleNames(); // <-- @@ -497,7 +497,7 @@ IMPL_LINK( SfxCommonPrintOptionsTabPage, ToggleOutputPrintFileRBHdl, RadioButton { aOutputGB.SetText( OutputDevice::GetNonMnemonicString( pButton->GetText() ) ); ImplUpdateControls( &maPrintFileOptions ); - bOutputForPrinter = FALSE; + bOutputForPrinter = sal_False; // --> OD 2008-06-25 #i63982# ImplSetAccessibleNames(); // <-- |