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:
@@ -157,16 +157,9 @@ private:
|
||||
hApp->NewDocument(TCollection_ExtendedString("MDTV-CAF"), hDoc);
|
||||
|
||||
if (file.hasExtension({"stp", "step"})) {
|
||||
#if OCC_VERSION_HEX >= 0x070800
|
||||
Resource_FormatType cp = Resource_FormatType_UTF8;
|
||||
#endif
|
||||
try {
|
||||
Import::ReaderStep reader(file);
|
||||
#if OCC_VERSION_HEX < 0x070800
|
||||
reader.read(hDoc);
|
||||
#else
|
||||
reader.read(hDoc, cp);
|
||||
#endif
|
||||
}
|
||||
catch (OSD_Exception& e) {
|
||||
Base::Console().Error("%s\n", e.GetMessageString());
|
||||
|
||||
Reference in New Issue
Block a user