Commit 13c2af05 authored by Jan Möbius's avatar Jan Möbius
Browse files

Fixed cppcheck warning

parent cd565554
......@@ -395,7 +395,7 @@ class DataControlPlugin : public QObject, BaseInterface, ToolboxInterface, KeyIn
*
* @return object id of new group or -1 if failed
*/
int groupObjects(IdList _objectIDs, QString _groupName = "");
int groupObjects(IdList _objectIDs, const QString &_groupName = "");
/// add an object to an existing group
bool addObjectToGroup(int _objectId, int _groupId);
......
......@@ -359,7 +359,7 @@ int DataControlPlugin::addEmptyGroup(QString _groupName, int _parentGroupId) {
* @param _objectIDs list of object ids
* @param _groupName the name of the new group
*/
int DataControlPlugin::groupObjects(IdList _objectIDs, QString _groupName) {
int DataControlPlugin::groupObjects(IdList _objectIDs, const QString& _groupName) {
QVector< BaseObject* > objs;
// Try to get all objects given in list
......
......@@ -45,7 +45,7 @@ QMap<int,TreeItem*> TreeItem::kTreeMap_;
//--------------------------------------------------------------------------------
TreeItem::TreeItem(int _id, QString _name, DataType _type, TreeItem* _parent) :
TreeItem::TreeItem(int _id, const QString& _name, DataType _type, TreeItem* _parent) :
id_(_id),
dataType_(_type),
target_(true),
......@@ -166,7 +166,7 @@ QString TreeItem::name() {
//--------------------------------------------------------------------------------
void TreeItem::name(QString _name ) {
void TreeItem::name(const QString& _name ) {
name_ = _name;
}
......
......@@ -53,7 +53,7 @@ class TreeItem {
public :
TreeItem(int _id, QString _name, DataType _type, TreeItem* _parent);
TreeItem(int _id, const QString &_name, DataType _type, TreeItem* _parent);
~TreeItem();
......@@ -90,7 +90,7 @@ class TreeItem {
/// name
QString name( );
void name( QString _name );
void name(const QString &_name );
private:
bool target_;
......
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