summaryrefslogtreecommitdiff
path: root/svx/source
diff options
context:
space:
mode:
authorobo <obo@openoffice.org>2010-09-14 09:05:18 +0200
committerobo <obo@openoffice.org>2010-09-14 09:05:18 +0200
commit6ad40130806fd834591a516390fa2a92f0573c62 (patch)
tree4e01a39ddfa0c08e9ca87bec820c95c74922ac87 /svx/source
parent20ff1d5bf41b295f0f771d292c5dd2832e26539e (diff)
parentbfac8e3f220d826d3443d7a367794a3df778d549 (diff)
CWS-TOOLING: integrate CWS dba33i
Diffstat (limited to 'svx/source')
-rw-r--r--svx/source/dialog/checklbx.cxx9
1 files changed, 8 insertions, 1 deletions
diff --git a/svx/source/dialog/checklbx.cxx b/svx/source/dialog/checklbx.cxx
index c54634017392..80096ce70f32 100644
--- a/svx/source/dialog/checklbx.cxx
+++ b/svx/source/dialog/checklbx.cxx
@@ -212,7 +212,7 @@ void SvxCheckListBox::MouseButtonDown( const MouseEvent& rMEvt )
{
if ( rMEvt.IsLeft() )
{
- Point aPnt = rMEvt.GetPosPixel();
+ const Point aPnt = rMEvt.GetPosPixel();
SvLBoxEntry* pEntry = GetEntry( aPnt );
if ( pEntry )
@@ -230,6 +230,13 @@ void SvxCheckListBox::MouseButtonDown( const MouseEvent& rMEvt )
{
ToggleCheckButton( pEntry );
SvTreeListBox::MouseButtonDown( rMEvt );
+
+ // check if the entry below the mouse changed during the base method call. This is possible if,
+ // for instance, a handler invoked by the base class tampers with the list entries.
+ const SvLBoxEntry* pNewEntry = GetEntry( aPnt );
+ if ( pNewEntry != pEntry )
+ return;
+
if ( bCheck != ( GetCheckButtonState( pEntry ) == SV_BUTTON_CHECKED ) )
CheckButtonHdl();
return;