Commit 6c5a249f authored by Martin Schultz's avatar Martin Schultz

fixed more cppCheck warnings in merge plugin

added more documentation to merge plugin
parent a4c79bc6
......@@ -112,6 +112,14 @@ DataType MergePlugin::checkType(const std::vector< BaseObjectData* > & objects )
}
MergePlugin::MergePlugin() :
tool_(nullptr),
polyMergeID(0),
triMergeID(0)
{
}
/// init the Toolbox
void MergePlugin::initializePlugin() {
tool_ = new MergeToolBox();
......@@ -126,9 +134,6 @@ void MergePlugin::initializePlugin() {
connect(this,SIGNAL(cleanup(DataType, bool)),this,SLOT(slotCleanup(DataType, bool)),Qt::QueuedConnection);
emit addToolbox( tr("Merge") , tool_ );
polyMergeID = -1;
triMergeID = -1;
}
void MergePlugin::pluginsInitialized()
......
......@@ -40,7 +40,7 @@ Q_INTERFACES(ScriptInterface)
signals:
//BaseInterface
void updateView();
void updatedObject(int _identifier, const UpdateType _type);
void updatedObject(int _identifier, const UpdateType& _type);
//LoggingInterface:
void log( Logtype _type, QString _message );
......@@ -61,7 +61,7 @@ signals:
public :
MergePlugin() {};
MergePlugin();
~MergePlugin() {};
QString name() { return (QString("Merge")); };
......@@ -81,7 +81,21 @@ public slots:
void pluginsInitialized();
void mergeObjects();
/**
* @brief mergeObjects merges multiple OpenFlipper Objects of Type TriMesh or PolyMesh into one combined Mesh.
* @param _objects a vector of OpenFlipper Objects that shall be merged.
* @param _name The name of the merged object (default is "merged object")
* @param _deleteSeparateObjects flag to determine if the separate objects shall be deleted after merging (default is true)
* @return
*/
int mergeObjects(const std::vector< BaseObjectData* > & _objects, QString _name = "merged object", bool _deleteSeparateObjects = true);
/**
* @brief slotCleanup is called when the cleanup event is processed at the end of mergeObjects.
* @param _type the datatype that was used for merging
* @param _deleteSeparateObjects flag to determine if separated objects shall be deleted.
*/
void slotCleanup(DataType _type, bool _deleteSeparateObjects);
//template functions
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment