improve proj
- remove VTImage.hpp to make sure stb image do not need external project to ref. - finish CKStateChunk write part. add some compatibilty code. - add debugger pause function - add filename getter for CKPathManager.
This commit is contained in:
@ -99,6 +99,14 @@ namespace LibCmo::CK2::MgrImpls {
|
||||
return false;
|
||||
}
|
||||
|
||||
void CKPathManager::GetFileName(XContainer::XString& u8path) {
|
||||
std::filesystem::path filepath;
|
||||
EncodingHelper::U8PathToStdPath(filepath, u8path.c_str());
|
||||
|
||||
auto result = filepath.filename();
|
||||
EncodingHelper::StdPathToU8Path(u8path, result);
|
||||
}
|
||||
|
||||
void CKPathManager::GetExtension(XContainer::XString& u8path) {
|
||||
std::filesystem::path filepath;
|
||||
EncodingHelper::U8PathToStdPath(filepath, u8path.c_str());
|
||||
|
@ -53,9 +53,15 @@ namespace LibCmo::CK2::MgrImpls {
|
||||
*/
|
||||
bool ResolveFileName(XContainer::XString& u8_filename);
|
||||
|
||||
/**
|
||||
* @brief Get file name part of given path.
|
||||
* @param u8path[inout] The given path. overwritten by the gotten file name.
|
||||
*/
|
||||
void GetFileName(XContainer::XString& u8path);
|
||||
|
||||
/**
|
||||
* @brief Returns the file extension including period (.)
|
||||
* @param u8path[inout] The given path. overwritten by the gotten extension. set to blank when failed.
|
||||
* @param u8path[inout] The given path. overwritten by the gotten extension.
|
||||
*/
|
||||
void GetExtension(XContainer::XString& u8path);
|
||||
|
||||
|
Reference in New Issue
Block a user