]> granicus.if.org Git - taglib/commitdiff
Add a wide string export fuction.
authorScott Wheeler <wheeler@kde.org>
Sat, 11 Feb 2006 21:18:03 +0000 (21:18 +0000)
committerScott Wheeler <wheeler@kde.org>
Sat, 11 Feb 2006 21:18:03 +0000 (21:18 +0000)
git-svn-id: svn://anonsvn.kde.org/home/kde/trunk/kdesupport/taglib@508477 283d02a7-25f6-0310-bc7c-ecb5cbfe19da

toolkit/tstring.cpp
toolkit/tstring.h

index 1707a9474db924a238735840a88b4e8930df6ad4..5d0cf41acf4b80b0fa59fc0d69922eebca3447ac 100644 (file)
@@ -241,6 +241,11 @@ std::string String::to8Bit(bool unicode) const
   return s;
 }
 
+TagLib::wstring String::to32Bit() const
+{
+  return d->data;
+}
+
 const char *String::toCString(bool unicode) const
 {
   delete [] d->CString;
index 37edfec2c042ebfb6426acd2a5da702a7c18d9c6..66e71e9124f047908bef19b1438108ea90cc45ec 100644 (file)
@@ -169,6 +169,11 @@ namespace TagLib {
      */
     std::string to8Bit(bool unicode = false) const;
 
+    /*!
+     * Returns a wstring version of the TagLib string as a wide string.
+     */
+    wstring to32Bit() const;
+
     /*!
      * Creates and returns a C-String based on the data.  This string is still
      * owned by the String (class) and as such should not be deleted by the user.