From 5bce32904091ffe28884fd5c0f4801ee82bad101 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Wed, 27 Aug 2014 16:57:21 +0200 Subject: SfxHint: convert home-grown RTTI to normal C++ RTTI Also note that I fixed a bug in SvxFontMenuControl::Notify where the if statement had the check the wrong way around. Change-Id: I611e8929c65818191e36bd80f2b985820ada4411 Reviewed-on: https://gerrit.libreoffice.org/11147 Reviewed-by: Norbert Thiebaud Tested-by: Norbert Thiebaud --- sc/source/core/data/documen3.cxx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'sc/source/core/data/documen3.cxx') diff --git a/sc/source/core/data/documen3.cxx b/sc/source/core/data/documen3.cxx index 5b86ed962378..d439a44dee49 100644 --- a/sc/source/core/data/documen3.cxx +++ b/sc/source/core/data/documen3.cxx @@ -913,8 +913,9 @@ void ScDocument::BroadcastUno( const SfxHint &rHint ) // The listener calls must be processed after completing the broadcast, // because they can add or remove objects from pUnoBroadcaster. - if ( pUnoListenerCalls && rHint.ISA( SfxSimpleHint ) && - ((const SfxSimpleHint&)rHint).GetId() == SFX_HINT_DATACHANGED && + const SfxSimpleHint* pSimpleHint = dynamic_cast(&rHint); + if ( pUnoListenerCalls && pSimpleHint && + pSimpleHint->GetId() == SFX_HINT_DATACHANGED && !bInUnoListenerCall ) { // Listener calls may lead to BroadcastUno calls again. The listener calls -- cgit v1.2.3