summaryrefslogtreecommitdiffstats
path: root/sfx2
diff options
context:
space:
mode:
authorCao Cuong Ngo <cao.cuong.ngo@gmail.com>2013-08-23 15:25:06 +0200
committerCédric Bosdonnat <cedric.bosdonnat.ooo@free.fr>2013-09-02 13:51:56 +0200
commitb5e2d83bd529b0f0ce04d0690f4e0cccb667931e (patch)
tree3a4464decbeb4ca9bd44dcf18d62429bb8710205 /sfx2
parentConvert CMIS properties dialog to .ui (diff)
downloadcore-b5e2d83bd529b0f0ce04d0690f4e0cccb667931e.tar.gz
core-b5e2d83bd529b0f0ce04d0690f4e0cccb667931e.zip
CMIS properties dialog: fix scroll
Change-Id: I4f65adea63267dcafa448001fed7693f55378751
Diffstat (limited to 'sfx2')
-rw-r--r--sfx2/source/dialog/dinfdlg.cxx3
1 files changed, 3 insertions, 0 deletions
diff --git a/sfx2/source/dialog/dinfdlg.cxx b/sfx2/source/dialog/dinfdlg.cxx
index 6a1d6d8dd37e..ef7bdbca2531 100644
--- a/sfx2/source/dialog/dinfdlg.cxx
+++ b/sfx2/source/dialog/dinfdlg.cxx
@@ -2379,6 +2379,8 @@ void CmisPropertiesControl::setScrollRange()
{
sal_Int32 nScrollOffset = m_pPropertiesWin.GetItemHeight();
sal_Int32 nVisibleItems = m_rScrolledWindow.getVisibleChildSize().Height() / nScrollOffset;
+ if ( !nVisibleItems )
+ nVisibleItems = m_pPropertiesWin.GetLineCount() / 2;
m_rVertScroll.SetPageSize( nVisibleItems - 1 );
m_rVertScroll.SetVisibleSize( nVisibleItems );
m_rVertScroll.Scroll();
@@ -2475,6 +2477,7 @@ void SfxCmisPropertiesPage::Reset( const SfxItemSet& rItemSet )
aCmisProps[i].Choices,
aCmisProps[i].Value );
}
+ m_pPropertiesCtrl.setScrollRange();
}
int SfxCmisPropertiesPage::DeactivatePage( SfxItemSet* /*pSet*/ )