- Fixed MSVC build and some cosmetic fixes/optimizations

This commit is contained in:
Ianos Gnatiuc 2006-03-12 10:48:42 +00:00
parent c55d806b87
commit 8be23dd403
2 changed files with 16 additions and 33 deletions

View File

@ -342,17 +342,6 @@ void CMSSpellLang::BuildRTable(const char *codeset)
}
// ------------------------------------------------------------------
void CMSSpellLang::RecodeText(const char *srcText, char *dstText, bool flag)
{
if (flag)
XlatStr(dstText, srcText, mToDicTable->level, mToDicTable);
else
XlatStr(dstText, srcText, mToLocTable->level, mToLocTable);
}
// ------------------------------------------------------------------
void CMSSpellLang::BuildSuggest(const char *text, CSpellSuggestV &suggest)
@ -523,17 +512,6 @@ void CMYSpellLang::BuildRTable(const char *codeset)
}
// ------------------------------------------------------------------
void CMYSpellLang::RecodeText(const char *srcText, char *dstText, bool flag)
{
if (flag)
XlatStr(dstText, srcText, mToDicTable->level, mToDicTable);
else
XlatStr(dstText, srcText, mToLocTable->level, mToLocTable);
}
// ------------------------------------------------------------------
void CMYSpellLang::BuildSuggest(const char *text, CSpellSuggestV &suggest)
@ -568,15 +546,18 @@ bool CMYSpellLang::SpellCheck(const char *text)
// ------------------------------------------------------------------
bool CMYSpellLang::SpellSuggest(const char *text, bool more)
{
return false;
}
#endif //#if !defined(GCFG_NO_MYSPELL)
// ------------------------------------------------------------------
#endif //#if !defined(GCFG_NO_MYSPELL)
void CSpellLang::RecodeText(const char *srcText, char *dstText, bool flag)
{
if (flag)
XlatStr(dstText, srcText, mToDicTable->level, mToDicTable);
else
XlatStr(dstText, srcText, mToLocTable->level, mToLocTable);
}
// ------------------------------------------------------------------

View File

@ -34,6 +34,10 @@
#if defined (__WIN32__)
#include <windows.h>
#ifndef PATH_MAX
#define PATH_MAX _MAX_PATH
#endif
#endif
@ -72,12 +76,11 @@ public:
virtual void UnLoad() = 0;
virtual void BuildRTable(const char *codeset) = 0;
virtual void RecodeText(const char *srcText, char *dstText, bool flag) = 0;
void RecodeText(const char *srcText, char *dstText, bool flag);
virtual void BuildSuggest(const char *text, CSpellSuggestV &suggest) = 0;
virtual bool SpellCheck(const char *text) = 0;
virtual bool SpellSuggest(const char *text, bool more) = 0;
virtual bool AddWord(const char *text) = 0;
bool IsMdrLoaded() { return mIsMdrLoaded; }
@ -200,6 +203,9 @@ private:
SpellGetListUdr_fn mSpellGetListUdr;
SpellVerifyMdr_fn mSpellVerifyMdr;
private:
bool SpellSuggest(const char *text, bool more);
public:
CMSSpellLang() { mLibrary = NULL; }
~CMSSpellLang() { Close(); }
@ -210,12 +216,10 @@ public:
virtual void UnLoad();
virtual void BuildRTable(const char *codeset);
virtual void RecodeText(const char *srcText, char *dstText, bool flag);
virtual void BuildSuggest(const char *text, CSpellSuggestV &suggest);
virtual bool SpellCheck(const char *text);
virtual bool SpellSuggest(const char *text, bool more);
virtual bool AddWord(const char *text);
};
@ -244,12 +248,10 @@ public:
virtual void UnLoad();
virtual void BuildRTable(const char *codeset);
virtual void RecodeText(const char *srcText, char *dstText, bool flag);
virtual void BuildSuggest(const char *text, CSpellSuggestV &suggest);
virtual bool SpellCheck(const char *text);
virtual bool SpellSuggest(const char *text, bool more);
virtual bool AddWord(const char *) { return false; }
};