loplugin:nullptr (automatic rewrite)

Change-Id: I5d642a463f4dca8665745c19918699e7bfe7db99
This commit is contained in:
Stephan Bergmann 2015-11-10 10:19:12 +01:00
parent 64d1b574ad
commit 53a2e93fc5
15 changed files with 83 additions and 83 deletions

View File

@ -111,7 +111,7 @@ css::uno::Sequence< sal_Int16 >
// checks if file pointed to by rURL is readonly
// and may also check return if such a file exists or not
bool IsReadOnly( const OUString &rURL, bool *pbExist = 0 );
bool IsReadOnly( const OUString &rURL, bool *pbExist = nullptr );
// checks if a file with the given URL exists
bool FileExists( const OUString &rURL );

View File

@ -141,7 +141,7 @@ bool IsConvDic( const OUString &rFileURL, sal_Int16 &nLang, sal_Int16 &nConvType
// first argument being 0 should stop the file from being parsed
// up to the end (reading all entries) when the required
// data (language, conversion type) is found.
ConvDicXMLImport *pImport = new ConvDicXMLImport( 0 );
ConvDicXMLImport *pImport = new ConvDicXMLImport( nullptr );
//!! keep a first reference to ensure the lifetime of the object !!
uno::Reference< XInterface > xRef( static_cast<document::XFilter *>(pImport), UNO_QUERY );

View File

@ -370,7 +370,7 @@ void ConvDicList::MyAppExitListener::AtExit()
ConvDicList::ConvDicList() :
aEvtListeners( GetLinguMutex() )
{
pNameContainer = 0;
pNameContainer = nullptr;
bDisposing = false;
pExitListener = new MyAppExitListener( *this );
@ -626,7 +626,7 @@ void * SAL_CALL ConvDicList_getFactory(
const sal_Char * pImplName,
XMultiServiceFactory * pServiceManager, void * )
{
void * pRet = 0;
void * pRet = nullptr;
if ( ConvDicList::getImplementationName_Static().equalsAscii( pImplName ) )
{
uno::Reference< XSingleServiceFactory > xFactory =

View File

@ -190,7 +190,7 @@ SvXMLImportContext * ConvDicXMLImportContext::CreateChildContext(
sal_uInt16 nPrefix, const OUString& rLocalName,
const uno::Reference< xml::sax::XAttributeList > & /*rxAttrList*/ )
{
SvXMLImportContext *pContext = 0;
SvXMLImportContext *pContext = nullptr;
if ( nPrefix == XML_NAMESPACE_TCD && rLocalName == "text-conversion-dictionary" )
pContext = new ConvDicXMLDictionaryContext_Impl( GetConvDicImport(), nPrefix, rLocalName );
else
@ -225,7 +225,7 @@ SvXMLImportContext * ConvDicXMLDictionaryContext_Impl::CreateChildContext(
sal_uInt16 nPrefix, const OUString& rLocalName,
const uno::Reference< xml::sax::XAttributeList > & /*rxAttrList*/ )
{
SvXMLImportContext *pContext = 0;
SvXMLImportContext *pContext = nullptr;
if ( nPrefix == XML_NAMESPACE_TCD && rLocalName == "entry" )
pContext = new ConvDicXMLEntryTextContext_Impl( GetConvDicImport(), nPrefix, rLocalName );
else
@ -238,7 +238,7 @@ SvXMLImportContext * ConvDicXMLEntryTextContext_Impl::CreateChildContext(
sal_uInt16 nPrefix, const OUString& rLocalName,
const uno::Reference< xml::sax::XAttributeList > & /*rxAttrList*/ )
{
SvXMLImportContext *pContext = 0;
SvXMLImportContext *pContext = nullptr;
if ( nPrefix == XML_NAMESPACE_TCD && rLocalName == "right-text" )
pContext = new ConvDicXMLRightTextContext_Impl( GetConvDicImport(), nPrefix, rLocalName, *this );
else
@ -391,7 +391,7 @@ SvXMLImportContext * ConvDicXMLImport::CreateContext(
const OUString &rLocalName,
const uno::Reference < xml::sax::XAttributeList > & /*rxAttrList*/ )
{
SvXMLImportContext *pContext = 0;
SvXMLImportContext *pContext = nullptr;
if ( nPrefix == XML_NAMESPACE_TCD && rLocalName == "text-conversion-dictionary" )
pContext = new ConvDicXMLDictionaryContext_Impl( *this, nPrefix, rLocalName );
else

View File

@ -751,7 +751,7 @@ void SAL_CALL DictionaryNeo::setName( const OUString& aName )
if (aDicName != aName)
{
aDicName = aName;
launchEvent(DictionaryEventFlags::CHG_NAME, NULL);
launchEvent(DictionaryEventFlags::CHG_NAME, nullptr);
}
}
@ -792,7 +792,7 @@ void SAL_CALL DictionaryNeo::setActive( sal_Bool bActivate )
"lng : dictionary is still modified" );
}
launchEvent(nEvent, NULL);
launchEvent(nEvent, nullptr);
}
}
@ -830,7 +830,7 @@ void SAL_CALL DictionaryNeo::setLocale( const Locale& aLocale )
nLanguage = nLanguageP;
bIsModified = true; // new language needs to be saved with dictionary
launchEvent( DictionaryEventFlags::CHG_LANGUAGE, NULL );
launchEvent( DictionaryEventFlags::CHG_LANGUAGE, nullptr );
}
}
@ -987,7 +987,7 @@ void SAL_CALL DictionaryNeo::clear( )
bNeedEntries = false;
bIsModified = true;
launchEvent( DictionaryEventFlags::ENTRIES_CLEARED , NULL );
launchEvent( DictionaryEventFlags::ENTRIES_CLEARED , nullptr );
}
}

