summaryrefslogtreecommitdiff
authorskyhusker <skyhusker>2005-01-26 22:22:55 (UTC)
committer skyhusker <skyhusker>2005-01-26 22:22:55 (UTC)
commit1752010f14bb7806bae6f83b349c9896a3005c75 (patch) (unidiff)
treea43902f058fef91ed136622bb4f9964f1aa5441f
parentd3ca4c7807c7a22837e481c1016c9814a68e00fb (diff)
downloadopie-1752010f14bb7806bae6f83b349c9896a3005c75.zip
opie-1752010f14bb7806bae6f83b349c9896a3005c75.tar.gz
opie-1752010f14bb7806bae6f83b349c9896a3005c75.tar.bz2
Changed argument passing from value to const reference
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/net/opieirc/ircperson.cpp10
-rw-r--r--noncore/net/opieirc/ircperson.h10
2 files changed, 10 insertions, 10 deletions
diff --git a/noncore/net/opieirc/ircperson.cpp b/noncore/net/opieirc/ircperson.cpp
index 1dd2679..f673dee 100644
--- a/noncore/net/opieirc/ircperson.cpp
+++ b/noncore/net/opieirc/ircperson.cpp
@@ -13,10 +13,10 @@ IRCPerson::IRCPerson(const IRCPerson &person) {
13} 13}
14 14
15IRCPerson::IRCPerson(QString mask) { 15IRCPerson::IRCPerson(const QString &mask) {
16 IRCPerson(); 16 IRCPerson();
17 fromMask(mask); 17 fromMask(mask);
18} 18}
19 19
20void IRCPerson::fromMask(QString mask) { 20void IRCPerson::fromMask(const QString &mask) {
21 int sep1 = mask.find("!"); 21 int sep1 = mask.find("!");
22 int sep2 = mask.find("@"); 22 int sep2 = mask.find("@");
@@ -31,13 +31,13 @@ QString IRCPerson::toMask() {
31} 31}
32 32
33void IRCPerson::setNick(QString nick) { 33void IRCPerson::setNick(const QString &nick) {
34 m_nick = nick; 34 m_nick = nick;
35} 35}
36 36
37void IRCPerson::setUser(QString user) { 37void IRCPerson::setUser(const QString &user) {
38 m_user = user; 38 m_user = user;
39} 39}
40 40
41void IRCPerson::setHost(QString host) { 41void IRCPerson::setHost(const QString &host) {
42 m_host = host; 42 m_host = host;
43} 43}
diff --git a/noncore/net/opieirc/ircperson.h b/noncore/net/opieirc/ircperson.h
index 38732c4..9854f95 100644
--- a/noncore/net/opieirc/ircperson.h
+++ b/noncore/net/opieirc/ircperson.h
@@ -33,12 +33,12 @@ public:
33 IRCPerson(); 33 IRCPerson();
34 /* Create an IRCPerson from an IRC style description (nick!user@host) */ 34 /* Create an IRCPerson from an IRC style description (nick!user@host) */
35 IRCPerson(QString mask); 35 IRCPerson(const QString &mask);
36 /* Copy constructor */ 36 /* Copy constructor */
37 IRCPerson(const IRCPerson &person); 37 IRCPerson(const IRCPerson &person);
38 38
39 void fromMask(QString mask); 39 void fromMask(const QString &mask);
40 void setNick(QString name); 40 void setNick(const QString &name);
41 void setUser(QString user); 41 void setUser(const QString &user);
42 void setHost(QString host); 42 void setHost(const QString &host);
43 QString toMask(); 43 QString toMask();
44 QString nick(); 44 QString nick();