[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - desktop/source
Stephan Bergmann
sbergman at redhat.com
Thu Dec 19 04:44:28 PST 2013
desktop/source/deployment/gui/dp_gui_extlistbox.cxx | 6 ++++++
1 file changed, 6 insertions(+)
New commits:
commit f232b831d439bac53a662c32032c7a0abd430d5e
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Mon Dec 16 13:53:30 2013 +0100
m_bHasActive must be false after last visible entry is removed
...otherwise, ExtensionBox_Impl::RecalcAll would crash in CalcActiveHeight(-1).
Change-Id: If399825951c79b821ed44ebefa19d1032ab4f850
(cherry picked from commit 661f7bdefc8215f742951727b93395d47293cf0e)
Reviewed-on: https://gerrit.libreoffice.org/7097
Reviewed-by: Norbert Thiebaud <nthiebaud at gmail.com>
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
Tested-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/desktop/source/deployment/gui/dp_gui_extlistbox.cxx b/desktop/source/deployment/gui/dp_gui_extlistbox.cxx
index 19d2749..0d48d55 100644
--- a/desktop/source/deployment/gui/dp_gui_extlistbox.cxx
+++ b/desktop/source/deployment/gui/dp_gui_extlistbox.cxx
@@ -1224,7 +1224,13 @@ void ExtensionBox_Impl::checkEntries()
if ( nPos < m_nActive )
m_nActive -= 1;
else if ( ( nPos == m_nActive ) && ( nPos == (long) m_vEntries.size() - 1 ) )
+ {
m_nActive -= 1;
+ if (m_nActive == -1)
+ {
+ m_bHasActive = false;
+ }
+ }
m_vRemovedEntries.push_back( *iIndex );
m_vEntries.erase( iIndex );
iIndex = m_vEntries.begin() + nPos;
More information about the Libreoffice-commits
mailing list