Kaydet (Commit) 7b6fd204 authored tarafından Caolán McNamara's avatar Caolán McNamara

make workben example build again

üst 705e5fe9
...@@ -59,14 +59,14 @@ using ::rtl::OUString; ...@@ -59,14 +59,14 @@ using ::rtl::OUString;
PropertyChgHelper::PropertyChgHelper( PropertyChgHelper::PropertyChgHelper(
const Reference< XInterface > & rxSource, const Reference< XInterface > & rxSource,
Reference< XPropertySet > &rxPropSet, Reference< XPropertySet > &rxPropSet,
const char *pPropNames[], USHORT nPropCount ) : const char *pPropNames[], sal_uInt16 nPropCount )
xMyEvtObj (rxSource), : aPropNames(nPropCount)
xPropSet (rxPropSet), , xMyEvtObj(rxSource)
aPropNames (nPropCount), , aLngSvcEvtListeners(GetLinguMutex())
aLngSvcEvtListeners (GetLinguMutex()) , xPropSet(rxPropSet)
{ {
OUString *pName = aPropNames.getArray(); OUString *pName = aPropNames.getArray();
for (INT32 i = 0; i < nPropCount; ++i) for (sal_Int32 i = 0; i < nPropCount; ++i)
{ {
pName[i] = ::rtl::OUString::createFromAscii( pPropNames[i] ); pName[i] = ::rtl::OUString::createFromAscii( pPropNames[i] );
} }
...@@ -93,9 +93,9 @@ void PropertyChgHelper::AddAsPropListener() ...@@ -93,9 +93,9 @@ void PropertyChgHelper::AddAsPropListener()
{ {
if (xPropSet.is()) if (xPropSet.is())
{ {
INT32 nLen = aPropNames.getLength(); sal_Int32 nLen = aPropNames.getLength();
const OUString *pPropName = aPropNames.getConstArray(); const OUString *pPropName = aPropNames.getConstArray();
for (INT32 i = 0; i < nLen; ++i) for (sal_Int32 i = 0; i < nLen; ++i)
{ {
if (pPropName[i].getLength()) if (pPropName[i].getLength())
xPropSet->addPropertyChangeListener( pPropName[i], this ); xPropSet->addPropertyChangeListener( pPropName[i], this );
...@@ -107,9 +107,9 @@ void PropertyChgHelper::RemoveAsPropListener() ...@@ -107,9 +107,9 @@ void PropertyChgHelper::RemoveAsPropListener()
{ {
if (xPropSet.is()) if (xPropSet.is())
{ {
INT32 nLen = aPropNames.getLength(); sal_Int32 nLen = aPropNames.getLength();
const OUString *pPropName = aPropNames.getConstArray(); const OUString *pPropName = aPropNames.getConstArray();
for (INT32 i = 0; i < nLen; ++i) for (sal_Int32 i = 0; i < nLen; ++i)
{ {
if (pPropName[i].getLength()) if (pPropName[i].getLength())
xPropSet->removePropertyChangeListener( pPropName[i], this ); xPropSet->removePropertyChangeListener( pPropName[i], this );
...@@ -150,10 +150,10 @@ sal_Bool SAL_CALL ...@@ -150,10 +150,10 @@ sal_Bool SAL_CALL
{ {
MutexGuard aGuard( GetLinguMutex() ); MutexGuard aGuard( GetLinguMutex() );
BOOL bRes = FALSE; sal_Bool bRes = sal_False;
if (rxListener.is()) if (rxListener.is())
{ {
INT32 nCount = aLngSvcEvtListeners.getLength(); sal_Int32 nCount = aLngSvcEvtListeners.getLength();
bRes = aLngSvcEvtListeners.addInterface( rxListener ) != nCount; bRes = aLngSvcEvtListeners.addInterface( rxListener ) != nCount;
} }
return bRes; return bRes;
...@@ -167,10 +167,10 @@ sal_Bool SAL_CALL ...@@ -167,10 +167,10 @@ sal_Bool SAL_CALL
{ {
MutexGuard aGuard( GetLinguMutex() ); MutexGuard aGuard( GetLinguMutex() );
BOOL bRes = FALSE; sal_Bool bRes = sal_False;
if (rxListener.is()) if (rxListener.is())
{ {
INT32 nCount = aLngSvcEvtListeners.getLength(); sal_Int32 nCount = aLngSvcEvtListeners.getLength();
bRes = aLngSvcEvtListeners.removeInterface( rxListener ) != nCount; bRes = aLngSvcEvtListeners.removeInterface( rxListener ) != nCount;
} }
return bRes; return bRes;
...@@ -194,13 +194,13 @@ PropertyHelper_Spell::PropertyHelper_Spell( ...@@ -194,13 +194,13 @@ PropertyHelper_Spell::PropertyHelper_Spell(
PropertyChgHelper ( rxSource, rxPropSet, aSP, SAL_N_ELEMENTS(aSP)) PropertyChgHelper ( rxSource, rxPropSet, aSP, SAL_N_ELEMENTS(aSP))
{ {
SetDefault(); SetDefault();
INT32 nLen = GetPropNames().getLength(); sal_Int32 nLen = GetPropNames().getLength();
if (rxPropSet.is() && nLen) if (rxPropSet.is() && nLen)
{ {
const OUString *pPropName = GetPropNames().getConstArray(); const OUString *pPropName = GetPropNames().getConstArray();
for (INT32 i = 0; i < nLen; ++i) for (sal_Int32 i = 0; i < nLen; ++i)
{ {
BOOL *pbVal = NULL, sal_Bool *pbVal = NULL,
*pbResVal = NULL; *pbResVal = NULL;
if (A2OU( UPN_IS_GERMAN_PRE_REFORM ) == pPropName[i]) if (A2OU( UPN_IS_GERMAN_PRE_REFORM ) == pPropName[i])
...@@ -251,12 +251,12 @@ PropertyHelper_Spell::~PropertyHelper_Spell() ...@@ -251,12 +251,12 @@ PropertyHelper_Spell::~PropertyHelper_Spell()
void PropertyHelper_Spell::SetDefault() void PropertyHelper_Spell::SetDefault()
{ {
bResIsGermanPreReform = bIsGermanPreReform = FALSE; bResIsGermanPreReform = bIsGermanPreReform = sal_False;
bResIsIgnoreControlCharacters = bIsIgnoreControlCharacters = TRUE; bResIsIgnoreControlCharacters = bIsIgnoreControlCharacters = sal_True;
bResIsUseDictionaryList = bIsUseDictionaryList = TRUE; bResIsUseDictionaryList = bIsUseDictionaryList = sal_True;
bResIsSpellUpperCase = bIsSpellUpperCase = FALSE; bResIsSpellUpperCase = bIsSpellUpperCase = sal_False;
bResIsSpellWithDigits = bIsSpellWithDigits = FALSE; bResIsSpellWithDigits = bIsSpellWithDigits = sal_False;
bResIsSpellCapitalization = bIsSpellCapitalization = TRUE; bResIsSpellCapitalization = bIsSpellCapitalization = sal_True;
} }
...@@ -268,11 +268,11 @@ void SAL_CALL ...@@ -268,11 +268,11 @@ void SAL_CALL
if (GetPropSet().is() && rEvt.Source == GetPropSet()) if (GetPropSet().is() && rEvt.Source == GetPropSet())
{ {
INT16 nLngSvcFlags = 0; sal_Int16 nLngSvcFlags = 0;
BOOL bSCWA = FALSE, // SPELL_CORRECT_WORDS_AGAIN ? sal_Bool bSCWA = sal_False, // SPELL_CORRECT_WORDS_AGAIN ?
bSWWA = FALSE; // SPELL_WRONG_WORDS_AGAIN ? bSWWA = sal_False; // SPELL_WRONG_WORDS_AGAIN ?
BOOL *pbVal = NULL; sal_Bool *pbVal = NULL;
switch (rEvt.PropertyHandle) switch (rEvt.PropertyHandle)
{ {
case UPH_IS_IGNORE_CONTROL_CHARACTERS : case UPH_IS_IGNORE_CONTROL_CHARACTERS :
...@@ -283,34 +283,34 @@ void SAL_CALL ...@@ -283,34 +283,34 @@ void SAL_CALL
case UPH_IS_GERMAN_PRE_REFORM : case UPH_IS_GERMAN_PRE_REFORM :
{ {
pbVal = &bIsGermanPreReform; pbVal = &bIsGermanPreReform;
bSCWA = bSWWA = TRUE; bSCWA = bSWWA = sal_True;
break; break;
} }
case UPH_IS_USE_DICTIONARY_LIST : case UPH_IS_USE_DICTIONARY_LIST :
{ {
pbVal = &bIsUseDictionaryList; pbVal = &bIsUseDictionaryList;
bSCWA = bSWWA = TRUE; bSCWA = bSWWA = sal_True;
break; break;
} }
case UPH_IS_SPELL_UPPER_CASE : case UPH_IS_SPELL_UPPER_CASE :
{ {
pbVal = &bIsSpellUpperCase; pbVal = &bIsSpellUpperCase;
bSCWA = FALSE == *pbVal; // FALSE->TRUE change? bSCWA = sal_False == *pbVal; // sal_False->sal_True change?
bSWWA = !bSCWA; // TRUE->FALSE change? bSWWA = !bSCWA; // sal_True->sal_False change?
break; break;
} }
case UPH_IS_SPELL_WITH_DIGITS : case UPH_IS_SPELL_WITH_DIGITS :
{ {
pbVal = &bIsSpellWithDigits; pbVal = &bIsSpellWithDigits;
bSCWA = FALSE == *pbVal; // FALSE->TRUE change? bSCWA = sal_False == *pbVal; // sal_False->sal_True change?
bSWWA = !bSCWA; // TRUE->FALSE change? bSWWA = !bSCWA; // sal_True->sal_False change?
break; break;
} }
case UPH_IS_SPELL_CAPITALIZATION : case UPH_IS_SPELL_CAPITALIZATION :
{ {
pbVal = &bIsSpellCapitalization; pbVal = &bIsSpellCapitalization;
bSCWA = FALSE == *pbVal; // FALSE->TRUE change? bSCWA = sal_False == *pbVal; // sal_False->sal_True change?
bSWWA = !bSCWA; // TRUE->FALSE change? bSWWA = !bSCWA; // sal_True->sal_False change?
break; break;
} }
default: default:
...@@ -343,13 +343,13 @@ void PropertyHelper_Spell::SetTmpPropVals( const PropertyValues &rPropVals ) ...@@ -343,13 +343,13 @@ void PropertyHelper_Spell::SetTmpPropVals( const PropertyValues &rPropVals )
bResIsSpellWithDigits = bIsSpellWithDigits; bResIsSpellWithDigits = bIsSpellWithDigits;
bResIsSpellCapitalization = bIsSpellCapitalization; bResIsSpellCapitalization = bIsSpellCapitalization;
INT32 nLen = rPropVals.getLength(); sal_Int32 nLen = rPropVals.getLength();
if (nLen) if (nLen)
{ {
const PropertyValue *pVal = rPropVals.getConstArray(); const PropertyValue *pVal = rPropVals.getConstArray();
for (INT32 i = 0; i < nLen; ++i) for (sal_Int32 i = 0; i < nLen; ++i)
{ {
BOOL *pbResVal = NULL; sal_Bool *pbResVal = NULL;
switch (pVal[i].Handle) switch (pVal[i].Handle)
{ {
case UPH_IS_GERMAN_PRE_REFORM : pbResVal = &bResIsGermanPreReform; break; case UPH_IS_GERMAN_PRE_REFORM : pbResVal = &bResIsGermanPreReform; break;
......
...@@ -79,7 +79,7 @@ public: ...@@ -79,7 +79,7 @@ public:
PropertyChgHelper( PropertyChgHelper(
const Reference< XInterface > &rxSource, const Reference< XInterface > &rxSource,
Reference< XPropertySet > &rxPropSet, Reference< XPropertySet > &rxPropSet,
const char *pPropNames[], USHORT nPropCount ); const char *pPropNames[], sal_uInt16 nPropCount );
virtual ~PropertyChgHelper(); virtual ~PropertyChgHelper();
// XEventListener // XEventListener
...@@ -122,20 +122,20 @@ class PropertyHelper_Spell : ...@@ -122,20 +122,20 @@ class PropertyHelper_Spell :
public PropertyChgHelper public PropertyChgHelper
{ {
// default values // default values
BOOL bIsGermanPreReform; sal_Bool bIsGermanPreReform;
BOOL bIsIgnoreControlCharacters; sal_Bool bIsIgnoreControlCharacters;
BOOL bIsUseDictionaryList; sal_Bool bIsUseDictionaryList;
BOOL bIsSpellUpperCase; sal_Bool bIsSpellUpperCase;
BOOL bIsSpellWithDigits; sal_Bool bIsSpellWithDigits;
BOOL bIsSpellCapitalization; sal_Bool bIsSpellCapitalization;
// return values, will be set to default value or current temporary value // return values, will be set to default value or current temporary value
BOOL bResIsGermanPreReform; sal_Bool bResIsGermanPreReform;
BOOL bResIsIgnoreControlCharacters; sal_Bool bResIsIgnoreControlCharacters;
BOOL bResIsUseDictionaryList; sal_Bool bResIsUseDictionaryList;
BOOL bResIsSpellUpperCase; sal_Bool bResIsSpellUpperCase;
BOOL bResIsSpellWithDigits; sal_Bool bResIsSpellWithDigits;
BOOL bResIsSpellCapitalization; sal_Bool bResIsSpellCapitalization;
// disallow use of copy-constructor and assignment-operator // disallow use of copy-constructor and assignment-operator
...@@ -157,12 +157,12 @@ public: ...@@ -157,12 +157,12 @@ public:
void SetTmpPropVals( const PropertyValues &rPropVals ); void SetTmpPropVals( const PropertyValues &rPropVals );
BOOL IsGermanPreReform() const { return bResIsGermanPreReform; } sal_Bool IsGermanPreReform() const { return bResIsGermanPreReform; }
BOOL IsIgnoreControlCharacters() const { return bResIsIgnoreControlCharacters; } sal_Bool IsIgnoreControlCharacters() const { return bResIsIgnoreControlCharacters; }
BOOL IsUseDictionaryList() const { return bResIsUseDictionaryList; } sal_Bool IsUseDictionaryList() const { return bResIsUseDictionaryList; }
BOOL IsSpellUpperCase() const { return bResIsSpellUpperCase; } sal_Bool IsSpellUpperCase() const { return bResIsSpellUpperCase; }
BOOL IsSpellWithDigits() const { return bResIsSpellWithDigits; } sal_Bool IsSpellWithDigits() const { return bResIsSpellWithDigits; }
BOOL IsSpellCapitalization() const { return bResIsSpellCapitalization; } sal_Bool IsSpellCapitalization() const { return bResIsSpellCapitalization; }
}; };
......
...@@ -54,7 +54,7 @@ using namespace linguistic; ...@@ -54,7 +54,7 @@ using namespace linguistic;
using ::rtl::OUString; using ::rtl::OUString;
BOOL operator == ( const Locale &rL1, const Locale &rL2 ) sal_Bool operator == ( const Locale &rL1, const Locale &rL2 )
{ {
return rL1.Language == rL2.Language && return rL1.Language == rL2.Language &&
rL1.Country == rL2.Country && rL1.Country == rL2.Country &&
...@@ -66,7 +66,7 @@ BOOL operator == ( const Locale &rL1, const Locale &rL2 ) ...@@ -66,7 +66,7 @@ BOOL operator == ( const Locale &rL1, const Locale &rL2 )
SpellChecker::SpellChecker() : SpellChecker::SpellChecker() :
aEvtListeners ( GetLinguMutex() ) aEvtListeners ( GetLinguMutex() )
{ {
bDisposing = FALSE; bDisposing = sal_False;
pPropHelper = NULL; pPropHelper = NULL;
} }
...@@ -115,16 +115,16 @@ sal_Bool SAL_CALL SpellChecker::hasLocale(const Locale& rLocale) ...@@ -115,16 +115,16 @@ sal_Bool SAL_CALL SpellChecker::hasLocale(const Locale& rLocale)
{ {
MutexGuard aGuard( GetLinguMutex() ); MutexGuard aGuard( GetLinguMutex() );
BOOL bRes = FALSE; sal_Bool bRes = sal_False;
if (!aSuppLocales.getLength()) if (!aSuppLocales.getLength())
getLocales(); getLocales();
INT32 nLen = aSuppLocales.getLength(); sal_Int32 nLen = aSuppLocales.getLength();
for (INT32 i = 0; i < nLen; ++i) for (sal_Int32 i = 0; i < nLen; ++i)
{ {
const Locale *pLocale = aSuppLocales.getConstArray(); const Locale *pLocale = aSuppLocales.getConstArray();
if (rLocale == pLocale[i]) if (rLocale == pLocale[i])
{ {
bRes = TRUE; bRes = sal_True;
break; break;
} }
} }
...@@ -132,7 +132,7 @@ sal_Bool SAL_CALL SpellChecker::hasLocale(const Locale& rLocale) ...@@ -132,7 +132,7 @@ sal_Bool SAL_CALL SpellChecker::hasLocale(const Locale& rLocale)
} }
INT16 SpellChecker::GetSpellFailure( const OUString &rWord, const Locale &rLocale ) sal_Int16 SpellChecker::GetSpellFailure( const OUString &rWord, const Locale & )
{ {
// Checks wether a word is OK in a given language (Locale) or not, and // Checks wether a word is OK in a given language (Locale) or not, and
// provides a failure type for the incorrect ones. // provides a failure type for the incorrect ones.
...@@ -141,7 +141,7 @@ INT16 SpellChecker::GetSpellFailure( const OUString &rWord, const Locale &rLocal ...@@ -141,7 +141,7 @@ INT16 SpellChecker::GetSpellFailure( const OUString &rWord, const Locale &rLocal
// - words with 's' or 'S' as first letter will have the wrong caption. // - words with 's' or 'S' as first letter will have the wrong caption.
// - all other words will be OK. // - all other words will be OK.
INT16 nRes = -1; sal_Int16 nRes = -1;
String aTmp( rWord ); String aTmp( rWord );
if (aTmp.Len()) if (aTmp.Len())
...@@ -175,13 +175,13 @@ sal_Bool SAL_CALL ...@@ -175,13 +175,13 @@ sal_Bool SAL_CALL
MutexGuard aGuard( GetLinguMutex() ); MutexGuard aGuard( GetLinguMutex() );
if (rLocale == Locale() || !rWord.getLength()) if (rLocale == Locale() || !rWord.getLength())
return TRUE; return sal_True;
if (!hasLocale( rLocale )) if (!hasLocale( rLocale ))
#ifdef LINGU_EXCEPTIONS #ifdef LINGU_EXCEPTIONS
throw( IllegalArgumentException() ); throw( IllegalArgumentException() );
#else #else
return TRUE; return sal_True;
#endif #endif
// Get property values to be used. // Get property values to be used.
...@@ -193,10 +193,10 @@ sal_Bool SAL_CALL ...@@ -193,10 +193,10 @@ sal_Bool SAL_CALL
PropertyHelper_Spell &rHelper = GetPropHelper(); PropertyHelper_Spell &rHelper = GetPropHelper();
rHelper.SetTmpPropVals( rProperties ); rHelper.SetTmpPropVals( rProperties );
INT16 nFailure = GetSpellFailure( rWord, rLocale ); sal_Int16 nFailure = GetSpellFailure( rWord, rLocale );
if (nFailure != -1) if (nFailure != -1)
{ {
INT16 nLang = LocaleToLanguage( rLocale ); sal_Int16 nLang = LocaleToLanguage( rLocale );
// postprocess result for errors that should be ignored // postprocess result for errors that should be ignored
if ( (!rHelper.IsSpellUpperCase() && IsUpper( rWord, nLang )) if ( (!rHelper.IsSpellUpperCase() && IsUpper( rWord, nLang ))
|| (!rHelper.IsSpellWithDigits() && HasDigits( rWord )) || (!rHelper.IsSpellWithDigits() && HasDigits( rWord ))
...@@ -225,13 +225,13 @@ Reference< XSpellAlternatives > ...@@ -225,13 +225,13 @@ Reference< XSpellAlternatives >
String aTmp( rWord ); String aTmp( rWord );
if (aTmp.Len()) if (aTmp.Len())
{ {
INT16 nLang = LocaleToLanguage( rLocale ); sal_Int16 nLang = LocaleToLanguage( rLocale );
if (STRING_NOTFOUND != aTmp.SearchAscii( "liss" )) if (STRING_NOTFOUND != aTmp.SearchAscii( "liss" ))
{ {
aTmp.SearchAndReplaceAllAscii( "liss", A2OU("liz") ); aTmp.SearchAndReplaceAllAscii( "liss", A2OU("liz") );
xRes = new SpellAlternatives( aTmp, nLang, xRes = new SpellAlternatives( aTmp, nLang,
SpellFailure::IS_NEGATIVE_WORD, aTmp ); SpellFailure::IS_NEGATIVE_WORD, ::com::sun::star::uno::Sequence< ::rtl::OUString >() );
} }
else if (STRING_NOTFOUND != aTmp.Search( (sal_Unicode) 'x' ) || else if (STRING_NOTFOUND != aTmp.Search( (sal_Unicode) 'x' ) ||
STRING_NOTFOUND != aTmp.Search( (sal_Unicode) 'X' )) STRING_NOTFOUND != aTmp.Search( (sal_Unicode) 'X' ))
...@@ -263,7 +263,7 @@ Reference< XSpellAlternatives > ...@@ -263,7 +263,7 @@ Reference< XSpellAlternatives >
(sal_Unicode) 'S': (sal_Unicode) 's'; (sal_Unicode) 'S': (sal_Unicode) 's';
aTmp.GetBufferAccess()[0] = cNewChar; aTmp.GetBufferAccess()[0] = cNewChar;
xRes = new SpellAlternatives( aTmp, nLang, xRes = new SpellAlternatives( aTmp, nLang,
SpellFailure::CAPTION_ERROR, aTmp ); SpellFailure::CAPTION_ERROR, ::com::sun::star::uno::Sequence< ::rtl::OUString >() );
} }
} }
} }
...@@ -299,7 +299,7 @@ Reference< XSpellAlternatives > SAL_CALL ...@@ -299,7 +299,7 @@ Reference< XSpellAlternatives > SAL_CALL
Reference< XInterface > SAL_CALL SpellChecker_CreateInstance( Reference< XInterface > SAL_CALL SpellChecker_CreateInstance(
const Reference< XMultiServiceFactory > & rSMgr ) const Reference< XMultiServiceFactory > & )
throw(Exception) throw(Exception)
{ {
Reference< XInterface > xService = (cppu::OWeakObject*) new SpellChecker; Reference< XInterface > xService = (cppu::OWeakObject*) new SpellChecker;
...@@ -314,7 +314,7 @@ sal_Bool SAL_CALL ...@@ -314,7 +314,7 @@ sal_Bool SAL_CALL
{ {
MutexGuard aGuard( GetLinguMutex() ); MutexGuard aGuard( GetLinguMutex() );
BOOL bRes = FALSE; sal_Bool bRes = sal_False;
if (!bDisposing && rxLstnr.is()) if (!bDisposing && rxLstnr.is())
{ {
bRes = GetPropHelper().addLinguServiceEventListener( rxLstnr ); bRes = GetPropHelper().addLinguServiceEventListener( rxLstnr );
...@@ -330,7 +330,7 @@ sal_Bool SAL_CALL ...@@ -330,7 +330,7 @@ sal_Bool SAL_CALL
{ {
MutexGuard aGuard( GetLinguMutex() ); MutexGuard aGuard( GetLinguMutex() );
BOOL bRes = FALSE; sal_Bool bRes = sal_False;
if (!bDisposing && rxLstnr.is()) if (!bDisposing && rxLstnr.is())
{ {
DBG_ASSERT( xPropHelper.is(), "xPropHelper non existent" ); DBG_ASSERT( xPropHelper.is(), "xPropHelper non existent" );
...@@ -341,7 +341,7 @@ sal_Bool SAL_CALL ...@@ -341,7 +341,7 @@ sal_Bool SAL_CALL
OUString SAL_CALL OUString SAL_CALL
SpellChecker::getServiceDisplayName( const Locale& rLocale ) SpellChecker::getServiceDisplayName( const Locale& )
throw(RuntimeException) throw(RuntimeException)
{ {
MutexGuard aGuard( GetLinguMutex() ); MutexGuard aGuard( GetLinguMutex() );
...@@ -357,7 +357,7 @@ void SAL_CALL ...@@ -357,7 +357,7 @@ void SAL_CALL
if (!pPropHelper) if (!pPropHelper)
{ {
INT32 nLen = rArguments.getLength(); sal_Int32 nLen = rArguments.getLength();
if (2 == nLen) if (2 == nLen)
{ {
Reference< XPropertySet > xPropSet; Reference< XPropertySet > xPropSet;
...@@ -385,7 +385,7 @@ void SAL_CALL ...@@ -385,7 +385,7 @@ void SAL_CALL
if (!bDisposing) if (!bDisposing)
{ {
bDisposing = TRUE; bDisposing = sal_True;
EventObject aEvtObj( (XSpellChecker *) this ); EventObject aEvtObj( (XSpellChecker *) this );
aEvtListeners.disposeAndClear( aEvtObj ); aEvtListeners.disposeAndClear( aEvtObj );
} }
...@@ -431,10 +431,10 @@ sal_Bool SAL_CALL SpellChecker::supportsService( const OUString& ServiceName ) ...@@ -431,10 +431,10 @@ sal_Bool SAL_CALL SpellChecker::supportsService( const OUString& ServiceName )
Sequence< OUString > aSNL = getSupportedServiceNames(); Sequence< OUString > aSNL = getSupportedServiceNames();
const OUString * pArray = aSNL.getConstArray(); const OUString * pArray = aSNL.getConstArray();
for( INT32 i = 0; i < aSNL.getLength(); i++ ) for( sal_Int32 i = 0; i < aSNL.getLength(); i++ )
if( pArray[i] == ServiceName ) if( pArray[i] == ServiceName )
return TRUE; return sal_True;
return FALSE; return sal_False;
} }
...@@ -469,7 +469,7 @@ sal_Bool SAL_CALL SpellChecker_writeInfo( ...@@ -469,7 +469,7 @@ sal_Bool SAL_CALL SpellChecker_writeInfo(
pRegistryKey->createKey( aImpl ); pRegistryKey->createKey( aImpl );
Sequence< OUString > aServices = Sequence< OUString > aServices =
SpellChecker::getSupportedServiceNames_Static(); SpellChecker::getSupportedServiceNames_Static();
for( INT32 i = 0; i < aServices.getLength(); i++ ) for( sal_Int32 i = 0; i < aServices.getLength(); i++ )
xNewKey->createKey( aServices.getConstArray()[i] ); xNewKey->createKey( aServices.getConstArray()[i] );
return sal_True; return sal_True;
......
...@@ -69,7 +69,7 @@ class SpellChecker : ...@@ -69,7 +69,7 @@ class SpellChecker :
::cppu::OInterfaceContainerHelper aEvtListeners; ::cppu::OInterfaceContainerHelper aEvtListeners;
Reference< XPropertyChangeListener > xPropHelper; Reference< XPropertyChangeListener > xPropHelper;
PropertyHelper_Spell * pPropHelper; PropertyHelper_Spell * pPropHelper;
BOOL bDisposing; sal_Bool bDisposing;
// disallow copy-constructor and assignment-operator for now // disallow copy-constructor and assignment-operator for now
SpellChecker(const SpellChecker &); SpellChecker(const SpellChecker &);
...@@ -81,7 +81,7 @@ class SpellChecker : ...@@ -81,7 +81,7 @@ class SpellChecker :
return pPropHelper ? *pPropHelper : GetPropHelper_Impl(); return pPropHelper ? *pPropHelper : GetPropHelper_Impl();
} }
INT16 GetSpellFailure( const OUString &rWord, const Locale &rLocale ); sal_Int16 GetSpellFailure( const OUString &rWord, const Locale &rLocale );
Reference< XSpellAlternatives > Reference< XSpellAlternatives >
GetProposals( const OUString &rWord, const Locale &rLocale ); GetProposals( const OUString &rWord, const Locale &rLocale );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment