]> SALOME platform Git repositories - modules/shaper.git/commitdiff
Salome HOME
Fix compilation error on Linux. Part V.
authorazv <azv@opencascade.com>
Tue, 15 Dec 2015 07:58:24 +0000 (10:58 +0300)
committerazv <azv@opencascade.com>
Tue, 15 Dec 2015 07:58:24 +0000 (10:58 +0300)
src/SketchSolver/SketchSolver_Group.cpp
src/SketchSolver/SketchSolver_Group.h
src/SketchSolver/SolveSpaceSolver/SolveSpaceSolver_Builder.cpp
src/SketchSolver/SolveSpaceSolver/SolveSpaceSolver_ConstraintType.h
src/SketchSolver/SolveSpaceSolver/SolveSpaceSolver_ConstraintWrapper.h
src/SketchSolver/SolveSpaceSolver/SolveSpaceSolver_EntityWrapper.h
src/SketchSolver/SolveSpaceSolver/SolveSpaceSolver_ParameterWrapper.h

index 49402a50b44c1c16851eb07111095fd3fa560380..f4ba30c83ba97cd9ad720712f6be25c5eace4781 100644 (file)
@@ -124,8 +124,7 @@ bool SketchSolver_Group::isBaseWorkplane(CompositeFeaturePtr theWorkplane) const
 //  Class:    SketchSolver_Group
 //  Purpose:  verify are there any entities in the group used by given constraint
 // ============================================================================
-bool SketchSolver_Group::isInteract(
-    std::shared_ptr<SketchPlugin_Feature> theFeature) const
+bool SketchSolver_Group::isInteract(FeaturePtr theFeature) const
 {
   // Empty group interacts with everything
   if (isEmpty())
@@ -301,7 +300,7 @@ void SketchSolver_Group::updateConstraints()
   myChangedConstraints.clear();
 }
 
