diff options
Diffstat (limited to 'linguistic/source/spelldta.cxx')
-rw-r--r-- | linguistic/source/spelldta.cxx | 21 |
1 files changed, 18 insertions, 3 deletions
diff --git a/linguistic/source/spelldta.cxx b/linguistic/source/spelldta.cxx index a9c0ebbd8af3..f3729f231132 100644 --- a/linguistic/source/spelldta.cxx +++ b/linguistic/source/spelldta.cxx @@ -34,7 +34,6 @@ #include <com/sun/star/linguistic2/SpellFailure.hpp> #include <com/sun/star/linguistic2/XSearchableDictionaryList.hpp> -#include <com/sun/star/linguistic2/XDictionary1.hpp> #include <tools/debug.hxx> #include <unotools/processfactory.hxx> #include <osl/mutex.hxx> @@ -143,9 +142,9 @@ void SearchSimilarText( const OUString &rText, INT16 nLanguage, for (INT32 i = 0; i < nDics; i++) { - Reference< XDictionary1 > xDic( pDic[i], UNO_QUERY ); + Reference< XDictionary > xDic( pDic[i], UNO_QUERY ); - INT16 nLang = xDic->getLanguage(); + INT16 nLang = LocaleToLanguage( xDic->getLocale() ); if ( xDic.is() && xDic->isActive() && (nLang == nLanguage || nLang == LANGUAGE_NONE) ) @@ -326,6 +325,22 @@ Sequence< OUString > SAL_CALL SpellAlternatives::getAlternatives() } +void SAL_CALL SpellAlternatives::setAlternatives( const uno::Sequence< OUString >& rAlternatives ) +throw (uno::RuntimeException) +{ + MutexGuard aGuard( GetLinguMutex() ); + aAlt = rAlternatives; +} + + +void SAL_CALL SpellAlternatives::setFailureType( sal_Int16 nFailureType ) +throw (uno::RuntimeException) +{ + MutexGuard aGuard( GetLinguMutex() ); + nType = nFailureType; +} + + void SpellAlternatives::SetWordLanguage(const OUString &rWord, INT16 nLang) { MutexGuard aGuard( GetLinguMutex() ); |