From 8a4c0ec2c0d0f2ac8d06415d841b8374bedd9f8e Mon Sep 17 00:00:00 2001 From: wmayer Date: Sat, 6 Oct 2012 12:17:08 +0200 Subject: [PATCH] Handle API change in OCC 6.5 --- src/Mod/Import/Gui/AppImportGuiPy.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/Mod/Import/Gui/AppImportGuiPy.cpp b/src/Mod/Import/Gui/AppImportGuiPy.cpp index 5cb63a410..134fe15f7 100644 --- a/src/Mod/Import/Gui/AppImportGuiPy.cpp +++ b/src/Mod/Import/Gui/AppImportGuiPy.cpp @@ -671,7 +671,11 @@ static PyObject * exporter(PyObject *self, PyObject *args) writer.Transfer(hDoc, STEPControl_AsIs); // edit STEP header +#if OCC_VERSION_HEX > 0x060500 + APIHeaderSection_MakeHeader makeHeader(writer.ChangeWriter().Model()); +#else APIHeaderSection_MakeHeader makeHeader(writer.Writer().Model()); +#endif makeHeader.SetName(new TCollection_HAsciiString((const Standard_CString)filename)); makeHeader.SetAuthorValue (1, new TCollection_HAsciiString("FreeCAD")); makeHeader.SetOrganizationValue (1, new TCollection_HAsciiString("FreeCAD"));