# HG changeset patch # User John Kern # Date 1281664104 25200 # Node ID afa910b5ae8193ce2ac4dbb24f51922ba20de152 # Parent d9f0df25b6a30e8c4ca821a7faaa29a6ed20ddd5 ok I did say to use QDesktopServices but treating contacts.csv is simpler diff -r d9f0df25b6a3 -r afa910b5ae81 contactengine/contactengine.pro --- a/contactengine/contactengine.pro Thu Aug 12 17:06:22 2010 -0700 +++ b/contactengine/contactengine.pro Thu Aug 12 18:48:24 2010 -0700 @@ -1,44 +1,47 @@ -#------------------------------------------------- -# -# Project created by QtCreator 2010-08-03T16:15:24 -# -#------------------------------------------------- - -QT += core gui sql - -TARGET = contactengine -TEMPLATE = app - -CONFIG += debug - -SOURCES += main.cpp\ - mainwindow.cpp \ - contactsengine.cpp \ - dbtools.cpp - -HEADERS += mainwindow.h \ - contactsengine.h \ - database.h \ - dbtools.h \ - database.h - - -FORMS += mainwindow.ui - -CONFIG += mobility -MOBILITY = contacts - -unix:INCLUDEPATH += /home/johnk/libs/include/QtContacts /home/johnk/libs/include/ -unix:LIBS += -L/home/johnk/libs/lib -lQtContacts - -databasefiles.sources = contacts.csv -databasefiles.path = . - -DEPLOYMENT += databasefiles - -symbian { - TARGET.UID3 = 0xec200759 - TARGET.CAPABILITY += ReadUserData WriteUserData - TARGET.EPOCSTACKSIZE = 0x14000 - TARGET.EPOCHEAPSIZE = 0x020000 0x800000 -} +#------------------------------------------------- +# +# Project created by QtCreator 2010-08-03T16:15:24 +# +#------------------------------------------------- + +QT += core gui + +TARGET = contactengine +TEMPLATE = app + +CONFIG += debug + +SOURCES += main.cpp\ + mainwindow.cpp \ + contactsengine.cpp \ + dbtools.cpp + +HEADERS += mainwindow.h \ + contactsengine.h \ + database.h \ + dbtools.h \ + database.h + + +FORMS += mainwindow.ui + +CONFIG += mobility +MOBILITY = contacts + +unix:INCLUDEPATH += /home/johnk/libs/include/QtContacts /home/johnk/libs/include/ +unix:LIBS += -L/home/johnk/libs/lib -lQtContacts + +databasefiles.sources = contacts.csv +databasefiles.path = . + +DEPLOYMENT += databasefiles + +symbian { + TARGET.UID3 = 0xec200759 + TARGET.CAPABILITY += ReadUserData WriteUserData + TARGET.EPOCSTACKSIZE = 0x14000 + TARGET.EPOCHEAPSIZE = 0x020000 0x800000 +} + +RESOURCES += \ + resouce.qrc diff -r d9f0df25b6a3 -r afa910b5ae81 contactengine/main.cpp --- a/contactengine/main.cpp Thu Aug 12 17:06:22 2010 -0700 +++ b/contactengine/main.cpp Thu Aug 12 18:48:24 2010 -0700 @@ -11,16 +11,8 @@ MainWindow w; DBTools dbt; - QString dbLocation; + QString dbLocation(":/contacts.csv"); -#ifdef Q_OS_SYMBIAN - dbLocation = QDesktopServices::storageLocation(QDesktopServices::DataLocation); - dbLocation.append(QDir::separator()); - dbLocation.append("contacts.csv"); - -#else - dbLocation = "C:\\workspace\\QtExamples\\contactengine\\contacts.csv"; -#endif qDebug() << "dbLocation=" << dbLocation << endl; dbt.importCSV(dbLocation); diff -r d9f0df25b6a3 -r afa910b5ae81 contactengine/resouce.qrc --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/contactengine/resouce.qrc Thu Aug 12 18:48:24 2010 -0700 @@ -0,0 +1,5 @@ + + + contacts.csv + +