changed: now we do not use std::string and char* in the Winix API
everywhere we are using std::wstring and wchar_t* (std::string and char* is used only locally in some places especially when creating a path to OS file system etc.) added: to the special thread when winix closes: a write function for curl: FetchPageOnExitCurlCallback() without this function the curl library will print the page's content to the standart output changed: TextStream<> class from core can make UTF8<->wide strings conversions removed: from config: utf8 option now winix expects UTF8 from the user's input (html forms, url-es) and outputs strings in the UTF8 format git-svn-id: svn://ttmath.org/publicrep/winix/trunk@965 e52654a7-88a9-db11-a3e9-0013d4bc506e
This commit is contained in:
@@ -186,17 +186,18 @@ void Plugin::LoadPlugins(const std::wstring & plugins_dir, const std::vector<std
|
||||
}
|
||||
|
||||
|
||||
void Plugin::LoadPlugin(const std::string & filename)
|
||||
{
|
||||
LoadPlugin(filename.c_str());
|
||||
}
|
||||
|
||||
|
||||
// we don't have to use Lock() here because plusings are read
|
||||
// we don't have to use Lock() here because plugins are read
|
||||
// before threads are started
|
||||
void * Plugin::LoadInitFun(const char * filename, Fun1 & fun_init)
|
||||
void * Plugin::LoadInitFun(const wchar_t * filename, Fun1 & fun_init)
|
||||
{
|
||||
void * p = dlopen(filename, RTLD_NOW | RTLD_LOCAL);
|
||||
char file[WINIX_OS_PATH_SIZE];
|
||||
|
||||
if( !WideToUTF8(filename, file, WINIX_OS_PATH_SIZE) )
|
||||
return 0;
|
||||
|
||||
void * p = dlopen(file, RTLD_NOW | RTLD_LOCAL);
|
||||
|
||||
if( !p )
|
||||
{
|
||||
@@ -225,7 +226,7 @@ return p;
|
||||
|
||||
|
||||
|
||||
void Plugin::LoadPlugin(const char * filename)
|
||||
void Plugin::LoadPlugin(const wchar_t * filename)
|
||||
{
|
||||
Fun1 fun_init;
|
||||
void * plugin_handle;
|
||||
@@ -255,19 +256,13 @@ PluginInfo info;
|
||||
}
|
||||
|
||||
|
||||
void Plugin::LoadPlugin(const wchar_t * filename)
|
||||
{
|
||||
AssignString(filename, afilename);
|
||||
LoadPlugin(afilename.c_str());
|
||||
}
|
||||
|
||||
|
||||
void Plugin::LoadPlugin(const std::wstring & filename)
|
||||
{
|
||||
LoadPlugin(filename.c_str());
|
||||
}
|
||||
|
||||
|
||||
|
||||
bool Plugin::HasPlugin(const wchar_t * name)
|
||||
{
|
||||
if( *name == 0 )
|
||||
|
Reference in New Issue
Block a user