summaryrefslogtreecommitdiff
path: root/extensions
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2017-03-23 16:06:18 +0000
committerAndras Timar <andras.timar@collabora.com>2017-03-28 13:00:27 +0200
commit95d4a75be880f069795ee98be4234c85573f4b17 (patch)
tree410daa98122a8147cbaa4695c84f72d1430f0148 /extensions
parentd7e64d62071757ee7613c82925d978a73b46a2f8 (diff)
Resolves: tdf#106461 use a row height of max of edit and listbox height
not just take the listbox because edits can be taller and result in overlaps Change-Id: I6067b384484d933727220febda723bc9e8c5e90b (cherry picked from commit 5013abeb191cdc6f8375f107a4d30abd802547d2) Reviewed-on: https://gerrit.libreoffice.org/35596 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: David Tardon <dtardon@redhat.com> (cherry picked from commit 910582360d2a2f0455841b2cd0c3cc2c7ed08344)
Diffstat (limited to 'extensions')
-rw-r--r--extensions/source/propctrlr/browserlistbox.cxx9
1 files changed, 5 insertions, 4 deletions
diff --git a/extensions/source/propctrlr/browserlistbox.cxx b/extensions/source/propctrlr/browserlistbox.cxx
index 9d6b899ce0e2..93e901f98131 100644
--- a/extensions/source/propctrlr/browserlistbox.cxx
+++ b/extensions/source/propctrlr/browserlistbox.cxx
@@ -332,9 +332,11 @@ namespace pcr
,m_bUpdate(true)
,m_pControlContextImpl( new PropertyControlContext_Impl( *this ) )
{
- ScopedVclPtrInstance< ListBox > aListBox(this,WB_DROPDOWN);
- aListBox->SetPosSizePixel(Point(0,0),Size(100,100));
- m_nRowHeight = aListBox->GetSizePixel().Height()+2;
+ ScopedVclPtrInstance<ListBox> aListBox(this, WB_DROPDOWN);
+ ScopedVclPtrInstance<Edit> aEditBox(this);
+ m_nRowHeight = std::max(aListBox->get_preferred_size().Height(),
+ aEditBox->get_preferred_size().Height());
+ m_nRowHeight += 2;
SetBackground( pParent->GetBackground() );
m_aLinesPlayground->SetBackground( GetBackground() );
@@ -345,7 +347,6 @@ namespace pcr
m_aVScroll->SetScrollHdl(LINK(this, OBrowserListBox, ScrollHdl));
}
-
OBrowserListBox::~OBrowserListBox()
{
disposeOnce();