Fem: Apply clang-format
This commit is contained in:
@@ -22,12 +22,12 @@
|
||||
|
||||
#include "PreCompiled.h"
|
||||
|
||||
#include <App/GeoFeaturePy.h>
|
||||
#include <App/FeaturePythonPyImp.h>
|
||||
#include <App/GeoFeaturePy.h>
|
||||
#include <Base/Placement.h>
|
||||
|
||||
#include "FemMeshObject.h"
|
||||
#include "FemMesh.h"
|
||||
#include "FemMeshObject.h"
|
||||
|
||||
|
||||
using namespace Fem;
|
||||
@@ -38,7 +38,7 @@ PROPERTY_SOURCE(Fem::FemMeshObject, App::GeoFeature)
|
||||
|
||||
FemMeshObject::FemMeshObject()
|
||||
{
|
||||
ADD_PROPERTY_TYPE(FemMesh,(), "FEM Mesh",Prop_NoRecompute,"FEM Mesh object");
|
||||
ADD_PROPERTY_TYPE(FemMesh, (), "FEM Mesh", Prop_NoRecompute, "FEM Mesh object");
|
||||
// in the regard of recomputes see:
|
||||
// https://forum.freecad.org/viewtopic.php?f=18&t=33329#p279203
|
||||
}
|
||||
@@ -50,9 +50,9 @@ short FemMeshObject::mustExecute() const
|
||||
return 0;
|
||||
}
|
||||
|
||||
PyObject *FemMeshObject::getPyObject()
|
||||
PyObject* FemMeshObject::getPyObject()
|
||||
{
|
||||
if (PythonObject.is(Py::_None())){
|
||||
if (PythonObject.is(Py::_None())) {
|
||||
// ref counter is set to 1
|
||||
PythonObject = Py::asObject(new GeoFeaturePy(this));
|
||||
}
|
||||
@@ -67,19 +67,23 @@ void FemMeshObject::onChanged(const Property* prop)
|
||||
if (prop == &this->Placement) {
|
||||
this->FemMesh.setTransform(this->Placement.getValue().toMatrix());
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Python feature ---------------------------------------------------------
|
||||
|
||||
namespace App {
|
||||
namespace App
|
||||
{
|
||||
/// @cond DOXERR
|
||||
PROPERTY_SOURCE_TEMPLATE(Fem::FemMeshObjectPython, Fem::FemMeshObject)
|
||||
template<> const char* Fem::FemMeshObjectPython::getViewProviderName() const {
|
||||
template<>
|
||||
const char* Fem::FemMeshObjectPython::getViewProviderName() const
|
||||
{
|
||||
return "FemGui::ViewProviderFemMeshPython";
|
||||
}
|
||||
|
||||
template<> PyObject* Fem::FemMeshObjectPython::getPyObject() {
|
||||
template<>
|
||||
PyObject* Fem::FemMeshObjectPython::getPyObject()
|
||||
{
|
||||
if (PythonObject.is(Py::_None())) {
|
||||
// ref counter is set to 1
|
||||
PythonObject = Py::asObject(new App::FeaturePythonPyT<App::GeoFeaturePy>(this));
|
||||
@@ -92,4 +96,4 @@ template class FemExport FeaturePythonT<Fem::FemMeshObject>;
|
||||
|
||||
/// @endcond
|
||||
|
||||
}
|
||||
} // namespace App
|
||||
|
||||
Reference in New Issue
Block a user