summaryrefslogtreecommitdiffabout
path: root/kabc/vcardparser/vcardline.cpp
Unidiff
Diffstat (limited to 'kabc/vcardparser/vcardline.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--kabc/vcardparser/vcardline.cpp14
1 files changed, 9 insertions, 5 deletions
diff --git a/kabc/vcardparser/vcardline.cpp b/kabc/vcardparser/vcardline.cpp
index 0972a35..8df2d32 100644
--- a/kabc/vcardparser/vcardline.cpp
+++ b/kabc/vcardparser/vcardline.cpp
@@ -82,19 +82,23 @@ QString VCardLine::identifier() const
82 return mIdentifier; 82 return mIdentifier;
83} 83}
84 84
85void VCardLine::setValue( const QString& value ) 85void VCardLine::setValueString( const QString& value )
86{ 86{
87 mValue.duplicate( value.data(), value.length() ); 87 setValueCString( value.utf8() );
88}
89void VCardLine::setValueCString( const QCString& value )
90{
91 mValue.duplicate( value.data(), value.length() );
88} 92}
89 93
90void VCardLine::setValue( const QByteArray& value ) 94void VCardLine::setValueBytes( const QByteArray& value )
91{ 95{
92 mValue = value; 96 mValue = value;
93} 97}
94 98
95QVariant VCardLine::value() const 99QString VCardLine::valueString() const
96{ 100{
97 return QVariant( QCString( mValue.data(), mValue.size()+1 ) ); 101 return QString::fromUtf8( mValue.data(), mValue.size() );
98} 102}
99 103
100QByteArray VCardLine::valueBytes() const 104QByteArray VCardLine::valueBytes() const