Commit 8aa361fc authored by Rémi Duraffort's avatar Rémi Duraffort

qt4_sout: use references for const QString.

parent 265371e9
...@@ -42,7 +42,7 @@ class QTextEdit; ...@@ -42,7 +42,7 @@ class QTextEdit;
class SoutMrl class SoutMrl
{ {
public: public:
SoutMrl( const QString head = "") SoutMrl( const QString& head = "")
{ {
mrl = head; mrl = head;
b_first = true; b_first = true;
...@@ -54,7 +54,7 @@ public: ...@@ -54,7 +54,7 @@ public:
return mrl; return mrl;
} }
void begin( QString module ) void begin( const QString& module )
{ {
if( !b_first ) if( !b_first )
mrl += ":"; mrl += ":";
...@@ -68,7 +68,7 @@ public: ...@@ -68,7 +68,7 @@ public:
if( b_has_bracket ) if( b_has_bracket )
mrl += "}"; mrl += "}";
} }
void option( const QString option, const QString value = "" ) void option( const QString& option, const QString& value = "" )
{ {
if( !b_has_bracket ) if( !b_has_bracket )
mrl += "{"; mrl += "{";
...@@ -88,16 +88,16 @@ public: ...@@ -88,16 +88,16 @@ public:
} }
} }
} }
void option( const QString name, const int i_value, const int i_precision = 10 ) void option( const QString& name, const int i_value, const int i_precision = 10 )
{ {
option( name, QString::number( i_value, i_precision ) ); option( name, QString::number( i_value, i_precision ) );
} }
void option( const QString name, const double f_value ) void option( const QString& name, const double f_value )
{ {
option( name, QString::number( f_value ) ); option( name, QString::number( f_value ) );
} }
void option( const QString name, const QString base, const int i_value, const int i_precision = 10 ) void option( const QString& name, const QString& base, const int i_value, const int i_precision = 10 )
{ {
option( name, base + ":" + QString::number( i_value, i_precision ) ); option( name, base + ":" + QString::number( i_value, i_precision ) );
} }
......
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