Subversion Repositories spk

Rev

Rev 242 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 242 Rev 298
Line 24... Line 24...
24
	const wchar_t* chars = (const wchar_t*)(Marshal::StringToHGlobalUni(str)).ToPointer();
24
	const wchar_t* chars = (const wchar_t*)(Marshal::StringToHGlobalUni(str)).ToPointer();
25
	std::wstring s = chars;
25
	std::wstring s = chars;
26
	Marshal::FreeHGlobal(IntPtr((void*)chars));
26
	Marshal::FreeHGlobal(IntPtr((void*)chars));
27
	return s;
27
	return s;
28
}
28
}
29
inline CyString CyStringFromSystemString( System::String ^str)
-
 
30
{
-
 
31
	if ( !str || !str->Length )
-
 
32
		return NullString;
-
 
33
	const char* chars = (const char*)(Marshal::StringToHGlobalAnsi(str)).ToPointer();
-
 
34
	std::string s = chars;
-
 
35
//	CyString *newStr = new CyString(chars);
-
 
36
	Marshal::FreeHGlobal(IntPtr((void*)chars));
-
 
37
//	return *newStr;
-
 
38
	return CyString(s);
-
 
39
}
-
 
40
 
-
 
41
inline int CheckWebFileExists(String ^url)
29
inline int CheckWebFileExists(String ^url)
42
{
30
{
43
	int ret = CONNECTERROR_UNKNOWN;
31
	int ret = CONNECTERROR_UNKNOWN;
44
	try 
32
	try 
45
	{
33
	{