summaryrefslogtreecommitdiffabout
path: root/kaddressbook/kabcore.cpp
Side-by-side diff
Diffstat (limited to 'kaddressbook/kabcore.cpp') (more/less context) (show whitespace changes)
-rw-r--r--kaddressbook/kabcore.cpp55
1 files changed, 8 insertions, 47 deletions
diff --git a/kaddressbook/kabcore.cpp b/kaddressbook/kabcore.cpp
index 2e408b7..11eeabc 100644
--- a/kaddressbook/kabcore.cpp
+++ b/kaddressbook/kabcore.cpp
@@ -710,3 +710,3 @@ QString KABCore::getPhoneFile()
{
-#ifdef _WIN32_
+#ifdef DESKTOP_VERSION
return locateLocal("tmp", "phonefile.vcf");
@@ -734,50 +734,11 @@ void KABCore::beamVCard(const QStringList& uids)
{
-/*US
- QString beamFilename;
- Opie::OPimContact c;
- if ( actionPersonal->isOn() ) {
- beamFilename = addressbookPersonalVCardName();
- if ( !QFile::exists( beamFilename ) )
- return; // can't beam a non-existent file
- Opie::OPimContactAccessBackend* vcard_backend = new Opie::OPimContactAccessBackend_VCard( QString::null,
- beamFilename );
- Opie::OPimContactAccess* access = new Opie::OPimContactAccess ( "addressbook", QString::null , vcard_backend, true );
- Opie::OPimContactAccess::List allList = access->allRecords();
- Opie::OPimContactAccess::List::Iterator it = allList.begin(); // Just take first
- c = *it;
-
- delete access;
- } else {
- unlink( beamfile ); // delete if exists
- mkdir("/tmp/obex/", 0755);
- c = m_abView -> currentEntry();
- Opie::OPimContactAccessBackend* vcard_backend = new Opie::OPimContactAccessBackend_VCard( QString::null,
- beamfile );
- Opie::OPimContactAccess* access = new Opie::OPimContactAccess ( "addressbook", QString::null , vcard_backend, true );
- access->add( c );
- access->save();
- delete access;
-
- beamFilename = beamfile;
- }
-
- owarn << "Beaming: " << beamFilename << oendl;
-*/
-
-#if 0
- QString tmpdir = locateLocal("tmp", KGlobal::getAppName());
-
- QString dirName = tmpdir + "/" + KApplication::randomString( 8 );
- QString name = "contact.vcf";
+ // LR: we should use the /tmp dir on the Zaurus,
+ // because: /tmp = RAM, (HOME)/kdepim = flash memory
- QString fileName = dirName + "/" + name;
-#endif
- // LR: we should use the /tmp dir, because: /tmp = RAM, (HOME)/kdepim = flash memory
- //
+#ifdef DESKTOP_VERSION
+ QString fileName = locateLocal("tmp", "kapibeamfile.vcf");
+#else
QString fileName = "/tmp/kapibeamfile.vcf";
-
-
- //QDir().mkdir( dirName, true );
-
+#endif
@@ -2864,3 +2825,3 @@ QString KABCore::sentSyncFile()
{
-#ifdef _WIN32_
+#ifdef DESKTOP_VERSION
return locateLocal( "tmp", "copysyncab.vcf" );