本文整理汇总了C++中CSysString::ReverseFind方法的典型用法代码示例。如果您正苦于以下问题:C++ CSysString::ReverseFind方法的具体用法?C++ CSysString::ReverseFind怎么用?C++ CSysString::ReverseFind使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CSysString
的用法示例。
在下文中一共展示了CSysString::ReverseFind方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: NormalizeDirPathPrefix
void NormalizeDirPathPrefix(CSysString &dirPath)
{
if (dirPath.IsEmpty())
return;
if (dirPath.ReverseFind(kDirDelimiter) != dirPath.Length() - 1)
dirPath += kDirDelimiter;
}
示例2: GetBaseFolderPrefix
CSysString GetBaseFolderPrefix()
{
CSysString libPrefix = GetLibraryFolderPrefix();
CSysString temp = libPrefix;
temp.Delete(temp.Length() - 1);
int pos = temp.ReverseFind(TEXT(CHAR_PATH_SEPARATOR));
return temp.Left(pos + 1);
}
示例3: GetLibraryFolderPrefix
static CSysString GetLibraryFolderPrefix()
{
#ifdef _WIN32
TCHAR fullPath[MAX_PATH + 1];
::GetModuleFileName(g_hInstance, fullPath, MAX_PATH);
CSysString path = fullPath;
int pos = path.ReverseFind(TEXT(CHAR_PATH_SEPARATOR));
return path.Left(pos + 1);
#else
return CSysString(); // FIX IT
#endif
}
示例4: GetLibraryFolderPrefix
static CSysString GetLibraryFolderPrefix()
{
#ifdef _WIN32
TCHAR fullPath[MAX_PATH + 1];
::GetModuleFileName(g_hInstance, fullPath, MAX_PATH);
CSysString path = fullPath;
int pos = path.ReverseFind(TEXT(CHAR_PATH_SEPARATOR));
return path.Left(pos + 1);
#else
const char *p7zip_home_dir = getenv("P7ZIP_HOME_DIR");
if (p7zip_home_dir == 0) p7zip_home_dir="./";
#ifdef _UNICODE
return MultiByteToUnicodeString(p7zip_home_dir);
#else
return p7zip_home_dir;
#endif
#endif
}
示例5: GetLibraryFolderPrefix
static CSysString GetLibraryFolderPrefix()
{
CSysString path = GetLibraryPath();
int pos = path.ReverseFind(TEXT(CHAR_PATH_SEPARATOR));
return path.Left(pos + 1);
}