diff options
Diffstat (limited to 'sc/source/ui/navipi/navipi.cxx')
-rw-r--r-- | sc/source/ui/navipi/navipi.cxx | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/sc/source/ui/navipi/navipi.cxx b/sc/source/ui/navipi/navipi.cxx index a2191840d5ae..f60f4b25d804 100644 --- a/sc/source/ui/navipi/navipi.cxx +++ b/sc/source/ui/navipi/navipi.cxx @@ -810,9 +810,10 @@ void ScNavigatorDlg::DoResize() void ScNavigatorDlg::Notify( SfxBroadcaster&, const SfxHint& rHint ) { - if ( rHint.ISA(SfxSimpleHint) ) + const SfxSimpleHint* pSimpleHint = dynamic_cast<const SfxSimpleHint*>( &rHint ); + if ( pSimpleHint ) { - sal_uLong nHintId = ((SfxSimpleHint&)rHint).GetId(); + sal_uLong nHintId = pSimpleHint->GetId(); if ( nHintId == SC_HINT_DOCNAME_CHANGED ) { @@ -868,9 +869,9 @@ void ScNavigatorDlg::Notify( SfxBroadcaster&, const SfxHint& rHint ) } } } - else if ( rHint.ISA(SfxEventHint) ) + else if ( dynamic_cast<const SfxEventHint*>(&rHint) ) { - sal_uLong nEventId = ((SfxEventHint&)rHint).GetEventId(); + sal_uLong nEventId = static_cast<const SfxEventHint&>(rHint).GetEventId(); if ( nEventId == SFX_EVENT_ACTIVATEDOC ) { aLbEntries.ActiveDocChanged(); |