Base: implement a lightweight smart pointer for PyObject like Py::Object to reduce includes of Python.h in header files
This commit is contained in:
@@ -24,6 +24,7 @@
|
||||
#define MEASURE_MEASUREMENT_H
|
||||
|
||||
#include <Base/BaseClass.h>
|
||||
#include <Base/SmartPtrPy.h>
|
||||
#include <Base/Vector3D.h>
|
||||
|
||||
#include <App/DocumentObject.h>
|
||||
@@ -84,7 +85,7 @@ public:
|
||||
protected:
|
||||
TopoDS_Shape getShape(App::DocumentObject *obj , const char *subName) const;
|
||||
MeasureType measureType;
|
||||
Py::Object PythonObject;
|
||||
Py::SmartPtr PythonObject;
|
||||
};
|
||||
|
||||
|
||||
|
||||
@@ -28,6 +28,7 @@
|
||||
#include <App/DocumentObject.h>
|
||||
#include <App/PropertyLinks.h>
|
||||
#include <App/PropertyLinks.h>
|
||||
#include <Base/SmartPtrPy.h>
|
||||
#include "Cell.h"
|
||||
|
||||
namespace Spreadsheet
|
||||
@@ -283,7 +284,7 @@ private:
|
||||
std::map<std::string, App::CellAddress> revAliasProp;
|
||||
|
||||
/*! The associated python object */
|
||||
Py::Object PythonObject;
|
||||
Py::SmartPtr PythonObject;
|
||||
|
||||
std::map<const App::DocumentObject*, boost::signals2::scoped_connection> depConnections;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user