-bool SketchSolver_Group::updateFeature(std::shared_ptr<SketchPlugin_Feature> theFeature)
+bool SketchSolver_Group::updateFeature(FeaturePtr theFeature)
 {
   if (!checkFeatureValidity(theFeature))
     return false;
@@ -335,7 +334,7 @@ bool SketchSolver_Group::updateFeature(std::shared_ptr<SketchPlugin_Feature> the
   return isUpdated;
 }
 
-void SketchSolver_Group::moveFeature(std::shared_ptr<SketchPlugin_Feature> theFeature)
+void SketchSolver_Group::moveFeature(FeaturePtr theFeature)
 {
   BuilderPtr aBuilder = SketchSolver_Manager::instance()->builder();
 
@@ -390,9 +389,9 @@ bool SketchSolver_Group::updateWorkplane()
     myStorage = aBuilder->createStorage(getId());
 
   // sketch should be unchanged, set it out of current group
-  bool isUpdated = myStorage->update(mySketch, GID_OUTOFGROUP);
+  bool isUpdated = myStorage->update(FeaturePtr(mySketch), GID_OUTOFGROUP);
   if (isUpdated) {
-    EntityWrapperPtr anEntity = myStorage->entity(mySketch);
+    EntityWrapperPtr anEntity = myStorage->entity(FeaturePtr(mySketch));
     myWorkplaneID = anEntity->id();
   }
   return isUpdated;
@@ -542,7 +541,7 @@ void SketchSolver_Group::splitGroup(std::list<SketchSolver_Group*>& theCuts)
   std::list<ConstraintPtr> anUnusedConstraints;
   ConstraintConstraintMap::iterator aCIter = myConstraints.begin();
   for ( ; aCIter != myConstraints.end(); aCIter++) {
-    if (aNewStorage->isInteract(aCIter->first))
+    if (aNewStorage->isInteract(FeaturePtr(aCIter->first)))
       aNewStorage->addConstraint(aCIter->first, aDummyVec);
     else
       anUnusedConstraints.push_back(aCIter->first);
@@ -551,7 +550,7 @@ void SketchSolver_Group::splitGroup(std::list<SketchSolver_Group*>& theCuts)
   // Check the unused constraints once again, because they may become interacted with new storage since adding constraints
   std::list<ConstraintPtr>::iterator aUnuseIt = anUnusedConstraints.begin();
   while (aUnuseIt != anUnusedConstraints.end()) {
-    if (aNewStorage->isInteract(*aUnuseIt)) {
+    if (aNewStorage->isInteract(FeaturePtr(*aUnuseIt))) {
       aNewStorage->addConstraint(*aUnuseIt, aDummyVec);
       anUnusedConstraints.erase(aUnuseIt);
       aUnuseIt = anUnusedConstraints.begin();
index 36bd337399dc6e7ae2daa04fd78fa2ff2f59913f..a8c09c2ac88349621d9f0e7763abc3a1062a2f74 100644 (file)
@@ -75,19 +75,19 @@ class SketchSolver_Group
   /** \brief Updates the data corresponding the specified feature
    *  \param[in] theFeature the feature to be updated
    */
-  bool updateFeature(std::shared_ptr<SketchPlugin_Feature> theFeature);
+  bool updateFeature(FeaturePtr theFeature);
 
   /** \brief Updates the data corresponding the specified feature moved in GUI.
    *         Additional Fixed constraints are created.
    *  \param[in] theFeature the feature to be updated
    */
-  void moveFeature(std::shared_ptr<SketchPlugin_Feature> theFeature);
+  void moveFeature(FeaturePtr theFeature);
 
   /** \brief Verifies the feature attributes are used in this group
    *  \param[in] theFeature constraint or any other object for verification of interaction
    *  \return \c true if some of attributes are used in current group
    */
-  bool isInteract(std::shared_ptr<SketchPlugin_Feature> theFeature) const;
+  bool isInteract(FeaturePtr theFeature) const;
 
   /** \brief Verifies the specified feature is equal to the base workplane for this group
    *  \param[in] theWorkplane the feature to be compared with base workplane
index fac5e3cc3039e802c91f1d490c5d5b1fffca8966..b74a8db1a995722d70fb4cdf4e783c6ffa1fb85b 100644 (file)
@@ -455,7 +455,8 @@ EntityWrapperPtr SolveSpaceSolver_Builder::createSketchEntity(
   Slvs_Entity aWorkplane = Slvs_MakeWorkplane(SLVS_E_UNKNOWN, (Slvs_hGroup)theGroupID,
       SLVS_E_UNKNOWN, SLVS_E_UNKNOWN);
 
-  aNewEnt = EntityWrapperPtr(new SolveSpaceSolver_EntityWrapper(theSketch, aWorkplane));
+  aNewEnt = EntityWrapperPtr(
+      new SolveSpaceSolver_EntityWrapper(FeaturePtr(theSketch), aWorkplane));
   aNewEnt->setSubEntities(aSubs);
   return aNewEnt;
 }
index c9243e6657ae45b5b273bf8ceebe1931c16c23d1..a38939bd415378dbacb5ba3ea6bbe76dcb60c58d 100644 (file)
@@ -9,7 +9,6 @@
 
 #include <SketchSolver_IConstraintWrapper.h>
 #include <SolveSpaceSolver_Solver.h>
-#include <slvs.h>
 
 namespace ConstraintType
 {
index 7045dca3e8233e3fa8407bda83f201ee23d1b9b5..dd1bb1c69e1c708f446a4eb464b34fe692afdb0e 100644 (file)
@@ -8,7 +8,7 @@
 #define SolveSpaceSolver_ConstraintWrapper_H_
 
 #include <SketchSolver_IConstraintWrapper.h>
-#include <slvs.h>
+#include <SolveSpaceSolver_Solver.h>
 
 
 /**
index 14b0bdb841f1273119397efb22dfc8065089bbc8..4f74823612c0bb7dd2bd307eb27a09b7019628ec 100644 (file)
@@ -8,7 +8,7 @@
 #define SolveSpaceSolver_EntityWrapper_H_
 
 #include <SketchSolver_IEntityWrapper.h>
-#include <slvs.h>
+#include <SolveSpaceSolver_Solver.h>
 
 /**
  *  Wrapper providing operations with SolveSpace entities.
index eb92245a1362ff6194c75c4622823434d7dc319f..35609f5436e63b68b42aa694a53bfb8a14fd6e3e 100644 (file)
@@ -8,8 +8,7 @@
 #define SolveSpaceSolver_ParameterWrapper_H_
 
 #include <SketchSolver_IParameterWrapper.h>
-
-#include <slvs.h>
+#include <SolveSpaceSolver_Solver.h>
 
 /**
  *  Wrapper providing operations with parameters in SolveSpace.