diff options
| author | Noel Grandin <noel@peralex.com> | 2014-08-27 16:57:21 +0200 |
|---|---|---|
| committer | Norbert Thiebaud <nthiebaud@gmail.com> | 2014-09-06 15:47:44 -0500 |
| commit | 5bce32904091ffe28884fd5c0f4801ee82bad101 (patch) | |
| tree | fc2573078a858de456a0dc7b7810176d433241c7 /basic/source/runtime | |
| parent | 10143717834d8401d85fdf9564e782a58b9983ec (diff) | |
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 <nthiebaud@gmail.com>
Tested-by: Norbert Thiebaud <nthiebaud@gmail.com>
Diffstat (limited to 'basic/source/runtime')
| -rw-r--r-- | basic/source/runtime/stdobj.cxx | 2 | ||||
| -rw-r--r-- | basic/source/runtime/stdobj1.cxx | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/basic/source/runtime/stdobj.cxx b/basic/source/runtime/stdobj.cxx index 9a69beadcd1c..da9edc2111d0 100644 --- a/basic/source/runtime/stdobj.cxx +++ b/basic/source/runtime/stdobj.cxx @@ -821,7 +821,7 @@ void SbiStdObject::SFX_NOTIFY( SfxBroadcaster& rBC, const TypeId& rBCType, const SfxHint& rHint, const TypeId& rHintType ) { - const SbxHint* pHint = PTR_CAST(SbxHint,&rHint); + const SbxHint* pHint = dynamic_cast<const SbxHint*>(&rHint); if( pHint ) { SbxVariable* pVar = pHint->GetVar(); diff --git a/basic/source/runtime/stdobj1.cxx b/basic/source/runtime/stdobj1.cxx index 061aa646f038..3f52a8a19b2a 100644 --- a/basic/source/runtime/stdobj1.cxx +++ b/basic/source/runtime/stdobj1.cxx @@ -144,7 +144,7 @@ void SbStdPicture::SFX_NOTIFY( SfxBroadcaster& rBC, const TypeId& rBCType, const SfxHint& rHint, const TypeId& rHintType ) { - const SbxHint* pHint = PTR_CAST( SbxHint, &rHint ); + const SbxHint* pHint = dynamic_cast<const SbxHint*>(&rHint); if( pHint ) { @@ -269,7 +269,7 @@ SbxVariable* SbStdFont::Find( const OUString& rName, SbxClassType t ) void SbStdFont::SFX_NOTIFY( SfxBroadcaster& rBC, const TypeId& rBCType, const SfxHint& rHint, const TypeId& rHintType ) { - const SbxHint* pHint = PTR_CAST( SbxHint, &rHint ); + const SbxHint* pHint = dynamic_cast<const SbxHint*>(&rHint); if( pHint ) { @@ -438,7 +438,7 @@ SbxVariable* SbStdClipboard::Find( const OUString& rName, SbxClassType t ) void SbStdClipboard::SFX_NOTIFY( SfxBroadcaster& rBC, const TypeId& rBCType, const SfxHint& rHint, const TypeId& rHintType ) { - const SbxHint* pHint = PTR_CAST( SbxHint, &rHint ); + const SbxHint* pHint = dynamic_cast<const SbxHint*>(&rHint); if( pHint ) { |
