summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRafael Dominguez <venccsralph@gmail.com>2012-06-29 11:05:39 -0430
committerRafael Dominguez <venccsralph@gmail.com>2012-06-29 11:05:39 -0430
commitfd4ba654170c7142fb05f2183ec43384f55dfbda (patch)
treecfd9194c12fad3cbcba70542075c94ccf77d88cc
parent8f7d779f94ef277ab4162b4a45d81d1fdd2a1f7c (diff)
Display scrollbar and take into account header size for dimensions.
Change-Id: Iff580a408077e7320d532d1d4c1c7af8b6932910
-rw-r--r--sfx2/source/control/thumbnailview.cxx7
1 files changed, 4 insertions, 3 deletions
diff --git a/sfx2/source/control/thumbnailview.cxx b/sfx2/source/control/thumbnailview.cxx
index 7905e946e04e..b17b4674c16f 100644
--- a/sfx2/source/control/thumbnailview.cxx
+++ b/sfx2/source/control/thumbnailview.cxx
@@ -366,8 +366,8 @@ void ThumbnailView::CalculateItemPositions ()
// arrange ScrollBar, set values and show it
if ( mpScrBar )
{
- Point aPos( aWinSize.Width()-nScrBarWidth+SCRBAR_OFFSET, 0 );
- Size aSize( nScrBarWidth-SCRBAR_OFFSET, aWinSize.Height() );
+ Point aPos( aWinSize.Width()-nScrBarWidth+SCRBAR_OFFSET, mnHeaderHeight );
+ Size aSize( nScrBarWidth-SCRBAR_OFFSET, aWinSize.Height() - mnHeaderHeight );
mpScrBar->SetPosSizePixel( aPos, aSize );
mpScrBar->SetRangeMax( mnLines );
@@ -377,6 +377,7 @@ void ThumbnailView::CalculateItemPositions ()
if ( nPageSize < 1 )
nPageSize = 1;
mpScrBar->SetPageSize( nPageSize );
+ mpScrBar->Show();
}
// delete ScrollBar
@@ -808,7 +809,7 @@ void ThumbnailView::Paint( const Rectangle &aRect)
}
if ( mpScrBar && mpScrBar->IsVisible() )
- mpScrBar->Invalidate();
+ mpScrBar->Paint(aRect);
}
void ThumbnailView::GetFocus()