Kaydet (Commit) 35fa2673 authored tarafından Michael Meeks's avatar Michael Meeks

tdf#90956 - ComboBox: handle re-size calculation during dispose.

Change-Id: I3d6e421a10b0d6b0edb85c0a6454315198bfd22f
üst 207b0799
...@@ -559,20 +559,23 @@ void ComboBox::Resize() ...@@ -559,20 +559,23 @@ void ComboBox::Resize()
{ {
Control::Resize(); Control::Resize();
Size aOutSz = GetOutputSizePixel(); if (mpSubEdit)
if( IsDropDownBox() )
{ {
ComboBoxBounds aBounds(calcComboBoxDropDownComponentBounds(aOutSz, Size aOutSz = GetOutputSizePixel();
GetWindow(WINDOW_BORDER)->GetOutputSizePixel())); if( IsDropDownBox() )
mpSubEdit->SetPosSizePixel(aBounds.aSubEditPos, aBounds.aSubEditSize); {
mpBtn->SetPosSizePixel(aBounds.aButtonPos, aBounds.aButtonSize); ComboBoxBounds aBounds(calcComboBoxDropDownComponentBounds(aOutSz,
} GetWindow(WINDOW_BORDER)->GetOutputSizePixel()));
else mpSubEdit->SetPosSizePixel(aBounds.aSubEditPos, aBounds.aSubEditSize);
{ mpBtn->SetPosSizePixel(aBounds.aButtonPos, aBounds.aButtonSize);
mpSubEdit->SetSizePixel( Size( aOutSz.Width(), mnDDHeight ) ); }
mpImplLB->setPosSizePixel( 0, mnDDHeight, aOutSz.Width(), aOutSz.Height() - mnDDHeight ); else
if ( !GetText().isEmpty() ) {
ImplUpdateFloatSelection(); mpSubEdit->SetSizePixel( Size( aOutSz.Width(), mnDDHeight ) );
mpImplLB->setPosSizePixel( 0, mnDDHeight, aOutSz.Width(), aOutSz.Height() - mnDDHeight );
if ( !GetText().isEmpty() )
ImplUpdateFloatSelection();
}
} }
// adjust the size of the FloatingWindow even when invisible // adjust the size of the FloatingWindow even when invisible
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment