Import: Simplify handling of Resource_FormatType
The type Resource_FormatType already exists since 2015. So, its usage doesn't require pre-processor macros everywhere.
This commit is contained in:
@@ -40,13 +40,13 @@ using namespace Import;
|
||||
|
||||
ReaderStep::ReaderStep(const Base::FileInfo& file) // NOLINT
|
||||
: file {file}
|
||||
{}
|
||||
|
||||
#if OCC_VERSION_HEX < 0x070800
|
||||
void ReaderStep::read(Handle(TDocStd_Document) hDoc) // NOLINT
|
||||
#else
|
||||
void ReaderStep::read(Handle(TDocStd_Document) hDoc, Resource_FormatType codePage) // NOLINT
|
||||
{
|
||||
#if OCC_VERSION_HEX >= 0x070800
|
||||
codePage = Resource_FormatType_UTF8;
|
||||
#endif
|
||||
}
|
||||
|
||||
void ReaderStep::read(Handle(TDocStd_Document) hDoc) // NOLINT
|
||||
{
|
||||
std::string utf8Name = file.filePath();
|
||||
std::string name8bit = Part::encodeFilename(utf8Name);
|
||||
|
||||
Reference in New Issue
Block a user