summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorChristian Glöckner <cgloeckner@freenet.de>2016-03-29 16:08:45 +0200
committerAndré Nusser <andre.nusser@googlemail.com>2016-03-31 17:44:25 +0200
commit4f4ac639f9bea3fcacf439213aabd0b70c678ecb (patch)
tree12c21f5aa51f5a6eb986eba39f6e86a9fdc1a715 /src
parent44695ff87966053ae090c2dd43ee6ab0a169775d (diff)
API Refactoring for class Instrument
Diffstat (limited to 'src')
-rw-r--r--src/instrument.cc2
-rw-r--r--src/instrument.h7
2 files changed, 3 insertions, 6 deletions
diff --git a/src/instrument.cc b/src/instrument.cc
index 9dec687..9f18233 100644
--- a/src/instrument.cc
+++ b/src/instrument.cc
@@ -153,7 +153,7 @@ std::string Instrument::getGroup() const
return _group;
}
-void Instrument::setGroup(std::string g)
+void Instrument::setGroup(const std::string& g)
{
_group = g;
}
diff --git a/src/instrument.h b/src/instrument.h
index 5dc656d..de5546b 100644
--- a/src/instrument.h
+++ b/src/instrument.h
@@ -24,8 +24,7 @@
* along with DrumGizmo; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
*/
-#ifndef __DRUMGIZMO_INSTRUMENT_H__
-#define __DRUMGIZMO_INSTRUMENT_H__
+#pragma once
#include <string>
#include <vector>
@@ -52,7 +51,7 @@ public:
std::string getDescription() const;
std::string getGroup() const;
- void setGroup(std::string group);
+ void setGroup(const std::string& group);
// std::map<std::string, std::string> channelmap;
@@ -85,5 +84,3 @@ private:
// typedef std::map< std::string, Instrument > Instruments;
typedef std::vector<Instrument*> Instruments;
-
-#endif /*__DRUMGIZMO_INSTRUMENT_H__*/