From 9d759ae95e6939ba66eb7efa95ea412c68b894c8 Mon Sep 17 00:00:00 2001 From: mpv Date: Fri, 6 May 2016 09:42:38 +0300 Subject: [PATCH] Fix some doxygen documentation problems and compiler warnings --- src/ConnectorPlugin/ConnectorPlugin_ExportFeature.py | 4 ++++ src/Events/Events_Error.h | 2 +- src/Model/Model_AttributeSelectionList.h | 1 + src/Model/Model_SelectionNaming.cpp | 8 ++++---- src/Model/Model_Update.h | 1 - src/ModelAPI/ModelAPI_AttributeSelectionList.h | 1 + src/ModelAPI/ModelAPI_Events.h | 4 +++- src/ModelAPI/ModelAPI_Feature.h | 4 ++-- src/XGUI/XGUI_MenuMgr.cpp | 2 +- 9 files changed, 17 insertions(+), 10 deletions(-) diff --git a/src/ConnectorPlugin/ConnectorPlugin_ExportFeature.py b/src/ConnectorPlugin/ConnectorPlugin_ExportFeature.py index 31db8fc9a..e9cb9804f 100644 --- a/src/ConnectorPlugin/ConnectorPlugin_ExportFeature.py +++ b/src/ConnectorPlugin/ConnectorPlugin_ExportFeature.py @@ -27,6 +27,10 @@ class ExportFeature(ModelAPI.ModelAPI_Feature): ## The constructor. def __init__(self): ModelAPI.ModelAPI_Feature.__init__(self) + ## Shape that will be exported (the compound if there are several exported bodies) + self.shape = None + ## BRep representation of the exported shape (a stream that will be sent to GEOM and converted to GEOM object) + self.brep = None @staticmethod ## Export kind. Static. diff --git a/src/Events/Events_Error.h b/src/Events/Events_Error.h index b344c6e36..aefa5dd73 100644 --- a/src/Events/Events_Error.h +++ b/src/Events/Events_Error.h @@ -38,7 +38,7 @@ public: EVENTS_EXPORT static void send(const std::string& theDescription, const void* theSender = 0); /// Throws a C++ exception about using an empty AIS object - /// \theDescription an exception information + /// \param theDescription an exception information EVENTS_EXPORT static void throwException(const std::string& theDescription); protected: diff --git a/src/Model/Model_AttributeSelectionList.h b/src/Model/Model_AttributeSelectionList.h index c0f36fd7c..3c6317d5a 100644 --- a/src/Model/Model_AttributeSelectionList.h +++ b/src/Model/Model_AttributeSelectionList.h @@ -57,6 +57,7 @@ public: /// Returns true if the object with the shape are in list /// \param theContext object where the sub-shape was selected /// \param theSubShape selected sub-shape (if null, the whole context is selected) + /// \param theTemporarily if it is true, it checks also the temporary added item /// \returns true if the pair is found in the attirbute MODEL_EXPORT virtual bool isInList( const ResultPtr& theContext, const std::shared_ptr& theSubShape, diff --git a/src/Model/Model_SelectionNaming.cpp b/src/Model/Model_SelectionNaming.cpp index 2a776e624..167d3b935 100644 --- a/src/Model/Model_SelectionNaming.cpp +++ b/src/Model/Model_SelectionNaming.cpp @@ -335,11 +335,11 @@ const TopoDS_Shape findFaceByName( return aFace; } -int ParseName(const std::string& theSubShapeName, std::list& theList) +size_t ParseName(const std::string& theSubShapeName, std::list& theList) { std::string aName = theSubShapeName; std::string aLastName; - int n1(0), n2(0); // n1 - start position, n2 - position of the delimiter + size_t n1(0), n2(0); // n1 - start position, n2 - position of the delimiter while ((n2 = aName.find('&', n1)) != std::string::npos) { const std::string aName1 = aName.substr(n1, n2 - n1); //name of face theList.push_back(aName1); @@ -495,7 +495,7 @@ bool Model_SelectionNaming::selectSubShape(const std::string& theType, } if(aSelection.IsNull()) { std::list aListofNames; - int n = ParseName(theSubShapeName, aListofNames); + size_t n = ParseName(theSubShapeName, aListofNames); if(n > 1 && n < 5) { TopTools_ListOfShape aList; std::list::iterator it =aListofNames.begin(); @@ -527,7 +527,7 @@ bool Model_SelectionNaming::selectSubShape(const std::string& theType, } if(aSelection.IsNull()) { std::list aListofNames; - int n = ParseName(theSubShapeName, aListofNames); + size_t n = ParseName(theSubShapeName, aListofNames); if(n > 1 && n < 4) { // 2 || 3 TopTools_ListOfShape aList; std::list::iterator it = aListofNames.begin(); diff --git a/src/Model/Model_Update.h b/src/Model/Model_Update.h index 50199c8c3..7eb4a8ef2 100644 --- a/src/Model/Model_Update.h +++ b/src/Model/Model_Update.h @@ -72,7 +72,6 @@ protected: const ModelAPI_ExecState theState); /// On operation start/end/abort the "Just" fileds must be cleared and processed in the right way - /// \param theFinish is true for start, close or abort transaction: all objects must be processed //! \param theFlushRedisplay a boolean value if the redisplay signal should be flushed void processFeatures(const bool theFlushRedisplay = true); diff --git a/src/ModelAPI/ModelAPI_AttributeSelectionList.h b/src/ModelAPI/ModelAPI_AttributeSelectionList.h index 9f0b0a69a..aa2e72915 100644 --- a/src/ModelAPI/ModelAPI_AttributeSelectionList.h +++ b/src/ModelAPI/ModelAPI_AttributeSelectionList.h @@ -45,6 +45,7 @@ class ModelAPI_AttributeSelectionList : public ModelAPI_Attribute /// Returns true if the object with the shape are in list /// \param theContext object where the sub-shape was selected /// \param theSubShape selected sub-shape (if null, the whole context is selected) + /// \param theTemporarily if it is true, it checks also the temporary added item /// \returns true if the pair is found in the attirbute virtual bool isInList( const ResultPtr& theContext, const std::shared_ptr& theSubShape, diff --git a/src/ModelAPI/ModelAPI_Events.h b/src/ModelAPI/ModelAPI_Events.h index aee15049d..1bbf8d2fb 100644 --- a/src/ModelAPI/ModelAPI_Events.h +++ b/src/ModelAPI/ModelAPI_Events.h @@ -311,11 +311,13 @@ class ModelAPI_ReplaceParameterMessage : public Events_Message MODELAPI_EXPORT void setObject(ObjectPtr theObject); }; - +/// Message that sends the sketch solver and sketcher GUI processes to show in the property panel class ModelAPI_SolverFailedMessage : public Events_Message { public: + /// Creates an message MODELAPI_EXPORT ModelAPI_SolverFailedMessage(const Events_ID theID, const void* theSender = 0); + /// Default destructor MODELAPI_EXPORT virtual ~ModelAPI_SolverFailedMessage(); /// Sets list of conflicting constraints diff --git a/src/ModelAPI/ModelAPI_Feature.h b/src/ModelAPI/ModelAPI_Feature.h index a9fc2f077..66eb18225 100644 --- a/src/ModelAPI/ModelAPI_Feature.h +++ b/src/ModelAPI/ModelAPI_Feature.h @@ -142,8 +142,8 @@ class ModelAPI_Feature : public ModelAPI_Object /// Returns the feature is stable or not. MODELAPI_EXPORT virtual bool isStable(); - /// Performs some functionality for the indes - /// \param theAttributeId an action key + /// Performs some custom feature specific functionality (normally called by some GUI button) + /// \param theActionId an action key /// \return a boolean value about it is performed MODELAPI_EXPORT virtual bool customAction(const std::string& theActionId); diff --git a/src/XGUI/XGUI_MenuMgr.cpp b/src/XGUI/XGUI_MenuMgr.cpp index 9ee7ed9e9..57acc07cb 100755 --- a/src/XGUI/XGUI_MenuMgr.cpp +++ b/src/XGUI/XGUI_MenuMgr.cpp @@ -171,7 +171,7 @@ void XGUI_MenuMgr::createFeatureActions() QAction* XGUI_MenuMgr::buildAction(const std::shared_ptr& theMessage, const std::string& theWchName, const bool aUseSeparator) const { - QAction* anAction; + QAction* anAction = 0; #ifdef HAVE_SALOME XGUI_SalomeConnector* aSalomeConnector = myWorkshop->salomeConnector(); -- 2.39.2