diff options
author | David Tardon <dtardon@redhat.com> | 2011-12-24 06:38:12 +0100 |
---|---|---|
committer | David Tardon <dtardon@redhat.com> | 2011-12-24 06:38:12 +0100 |
commit | 80e977a34bd6eb1d3d3af849dcf86c5886c15a8f (patch) | |
tree | eaef10845c16ec83ed6d4a47602b50df26c8f085 /editeng | |
parent | 93d3f6258f8f061dc53b5e6003de65479c2290ba (diff) |
std::map* -> std::map
Diffstat (limited to 'editeng')
-rw-r--r-- | editeng/inc/editeng/svxacorr.hxx | 2 | ||||
-rw-r--r-- | editeng/source/misc/svxacorr.cxx | 13 |
2 files changed, 6 insertions, 9 deletions
diff --git a/editeng/inc/editeng/svxacorr.hxx b/editeng/inc/editeng/svxacorr.hxx index aabc6442594d..e2a3a8c00379 100644 --- a/editeng/inc/editeng/svxacorr.hxx +++ b/editeng/inc/editeng/svxacorr.hxx @@ -209,7 +209,7 @@ class EDITENG_DLLPUBLIC SvxAutoCorrect // all languages in a table SvxAutoCorrLanguageTable_Impl* pLangTable; - std::map<LanguageType, long>* pLastFileTable; + std::map<LanguageType, long> aLastFileTable; CharClass* pCharClass; bool bRunNext; diff --git a/editeng/source/misc/svxacorr.cxx b/editeng/source/misc/svxacorr.cxx index f28df9dd0fc5..413c509b87a6 100644 --- a/editeng/source/misc/svxacorr.cxx +++ b/editeng/source/misc/svxacorr.cxx @@ -342,7 +342,6 @@ SvxAutoCorrect::SvxAutoCorrect( const String& rShareAutocorrFile, : sShareAutoCorrFile( rShareAutocorrFile ), sUserAutoCorrFile( rUserAutocorrFile ), pLangTable( new SvxAutoCorrLanguageTable_Impl ), - pLastFileTable( new std::map<LanguageType, long> ), pCharClass( 0 ), bRunNext( false ), cStartDQuote( 0 ), cEndDQuote( 0 ), cStartSQuote( 0 ), cEndSQuote( 0 ) { @@ -359,7 +358,6 @@ SvxAutoCorrect::SvxAutoCorrect( const SvxAutoCorrect& rCpy ) aSwFlags( rCpy.aSwFlags ), pLangTable( new SvxAutoCorrLanguageTable_Impl ), - pLastFileTable( new std::map<LanguageType, long> ), pCharClass( 0 ), bRunNext( false ), nFlags( rCpy.nFlags & ~(ChgWordLstLoad|CplSttLstLoad|WrdSttLstLoad)), @@ -374,7 +372,6 @@ SvxAutoCorrect::~SvxAutoCorrect() { lcl_ClearTable(*pLangTable); delete pLangTable; - delete pLastFileTable; delete pCharClass; } @@ -1616,8 +1613,8 @@ sal_Bool SvxAutoCorrect::CreateLanguageFile( LanguageType eLang, sal_Bool bNewFi Time nMinTime( 0, 2 ), nAktTime( Time::SYSTEM ), nLastCheckTime( Time::EMPTY ); - std::map<LanguageType, long>::iterator nFndPos = pLastFileTable->find(eLang); - if(nFndPos != pLastFileTable->end() && + std::map<LanguageType, long>::iterator nFndPos = aLastFileTable.find(eLang); + if(nFndPos != aLastFileTable.end() && (nLastCheckTime.SetTime(nFndPos->second), nLastCheckTime < nAktTime) && nAktTime - nLastCheckTime < nMinTime) { @@ -1629,7 +1626,7 @@ sal_Bool SvxAutoCorrect::CreateLanguageFile( LanguageType eLang, sal_Bool bNewFi pLists = new SvxAutoCorrectLanguageLists( *this, sShareDirFile, sUserDirFile, eLang ); pLangTable->Insert( sal_uLong(eLang), pLists ); - pLastFileTable->erase(nFndPos); + aLastFileTable.erase(nFndPos); } } else if( ( FStatHelper::IsDocument( sUserDirFile ) || @@ -1640,11 +1637,11 @@ sal_Bool SvxAutoCorrect::CreateLanguageFile( LanguageType eLang, sal_Bool bNewFi pLists = new SvxAutoCorrectLanguageLists( *this, sShareDirFile, sUserDirFile, eLang ); pLangTable->Insert( sal_uLong(eLang), pLists ); - pLastFileTable->erase(nFndPos); + aLastFileTable.erase(nFndPos); } else if( !bNewFile ) { - (*pLastFileTable)[eLang] = nAktTime.GetTime(); + aLastFileTable[eLang] = nAktTime.GetTime(); } return pLists != 0; } |