summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorPhilipp Lohmann <pl@openoffice.org>2009-08-06 09:00:23 +0000
committerPhilipp Lohmann <pl@openoffice.org>2009-08-06 09:00:23 +0000
commitcda2521771d4166377f72a811e1801337954b22d (patch)
treed6d5e5fb6a4c8eb28c83badcf80241313ea52194 /vcl
parentaafa25d0a440418cbcff23521862eadcc3c1466f (diff)
#i92516# fix a layout problem, fix a warning
Diffstat (limited to 'vcl')
-rw-r--r--vcl/source/window/printdlg.cxx55
-rw-r--r--vcl/win/source/gdi/salprn.cxx2
2 files changed, 6 insertions, 51 deletions
diff --git a/vcl/source/window/printdlg.cxx b/vcl/source/window/printdlg.cxx
index eeb42437f47a..3395e4aff62d 100644
--- a/vcl/source/window/printdlg.cxx
+++ b/vcl/source/window/printdlg.cxx
@@ -580,6 +580,7 @@ void PrintDialog::JobTabPage::readFromSettings()
rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Collate" ) ) );
maCollateBox.Check( aValue.equalsIgnoreAsciiCaseAscii( "true" ) );
}
+ Resize();
}
void PrintDialog::JobTabPage::storeToSettings()
@@ -1489,6 +1490,10 @@ void PrintDialog::setupOptionalUI()
delete *it;
*it = NULL;
}
+ maJobPage.Resize();
+ maNUpPage.Resize();
+ maOptionsPage.Resize();
+ Resize();
}
void PrintDialog::checkControlDependencies()
@@ -2029,57 +2034,7 @@ void PrintDialog::Command( const CommandEvent& rEvt )
void PrintDialog::Resize()
{
- #if 0
- Size aPixDiff( LogicToPixel( Size( 5, 5 ), MapMode( MAP_APPFONT ) ) );
- Size aWindowSize( GetOutputSizePixel() );
-
- // position buttons from lower end, right to left
- Size aBtnSize( maCancelButton.GetSizePixel() );
- Rectangle aBtnRect( Point( aWindowSize.Width() - aPixDiff.Width() - aBtnSize.Width(),
- aWindowSize.Height() - aPixDiff.Height() - aBtnSize.Height() ),
- aBtnSize );
- maCancelButton.SetPosSizePixel( aBtnRect.TopLeft(), aBtnRect.GetSize() );
- aBtnSize = maOKButton.GetSizePixel();
- aBtnRect = Rectangle( Point( aBtnRect.Left() - aPixDiff.Width() - aBtnSize.Width(),
- aWindowSize.Height() - aPixDiff.Height() - aBtnSize.Height() ),
- aBtnSize );
- maOKButton.SetPosSizePixel( aBtnRect.TopLeft(), aBtnRect.GetSize() );
- aBtnSize = maButtonLine.GetSizePixel();
-
- // position fixed line above buttons
- aBtnRect = Rectangle( Point( 0, aBtnRect.Top() - aPixDiff.Width() - aBtnSize.Height()/2 ),
- Size( aWindowSize.Width(), aBtnSize.Height() ) );
- maButtonLine.SetPosSizePixel( aBtnRect.TopLeft(), aBtnRect.GetSize() );
-
- // position tab control on upper right
- aBtnSize = maTabCtrl.GetSizePixel();
- aBtnRect = Rectangle( Point( aWindowSize.Width() - aPixDiff.Width() - aBtnSize.Width(),
- aPixDiff.Height() ),
- Size( aBtnSize.Width(), maButtonLine.GetPosPixel().Y() - 2*aPixDiff.Height() ) );
- maTabCtrl.SetPosSizePixel( aBtnRect.TopLeft(), aBtnRect.GetSize() );
-
- // set size for preview
- long nMaxX = maTabCtrl.GetPosPixel().X() - 2*aPixDiff.Width();
- long nMaxY = maButtonLine.GetPosPixel().Y()
- - 4 * aPixDiff.Height()
- - maForwardBtn.GetSizePixel().Height();
- long nPreviewLength = std::min( nMaxX, nMaxY );
- maPreviewSpace = Rectangle( Point( aPixDiff.Width(), 2 * aPixDiff.Height() ),
- Size( nPreviewLength, nPreviewLength ) );
-
- // position text and slider below preview, aligned
- Size aPrefSize( maPreviewCtrlRow.getOptimalSize( WINDOWSIZE_PREFERRED ) );
- aPrefSize.Width() = nPreviewLength - 2* aPixDiff.Width();
- Point aCtrlPos( 2*aPixDiff.Width(), 3*aPixDiff.Height() + nPreviewLength );
- maPreviewCtrlRow.setManagedArea( Rectangle( aCtrlPos, aPrefSize ) );
- maPreviewBackground.Left() = aPixDiff.Width() - 2;
- maPreviewBackground.Top() = aPixDiff.Height() - 2;
- maPreviewBackground.Right() = aPixDiff.Width() + nPreviewLength + 2;
- maPreviewBackground.Bottom() = maPreviewCtrlRow.getManagedArea().Bottom() + aPixDiff.Height();
- #else
maLayout.setManagedArea( Rectangle( Point( 0, 0 ), GetSizePixel() ) );
- #endif
-
// and do the preview; however the metafile does not need to be gotten anew
preparePreview( false );
diff --git a/vcl/win/source/gdi/salprn.cxx b/vcl/win/source/gdi/salprn.cxx
index 8fe9b5d8f4d0..f4f55dd0adbf 100644
--- a/vcl/win/source/gdi/salprn.cxx
+++ b/vcl/win/source/gdi/salprn.cxx
@@ -1968,7 +1968,7 @@ BOOL WinSalPrinter::StartJob( const XubString* pFileName,
const XubString&,
ULONG nCopies,
bool bCollate,
- bool bDirect,
+ bool /*bDirect*/,
ImplJobSetup* pSetupData )
{
mnError = 0;