View File

@ -758,7 +758,7 @@ uno::Sequence< OUString > DicList::getSupportedServiceNames_Static() throw()
void * SAL_CALL DicList_getFactory( const sal_Char * pImplName,
XMultiServiceFactory * pServiceManager, void * )
{
void * pRet = 0;
void * pRet = nullptr;
if ( DicList::getImplementationName_Static().equalsAscii( pImplName ) )
{
uno::Reference< XSingleServiceFactory > xFactory =

View File

@ -256,11 +256,11 @@ void GrammarCheckingIterator::TerminateThread()
{
::osl::Guard< ::osl::Mutex > aGuard( MyMutex::get() );
t = m_thread;
m_thread = 0;
m_thread = nullptr;
m_bEnd = true;
m_aWakeUpThread.set();
}
if (t != 0)
if (t != nullptr)
{
osl_joinWithThread(t);
osl_destroyThread(t);
@ -658,7 +658,7 @@ throw (uno::RuntimeException, lang::IllegalArgumentException, std::exception)
const bool bAutomatic = true;
uno::Reference<text::XFlatParagraphIterator> xFPIterator = xIteratorProvider->getFlatParagraphIterator(
text::TextMarkupType::PROOFREADING, bAutomatic );
uno::Reference< text::XFlatParagraph > xPara( xFPIterator.is()? xFPIterator->getFirstPara() : NULL );
uno::Reference< text::XFlatParagraph > xPara( xFPIterator.is()? xFPIterator->getFirstPara() : nullptr );
uno::Reference< lang::XComponent > xComponent( xDoc, uno::UNO_QUERY );
// ---- THREAD SAFE START ----
@ -1158,7 +1158,7 @@ void * SAL_CALL GrammarCheckingIterator_getFactory(
lang::XMultiServiceFactory *pServiceManager,
void * /*pRegistryKey*/ )
{
void * pRet = 0;
void * pRet = nullptr;
if ( GrammarCheckingIterator_getImplementationName().equalsAscii( pImplName ) )
{
uno::Reference< lang::XSingleServiceFactory > xFactory =

View File

@ -287,12 +287,12 @@ Reference< XHyphenatedWord > SAL_CALL
// search for entry with that language
HyphSvcByLangMap_t::iterator aIt( aSvcMap.find( nLanguage ) );
LangSvcEntries_Hyph *pEntry = aIt != aSvcMap.end() ? aIt->second.get() : NULL;
LangSvcEntries_Hyph *pEntry = aIt != aSvcMap.end() ? aIt->second.get() : nullptr;
bool bWordModified = false;
if (!pEntry || (nMaxLeading < 0 || nMaxLeading > nWordLen))
{
return NULL;
return nullptr;
}
else
{
@ -423,12 +423,12 @@ Reference< XHyphenatedWord > SAL_CALL
// search for entry with that language
HyphSvcByLangMap_t::iterator aIt( aSvcMap.find( nLanguage ) );
LangSvcEntries_Hyph *pEntry = aIt != aSvcMap.end() ? aIt->second.get() : NULL;
LangSvcEntries_Hyph *pEntry = aIt != aSvcMap.end() ? aIt->second.get() : nullptr;
bool bWordModified = false;
if (!pEntry || !(0 <= nIndex && nIndex <= nWordLen - 2))
{
return NULL;
return nullptr;
}
else
{
@ -554,7 +554,7 @@ Reference< XPossibleHyphens > SAL_CALL
// search for entry with that language
HyphSvcByLangMap_t::iterator aIt( aSvcMap.find( nLanguage ) );
LangSvcEntries_Hyph *pEntry = aIt != aSvcMap.end() ? aIt->second.get() : NULL;
LangSvcEntries_Hyph *pEntry = aIt != aSvcMap.end() ? aIt->second.get() : nullptr;
if (pEntry)
{
@ -699,7 +699,7 @@ Sequence< OUString >
// search for entry with that language and use data from that
sal_Int16 nLanguage = LinguLocaleToLanguage( rLocale );
const HyphSvcByLangMap_t::const_iterator aIt( aSvcMap.find( nLanguage ) );
const LangSvcEntries_Hyph *pEntry = aIt != aSvcMap.end() ? aIt->second.get() : NULL;
const LangSvcEntries_Hyph *pEntry = aIt != aSvcMap.end() ? aIt->second.get() : nullptr;
if (pEntry)
{
aRes = pEntry->aSvcImplNames;

View File

@ -139,12 +139,12 @@ void SAL_CALL FlushListener::disposing( const EventObject& rSource )
if (xDicList.is() && rSource.Source == xDicList)
{
xDicList->removeDictionaryListEventListener( this );
xDicList = NULL; //! release reference
xDicList = nullptr; //! release reference
}
if (xPropSet.is() && rSource.Source == xPropSet)
{
lcl_RemoveAsPropertyChangeListener( this, xPropSet );
xPropSet = NULL; //! release reference
xPropSet = nullptr; //! release reference
}
}

View File

@ -51,7 +51,7 @@ using namespace com::sun::star::registry;
// static member intialization
SvtLinguOptions * LinguOptions::pData = NULL;
SvtLinguOptions * LinguOptions::pData = nullptr;
oslInterlockedCount LinguOptions::nRefCount;
@ -81,7 +81,7 @@ LinguOptions::~LinguOptions()
if ( osl_atomic_decrement( &nRefCount ) == 0 )
{
delete pData; pData = NULL;
delete pData; pData = nullptr;
}
}
@ -95,7 +95,7 @@ struct WID_Name
//! since the WID is used as index in this table!
WID_Name aWID_Name[] =
{
{ 0, 0 },
{ 0, nullptr },
{ UPH_IS_USE_DICTIONARY_LIST, UPN_IS_USE_DICTIONARY_LIST },
{ UPH_IS_IGNORE_CONTROL_CHARACTERS, UPN_IS_IGNORE_CONTROL_CHARACTERS },
{ UPH_IS_SPELL_UPPER_CASE, UPN_IS_SPELL_UPPER_CASE },
@ -106,16 +106,16 @@ WID_Name aWID_Name[] =
{ UPH_HYPH_MIN_WORD_LENGTH, UPN_HYPH_MIN_WORD_LENGTH },
{ UPH_DEFAULT_LOCALE, UPN_DEFAULT_LOCALE },
{ UPH_IS_SPELL_AUTO, UPN_IS_SPELL_AUTO },
{ 0, 0 },
{ 0, 0 },
{ 0, nullptr },
{ 0, nullptr },
{ UPH_IS_SPELL_SPECIAL, UPN_IS_SPELL_SPECIAL },
{ UPH_IS_HYPH_AUTO, UPN_IS_HYPH_AUTO },
{ UPH_IS_HYPH_SPECIAL, UPN_IS_HYPH_SPECIAL },
{ UPH_IS_WRAP_REVERSE, UPN_IS_WRAP_REVERSE },
{ 0, 0 },
{ 0, 0 },
{ 0, 0 },
{ 0, 0 },
{ 0, nullptr },
{ 0, nullptr },
{ 0, nullptr },
{ 0, nullptr },
{ UPH_DEFAULT_LANGUAGE, UPN_DEFAULT_LANGUAGE },
{ UPH_DEFAULT_LOCALE_CJK, UPN_DEFAULT_LOCALE_CJK },
{ UPH_DEFAULT_LOCALE_CTL, UPN_DEFAULT_LOCALE_CTL }
@ -481,7 +481,7 @@ Locale LinguProps::getPropertyLocale(const OUString& aPropertyName) throw (css::
void * SAL_CALL LinguProps_getFactory( const sal_Char * pImplName,
XMultiServiceFactory *pServiceManager, void * )
{
void * pRet = 0;
void * pRet = nullptr;
if ( LinguProps::getImplementationName_Static().equalsAscii( pImplName ) )
{
Reference< XSingleServiceFactory > xFactory =

View File

@ -110,8 +110,8 @@ void PropertyChgHelper::GetCurrentValues()
const OUString *pPropName = GetPropNames().getConstArray();
for (sal_Int32 i = 0; i < nLen; ++i)
{
bool *pbVal = NULL,
*pbResVal = NULL;
bool *pbVal = nullptr,
*pbResVal = nullptr;
if ( pPropName[i] == UPN_IS_IGNORE_CONTROL_CHARACTERS )
{
@ -147,7 +147,7 @@ void PropertyChgHelper::SetTmpPropVals( const PropertyValues &rPropVals )
const PropertyValue *pVal = rPropVals.getConstArray();
for (sal_Int32 i = 0; i < nLen; ++i)
{
bool *pbResVal = NULL;
bool *pbResVal = nullptr;
switch (pVal[i].Handle)
{
case UPH_IS_IGNORE_CONTROL_CHARACTERS :
@ -175,7 +175,7 @@ bool PropertyChgHelper::propertyChange_Impl( const PropertyChangeEvent& rEvt )
bool bSCWA = false, // SPELL_CORRECT_WORDS_AGAIN ?
bSWWA = false; // SPELL_WRONG_WORDS_AGAIN ?
bool *pbVal = NULL;
bool *pbVal = nullptr;
switch (rEvt.PropertyHandle)
{
case UPH_IS_IGNORE_CONTROL_CHARACTERS :
@ -194,7 +194,7 @@ bool PropertyChgHelper::propertyChange_Impl( const PropertyChangeEvent& rEvt )
if (pbVal)
rEvt.NewValue >>= *pbVal;
bRes = 0 != pbVal; // sth changed?
bRes = nullptr != pbVal; // sth changed?
if (bRes)
{
bool bSpellEvts = (nEvtFlags & AE_SPELLCHECKER);
@ -271,7 +271,7 @@ void SAL_CALL PropertyChgHelper::disposing( const EventObject& rSource )
if (rSource.Source == xPropSet)
{
RemoveAsPropListener();
xPropSet = NULL;
xPropSet = nullptr;
aPropNames.realloc( 0 );
}
}
@ -385,8 +385,8 @@ void PropertyHelper_Spell::GetCurrentValues()
const OUString *pPropName = GetPropNames().getConstArray();
for (sal_Int32 i = 0; i < nLen; ++i)
{
bool *pbVal = NULL,
*pbResVal = NULL;
bool *pbVal = nullptr,
*pbResVal = nullptr;
if ( pPropName[i] == UPN_IS_SPELL_UPPER_CASE )
{
@ -423,7 +423,7 @@ bool PropertyHelper_Spell::propertyChange_Impl( const PropertyChangeEvent& rEvt
bool bSCWA = false, // SPELL_CORRECT_WORDS_AGAIN ?
bSWWA = false; // SPELL_WRONG_WORDS_AGAIN ?
bool *pbVal = NULL;
bool *pbVal = nullptr;
switch (rEvt.PropertyHandle)
{
case UPH_IS_SPELL_UPPER_CASE :
@ -453,7 +453,7 @@ bool PropertyHelper_Spell::propertyChange_Impl( const PropertyChangeEvent& rEvt
if (pbVal)
rEvt.NewValue >>= *pbVal;
bRes = (pbVal != 0);
bRes = (pbVal != nullptr);
if (bRes)
{
sal_Int16 nLngSvcFlags = 0;
@ -505,7 +505,7 @@ void PropertyHelper_Spell::SetTmpPropVals( const PropertyValues &rPropVals )
}
else
{
bool *pbResVal = NULL;
bool *pbResVal = nullptr;
switch (pVal[i].Handle)
{
case UPH_IS_SPELL_UPPER_CASE : pbResVal = &bResIsSpellUpperCase; break;
@ -565,8 +565,8 @@ void PropertyHelper_Hyphen::GetCurrentValues()
const OUString *pPropName = GetPropNames().getConstArray();
for (sal_Int32 i = 0; i < nLen; ++i)
{
sal_Int16 *pnVal = NULL,
*pnResVal = NULL;
sal_Int16 *pnVal = nullptr,
*pnResVal = nullptr;
if ( pPropName[i] == UPN_HYPH_MIN_LEADING )
{
@ -602,7 +602,7 @@ bool PropertyHelper_Hyphen::propertyChange_Impl( const PropertyChangeEvent& rEvt
{
sal_Int16 nLngSvcFlags = LinguServiceEventFlags::HYPHENATE_AGAIN;
sal_Int16 *pnVal = NULL;
sal_Int16 *pnVal = nullptr;
switch (rEvt.PropertyHandle)
{
case UPH_HYPH_MIN_LEADING : pnVal = &nHyphMinLeading; break;
@ -614,7 +614,7 @@ bool PropertyHelper_Hyphen::propertyChange_Impl( const PropertyChangeEvent& rEvt
if (pnVal)
rEvt.NewValue >>= *pnVal;
bRes = (pnVal != 0);
bRes = (pnVal != nullptr);
if (bRes)
{
if (nLngSvcFlags)
@ -655,7 +655,7 @@ void PropertyHelper_Hyphen::SetTmpPropVals( const PropertyValues &rPropVals )
const PropertyValue *pVal = rPropVals.getConstArray();
for (sal_Int32 i = 0; i < nLen; ++i)
{
sal_Int16 *pnResVal = NULL;
sal_Int16 *pnResVal = nullptr;
if ( pVal[i].Name == UPN_HYPH_MIN_LEADING )
pnResVal = &nResHyphMinLeading;

View File

@ -255,7 +255,7 @@ void SAL_CALL LngSvcMgrListenerHelper::disposing( const lang::EventObject& rSour
aLngSvcMgrListeners .removeInterface( xRef );
aLngSvcEvtBroadcasters.removeInterface( xRef );
if (xDicList == xRef)
xDicList = 0;
xDicList = nullptr;
}
}
@ -410,7 +410,7 @@ void LngSvcMgrListenerHelper::DisposeAndClear( const lang::EventObject &rEvtObj
{
xDicList->removeDictionaryListEventListener(
static_cast<linguistic2::XDictionaryListEventListener *>(this) );
xDicList = 0;
xDicList = nullptr;
}
}
@ -451,16 +451,16 @@ LngSvcMgr::LngSvcMgr()
{
bDisposing = false;
pSpellDsp = 0;
pGrammarDsp = 0;
pHyphDsp = 0;
pThesDsp = 0;
pSpellDsp = nullptr;
pGrammarDsp = nullptr;
pHyphDsp = nullptr;
pThesDsp = nullptr;
pAvailSpellSvcs = 0;
pAvailGrammarSvcs = 0;
pAvailHyphSvcs = 0;
pAvailThesSvcs = 0;
pListenerHelper = 0;
pAvailSpellSvcs = nullptr;
pAvailGrammarSvcs = nullptr;
pAvailHyphSvcs = nullptr;
pAvailThesSvcs = nullptr;
pListenerHelper = nullptr;
// request notify events when properties (i.e. something in the subtree) changes
uno::Sequence< OUString > aNames(4);
@ -561,7 +561,7 @@ void LngSvcMgr::disposing(const lang::EventObject&)
void LngSvcMgr::clearSvcInfoArray(SvcInfoArray* &rpInfo)
{
delete rpInfo;
rpInfo = NULL;
rpInfo = nullptr;
}
LngSvcMgr::~LngSvcMgr()
@ -1004,7 +1004,7 @@ void LngSvcMgr::GetGrammarCheckerDsp_Impl( bool bSetSvcList )
{
pGrammarDsp = dynamic_cast< GrammarCheckingIterator * >(xGCI.get());
xGrammarDsp = xGCI;
SAL_WARN_IF( pGrammarDsp == NULL, "linguistic", "failed to get implementation" );
SAL_WARN_IF( pGrammarDsp == nullptr, "linguistic", "failed to get implementation" );
if (bSetSvcList && pGrammarDsp)
SetCfgServiceLists( *pGrammarDsp );
}
@ -1550,7 +1550,7 @@ uno::Sequence< OUString > SAL_CALL
osl::MutexGuard aGuard( GetLinguMutex() );
uno::Sequence< OUString > aRes;
const SvcInfoArray *pInfoArray = 0;
const SvcInfoArray *pInfoArray = nullptr;
if (rServiceName == SN_SPELLCHECKER)
{
@ -1610,7 +1610,7 @@ uno::Sequence< lang::Locale > SAL_CALL
uno::Sequence< lang::Locale > aRes;
uno::Sequence< lang::Locale > *pAvailLocales = NULL;
uno::Sequence< lang::Locale > *pAvailLocales = nullptr;
if (rServiceName == SN_SPELLCHECKER)
pAvailLocales = &aAvailSpellLocales;
else if (rServiceName == SN_GRAMMARCHECKER)
@ -1742,7 +1742,7 @@ bool LngSvcMgr::SaveCfgSvcs( const OUString &rServiceName )
bool bRes = false;
LinguDispatcher *pDsp = 0;
LinguDispatcher *pDsp = nullptr;
uno::Sequence< lang::Locale > aLocales;
if (rServiceName == SN_SPELLCHECKER)
@ -1784,7 +1784,7 @@ bool LngSvcMgr::SaveCfgSvcs( const OUString &rServiceName )
beans::PropertyValue *pValue = pValues;
// get node name to be used
const char *pNodeName = NULL;
const char *pNodeName = nullptr;
if (pDsp == pSpellDsp)
pNodeName = "ServiceManager/SpellCheckerList";
else if (pDsp == pGrammarDsp)
@ -2072,7 +2072,7 @@ void * SAL_CALL LngSvcMgr_getFactory(
void * /*pRegistryKey*/ )
{
void * pRet = 0;
void * pRet = nullptr;
if ( LngSvcMgr::getImplementationName_Static().equalsAscii( pImplName ) )
{
uno::Reference< lang::XSingleServiceFactory > xFactory =

View File

@ -312,7 +312,7 @@ uno::Reference< XDictionaryEntry > SearchDicList(
if (bSearchSpellEntry || lcl_HasHyphInfo( xEntry ))
break;
}
xEntry = 0;
xEntry = nullptr;
}
}
}
@ -790,7 +790,7 @@ void SAL_CALL
if (xDesktop.is() && rEvtSource.Source == xDesktop)
{
xDesktop = NULL; //! release reference to desktop
xDesktop = nullptr; //! release reference to desktop
}
}

View File

@ -176,8 +176,8 @@ bool SvcListHasLanguage(
SpellCheckerDispatcher::SpellCheckerDispatcher( LngSvcMgr &rLngSvcMgr ) :
rMgr (rLngSvcMgr)
{
pCache = NULL;
pCharClass = NULL;
pCache = nullptr;
pCharClass = nullptr;
}
@ -292,7 +292,7 @@ bool SpellCheckerDispatcher::isValid_Impl(
// search for entry with that language
SpellSvcByLangMap_t::iterator aIt( aSvcMap.find( nLanguage ) );
LangSvcEntries_Spell *pEntry = aIt != aSvcMap.end() ? aIt->second.get() : NULL;
LangSvcEntries_Spell *pEntry = aIt != aSvcMap.end() ? aIt->second.get() : nullptr;
if (pEntry)
{
@ -458,7 +458,7 @@ Reference< XSpellAlternatives > SpellCheckerDispatcher::spell_Impl(
// search for entry with that language
SpellSvcByLangMap_t::iterator aIt( aSvcMap.find( nLanguage ) );
LangSvcEntries_Spell *pEntry = aIt != aSvcMap.end() ? aIt->second.get() : NULL;
LangSvcEntries_Spell *pEntry = aIt != aSvcMap.end() ? aIt->second.get() : nullptr;
if (pEntry)
{
@ -497,7 +497,7 @@ Reference< XSpellAlternatives > SpellCheckerDispatcher::spell_Impl(
{
bool bOK = GetCache().CheckWord( aChkWord, nLanguage );
if (bOK)
xTmpRes = NULL;
xTmpRes = nullptr;
else
{
xTmpRes = pRef[i]->spell( aChkWord, aLocale, rProperties );
@ -576,7 +576,7 @@ Reference< XSpellAlternatives > SpellCheckerDispatcher::spell_Impl(
{
bool bOK = GetCache().CheckWord( aChkWord, nLanguage );
if (bOK)
xTmpRes = NULL;
xTmpRes = nullptr;
else
{
xTmpRes = xSpell->spell( aChkWord, aLocale, rProperties );
@ -626,7 +626,7 @@ Reference< XSpellAlternatives > SpellCheckerDispatcher::spell_Impl(
// if word is finally found to be correct
// clear previously remembered alternatives
if (bTmpResValid && !xTmpRes.is())
xRes = NULL;
xRes = nullptr;
// list of proposals found (to be checked against entries of
// negative dictionaries)
@ -663,7 +663,7 @@ Reference< XSpellAlternatives > SpellCheckerDispatcher::spell_Impl(
}
else // positive entry found
{
xRes = NULL;
xRes = nullptr;
eFailureType = -1; // no failure
}
}
@ -703,7 +703,7 @@ Reference< XSpellAlternatives > SpellCheckerDispatcher::spell_Impl(
}
else // positive entry found
{
xRes = NULL;
xRes = nullptr;
eFailureType = -1; // no failure
}
}
@ -836,7 +836,7 @@ Sequence< OUString >
// search for entry with that language and use data from that
sal_Int16 nLanguage = LinguLocaleToLanguage( rLocale );
const SpellSvcByLangMap_t::const_iterator aIt( aSvcMap.find( nLanguage ) );
const LangSvcEntries_Spell *pEntry = aIt != aSvcMap.end() ? aIt->second.get() : NULL;
const LangSvcEntries_Spell *pEntry = aIt != aSvcMap.end() ? aIt->second.get() : nullptr;
if (pEntry)
aRes = pEntry->aSvcImplNames;

View File

@ -121,7 +121,7 @@ Sequence< Reference< XMeaning > > SAL_CALL
// search for entry with that language
ThesSvcByLangMap_t::iterator aIt( aSvcMap.find( nLanguage ) );
LangSvcEntries_Thes *pEntry = aIt != aSvcMap.end() ? aIt->second.get() : NULL;
LangSvcEntries_Thes *pEntry = aIt != aSvcMap.end() ? aIt->second.get() : nullptr;
if (pEntry)
{
@ -243,7 +243,7 @@ Sequence< OUString >
// search for entry with that language and use data from that
sal_Int16 nLanguage = LinguLocaleToLanguage( rLocale );
const ThesSvcByLangMap_t::const_iterator aIt( aSvcMap.find( nLanguage ) );
const LangSvcEntries_Thes *pEntry = aIt != aSvcMap.end() ? aIt->second.get() : NULL;
const LangSvcEntries_Thes *pEntry = aIt != aSvcMap.end() ? aIt->second.get() : nullptr;
if (pEntry)
aRes = pEntry->aSvcImplNames;