summaryrefslogtreecommitdiff
path: root/linguistic/source
diff options
context:
space:
mode:
authorXisco Fauli <anistenis@gmail.com>2011-04-04 15:13:25 +0200
committerChristina Rossmanith <ChrRossmanith@web.de>2011-04-04 15:13:25 +0200
commitfe44fe403e57155cb479cd8e9cfbb77e1ba4fb01 (patch)
treed2eb6d6abccf8c091e0014499d58850bb0cfcdaf /linguistic/source
parent8607aaf27498ebd949023354d776ae0af49ab43a (diff)
Remove commented code in libs-core/linguistic
Diffstat (limited to 'linguistic/source')
-rw-r--r--linguistic/source/convdic.cxx5
-rw-r--r--linguistic/source/convdic.hxx6
-rw-r--r--linguistic/source/convdiclist.cxx9
-rw-r--r--linguistic/source/convdiclist.hxx2
-rw-r--r--linguistic/source/convdicxml.cxx15
-rw-r--r--linguistic/source/convdicxml.hxx5
-rw-r--r--linguistic/source/defs.hxx4
-rw-r--r--linguistic/source/dicimp.cxx4
-rw-r--r--linguistic/source/dicimp.hxx7
-rw-r--r--linguistic/source/dlistimp.cxx12
-rw-r--r--linguistic/source/dlistimp.hxx2
-rw-r--r--linguistic/source/gciterator.cxx153
-rw-r--r--linguistic/source/gciterator.hxx10
-rw-r--r--linguistic/source/grammarchecker.cxx2
-rw-r--r--linguistic/source/grammarchecker.hxx1
-rw-r--r--linguistic/source/hhconvdic.cxx3
-rw-r--r--linguistic/source/hhconvdic.hxx2
-rw-r--r--linguistic/source/hyphdsp.cxx16
-rw-r--r--linguistic/source/hyphdsp.hxx2
-rw-r--r--linguistic/source/hyphdta.cxx3
-rw-r--r--linguistic/source/iprcache.cxx3
-rw-r--r--linguistic/source/lngopt.cxx9
-rw-r--r--linguistic/source/lngopt.hxx5
-rw-r--r--linguistic/source/lngprophelp.cxx9
-rw-r--r--linguistic/source/lngreg.cxx18
-rw-r--r--linguistic/source/lngsvcmgr.cxx45
-rw-r--r--linguistic/source/lngsvcmgr.hxx2
-rw-r--r--linguistic/source/misc.cxx14
-rw-r--r--linguistic/source/misc2.cxx3
-rw-r--r--linguistic/source/spelldsp.cxx19
-rw-r--r--linguistic/source/spelldsp.hxx2
-rw-r--r--linguistic/source/spelldta.cxx4
-rw-r--r--linguistic/source/thesdsp.cxx3
-rw-r--r--linguistic/source/thesdsp.hxx2
-rw-r--r--linguistic/source/thesdta.cxx2
35 files changed, 4 insertions, 399 deletions
diff --git a/linguistic/source/convdic.cxx b/linguistic/source/convdic.cxx
index 1093b363314d..c1b59ed974be 100644
--- a/linguistic/source/convdic.cxx
+++ b/linguistic/source/convdic.cxx
@@ -85,7 +85,6 @@ using ::rtl::OUString;
#define SN_HCD_CONV_DICTIONARY "com.sun.star.linguistic2.HangulHanjaConversionDictionary"
-///////////////////////////////////////////////////////////////////////////
void ReadThroughDic( const String &rMainURL, ConvDicXMLImport &rImport )
{
if (rMainURL.Len() == 0)
@@ -130,8 +129,6 @@ void ReadThroughDic( const String &rMainURL, ConvDicXMLImport &rImport )
if (!xParser.is())
return;
- // get filter
- //ConvDicXMLImport *pImport = new ConvDicXMLImport( this, rMainURL );
//!! keep a reference until everything is done to
//!! ensure the proper lifetime of the object
uno::Reference < xml::sax::XDocumentHandler > xFilter(
@@ -195,7 +192,6 @@ sal_Bool IsConvDic( const String &rFileURL, sal_Int16 &nLang, sal_Int16 &nConvTy
}
-///////////////////////////////////////////////////////////////////////////
ConvDic::ConvDic(
const String &rName,
@@ -733,7 +729,6 @@ uno::Sequence< OUString > ConvDic::getSupportedServiceNames_Static()
return aSNS;
}
-///////////////////////////////////////////////////////////////////////////
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/linguistic/source/convdic.hxx b/linguistic/source/convdic.hxx
index ad7bb42be498..f33ad751f91b 100644
--- a/linguistic/source/convdic.hxx
+++ b/linguistic/source/convdic.hxx
@@ -51,12 +51,8 @@
class SvStream;
-///////////////////////////////////////////////////////////////////////////
-
sal_Bool IsConvDic( const String &rFileURL, sal_Int16 &nLang, sal_Int16 &nConvType );
-///////////////////////////////////////////////////////////////////////////
-
struct StrLT
{
bool operator()( const rtl::OUString &rTxt1, const rtl::OUString &rTxt2 ) const
@@ -81,7 +77,6 @@ typedef std::set< rtl::OUString, StrLT > ConvMapKeySet;
typedef boost::unordered_multimap< const rtl::OUString, sal_Int16,
rtl::OUStringHash, StrEQ > PropTypeMap;
-///////////////////////////////////////////////////////////////////////////
class ConvDic :
public ::cppu::WeakImplHelper4
@@ -174,7 +169,6 @@ inline ::rtl::OUString ConvDic::getImplementationName_Static() throw()
return A2OU( "com.sun.star.lingu2.ConvDic" );
}
-///////////////////////////////////////////////////////////////////////////
#endif
diff --git a/linguistic/source/convdiclist.cxx b/linguistic/source/convdiclist.cxx
index d4878227824d..b240d13e03a6 100644
--- a/linguistic/source/convdiclist.cxx
+++ b/linguistic/source/convdiclist.cxx
@@ -68,7 +68,6 @@ using ::rtl::OUString;
#define SN_CONV_DICTIONARY_LIST "com.sun.star.linguistic2.ConversionDictionaryList"
-///////////////////////////////////////////////////////////////////////////
bool operator == ( const Locale &r1, const Locale &r2 )
{
@@ -77,7 +76,6 @@ bool operator == ( const Locale &r1, const Locale &r2 )
r1.Variant == r2.Variant;
}
-///////////////////////////////////////////////////////////////////////////
String GetConvDicMainURL( const String &rDicName, const String &rDirectoryURL )
{
@@ -97,7 +95,6 @@ String GetConvDicMainURL( const String &rDicName, const String &rDirectoryURL )
return aURLObj.GetMainURL( INetURLObject::DECODE_TO_IURI );
}
-///////////////////////////////////////////////////////////////////////////
class ConvDicNameContainer :
public cppu::WeakImplHelper1
@@ -393,7 +390,6 @@ void ConvDicNameContainer::AddConvDics(
}
}
-///////////////////////////////////////////////////////////////////////////
namespace
{
@@ -426,9 +422,6 @@ ConvDicList::ConvDicList() :
ConvDicList::~ConvDicList()
{
- // NameContainer will deleted when the reference xNameContainer
- // is destroyed.
- // delete pNameContainer;
if (!bDisposing && pNameContainer)
pNameContainer->FlushDics();
@@ -680,7 +673,6 @@ uno::Sequence< OUString > ConvDicList::getSupportedServiceNames_Static()
}
-///////////////////////////////////////////////////////////////////////////
uno::Reference< uno::XInterface > SAL_CALL ConvDicList_CreateInstance(
const uno::Reference< XMultiServiceFactory > & /*rSMgr*/ )
@@ -709,6 +701,5 @@ void * SAL_CALL ConvDicList_getFactory(
return pRet;
}
-///////////////////////////////////////////////////////////////////////////
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/linguistic/source/convdiclist.hxx b/linguistic/source/convdiclist.hxx
index cd6f1b75b834..f5f4c74360d8 100644
--- a/linguistic/source/convdiclist.hxx
+++ b/linguistic/source/convdiclist.hxx
@@ -43,7 +43,6 @@
class ConvDicNameContainer;
-///////////////////////////////////////////////////////////////////////////
class ConvDicList :
public cppu::WeakImplHelper3
@@ -117,7 +116,6 @@ inline ::rtl::OUString ConvDicList::getImplementationName_Static() throw()
return A2OU( "com.sun.star.lingu2.ConvDicList" );
}
-///////////////////////////////////////////////////////////////////////////
#endif
diff --git a/linguistic/source/convdicxml.cxx b/linguistic/source/convdicxml.cxx
index 017f930a39cb..56ddd94f4487 100644
--- a/linguistic/source/convdicxml.cxx
+++ b/linguistic/source/convdicxml.cxx
@@ -75,7 +75,6 @@ using ::rtl::OUString;
#define CONV_TYPE_HANGUL_HANJA "Hangul / Hanja"
#define CONV_TYPE_SCHINESE_TCHINESE "Chinese simplified / Chinese traditional"
-///////////////////////////////////////////////////////////////////////////
static const OUString ConversionTypeToText( sal_Int16 nConversionType )
{
@@ -97,7 +96,6 @@ static sal_Int16 GetConversionTypeFromText( const String &rText )
return nRes;
}
-///////////////////////////////////////////////////////////////////////////
class ConvDicXMLImportContext :
public SvXMLImportContext
@@ -204,7 +202,6 @@ public:
ConvDic * GetDic() { return GetConvDicImport().GetDic(); }
};
-///////////////////////////////////////////////////////////////////////////
void ConvDicXMLImportContext::Characters(const OUString & /*rChars*/)
{
@@ -216,8 +213,6 @@ void ConvDicXMLImportContext::Characters(const OUString & /*rChars*/)
*/
//collapsing not done yet!
- // warning-free code: since the result is not used there is no need for trimming...
- //const OUString &rChars2 = rChars.trim();
}
SvXMLImportContext * ConvDicXMLImportContext::CreateChildContext(
@@ -232,7 +227,6 @@ SvXMLImportContext * ConvDicXMLImportContext::CreateChildContext(
return pContext;
}
-////////////////////////////////////////
void ConvDicXMLDictionaryContext_Impl::StartElement(
const uno::Reference< xml::sax::XAttributeList > &rxAttrList )
@@ -254,10 +248,6 @@ void ConvDicXMLDictionaryContext_Impl::StartElement(
GetConvDicImport().SetLanguage( nLanguage );
GetConvDicImport().SetConversionType( nConversionType );
- //!! hack to stop the parser from reading the rest of the file !!
- //!! when only the header (language, conversion type) is needed !!
-// if (GetConvDicImport().GetDic() == 0)
-// throw uno::RuntimeException();
}
SvXMLImportContext * ConvDicXMLDictionaryContext_Impl::CreateChildContext(
@@ -272,7 +262,6 @@ SvXMLImportContext * ConvDicXMLDictionaryContext_Impl::CreateChildContext(
return pContext;
}
-////////////////////////////////////////
SvXMLImportContext * ConvDicXMLEntryTextContext_Impl::CreateChildContext(
sal_uInt16 nPrefix, const OUString& rLocalName,
@@ -305,7 +294,6 @@ void ConvDicXMLEntryTextContext_Impl::StartElement(
}
}
-////////////////////////////////////////
SvXMLImportContext * ConvDicXMLRightTextContext_Impl::CreateChildContext(
sal_uInt16 nPrefix, const OUString& rLocalName,
@@ -329,7 +317,6 @@ void ConvDicXMLRightTextContext_Impl::EndElement()
}
-///////////////////////////////////////////////////////////////////////////
sal_Bool ConvDicXMLExport::Export()
{
@@ -421,7 +408,6 @@ void ConvDicXMLExport::_ExportContent()
return A2OU( "com.sun.star.lingu2.ConvDicXMLExport" );
}
-///////////////////////////////////////////////////////////////////////////
void SAL_CALL ConvDicXMLImport::startDocument(void)
throw( xml::sax::SAXException, uno::RuntimeException )
@@ -458,6 +444,5 @@ OUString SAL_CALL ConvDicXMLImport::getImplementationName()
return A2OU( "com.sun.star.lingu2.ConvDicXMLImport" );
}
-///////////////////////////////////////////////////////////////////////////
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/linguistic/source/convdicxml.hxx b/linguistic/source/convdicxml.hxx
index b9b280ccaf0f..c93965d65dcf 100644
--- a/linguistic/source/convdicxml.hxx
+++ b/linguistic/source/convdicxml.hxx
@@ -45,16 +45,12 @@
class ConvDic;
-///////////////////////////////////////////////////////////////////////////
class ConvDicXMLExport : public SvXMLExport
{
ConvDic &rDic;
sal_Bool bSuccess;
-protected:
- //void ExportNodes(const SmNode *pIn, int nLevel);
-
public:
ConvDicXMLExport( ConvDic &rConvDic,
const rtl::OUString &rFileName,
@@ -129,7 +125,6 @@ public:
void SetConversionType( sal_Int16 nType ) { nConversionType = nType; }
};
-///////////////////////////////////////////////////////////////////////////
#endif
diff --git a/linguistic/source/defs.hxx b/linguistic/source/defs.hxx
index a7af9e7ba6a1..14c0ce2f2853 100644
--- a/linguistic/source/defs.hxx
+++ b/linguistic/source/defs.hxx
@@ -39,13 +39,11 @@
class SvStream;
-///////////////////////////////////////////////////////////////////////////
typedef boost::shared_ptr< SvStream > SvStreamPtr;
namespace css = ::com::sun::star;
-///////////////////////////////////////////////////////////////////////////
struct LangSvcEntries
{
@@ -116,7 +114,6 @@ struct LangSvcEntries_Thes : public LangSvcEntries
LangSvcEntries_Thes( const css::uno::Sequence< ::rtl::OUString > &rSvcImplNames ) : LangSvcEntries( rSvcImplNames ) {}
};
-///////////////////////////////////////////////////////////////////////////
// virtual base class for the different dispatchers
class LinguDispatcher
@@ -129,7 +126,6 @@ public:
virtual DspType GetDspType() const = 0;
};
-///////////////////////////////////////////////////////////////////////////
#endif
diff --git a/linguistic/source/dicimp.cxx b/linguistic/source/dicimp.cxx
index a00e52113b47..9339136b9faa 100644
--- a/linguistic/source/dicimp.cxx
+++ b/linguistic/source/dicimp.cxx
@@ -63,7 +63,6 @@ using namespace linguistic;
using ::rtl::OUString;
-///////////////////////////////////////////////////////////////////////////
#define BUFSIZE 4096
#define VERS2_NOLANGUAGE 1024
@@ -203,7 +202,6 @@ const String GetDicExtension()
return String::CreateFromAscii( pDicExt );
}
-///////////////////////////////////////////////////////////////////////////
DictionaryNeo::DictionaryNeo() :
aDicEvtListeners( GetLinguMutex() ),
@@ -1078,7 +1076,6 @@ void SAL_CALL DictionaryNeo::storeToURL(
}
}
-///////////////////////////////////////////////////////////////////////////
DicEntry::DicEntry()
{
@@ -1152,6 +1149,5 @@ OUString SAL_CALL DicEntry::getReplacementText( )
}
-///////////////////////////////////////////////////////////////////////////
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/linguistic/source/dicimp.hxx b/linguistic/source/dicimp.hxx
index 288682e481ec..8f5e232b724d 100644
--- a/linguistic/source/dicimp.hxx
+++ b/linguistic/source/dicimp.hxx
@@ -43,16 +43,11 @@
#include "defs.hxx"
#include "linguistic/misc.hxx"
-
-///////////////////////////////////////////////////////////////////////////
-
#define DIC_MAX_ENTRIES 30000
sal_Int16 ReadDicVersion( SvStreamPtr &rpStream, sal_uInt16 &nLng, sal_Bool &bNeg );
const String GetDicExtension();
-///////////////////////////////////////////////////////////////////////////
-
class DictionaryNeo :
public ::cppu::WeakImplHelper2
<
@@ -196,7 +191,6 @@ public:
};
-///////////////////////////////////////////////////////////////////////////
class DicEntry :
public cppu::WeakImplHelper1
@@ -233,7 +227,6 @@ public:
};
-///////////////////////////////////////////////////////////////////////////
#endif
diff --git a/linguistic/source/dlistimp.cxx b/linguistic/source/dlistimp.cxx
index 14255d99d349..a652b55d1721 100644
--- a/linguistic/source/dlistimp.cxx
+++ b/linguistic/source/dlistimp.cxx
@@ -69,7 +69,6 @@ using namespace linguistic;
using ::rtl::OUString;
-///////////////////////////////////////////////////////////////////////////
static sal_Bool IsVers2OrNewer( const String& rFileURL, sal_uInt16& nLng, sal_Bool& bNeg );
@@ -77,7 +76,6 @@ static void AddInternal( const uno::Reference< XDictionary > &rDic,
const rtl::OUString& rNew );
static void AddUserData( const uno::Reference< XDictionary > &rDic );
-///////////////////////////////////////////////////////////////////////////
class DicEvtListenerHelper :
public cppu::WeakImplHelper1
@@ -184,9 +182,7 @@ void SAL_CALL DicEvtListenerHelper::processDictionaryEvent(
|| xDicEntry.is(),
"lng : missing dictionary entry" );
- //
// evaluate DictionaryEvents and update data for next DictionaryListEvent
- //
DictionaryType eDicType = xDic->getDictionaryType();
DBG_ASSERT(eDicType != DictionaryType_MIXED,
"lng : unexpected dictionary type");
@@ -296,7 +292,6 @@ sal_Int16 DicEvtListenerHelper::FlushEvents()
}
-///////////////////////////////////////////////////////////////////////////
void DicList::MyAppExitListener::AtExit()
@@ -695,12 +690,10 @@ void DicList::_CreateDicList()
// evaluate list of dictionaries to be activated from configuration
- //
//! to suppress overwriting the list of active dictionaries in the
//! configuration with incorrect arguments during the following
//! activation of the dictionaries
pDicEvtLstnrHelper->BeginCollectEvents();
- //
const uno::Sequence< rtl::OUString > aActiveDics( aOpt.GetActiveDics() );
const rtl::OUString *pActiveDic = aActiveDics.getConstArray();
sal_Int32 nLen = aActiveDics.getLength();
@@ -753,9 +746,7 @@ void DicList::SaveDics()
}
-///////////////////////////////////////////////////////////////////////////
// Service specific part
-//
rtl::OUString SAL_CALL DicList::getImplementationName( ) throw(RuntimeException)
{
@@ -814,7 +805,6 @@ void * SAL_CALL DicList_getFactory( const sal_Char * pImplName,
return pRet;
}
-///////////////////////////////////////////////////////////////////////////
xub_StrLen lcl_GetToken( String &rToken,
const String &rText, xub_StrLen nPos, const String &rDelim )
@@ -890,7 +880,6 @@ static void AddUserData( const uno::Reference< XDictionary > &rDic )
}
}
-///////////////////////////////////////////////////////////////////////////
#if defined _MSC_VER
#pragma optimize("g",off)
@@ -939,6 +928,5 @@ static sal_Bool IsVers2OrNewer( const String& rFileURL, sal_uInt16& nLng, sal_Bo
return sal_False;
}
-///////////////////////////////////////////////////////////////////////////
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/linguistic/source/dlistimp.hxx b/linguistic/source/dlistimp.hxx
index d81a2cbffc7f..ca8df5a3b2c4 100644
--- a/linguistic/source/dlistimp.hxx
+++ b/linguistic/source/dlistimp.hxx
@@ -47,7 +47,6 @@
class DicEvtListenerHelper;
-///////////////////////////////////////////////////////////////////////////
class DicList :
public cppu::WeakImplHelper3
@@ -146,7 +145,6 @@ inline ::rtl::OUString DicList::getImplementationName_Static() throw()
return A2OU( "com.sun.star.lingu2.DicList" );
}
-///////////////////////////////////////////////////////////////////////////
#endif
diff --git a/linguistic/source/gciterator.cxx b/linguistic/source/gciterator.cxx
index a5ca694c678e..0f7b7cb2f920 100644
--- a/linguistic/source/gciterator.cxx
+++ b/linguistic/source/gciterator.cxx
@@ -84,7 +84,6 @@ static ::rtl::OUString GrammarCheckingIterator_getImplementationName() throw();
static uno::Sequence< OUString > GrammarCheckingIterator_getSupportedServiceNames() throw();
-//////////////////////////////////////////////////////////////////////
// white space list: obtained from the fonts.config.txt of a Linux system.
static sal_Unicode aWhiteSpaces[] =
@@ -229,7 +228,6 @@ static sal_Int32 lcl_BacktraceWhiteSpaces( const OUString &rText, sal_Int32 nSta
return nRes;
}
-//////////////////////////////////////////////////////////////////////
extern "C" void workerfunc (void * gci)
{
@@ -244,37 +242,6 @@ static lang::Locale lcl_GetPrimaryLanguageOfSentence(
return xFlatPara->getLanguageOfText( nStartIndex, 1 );
}
-//////////////////////////////////////////////////////////////////////
-/*
-class MyThread : punlic osl::Thread
-{
- void run ()
- {
- DequeueAndCheck();
- }
-
- void own_terminate ()
- {
- m_bEnd = true;
- wait (3000);
- terminate ();
- }
-}
-
-MyThread m_aQueue;
-
-vois startGrammarChecking()
-{
- if (!m_aQueue.isRunning ())
- m_aQueue.create ();
-}
-
-void stopGrammarChecking ()
-{
- if (m_aQueue.isRunning ())
- m_aQueue.own_terminate ();
-}
-*/
GrammarCheckingIterator::GrammarCheckingIterator( const uno::Reference< lang::XMultiServiceFactory > & rxMgr ) :
m_xMSF( rxMgr ),
@@ -373,9 +340,7 @@ void GrammarCheckingIterator::ProcessResult(
}
else // paragraph is still unchanged...
{
- //
// mark found errors...
- //
sal_Int32 nTextLen = rRes.aText.getLength();
bool bBoundariesOk = 0 <= rRes.nStartOfSentencePosition && rRes.nStartOfSentencePosition <= nTextLen &&
@@ -470,9 +435,7 @@ uno::Reference< linguistic2::XProofreader > GrammarCheckingIterator::GetGrammarC
// check supported locales for each grammarchecker if not already done
if (!m_bGCServicesChecked)
{
- //GetAvailableGCSvcs_Impl();
GetConfiguredGCSvcs_Impl();
- //GetMatchingGCSvcs_Impl();
m_bGCServicesChecked = sal_True;
}
@@ -912,7 +875,6 @@ throw (uno::RuntimeException)
{
if (xListener.is())
{
-// ::osl::Guard< ::osl::Mutex > aGuard( MyMutex::get() );
m_aNotifyListeners.addInterface( xListener );
}
return sal_True;
@@ -925,7 +887,6 @@ throw (uno::RuntimeException)
{
if (xListener.is())
{
-// ::osl::Guard< ::osl::Mutex > aGuard( MyMutex::get() );
m_aNotifyListeners.removeInterface( xListener );
}
return sal_True;
@@ -938,9 +899,7 @@ throw (uno::RuntimeException)
lang::EventObject aEvt( (linguistic2::XProofreadingIterator *) this );
m_aEventListeners.disposeAndClear( aEvt );
- //
// now end the thread...
- //
m_aRequestEndThread.reset();
// ---- THREAD SAFE START ----
{
@@ -981,7 +940,6 @@ throw (uno::RuntimeException)
{
if (xListener.is())
{
-// ::osl::Guard< ::osl::Mutex > aGuard( MyMutex::get() );
m_aEventListeners.addInterface( xListener );
}
}
@@ -993,7 +951,6 @@ throw (uno::RuntimeException)
{
if (xListener.is())
{
-// ::osl::Guard< ::osl::Mutex > aGuard( MyMutex::get() );
m_aEventListeners.removeInterface( xListener );
}
}
@@ -1104,116 +1061,7 @@ void GrammarCheckingIterator::GetConfiguredGCSvcs_Impl()
}
}
-/*
-void GrammarCheckingIterator::GetMatchingGCSvcs_Impl()
-{
- GCImplNames_t aTmpGCImplNamesByLang;
- try
- {
- // get node names (locale iso strings) for configured grammar checkers
- uno::Reference< container::XNameAccess > xNA( GetUpdateAccess(), uno::UNO_QUERY_THROW );
- xNA.set( xNA->getByName( A2OU("GrammarCheckers") ), uno::UNO_QUERY_THROW );
- const uno::Sequence< OUString > aGCImplNames( xNA->getElementNames() );
- const OUString *pGCImplNames = aGCImplNames.getConstArray();
-
- sal_Int32 nLen = aGCImplNames.getLength();
- for (sal_Int32 i = 0; i < nLen; ++i)
- {
- uno::Reference< container::XNameAccess > xTmpNA( xNA->getByName( pGCImplNames[i] ), uno::UNO_QUERY_THROW );
- uno::Any aTmp( xTmpNA->getByName( A2OU("Locales") ) );
- uno::Sequence< OUString > aIsoLocaleNames;
- if (aTmp >>= aIsoLocaleNames)
- {
- const OUString *pIsoLocaleNames = aIsoLocaleNames.getConstArray();
- for (sal_Int32 k = 0; k < aIsoLocaleNames.getLength(); ++k)
- {
- // if there are more grammar checkers for one language, for the time being,
- // the last one found here will win...
- const LanguageType nLang = MsLangId::convertIsoStringToLanguage( pIsoLocaleNames[k] );
- aTmpGCImplNamesByLang[ nLang ] = pGCImplNames[i];
- }
- }
- else
- {
- DBG_ASSERT( 0, "failed to get aImplNames. Wrong type?" );
- }
- }
- }
- catch (uno::Exception &)
- {
- DBG_ASSERT( 0, "exception caught. Failed to get matching grammar checker services" );
- }
-
- {
- // ---- THREAD SAFE START ----
- ::osl::Guard< ::osl::Mutex > aGuard( MyMutex::get() );
- m_aGCImplNamesByLang = aTmpGCImplNamesByLang;
- // ---- THREAD SAFE END ----
- }
-}
-*/
-
-/*
-void GrammarCheckingIterator::GetAvailableGCSvcs_Impl()
-{
- // internal method; will always be called with locked mutex
- if (m_xMSF.is())
- {
- uno::Reference< container::XContentEnumerationAccess > xEnumAccess( m_xMSF, uno::UNO_QUERY );
- uno::Reference< container::XEnumeration > xEnum;
- if (xEnumAccess.is())
- xEnum = xEnumAccess->createContentEnumeration( A2OU( SN_GRAMMARCHECKER ) );
-
- if (xEnum.is())
- {
- while (xEnum->hasMoreElements())
- {
- uno::Any aCurrent = xEnum->nextElement();
- uno::Reference< lang::XSingleComponentFactory > xCompFactory;
- uno::Reference< lang::XSingleServiceFactory > xFactory;
-
- uno::Reference< uno::XComponentContext > xContext;
- uno::Reference< beans::XPropertySet > xProps( m_xMSF, uno::UNO_QUERY );
- xProps->getPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "DefaultContext" ))) >>= xContext;
-
- if ( xContext.is() &&
- (cppu::extractInterface( xCompFactory, aCurrent ) ||
- cppu::extractInterface( xFactory, aCurrent )) )
- {
- try
- {
- uno::Reference< linguistic2::XProofreader > xSvc( ( xCompFactory.is() ? xCompFactory->createInstanceWithContext( xContext ) : xFactory->createInstance() ), uno::UNO_QUERY );
- if (xSvc.is())
- {
- OUString aImplName;
- uno::Reference< XServiceInfo > xInfo( xSvc, uno::UNO_QUERY );
- if (xInfo.is())
- aImplName = xInfo->getImplementationName();
- DBG_ASSERT( aImplName.getLength(), "empty implementation name" );
- uno::Reference< linguistic2::XSupportedLocales > xSuppLoc( xSvc, uno::UNO_QUERY );
- DBG_ASSERT( xSuppLoc.is(), "interfaces not supported" );
- if (xSuppLoc.is() && aImplName.getLength() > 0)
- {
- uno::Sequence< lang::Locale > aLocaleSequence( xSuppLoc->getLocales() );
- // ---- THREAD SAFE START ----
- ::osl::Guard< ::osl::Mutex > aGuard( MyMutex::get() );
- m_aGCLocalesByService[ aImplName ] = aLocaleSequence;
- m_aGCReferencesByService[ aImplName ] = xSvc;
- // ---- THREAD SAFE END ----
- }
- }
- }
- catch (uno::Exception &)
- {
- DBG_ASSERT( 0, "instantiating grammar checker failed" );
- }
- }
- }
- }
- }
-}
-*/
sal_Bool SAL_CALL GrammarCheckingIterator::supportsService(
@@ -1290,7 +1138,6 @@ LinguDispatcher::DspType GrammarCheckingIterator::GetDspType() const
}
-///////////////////////////////////////////////////////////////////////////
static OUString GrammarCheckingIterator_getImplementationName() throw()
diff --git a/linguistic/source/gciterator.hxx b/linguistic/source/gciterator.hxx
index 4707088a7cfb..aab04dd6f0ae 100644
--- a/linguistic/source/gciterator.hxx
+++ b/linguistic/source/gciterator.hxx
@@ -50,7 +50,6 @@
#include "defs.hxx"
-//////////////////////////////////////////////////////////////////////
struct FPEntry
@@ -79,7 +78,6 @@ struct FPEntry
};
-///////////////////////////////////////////////////////////////////////////
class GrammarCheckingIterator:
@@ -110,10 +108,6 @@ class GrammarCheckingIterator:
typedef std::map< XComponent *, ::rtl::OUString > DocMap_t;
DocMap_t m_aDocIdMap;
- // parameter ::rtl::OUString --> implementation name
- // parameter ::com::sun::star::uno::Sequence< ::com::sun::star::lang::Locale > --> list of locales supported by service
-// typedef std::map< ::rtl::OUString, ::com::sun::star::uno::Sequence< ::com::sun::star::lang::Locale > > GCLocales_t;
-// GCLocales_t m_aGCLocalesByService;
// language -> implname mapping
typedef std::map< LanguageType, ::rtl::OUString > GCImplNames_t;
@@ -132,7 +126,6 @@ class GrammarCheckingIterator:
//! beware of initilization order !
struct MyMutex : public rtl::Static< osl::Mutex, MyMutex > {};
- //
cppu::OInterfaceContainerHelper m_aEventListeners;
cppu::OInterfaceContainerHelper m_aNotifyListeners;
@@ -154,8 +147,6 @@ class GrammarCheckingIterator:
sal_Int32 GetSuggestedEndOfSentence( const ::rtl::OUString &rText, sal_Int32 nSentenceStartPos, const ::com::sun::star::lang::Locale &rLocale );
void GetConfiguredGCSvcs_Impl();
-// void GetMatchingGCSvcs_Impl();
-// void GetAvailableGCSvcs_Impl();
::com::sun::star::uno::Reference< ::com::sun::star::linguistic2::XProofreader > GetGrammarChecker( const ::com::sun::star::lang::Locale & rLocale );
::com::sun::star::uno::Reference< ::com::sun::star::util::XChangesBatch > GetUpdateAccess() const;
@@ -204,7 +195,6 @@ public:
};
-///////////////////////////////////////////////////////////////////////////
#endif
diff --git a/linguistic/source/grammarchecker.cxx b/linguistic/source/grammarchecker.cxx
index 961df73e5a89..a5c1fa11b564 100644
--- a/linguistic/source/grammarchecker.cxx
+++ b/linguistic/source/grammarchecker.cxx
@@ -59,7 +59,6 @@ using namespace ::utl;
using namespace ::rtl;
using namespace ::com::sun::star;
-////////////////////////////////////////////////////////////
GrammarChecker::GrammarChecker( /*uno::Reference< uno::XComponentContext > const & context*/ )
/*m_xContext(context)*/
@@ -258,7 +257,6 @@ sal_Bool SAL_CALL GrammarChecker::supportsService( const OUString& ServiceName )
uno::Sequence< OUString > GrammarChecker::getSupportedServiceNames_Static( ) throw()
{
- //osl::Guard< osl::Mutex > aGuard(GetMutex());
uno::Sequence< OUString > aSNS( 1 ); // more than 1 service possible
aSNS.getArray()[0] = A2OU( "com.sun.star.linguistic2.GrammarChecker" );//SN_LINGU_SERVCICE_MANAGER
diff --git a/linguistic/source/grammarchecker.hxx b/linguistic/source/grammarchecker.hxx
index e3f8ae352554..d7443530ab0d 100644
--- a/linguistic/source/grammarchecker.hxx
+++ b/linguistic/source/grammarchecker.hxx
@@ -50,7 +50,6 @@ class GrammarChecker:
::com::sun::star::lang::XServiceInfo
>
{
-// com::sun::star::uno::Reference< uno::XComponentContext > m_xContext;
// disallow use of copy c-tor and assignment operator
GrammarChecker( const GrammarChecker & );
diff --git a/linguistic/source/hhconvdic.cxx b/linguistic/source/hhconvdic.cxx
index bebe9b8259e7..706005a68c62 100644
--- a/linguistic/source/hhconvdic.cxx
+++ b/linguistic/source/hhconvdic.cxx
@@ -62,7 +62,6 @@ using ::rtl::OUString;
#define SN_HH_CONV_DICTIONARY "com.sun.star.linguistic2.HangulHanjaConversionDictionary"
-///////////////////////////////////////////////////////////////////////////
#include <i18nutil/unicode.hxx>
#include <com/sun/star/i18n/UnicodeScript.hpp>
@@ -100,7 +99,6 @@ sal_Bool TextIsAllScriptType( const OUString &rTxt, sal_Int16 nScriptType )
}
-///////////////////////////////////////////////////////////////////////////
HHConvDic::HHConvDic( const String &rName, const String &rMainURL ) :
ConvDic( rName, LANGUAGE_KOREAN, ConversionDictionaryType::HANGUL_HANJA, sal_True, rMainURL )
@@ -165,6 +163,5 @@ uno::Sequence< OUString > HHConvDic::getSupportedServiceNames_Static()
return aSNS;
}
-///////////////////////////////////////////////////////////////////////////
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/linguistic/source/hhconvdic.hxx b/linguistic/source/hhconvdic.hxx
index 5ed6d554fdad..1419e0d78608 100644
--- a/linguistic/source/hhconvdic.hxx
+++ b/linguistic/source/hhconvdic.hxx
@@ -40,7 +40,6 @@
#include "defs.hxx"
#include "convdic.hxx"
-///////////////////////////////////////////////////////////////////////////
class HHConvDic :
public ConvDic
@@ -73,7 +72,6 @@ inline ::rtl::OUString HHConvDic::getImplementationName_Static() throw()
return A2OU( "com.sun.star.lingu2.HHConvDic" );
}
-///////////////////////////////////////////////////////////////////////////
#endif
diff --git a/linguistic/source/hyphdsp.cxx b/linguistic/source/hyphdsp.cxx
index 65bdadfc5f59..d745b10f4d4e 100644
--- a/linguistic/source/hyphdsp.cxx
+++ b/linguistic/source/hyphdsp.cxx
@@ -60,7 +60,6 @@ using namespace linguistic;
using ::rtl::OUString;
using ::rtl::OUStringBuffer;
-///////////////////////////////////////////////////////////////////////////
HyphenatorDispatcher::HyphenatorDispatcher( LngSvcMgr &rLngSvcMgr ) :
rMgr (rLngSvcMgr)
@@ -341,7 +340,6 @@ Reference< XHyphenatedWord > SAL_CALL
else if (pEntry->nLastTriedSvcIndex < nLen - 1)
// instantiate services and try it
{
-// const OUString *pImplNames = pEntry->aSvcImplNames.getConstArray();
Reference< XHyphenator > *pRef = pEntry->aSvcRefs.getArray();
Reference< XMultiServiceFactory > xMgr( getProcessServiceFactory() );
@@ -350,9 +348,6 @@ Reference< XHyphenatedWord > SAL_CALL
// build service initialization argument
Sequence< Any > aArgs(2);
aArgs.getArray()[0] <<= GetPropSet();
- //! The dispatcher searches the dictionary-list
- //! thus the service needs not to now about it
- //aArgs.getArray()[1] <<= GetDicList();
// create specific service via it's implementation name
try
@@ -480,7 +475,6 @@ Reference< XHyphenatedWord > SAL_CALL
else if (pEntry->nLastTriedSvcIndex < nLen - 1)
// instantiate services and try it
{
-// const OUString *pImplNames = pEntry->aSvcImplNames.getConstArray();
Reference< XHyphenator > *pRef = pEntry->aSvcRefs.getArray();
Reference< XMultiServiceFactory > xMgr( getProcessServiceFactory() );
@@ -489,9 +483,6 @@ Reference< XHyphenatedWord > SAL_CALL
// build service initialization argument
Sequence< Any > aArgs(2);
aArgs.getArray()[0] <<= GetPropSet();
- //! The dispatcher searches the dictionary-list
- //! thus the service needs not to now about it
- //aArgs.getArray()[1] <<= GetDicList();
// create specific service via it's implementation name
try
@@ -614,7 +605,6 @@ Reference< XPossibleHyphens > SAL_CALL
else if (pEntry->nLastTriedSvcIndex < nLen - 1)
// instantiate services and try it
{
-// const OUString *pImplNames = pEntry->aSvcImplNames.getConstArray();
Reference< XHyphenator > *pRef = pEntry->aSvcRefs.getArray();
Reference< XMultiServiceFactory > xMgr( getProcessServiceFactory() );
@@ -623,9 +613,6 @@ Reference< XPossibleHyphens > SAL_CALL
// build service initialization argument
Sequence< Any > aArgs(2);
aArgs.getArray()[0] <<= GetPropSet();
- //! The dispatcher searches the dictionary-list
- //! thus the service needs not to now about it
- //aArgs.getArray()[1] <<= GetDicList();
// create specific service via it's implementation name
try
@@ -687,8 +674,6 @@ void HyphenatorDispatcher::SetServiceList( const Locale &rLocale,
{
// modify/add entry
LangSvcEntries_Hyph *pEntry = aSvcMap[ nLanguage ].get();
- // only one hypenator can be in use for a language...
- //const OUString &rSvcImplName = rSvcImplNames.getConstArray()[0];
if (pEntry)
{
pEntry->Clear();
@@ -735,6 +720,5 @@ LinguDispatcher::DspType HyphenatorDispatcher::GetDspType() const
}
-///////////////////////////////////////////////////////////////////////////
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/linguistic/source/hyphdsp.hxx b/linguistic/source/hyphdsp.hxx
index 75c1976a26eb..520365d0edcf 100644
--- a/linguistic/source/hyphdsp.hxx
+++ b/linguistic/source/hyphdsp.hxx
@@ -51,7 +51,6 @@
class LngSvcMgr;
-///////////////////////////////////////////////////////////////////////////
class HyphenatorDispatcher :
public cppu::WeakImplHelper1
@@ -166,7 +165,6 @@ inline ::com::sun::star::uno::Reference<
}
-///////////////////////////////////////////////////////////////////////////
#endif
diff --git a/linguistic/source/hyphdta.cxx b/linguistic/source/hyphdta.cxx
index ed6b4e169b7b..d03636db7dad 100644
--- a/linguistic/source/hyphdta.cxx
+++ b/linguistic/source/hyphdta.cxx
@@ -50,7 +50,6 @@ using ::rtl::OUString;
namespace linguistic
{
-///////////////////////////////////////////////////////////////////////////
HyphenatedWord::HyphenatedWord(const OUString &rWord, sal_Int16 nLang, sal_Int16 nHPos,
@@ -133,7 +132,6 @@ sal_Bool SAL_CALL HyphenatedWord::isAlternativeSpelling()
}
-///////////////////////////////////////////////////////////////////////////
PossibleHyphens::PossibleHyphens(const OUString &rWord, sal_Int16 nLang,
@@ -183,7 +181,6 @@ Sequence< sal_Int16 > SAL_CALL PossibleHyphens::getHyphenationPositions()
return aOrigHyphenPos;
}
-///////////////////////////////////////////////////////////////////////////
} // namespace linguistic
diff --git a/linguistic/source/iprcache.cxx b/linguistic/source/iprcache.cxx
index 6b4e28c96607..60fead4a3374 100644
--- a/linguistic/source/iprcache.cxx
+++ b/linguistic/source/iprcache.cxx
@@ -53,7 +53,6 @@ using ::rtl::OUString;
namespace linguistic
{
-///////////////////////////////////////////////////////////////////////////
#define NUM_FLUSH_PROPS 6
@@ -214,7 +213,6 @@ void SAL_CALL FlushListener::propertyChange(
}
-///////////////////////////////////////////////////////////////////////////
SpellCache::SpellCache()
{
@@ -259,7 +257,6 @@ void SpellCache::AddWord( const OUString& rWord, LanguageType nLang )
rList.clear();
rList.insert( rWord );
}
-///////////////////////////////////////////////////////////////////////////
} // namespace linguistic
diff --git a/linguistic/source/lngopt.cxx b/linguistic/source/lngopt.cxx
index 8fa1ff68a42a..b7b2f1546015 100644
--- a/linguistic/source/lngopt.cxx
+++ b/linguistic/source/lngopt.cxx
@@ -62,7 +62,6 @@ using namespace com::sun::star::registry;
using ::rtl::OUString;
-///////////////////////////////////////////////////////////////////////////
// static member intialization
@@ -193,8 +192,6 @@ sal_Bool LinguOptions::SetValue( Any &rOld, const Any &rVal, sal_Int32 nWID )
}
}
-// if (bRes)
-// pData->SetModified();
return bRes;
}
@@ -310,7 +307,6 @@ OUString LinguOptions::GetName( sal_Int32 nWID )
}
-///////////////////////////////////////////////////////////////////////////
//! map must be sorted by first entry in alphabetical increasing order.
const SfxItemPropertyMapEntry* lcl_GetLinguProps()
@@ -498,7 +494,6 @@ void SAL_CALL LinguProps::addVetoableChangeListener(
const Reference< XVetoableChangeListener >& /*xListener*/ )
throw(UnknownPropertyException, WrappedTargetException, RuntimeException)
{
-// MutexGuard aGuard( GetLinguMutex() );
}
void SAL_CALL LinguProps::removeVetoableChangeListener(
@@ -506,7 +501,6 @@ void SAL_CALL LinguProps::removeVetoableChangeListener(
const Reference< XVetoableChangeListener >& /*xListener*/ )
throw(UnknownPropertyException, WrappedTargetException, RuntimeException)
{
-// MutexGuard aGuard( GetLinguMutex() );
}
@@ -617,9 +611,7 @@ void SAL_CALL
}
-///////////////////////////////////////////////////////////////////////////
// Service specific part
-//
// XServiceInfo
OUString SAL_CALL LinguProps::getImplementationName()
@@ -681,6 +673,5 @@ void * SAL_CALL LinguProps_getFactory( const sal_Char * pImplName,
return pRet;
}
-///////////////////////////////////////////////////////////////////////////
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/linguistic/source/lngopt.hxx b/linguistic/source/lngopt.hxx
index 295483a8914d..d0e8ae556496 100644
--- a/linguistic/source/lngopt.hxx
+++ b/linguistic/source/lngopt.hxx
@@ -60,10 +60,8 @@ namespace com { namespace sun { namespace star {
-///////////////////////////////////////////////////////////////////////////
// LinguOptions
// This class represents all Linguistik relevant options.
-//
class LinguOptions
{
@@ -95,7 +93,6 @@ public:
};
-///////////////////////////////////////////////////////////////////////////
// uses templates from <cppuhelper/interfacecontainer.h>
@@ -113,7 +110,6 @@ typedef cppu::OMultiTypeInterfaceContainerHelperVar
std::equal_to< sal_Int32 >
> OPropertyListenerContainerHelper;
-///////////////////////////////////////////////////////////////////////////
class LinguProps :
@@ -180,7 +176,6 @@ inline ::rtl::OUString LinguProps::getImplementationName_Static() throw()
return A2OU( "com.sun.star.lingu2.LinguProps" );
}
-///////////////////////////////////////////////////////////////////////////
#endif
diff --git a/linguistic/source/lngprophelp.cxx b/linguistic/source/lngprophelp.cxx
index e9a27ac81bac..8a5c17c27827 100644
--- a/linguistic/source/lngprophelp.cxx
+++ b/linguistic/source/lngprophelp.cxx
@@ -56,7 +56,6 @@ using ::rtl::OUString;
namespace linguistic
{
-///////////////////////////////////////////////////////////////////////////
static const char *aCH[] =
{
@@ -170,7 +169,7 @@ void PropertyChgHelper::SetTmpPropVals( const PropertyValues &rPropVals )
// temporary value
bResIsIgnoreControlCharacters = bIsIgnoreControlCharacters;
bResIsUseDictionaryList = bIsUseDictionaryList;
- //
+
sal_Int32 nLen = rPropVals.getLength();
if (nLen)
{
@@ -186,7 +185,6 @@ void PropertyChgHelper::SetTmpPropVals( const PropertyValues &rPropVals )
pbResVal = &bResIsUseDictionaryList; break;
default:
;
- //DBG_ASSERT( 0, "unknown property" );
}
if (pbResVal)
pVal[i].Value >>= *pbResVal;
@@ -224,7 +222,6 @@ sal_Bool PropertyChgHelper::propertyChange_Impl( const PropertyChangeEvent& rEvt
default:
{
bRes = sal_False;
- //DBG_ASSERT( 0, "unknown property" );
}
}
if (pbVal)
@@ -346,7 +343,6 @@ sal_Bool SAL_CALL
return bRes;
}
-///////////////////////////////////////////////////////////////////////////
PropertyHelper_Thes::PropertyHelper_Thes(
@@ -373,7 +369,6 @@ void SAL_CALL
}
-///////////////////////////////////////////////////////////////////////////
// list of properties from the property set to be used
// and listened to
@@ -563,7 +558,6 @@ sal_Int16 PropertyHelper_Spell::GetDefaultNumberOfSuggestions() const
return 16;
}
-///////////////////////////////////////////////////////////////////////////
static const char *aHP[] =
{
@@ -713,7 +707,6 @@ void PropertyHelper_Hyphen::SetTmpPropVals( const PropertyValues &rPropVals )
}
}
-///////////////////////////////////////////////////////////////////////////
} // namespace linguistic
diff --git a/linguistic/source/lngreg.cxx b/linguistic/source/lngreg.cxx
index 24c60b87cc7f..46cdbd132d7f 100644
--- a/linguistic/source/lngreg.cxx
+++ b/linguistic/source/lngreg.cxx
@@ -74,16 +74,8 @@ extern void * SAL_CALL GrammarCheckingIterator_getFactory
void *
);
-//extern void * SAL_CALL GrammarChecker_getFactory
-//(
-// const sal_Char * pImplName,
-// XMultiServiceFactory * pServiceManager,
-// void *
-//);
-
-////////////////////////////////////////
+
// definition of the two functions that are used to provide the services
-//
extern "C"
{
@@ -126,17 +118,9 @@ void * SAL_CALL component_getFactory(
pImplName,
reinterpret_cast< XMultiServiceFactory * >( pServiceManager ),
pRegistryKey );
-/*
- if(!pRet)
- pRet = GrammarChecker_getFactory(
- pImplName,
- reinterpret_cast< XMultiServiceFactory * >( pServiceManager ),
- pRegistryKey );
-*/
return pRet;
}
}
-///////////////////////////////////////////////////////////////////////////
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/linguistic/source/lngsvcmgr.cxx b/linguistic/source/lngsvcmgr.cxx
index 00c0d96eba86..311ee0133d46 100644
--- a/linguistic/source/lngsvcmgr.cxx
+++ b/linguistic/source/lngsvcmgr.cxx
@@ -63,7 +63,6 @@ using ::rtl::OUString;
uno::Sequence< OUString > static GetLangSvcList( const uno::Any &rVal );
uno::Sequence< OUString > static GetLangSvc( const uno::Any &rVal );
-///////////////////////////////////////////////////////////////////////////
static sal_Bool lcl_SeqHasString( const uno::Sequence< OUString > &rSeq, const OUString &rText )
{
@@ -82,7 +81,6 @@ static sal_Bool lcl_SeqHasString( const uno::Sequence< OUString > &rSeq, const O
return bRes;
}
-///////////////////////////////////////////////////////////////////////////
static uno::Sequence< lang::Locale > GetAvailLocales(
const uno::Sequence< OUString > &rSvcImplNames )
@@ -153,7 +151,6 @@ static uno::Sequence< lang::Locale > GetAvailLocales(
return aRes;
}
-///////////////////////////////////////////////////////////////////////////
struct SvcInfo
{
@@ -186,7 +183,6 @@ sal_Bool SvcInfo::HasLanguage( sal_Int16 nLanguage ) const
}
-///////////////////////////////////////////////////////////////////////////
void LngSvcMgr::SetAvailableCfgServiceLists( LinguDispatcher &rDispatcher,
@@ -275,7 +271,6 @@ void LngSvcMgr::SetAvailableCfgServiceLists( LinguDispatcher &rDispatcher,
}
-///////////////////////////////////////////////////////////////////////////
class LngSvcMgrListenerHelper :
@@ -286,9 +281,7 @@ class LngSvcMgrListenerHelper :
>
{
LngSvcMgr &rMyManager;
-// Timer aLaunchTimer;
- //cppu::OMultiTypeInterfaceContainerHelper aListeners;
::cppu::OInterfaceContainerHelper aLngSvcMgrListeners;
::cppu::OInterfaceContainerHelper aLngSvcEvtBroadcasters;
uno::Reference< linguistic2::XDictionaryList > xDicList;
@@ -302,7 +295,6 @@ class LngSvcMgrListenerHelper :
void LaunchEvent( sal_Int16 nLngSvcEvtFlags );
-// DECL_LINK( TimeOut, Timer* );
long Timeout();
public:
@@ -356,14 +348,6 @@ LngSvcMgrListenerHelper::LngSvcMgrListenerHelper(
(linguistic2::XDictionaryListEventListener *) this, sal_False );
}
- //! The timer is used to 'sum up' different events in order to reduce the
- //! number of events forwarded.
- //! (This may happen already if a property was changed that has several
- //! listeners, and each of them is launching an event of it's own!)
- //! Thus this behaviour is necessary to avoid unecessary actions of
- //! this objects listeners!
-// aLaunchTimer.SetTimeout( 2000 );
-// aLaunchTimer.SetTimeoutHdl( LINK( this, LngSvcMgrListenerHelper, TimeOut ) );
nCombinedLngSvcEvt = 0;
}
@@ -389,7 +373,6 @@ long LngSvcMgrListenerHelper::Timeout()
{
osl::MutexGuard aGuard( GetLinguMutex() );
-// if (&aLaunchTimer == pTimer)
{
// change event source to LinguServiceManager since the listeners
// probably do not know (and need not to know) about the specific
@@ -416,7 +399,6 @@ long LngSvcMgrListenerHelper::Timeout()
void LngSvcMgrListenerHelper::AddLngSvcEvt( sal_Int16 nLngSvcEvt )
{
nCombinedLngSvcEvt |= nLngSvcEvt;
-// aLaunchTimer.Start();
Timeout();
}
@@ -453,11 +435,8 @@ void SAL_CALL
xRef->processDictionaryListEvent( rDicListEvent );
}
- //
// "translate" DictionaryList event into linguistic2::LinguServiceEvent
- //
sal_Int16 nLngSvcEvt = 0;
- //
sal_Int16 nSpellCorrectFlags =
linguistic2::DictionaryListEventFlags::ADD_NEG_ENTRY |
linguistic2::DictionaryListEventFlags::DEL_POS_ENTRY |
@@ -465,7 +444,7 @@ void SAL_CALL
linguistic2::DictionaryListEventFlags::DEACTIVATE_POS_DIC;
if (0 != (nDlEvt & nSpellCorrectFlags))
nLngSvcEvt |= linguistic2::LinguServiceEventFlags::SPELL_CORRECT_WORDS_AGAIN;
- //
+
sal_Int16 nSpellWrongFlags =
linguistic2::DictionaryListEventFlags::ADD_POS_ENTRY |
linguistic2::DictionaryListEventFlags::DEL_NEG_ENTRY |
@@ -473,7 +452,7 @@ void SAL_CALL
linguistic2::DictionaryListEventFlags::DEACTIVATE_NEG_DIC;
if (0 != (nDlEvt & nSpellWrongFlags))
nLngSvcEvt |= linguistic2::LinguServiceEventFlags::SPELL_WRONG_WORDS_AGAIN;
- //
+
sal_Int16 nHyphenateFlags =
linguistic2::DictionaryListEventFlags::ADD_POS_ENTRY |
linguistic2::DictionaryListEventFlags::DEL_POS_ENTRY |
@@ -572,7 +551,6 @@ sal_Bool LngSvcMgrListenerHelper::RemoveLngSvcEvtBroadcaster(
}
-///////////////////////////////////////////////////////////////////////////
LngSvcMgr::LngSvcMgr() :
@@ -1135,10 +1113,6 @@ void LngSvcMgr::SetCfgServiceLists( SpellCheckerDispatcher &rSpellDsp )
uno::Sequence< OUString > aSvcImplNames;
if (pValues[i] >>= aSvcImplNames)
{
-#if OSL_DEBUG_LEVEL > 1
-// sal_Int32 nSvcs = aSvcImplNames.getLength();
-// const OUString *pSvcImplNames = aSvcImplNames.getConstArray();
-#endif
String aLocaleStr( pNames[i] );
xub_StrLen nSeperatorPos = aLocaleStr.SearchBackward( sal_Unicode( '/' ) );
aLocaleStr = aLocaleStr.Copy( nSeperatorPos + 1 );
@@ -1182,10 +1156,6 @@ void LngSvcMgr::SetCfgServiceLists( GrammarCheckingIterator &rGrammarDsp )
if (aSvcImplNames.getLength() > 1)
aSvcImplNames.realloc(1);
-#if OSL_DEBUG_LEVEL > 1
-// sal_Int32 nSvcs = aSvcImplNames.getLength();
-// const OUString *pSvcImplNames = aSvcImplNames.getConstArray();
-#endif
String aLocaleStr( pNames[i] );
xub_StrLen nSeperatorPos = aLocaleStr.SearchBackward( sal_Unicode( '/' ) );
aLocaleStr = aLocaleStr.Copy( nSeperatorPos + 1 );
@@ -1229,10 +1199,6 @@ void LngSvcMgr::SetCfgServiceLists( HyphenatorDispatcher &rHyphDsp )
if (aSvcImplNames.getLength() > 1)
aSvcImplNames.realloc(1);
-#if OSL_DEBUG_LEVEL > 1
-// sal_Int32 nSvcs = aSvcImplNames.getLength();
-// const OUString *pSvcImplNames = aSvcImplNames.getConstArray();
-#endif
String aLocaleStr( pNames[i] );
xub_StrLen nSeperatorPos = aLocaleStr.SearchBackward( sal_Unicode( '/' ) );
aLocaleStr = aLocaleStr.Copy( nSeperatorPos + 1 );
@@ -1272,10 +1238,6 @@ void LngSvcMgr::SetCfgServiceLists( ThesaurusDispatcher &rThesDsp )
uno::Sequence< OUString > aSvcImplNames;
if (pValues[i] >>= aSvcImplNames)
{
-#if OSL_DEBUG_LEVEL > 1
-// sal_Int32 nSvcs = aSvcImplNames.getLength();
-// const OUString *pSvcImplNames = aSvcImplNames.getConstArray();
-#endif
String aLocaleStr( pNames[i] );
xub_StrLen nSeperatorPos = aLocaleStr.SearchBackward( sal_Unicode( '/' ) );
aLocaleStr = aLocaleStr.Copy( nSeperatorPos + 1 );
@@ -1521,7 +1483,6 @@ void SAL_CALL
osl::MutexGuard aGuard( GetLinguMutex() );
#if OSL_DEBUG_LEVEL > 1
-// const OUString *pImplNames = rServiceImplNames.getConstArray();
#endif
LanguageType nLanguage = LocaleToLanguage( rLocale );
@@ -1753,7 +1714,6 @@ static uno::Sequence< OUString > GetLangSvc( const uno::Any &rVal )
}
-///////////////////////////////////////////////////////////////////////////
uno::Sequence< OUString > SAL_CALL
LngSvcMgr::getConfiguredServices(
@@ -1992,6 +1952,5 @@ void * SAL_CALL LngSvcMgr_getFactory(
}
-///////////////////////////////////////////////////////////////////////////
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/linguistic/source/lngsvcmgr.hxx b/linguistic/source/lngsvcmgr.hxx
index 2ca73df51749..7054cf1b4455 100644
--- a/linguistic/source/lngsvcmgr.hxx
+++ b/linguistic/source/lngsvcmgr.hxx
@@ -62,7 +62,6 @@ namespace com { namespace sun { namespace star { namespace linguistic2 {
class XThesaurus;
} } } }
-///////////////////////////////////////////////////////////////////////////
class LngSvcMgr :
@@ -190,7 +189,6 @@ inline ::rtl::OUString LngSvcMgr::getImplementationName_Static()
}
-///////////////////////////////////////////////////////////////////////////
#endif
diff --git a/linguistic/source/misc.cxx b/linguistic/source/misc.cxx
index 73a19fe6d466..2f2df5e2f4a4 100644
--- a/linguistic/source/misc.cxx
+++ b/linguistic/source/misc.cxx
@@ -75,7 +75,6 @@ using ::rtl::OUString;
namespace linguistic
{
-///////////////////////////////////////////////////////////////////////////
//!! multi-thread safe mutex for all platforms !!
struct LinguMutex : public rtl::Static< osl::Mutex, LinguMutex >
@@ -87,7 +86,6 @@ osl::Mutex & GetLinguMutex()
return LinguMutex::get();
}
-///////////////////////////////////////////////////////////////////////////
LocaleDataWrapper & GetLocaleDataWrapper( sal_Int16 nLang )
{
@@ -104,7 +102,6 @@ LocaleDataWrapper & GetLocaleDataWrapper( sal_Int16 nLang )
return aLclDtaWrp;
}
-///////////////////////////////////////////////////////////////////////////
/**
returns text-encoding used for ByteString unicode String conversion
@@ -176,7 +173,6 @@ rtl_TextEncoding GetTextEncoding( sal_Int16 nLanguage )
return nEncoding;
}
-///////////////////////////////////////////////////////////////////////////
static inline sal_Int32 Minimum( sal_Int32 n1, sal_Int32 n2, sal_Int32 n3 )
{
@@ -184,7 +180,6 @@ static inline sal_Int32 Minimum( sal_Int32 n1, sal_Int32 n2, sal_Int32 n3 )
return nMin < n3 ? nMin : n3;
}
-///////////////////////////////////////////////////////////////////////////
class IntArray2D
{
@@ -266,7 +261,6 @@ sal_Int32 LevDistance( const OUString &rTxt1, const OUString &rTxt2 )
return nDist;
}
-///////////////////////////////////////////////////////////////////////////
sal_Bool IsUseDicList( const PropertyValues &rProperties,
const uno::Reference< XPropertySet > &rxProp )
@@ -459,7 +453,6 @@ sal_uInt8 AddEntryToDic(
}
-///////////////////////////////////////////////////////////////////////////
LanguageType LocaleToLanguage( const Locale& rLocale )
{
@@ -519,7 +512,6 @@ uno::Sequence< sal_Int16 >
return aLangs;
}
-///////////////////////////////////////////////////////////////////////////
sal_Bool IsReadOnly( const String &rURL, sal_Bool *pbExist )
{
@@ -551,7 +543,6 @@ sal_Bool IsReadOnly( const String &rURL, sal_Bool *pbExist )
return bRes;
}
-///////////////////////////////////////////////////////////////////////////
static sal_Bool GetAltSpelling( sal_Int16 &rnChgPos, sal_Int16 &rnChgLen, OUString &rRplc,
@@ -707,7 +698,6 @@ uno::Reference< XHyphenatedWord > RebuildHyphensAndControlChars(
}
-///////////////////////////////////////////////////////////////////////////
static CharClass & lcl_GetCharClass()
@@ -880,7 +870,6 @@ sal_Bool IsNumeric( const String &rText )
}
-///////////////////////////////////////////////////////////////////////////
uno::Reference< XInterface > GetOneInstanceService( const char *pServiceName )
{
@@ -932,7 +921,6 @@ uno::Reference< XDictionary > GetIgnoreAllList()
return xRes;
}
-///////////////////////////////////////////////////////////////////////////
AppExitListener::AppExitListener()
{
@@ -990,7 +978,6 @@ void SAL_CALL
AppExitListener::queryTermination( const EventObject& /*rEvtSource*/ )
throw(frame::TerminationVetoException, RuntimeException)
{
- //MutexGuard aGuard( GetLinguMutex() );
}
@@ -1006,7 +993,6 @@ void SAL_CALL
}
}
-///////////////////////////////////////////////////////////////////////////
} // namespace linguistic
diff --git a/linguistic/source/misc2.cxx b/linguistic/source/misc2.cxx
index b8c0e1727b09..6895eae9bff8 100644
--- a/linguistic/source/misc2.cxx
+++ b/linguistic/source/misc2.cxx
@@ -52,7 +52,6 @@ using namespace com::sun::star;
namespace linguistic
{
-///////////////////////////////////////////////////////////////////////////
sal_Bool FileExists( const String &rMainURL )
{
@@ -72,7 +71,6 @@ sal_Bool FileExists( const String &rMainURL )
return bExists;
}
-///////////////////////////////////////////////////////////////////////////
rtl::OUString StripTrailingChars( rtl::OUString &rTxt, sal_Unicode cChar )
{
@@ -87,7 +85,6 @@ rtl::OUString StripTrailingChars( rtl::OUString &rTxt, sal_Unicode cChar )
return aRes;
}
-///////////////////////////////////////////////////////////////////////////
static uno::Sequence< rtl::OUString > GetMultiPaths_Impl(
const rtl::OUString &rPathPrefix,
diff --git a/linguistic/source/spelldsp.cxx b/linguistic/source/spelldsp.cxx
index 3ab2eeb3a0bd..97f96ce227b4 100644
--- a/linguistic/source/spelldsp.cxx
+++ b/linguistic/source/spelldsp.cxx
@@ -60,7 +60,6 @@ using namespace linguistic;
using ::rtl::OUString;
-///////////////////////////////////////////////////////////////////////////
// ProposalList: list of proposals for misspelled words
// The order of strings in the array should be left unchanged because the
// spellchecker should have put the more likely suggestions at the top.
@@ -68,7 +67,6 @@ using ::rtl::OUString;
// Removing entries is done by assigning the empty string.
// The sequence is constructed from all non empty strings in the original
// while maintaining the order.
-//
class ProposalList
{
std::vector< OUString > aVec;
@@ -82,7 +80,6 @@ class ProposalList
public:
ProposalList() {}
- //size_t Size() const { return aVec.size(); }
size_t Count() const;
void Prepend( const OUString &rText );
void Append( const OUString &rNew );
@@ -185,9 +182,6 @@ void ProposalList::Remove( const OUString &rText )
}
}
-
-///////////////////////////////////////////////////////////////////////////
-
sal_Bool SvcListHasLanguage(
const LangSvcEntries_Spell &rEntry,
LanguageType nLanguage )
@@ -210,9 +204,6 @@ sal_Bool SvcListHasLanguage(
return bHasLanguage;
}
-///////////////////////////////////////////////////////////////////////////
-
-
SpellCheckerDispatcher::SpellCheckerDispatcher( LngSvcMgr &rLngSvcMgr ) :
rMgr (rLngSvcMgr)
{
@@ -408,9 +399,6 @@ sal_Bool SpellCheckerDispatcher::isValid_Impl(
// build service initialization argument
Sequence< Any > aArgs(2);
aArgs.getArray()[0] <<= GetPropSet();
- //! The dispatcher searches the dictionary-list
- //! thus the service needs not to now about it
- //aArgs.getArray()[1] <<= GetDicList();
while (i < nLen && (!bTmpResValid || sal_False == bTmpRes))
{
@@ -594,9 +582,6 @@ Reference< XSpellAlternatives > SpellCheckerDispatcher::spell_Impl(
// build service initialization argument
Sequence< Any > aArgs(2);
aArgs.getArray()[0] <<= GetPropSet();
- //! The dispatcher searches the dictionary-list
- //! thus the service needs not to now about it
- //aArgs.getArray()[1] <<= GetDicList();
sal_Int32 nNumSugestions = -1;
while (i < nLen && (!bTmpResValid || xTmpRes.is()))
@@ -681,12 +666,10 @@ Reference< XSpellAlternatives > SpellCheckerDispatcher::spell_Impl(
// list of proposals found (to be checked against entries of
// neagtive dictionaries)
ProposalList aProposalList;
-// Sequence< OUString > aProposals;
sal_Int16 eFailureType = -1; // no failure
if (xRes.is())
{
aProposalList.Append( xRes->getAlternatives() );
-// aProposals = xRes->getAlternatives();
eFailureType = xRes->getFailureType();
}
Reference< XDictionaryList > xDList;
@@ -869,6 +852,4 @@ void SpellCheckerDispatcher::FlushSpellCache()
pCache->Flush();
}
-///////////////////////////////////////////////////////////////////////////
-
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/linguistic/source/spelldsp.hxx b/linguistic/source/spelldsp.hxx
index 5b50b5d621d7..9ae9cd45456b 100644
--- a/linguistic/source/spelldsp.hxx
+++ b/linguistic/source/spelldsp.hxx
@@ -53,7 +53,6 @@
class LngSvcMgr;
-///////////////////////////////////////////////////////////////////////////
class SpellCheckerDispatcher :
public cppu::WeakImplHelper2
@@ -158,7 +157,6 @@ inline ::com::sun::star::uno::Reference<
}
-///////////////////////////////////////////////////////////////////////////
#endif
diff --git a/linguistic/source/spelldta.cxx b/linguistic/source/spelldta.cxx
index fce7a4fea03f..3bc4ce100451 100644
--- a/linguistic/source/spelldta.cxx
+++ b/linguistic/source/spelldta.cxx
@@ -55,7 +55,6 @@ using ::rtl::OUString;
namespace linguistic
{
-///////////////////////////////////////////////////////////////////////////
#define MAX_PROPOSALS 40
@@ -236,14 +235,12 @@ Sequence< OUString > MergeProposalSeqs(
pMerged[ nIndex++ ] = pAlt[ i ];
}
}
- //DBG_ASSERT(nIndex == nCountNew, "wrong number of proposals");
aMerged.realloc( nIndex );
}
return aMerged;
}
-///////////////////////////////////////////////////////////////////////////
SpellAlternatives::SpellAlternatives()
@@ -362,7 +359,6 @@ void SpellAlternatives::SetAlternatives( const Sequence< OUString > &rAlt )
}
-///////////////////////////////////////////////////////////////////////////
} // namespace linguistic
diff --git a/linguistic/source/thesdsp.cxx b/linguistic/source/thesdsp.cxx
index 9cd6f0854cc9..7e4f72308597 100644
--- a/linguistic/source/thesdsp.cxx
+++ b/linguistic/source/thesdsp.cxx
@@ -52,7 +52,6 @@ using namespace linguistic;
using ::rtl::OUString;
-///////////////////////////////////////////////////////////////////////////
static sal_Bool SvcListHasLanguage(
const Sequence< Reference< XThesaurus > > &rRefs,
@@ -71,7 +70,6 @@ static sal_Bool SvcListHasLanguage(
return bHasLanguage;
}
-///////////////////////////////////////////////////////////////////////////
ThesaurusDispatcher::ThesaurusDispatcher()
@@ -280,6 +278,5 @@ LinguDispatcher::DspType ThesaurusDispatcher::GetDspType() const
}
-///////////////////////////////////////////////////////////////////////////
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/linguistic/source/thesdsp.hxx b/linguistic/source/thesdsp.hxx
index 48a8e0e65c60..dabd278a8926 100644
--- a/linguistic/source/thesdsp.hxx
+++ b/linguistic/source/thesdsp.hxx
@@ -54,7 +54,6 @@
#include "lngopt.hxx"
-///////////////////////////////////////////////////////////////////////////
class ThesaurusDispatcher :
public cppu::WeakImplHelper1
@@ -124,7 +123,6 @@ inline ::com::sun::star::uno::Reference<
}
-///////////////////////////////////////////////////////////////////////////
#endif
diff --git a/linguistic/source/thesdta.cxx b/linguistic/source/thesdta.cxx
index bed6421fb0a7..218e5ce2af89 100644
--- a/linguistic/source/thesdta.cxx
+++ b/linguistic/source/thesdta.cxx
@@ -48,7 +48,6 @@ using ::rtl::OUString;
namespace linguistic
{
-///////////////////////////////////////////////////////////////////////////
ThesaurusMeaning::ThesaurusMeaning(const OUString &rText,
@@ -77,7 +76,6 @@ uno::Sequence< OUString > SAL_CALL ThesaurusMeaning::querySynonyms()
}
*/
-///////////////////////////////////////////////////////////////////////////
} // namespace linguistic