diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2015-03-26 15:30:53 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2015-03-26 15:33:36 +0100 |
commit | 98ce4ac4017ac04d7cde9c94273a558c969586b9 (patch) | |
tree | e895588b75f11c19bb758dafa0e7949f84543f43 /sfx2/source/bastyp | |
parent | f474984cd7b8a29f410a686d540859226039bfe0 (diff) |
const_cast: convert some C-style casts and remove some redundant ones
Change-Id: I59526bea5104def80e98902e4cf16e7bcfaa250c
Diffstat (limited to 'sfx2/source/bastyp')
-rw-r--r-- | sfx2/source/bastyp/fltfnc.cxx | 2 | ||||
-rw-r--r-- | sfx2/source/bastyp/sfxhtml.cxx | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/sfx2/source/bastyp/fltfnc.cxx b/sfx2/source/bastyp/fltfnc.cxx index ee4a7fb15cec..4baecd5b403a 100644 --- a/sfx2/source/bastyp/fltfnc.cxx +++ b/sfx2/source/bastyp/fltfnc.cxx @@ -1101,7 +1101,7 @@ void SfxFilterContainer::ReadSingleFilter_Impl( sFilterName = sFilterName.copy( nStartRealName+2 ); } - SfxFilter* pFilter = bUpdate ? (SfxFilter*) SfxFilter::GetFilterByName( sFilterName ) : 0; + SfxFilter* pFilter = bUpdate ? const_cast<SfxFilter*>(SfxFilter::GetFilterByName( sFilterName )) : 0; bool bNew = false; if (!pFilter) { diff --git a/sfx2/source/bastyp/sfxhtml.cxx b/sfx2/source/bastyp/sfxhtml.cxx index 9c5eee8d0d69..5335eca582f7 100644 --- a/sfx2/source/bastyp/sfxhtml.cxx +++ b/sfx2/source/bastyp/sfxhtml.cxx @@ -311,7 +311,7 @@ void SfxHTMLParser::GetScriptType_Impl( SvKeyValueIterator *pHTTPHeader ) ScriptType SfxHTMLParser::GetScriptType( SvKeyValueIterator *pHTTPHeader ) const { if( aScriptType.isEmpty() ) - ((SfxHTMLParser *)this)->GetScriptType_Impl( pHTTPHeader ); + const_cast<SfxHTMLParser *>(this)->GetScriptType_Impl( pHTTPHeader ); return eScriptType; } @@ -320,7 +320,7 @@ const OUString& SfxHTMLParser::GetScriptTypeString( SvKeyValueIterator *pHTTPHeader ) const { if( aScriptType.isEmpty() ) - ((SfxHTMLParser *)this)->GetScriptType_Impl( pHTTPHeader ); + const_cast<SfxHTMLParser *>(this)->GetScriptType_Impl( pHTTPHeader ); return aScriptType; } |