author | zautrix <zautrix> | 2004-10-14 06:42:01 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2004-10-14 06:42:01 (UTC) |
commit | a6dff815a9c6d3a91094573d23c28a8553fc7cc2 (patch) (unidiff) | |
tree | a8830e9adcd72faa8178d4ee2517bfc31cda8653 /kaddressbook | |
parent | 909d25797c50fc38c435834a68aaf60bf87e32f9 (diff) | |
download | kdepimpi-a6dff815a9c6d3a91094573d23c28a8553fc7cc2.zip kdepimpi-a6dff815a9c6d3a91094573d23c28a8553fc7cc2.tar.gz kdepimpi-a6dff815a9c6d3a91094573d23c28a8553fc7cc2.tar.bz2 |
fixes umlaute in beaming
-rw-r--r-- | kaddressbook/kabcore.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/kaddressbook/kabcore.cpp b/kaddressbook/kabcore.cpp index 47ed858..dae9cd2 100644 --- a/kaddressbook/kabcore.cpp +++ b/kaddressbook/kabcore.cpp | |||
@@ -808,18 +808,19 @@ void KABCore::beamVCard(const QStringList& uids) | |||
808 | } | 808 | } |
809 | datastream += vcard.mid( start,vcard.length() ); | 809 | datastream += vcard.mid( start,vcard.length() ); |
810 | } | 810 | } |
811 | #ifndef DESKTOP_VERSION | 811 | #ifndef DESKTOP_VERSION |
812 | QFile outFile(fileName); | 812 | QFile outFile(fileName); |
813 | if ( outFile.open(IO_WriteOnly) ) { | 813 | if ( outFile.open(IO_WriteOnly) ) { |
814 | datastream.replace ( QRegExp("VERSION:3.0") , "VERSION:2.1" ); | 814 | datastream.replace ( QRegExp("VERSION:3.0") , "VERSION:2.1" ); |
815 | QTextStream t( &outFile ); // use a text stream | 815 | QTextStream t( &outFile ); // use a text stream |
816 | t.setEncoding( QTextStream::UnicodeUTF8 ); | 816 | //t.setEncoding( QTextStream::UnicodeUTF8 ); |
817 | t <<datastream; | 817 | t.setEncoding( QTextStream::Latin1 ); |
818 | t <<datastream.latin1(); | ||
818 | outFile.close(); | 819 | outFile.close(); |
819 | Ir *ir = new Ir( this ); | 820 | Ir *ir = new Ir( this ); |
820 | connect( ir, SIGNAL( done(Ir*) ), this, SLOT( beamDone(Ir*) ) ); | 821 | connect( ir, SIGNAL( done(Ir*) ), this, SLOT( beamDone(Ir*) ) ); |
821 | ir->send( fileName, description, "text/x-vCard" ); | 822 | ir->send( fileName, description, "text/x-vCard" ); |
822 | } else { | 823 | } else { |
823 | qDebug("Error open temp beam file "); | 824 | qDebug("Error open temp beam file "); |
824 | return; | 825 | return; |
825 | } | 826 | } |
@@ -827,16 +828,17 @@ void KABCore::beamVCard(const QStringList& uids) | |||
827 | 828 | ||
828 | } | 829 | } |
829 | 830 | ||
830 | void KABCore::beamDone( Ir *ir ) | 831 | void KABCore::beamDone( Ir *ir ) |
831 | { | 832 | { |
832 | #ifndef DESKTOP_VERSION | 833 | #ifndef DESKTOP_VERSION |
833 | delete ir; | 834 | delete ir; |
834 | #endif | 835 | #endif |
836 | topLevelWidget()->raise(); | ||
835 | } | 837 | } |
836 | 838 | ||
837 | 839 | ||
838 | void KABCore::browse( const QString& url ) | 840 | void KABCore::browse( const QString& url ) |
839 | { | 841 | { |
840 | #ifndef KAB_EMBEDDED | 842 | #ifndef KAB_EMBEDDED |
841 | kapp->invokeBrowser( url ); | 843 | kapp->invokeBrowser( url ); |
842 | #else //KAB_EMBEDDED | 844 | #else //KAB_EMBEDDED |