author | zautrix <zautrix> | 2005-01-25 15:12:21 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2005-01-25 15:12:21 (UTC) |
commit | fe4e6e85abc2ec90cc80108fc7434899b6e13048 (patch) (side-by-side diff) | |
tree | 9a3cf83ecf8796d0020076e4e8e275d193fb2584 | |
parent | 165d969ce6ac38c5e3d7b5c629af0b00d0fff017 (diff) | |
download | kdepimpi-fe4e6e85abc2ec90cc80108fc7434899b6e13048.zip kdepimpi-fe4e6e85abc2ec90cc80108fc7434899b6e13048.tar.gz kdepimpi-fe4e6e85abc2ec90cc80108fc7434899b6e13048.tar.bz2 |
small fixes
-rw-r--r-- | kaddressbook/kabcore.cpp | 9 | ||||
-rw-r--r-- | kaddressbook/kaddressbook.pro | 31 | ||||
-rw-r--r-- | kaddressbook/mainembedded.cpp | 28 | ||||
-rw-r--r-- | kdepim-desktop.pro | 2 | ||||
-rw-r--r-- | korganizer/koprefsdialog.cpp | 2 | ||||
-rw-r--r-- | korganizer/korganizer.pro | 32 | ||||
-rw-r--r-- | korganizer/main.cpp | 27 | ||||
-rw-r--r-- | korganizer/mainwindow.cpp | 6 |
8 files changed, 68 insertions, 69 deletions
diff --git a/kaddressbook/kabcore.cpp b/kaddressbook/kabcore.cpp index 505cbf4..590cc82 100644 --- a/kaddressbook/kabcore.cpp +++ b/kaddressbook/kabcore.cpp @@ -134,50 +134,51 @@ $Id$ #include <qtextstream.h> #include <qradiobutton.h> #include <qbuttongroup.h> #include <libkdepim/categoryselectdialog.h> #include <libkdepim/categoryeditdialog.h> #include <kabc/vcardconverter.h> #include "addresseeutil.h" #include "undocmds.h" #include "addresseeeditordialog.h" #include "viewmanager.h" #include "details/detailsviewcontainer.h" #include "kabprefs.h" #include "xxportmanager.h" #include "incsearchwidget.h" #include "jumpbuttonbar.h" #include "extensionmanager.h" #include "addresseeconfig.h" #include "nameeditdialog.h" #include <kcmultidialog.h> #ifdef _WIN32_ - +#ifdef _OL_IMPORT_ #include "kaimportoldialog.h" +#endif #else #include <unistd.h> #endif // sync includes #include <libkdepim/ksyncprofile.h> #include <libkdepim/ksyncprefsdialog.h> class KABCatPrefs : public QDialog { public: KABCatPrefs( QWidget *parent=0, const char *name=0 ) : QDialog( parent, name, true ) { setCaption( i18n("Manage new Categories") ); QVBoxLayout* lay = new QVBoxLayout( this ); lay->setSpacing( 3 ); lay->setMargin( 3 ); QLabel * lab = new QLabel( i18n("After importing/loading/syncing\nthere may be new categories in\naddressees\nwhich are not in the category list.\nPlease choose what to do:\n "), this ); lay->addWidget( lab ); QButtonGroup* format = new QButtonGroup( 1, Horizontal, i18n("New categories not in list:"), this ); lay->addWidget( format ); format->setExclusive ( true ) ; addCatBut = new QRadioButton(i18n("Add to category list"), format ); @@ -1270,49 +1271,49 @@ void KABCore::addEmail( QString aStr ) editContact( (*it).uid() ); } } if ( !found ) { KABC::Addressee addr; addr.setNameFromString( fullName ); addr.insertEmail( email, true ); mAddressBook->insertAddressee( addr ); mViewManager->refreshView( addr.uid() ); editContact( addr.uid() ); } #else //KAB_EMBEDDED qDebug("KABCore::addEmail finsih method"); #endif //KAB_EMBEDDED } void KABCore::importVCard( const KURL &url, bool showPreview ) { mXXPortManager->importVCard( url, showPreview ); } void KABCore::importFromOL() { -#ifdef _WIN32_ +#ifdef _OL_IMPORT_ KAImportOLdialog* idgl = new KAImportOLdialog( i18n("Import Contacts from OL"), mAddressBook, this ); idgl->exec(); KABC::Addressee::List list = idgl->getAddressList(); if ( list.count() > 0 ) { KABC::Addressee::List listNew; KABC::Addressee::List listExisting; KABC::Addressee::List::Iterator it; KABC::AddressBook::Iterator iter; for ( it = list.begin(); it != list.end(); ++it ) { if ( mAddressBook->findByUid((*it).uid() ).isEmpty()) listNew.append( (*it) ); else listExisting.append( (*it) ); } if ( listExisting.count() > 0 ) KMessageBox::information( this, i18n("%1 contacts not added to addressbook\nbecause they were already in the addressbook!").arg( listExisting.count() )); if ( listNew.count() > 0 ) { pasteWithNewUid = false; pasteContacts( listNew ); pasteWithNewUid = true; } } delete idgl; #endif @@ -2157,93 +2158,93 @@ void KABCore::addActionsManually() // if ((KGlobal::getDesktopSize() > KGlobal::Small ) || // (!KABPrefs::instance()->mMultipleViewsAtOnce )) mActionEditAddressee->plug( tb ); fileMenu->insertSeparator(); mActionSave->plug( fileMenu ); fileMenu->insertItem( "&Import", ImportMenu ); fileMenu->insertItem( "&Export", ExportMenu ); fileMenu->insertItem( i18n("&Change"), changeMenu ); #ifndef DESKTOP_VERSION if ( Ir::supported() ) fileMenu->insertItem( i18n("&Beam"), beamMenu ); #endif #if 0 // PENDING fix MailVCard fileMenu->insertSeparator(); mActionMailVCard->plug( fileMenu ); #endif #ifndef DESKTOP_VERSION if ( Ir::supported() ) mActionBR->plug( beamMenu ); if ( Ir::supported() ) mActionBeamVCard->plug( beamMenu ); if ( Ir::supported() ) mActionBeam->plug( beamMenu ); #endif fileMenu->insertSeparator(); mActionQuit->plug( fileMenu ); -#ifdef _WIN32_ +#ifdef _OL_IMPORT_ mActionImportOL->plug( ImportMenu ); #endif // edit menu mActionUndo->plug( editMenu ); mActionRedo->plug( editMenu ); editMenu->insertSeparator(); mActionCut->plug( editMenu ); mActionCopy->plug( editMenu ); mActionPaste->plug( editMenu ); mActionDelete->plug( editMenu ); editMenu->insertSeparator(); mActionSelectAll->plug( editMenu ); mActionSetFormattedName->plug( changeMenu ); mActionRemoveVoice->plug( changeMenu ); // settings menu //US special menuentry to configure the addressbook resources. On KDE // you do that through the control center !!! mActionConfigResources->plug( settingsMenu ); settingsMenu->insertSeparator(); mActionConfigKAddressbook->plug( settingsMenu ); if ( mIsPart ) { //US not implemented yet //mActionConfigShortcuts->plug( settingsMenu ); //mActionConfigureToolbars->plug( settingsMenu ); } else { //US not implemented yet //mActionKeyBindings->plug( settingsMenu ); } settingsMenu->insertSeparator(); mActionJumpBar->plug( settingsMenu ); mActionDetails->plug( settingsMenu ); //if (!KABPrefs::instance()->mMultipleViewsAtOnce || KGlobal::getDesktopSize() == KGlobal::Desktop ) mActionDetails->plug( tb ); settingsMenu->insertSeparator(); #ifndef DESKTOP_VERSION if ( Ir::supported() ) mActionBR->plug(settingsMenu ); -#endif settingsMenu->insertSeparator(); +#endif mActionWhoAmI->plug( settingsMenu ); mActionEditCategories->plug( settingsMenu ); mActionEditCategories->plug( changeMenu ); mActionCategories->plug( changeMenu ); mActionManageCategories->plug( changeMenu ); mActionCategories->plug( settingsMenu ); mActionManageCategories->plug( settingsMenu ); mActionWN->plug( helpMenu ); mActionSyncHowto->plug( helpMenu ); mActionKdeSyncHowto->plug( helpMenu ); mActionMultiSyncHowto->plug( helpMenu ); mActionFaq->plug( helpMenu ); mActionLicence->plug( helpMenu ); mActionAboutKAddressbook->plug( helpMenu ); if (KGlobal::getDesktopSize() > KGlobal::Small ) { mActionSave->plug( tb ); mViewManager->getFilterAction()->plug ( tb); //LR hide filteraction on started in 480x640 diff --git a/kaddressbook/kaddressbook.pro b/kaddressbook/kaddressbook.pro index fbbc026..e73de06 100644 --- a/kaddressbook/kaddressbook.pro +++ b/kaddressbook/kaddressbook.pro @@ -7,63 +7,66 @@ include( ../variables.pri ) INCLUDEPATH += . ./details ./features ./xxport ../libkdepim ../microkde ../microkde/kdecore ../microkde/kutils ../microkde/kio/kfile ../microkde/kio/kio ../microkde/kdeui ../microkde/kresources ../kabc ../ interfaces DEFINES += KAB_EMBEDDED KAB_NOSPLITTER DESKTOP_VERSION unix : { LIBS += ../bin/libmicrokdepim.so LIBS += ../bin/libmicrokde.so LIBS += ../bin/libmicrokabc.so LIBS += ../bin/libmicrokcal.so #LIBS += -lldap OBJECTS_DIR = obj/unix MOC_DIR = moc/unix } win32: { RC_FILE = winicons.rc DEFINES += _WIN32_ LIBS += ../bin/microkdepim.lib LIBS += ../bin/microkcal.lib LIBS += ../bin/microkde.lib LIBS += ../bin/microkabc.lib QMAKE_LINK += /NODEFAULTLIB:LIBC OBJECTS_DIR = obj/win MOC_DIR = moc/win +#olimport section +#blabla: { + LIBS += mfc71u.lib +DEFINES += _OL_IMPORT_ +HEADERS = ../outport/msoutl9.h \ + kaimportoldialog.h +SOURCES = ../outport/msoutl9.cpp \ + kaimportoldialog.cpp +#} +#olimport section end } - - - - - - - INTERFACES = \ # filteredit_base.ui \ # kofilterview_base.ui \ -HEADERS = \ +HEADERS += \ features/mergewidget.h \ features/distributionlistwidget.h \ kcmconfigs/addresseewidget.h \ kcmconfigs/extensionconfigdialog.h \ kcmconfigs/kcmkabconfig.h \ kcmconfigs/kabconfigwidget.h \ addresseeeditordialog.h \ addresseeeditorwidget.h \ addresseditwidget.h \ addresseeconfig.h \ addresseeutil.h \ emaileditwidget.h \ filtereditdialog.h \ kaddressbookmain.h \ kabprefs.h \ kabcore.h \ viewmanager.h \ extensionmanager.h \ extensionwidget.h \ kaddressbookview.h \ geowidget.h \ imagewidget.h \ incsearchwidget.h \ jumpbuttonbar.h \ @@ -87,49 +90,49 @@ details/detailsviewcontainer.h \ details/look_basic.h \ details/look_html.h \ views/kaddressbookiconview.h \ views/kaddressbooktableview.h \ views/kaddressbookcardview.h \ views/configuretableviewdialog.h \ views/configurecardviewdialog.h \ views/cardview.h \ views/colorlistbox.h \ views/contactlistview.h \ xxport/vcard_xxport.h \ xxport/kde2_xxport.h \ xxport/csv_xxport.h \ xxport/csvimportdialog.h \ xxport/opie_xxport.h \ xxport/qtopia_xxport.h \ xxport/sharpdtm_xxport.h \ #details/look_details.h \ #mainwindoiw.h \ # alarmclient.h \ # calendarview.h \ # customlistviewitem.h \ # datenavigator.h -SOURCES = \ +SOURCES += \ addresseeeditordialog.cpp \ addresseeeditorwidget.cpp \ addresseditwidget.cpp \ addresseeconfig.cpp \ addresseeutil.cpp \ extensionmanager.cpp \ features/mergewidget.cpp \ features/distributionlistwidget.cpp \ kcmconfigs/addresseewidget.cpp \ kcmconfigs/extensionconfigdialog.cpp \ kcmconfigs/kcmkabconfig.cpp \ kcmconfigs/kabconfigwidget.cpp \ emaileditwidget.cpp \ filtereditdialog.cpp \ mainembedded.cpp \ kaddressbookmain.cpp \ kabcore.cpp \ kabprefs.cpp \ viewmanager.cpp \ kaddressbookview.cpp \ extensionwidget.cpp \ geowidget.cpp \ imagewidget.cpp \ incsearchwidget.cpp \ @@ -151,34 +154,24 @@ xxportobject.cpp \ xxportselectdialog.cpp \ details/detailsviewcontainer.cpp \ details/look_basic.cpp \ details/look_html.cpp \ views/kaddressbookiconview.cpp \ views/kaddressbooktableview.cpp \ views/kaddressbookcardview.cpp \ views/configuretableviewdialog.cpp \ views/configurecardviewdialog.cpp \ views/cardview.cpp \ views/contactlistview.cpp \ views/colorlistbox.cpp \ xxport/vcard_xxport.cpp \ xxport/kde2_xxport.cpp \ xxport/csv_xxport.cpp \ xxport/csvimportdialog.cpp \ xxport/opie_xxport.cpp \ xxport/qtopia_xxport.cpp \ xxport/sharpdtm_xxport.cpp \ #details/look_details.cpp \ #mainwindow.cpp \ # calendarview.cpp \ # timespanview.cpp - - -win32: { -HEADERS += ../outport/msoutl9.h \ - kaimportoldialog.h - -SOURCES += ../outport/msoutl9.cpp \ - kaimportoldialog.cpp -} - diff --git a/kaddressbook/mainembedded.cpp b/kaddressbook/mainembedded.cpp index 1e03dba..d9968f3 100644 --- a/kaddressbook/mainembedded.cpp +++ b/kaddressbook/mainembedded.cpp @@ -1,70 +1,72 @@ #ifndef DESKTOP_VERSION #include <qpe/qpeapplication.h> #include <qcopchannel_qws.h> #include <stdlib.h> #else #include <qapplication.h> #include <qwindowsstyle.h> #include <qplatinumstyle.h> #include <qmainwindow.h> +#include <qmessagebox.h> +#include <stdlib.h> #endif #include <qtextcodec.h> #include <kstandarddirs.h> #include <qregexp.h> #include <kglobal.h> #include <stdio.h> #include <qdir.h> #include "kabprefs.h" #include "kaddressbookmain.h" #include "externalapphandler.h" #include <libkdepim/kpimglobalprefs.h> void dumpMissing(); int main( int argc, char **argv ) { #ifndef DESKTOP_VERSION QPEApplication a( argc, argv ); a.setKeepRunning (); #else QApplication a( argc, argv ); QApplication::setStyle( new QPlatinumStyle ()); - QString hdir = QDir::homeDirPath(); - // there is a bug when creating dirs for WIN 98 - // it is difficult to fix, because we have no WIN 98 runnung - // such that we try it to create the dirs at startup here - if ( hdir == "C:\\" ) { // win 98 or ME +#ifdef _WIN32_ + QString hdir ( getenv( "HOME") ); + if ( hdir.isEmpty() ) { + QString hd ("C:/" ); + //QMessageBox::information(0,"hh",QDir::homeDirPath()+" xx" +hd ); + if ( QDir::homeDirPath().lower() == hd.lower() ) { + _putenv( "HOME=C:"); + //QMessageBox::information(0,"hh",QString ( getenv( "HOME") ) ); + } + } else { QDir app_dir; - if ( !app_dir.exists("C:\\kdepim") ) - app_dir.mkdir ("C:\\kdepim"); - if ( !app_dir.exists("C:\\kdepim\\apps") ) - app_dir.mkdir ("C:\\kdepim\\apps"); - if ( !app_dir.exists("C:\\kdepim\\config") ) - app_dir.mkdir ("C:\\kdepim\\config"); - if ( !app_dir.exists("C:\\kdepim\\apps\\kaddressbook") ) - app_dir.mkdir ("C:\\kdepim\\apps\\kaddressbook"); + if ( !app_dir.exists(hdir) ) + app_dir.mkdir (hdir); } #endif +#endif bool exitHelp = false; if ( argc > 1 ) { QString command = argv[1]; if ( command == "-help" ){ printf("KA/E command line commands:\n"); printf(" no command: Start KA/E in usual way\n"); printf(" -help: This output\n"); printf(" KA/E is exiting now. Bye!\n"); exitHelp = true; } } if ( ! exitHelp ) { KGlobal::setAppName( "kaddressbook" ); #ifndef DESKTOP_VERSION if ( QApplication::desktop()->width() > 320 ) KGlobal::iconLoader()->setIconPath(QString(getenv("QPEDIR"))+"/pics/kdepim/kaddressbook/icons22/"); else KGlobal::iconLoader()->setIconPath(QString(getenv("QPEDIR"))+"/pics/kdepim/kaddressbook/icons16/"); #else QString fileName ; fileName = qApp->applicationDirPath () + "/kdepim/kaddressbook/icons22/"; KGlobal::iconLoader()->setIconPath(QDir::convertSeparators(fileName)); diff --git a/kdepim-desktop.pro b/kdepim-desktop.pro index b0d60b7..da3a966 100644 --- a/kdepim-desktop.pro +++ b/kdepim-desktop.pro @@ -1,8 +1,8 @@ TEMPLATE = subdirs -SUBDIRS = libical libkcal kabc libkdepim microkde korganizer kaddressbook kabc/plugins/file kabc/plugins/dir kabc/plugins/file kabc/plugins/qtopia gammu/emb/common gammu/emb/gammu +SUBDIRS = libical libkcal kabc libkdepim microkde korganizer kaddressbook kabc/plugins/file kabc/plugins/dir kabc/plugins/qtopia gammu/emb/common gammu/emb/gammu unix:{ SUBDIRS += kmicromail/libetpan kmicromail/libmailwrapper kmicromail pwmanager/libcrypt/cipher pwmanager/libcrypt/error pwmanager/libcrypt/mpi pwmanager/libcrypt/zlib pwmanager/pwmanager } diff --git a/korganizer/koprefsdialog.cpp b/korganizer/koprefsdialog.cpp index 8aa24ee..ea73fd0 100644 --- a/korganizer/koprefsdialog.cpp +++ b/korganizer/koprefsdialog.cpp @@ -73,50 +73,52 @@ KOPrefsDialog::KOPrefsDialog(QWidget *parent, char *name, bool modal) : KPrefsDialog(KOPrefs::instance(),parent,name,true) { setCaption( i18n("Preferences - some settings need a restart (nr)")); mCategoryDict.setAutoDelete(true); KGlobal::locale()->insertCatalogue("timezones"); setupGlobalTab(); setupMainTab(); // setupLocaleTab(); //setupTimeZoneTab(); setupTimeTab(); //setupLocaleDateTab(); setupFontsTab(); setupColorsTab(); setupViewsTab(); //setupSyncTab(); //setupSyncAlgTab(); //setupPrinterTab(); //setupGroupSchedulingTab(); //setupGroupAutomationTab(); +#ifndef DESKTOP_VERSION if ( QApplication::desktop()->height() == 480 ) hideButtons(); +#endif } KOPrefsDialog::~KOPrefsDialog() { } void KOPrefsDialog::setupGlobalTab() { QFrame *topFrame = addPage(i18n("Global"),0,0); kdelibcfg = new KDEPIMConfigWidget( KPimGlobalPrefs::instance(), topFrame, "KCMKdeLibConfig" ); QVBoxLayout *topLayout = new QVBoxLayout(topFrame); topLayout->addWidget( kdelibcfg ); } void KOPrefsDialog::setupLocaleDateTab() { #if 0 QFrame *topFrame = addPage(i18n("Date Format"),0,0); QGridLayout *topLayout = new QGridLayout(topFrame,3,2); topLayout->setSpacing(spacingHint()); topLayout->setMargin(marginHint()); int iii = 0; diff --git a/korganizer/korganizer.pro b/korganizer/korganizer.pro index c2602b2..4d67dca 100644 --- a/korganizer/korganizer.pro +++ b/korganizer/korganizer.pro @@ -1,77 +1,88 @@ TEMPLATE = app -CONFIG = qt warn_on +CONFIG += qt warn_off TARGET = kopi OBJECTS_DIR = _obj/ MOC_DIR = _moc DESTDIR= ../bin include( ../variables.pri ) INCLUDEPATH += ../microkde ../ interfaces ../microkde/kdecore ../microkde/kdeui ../microkde/kio/kfile ../microkde/kio/kio ../libkdepim #../qtcompat DEFINES += KORG_NODND KORG_NOPLUGINS KORG_NOARCHIVE KORG_NOMAIL DEFINES += KORG_NODCOP KORG_NOKALARMD KORG_NORESOURCEVIEW KORG_NOSPLITTER #KORG_NOPRINTER KORG_NOKABC DEFINES += KORG_NOLVALTERNATION DEFINES += DESKTOP_VERSION unix : { LIBS += ../bin/libmicrokdepim.so LIBS += ../bin/libmicrokcal.so LIBS += ../bin/libmicrokde.so LIBS += ../bin/libmicrokabc.so #LIBS += -lbluetooth #LIBS += -lsdp #LIBS += -lldap OBJECTS_DIR = obj/unix MOC_DIR = moc/unix } win32: { RC_FILE = winicons.rc DEFINES += _WIN32_ LIBS += ../bin/microkdepim.lib LIBS += ../bin/microkcal.lib LIBS += ../bin/microkde.lib LIBS += ../bin/microkabc.lib LIBS += ../libical/lib/ical.lib LIBS += ../libical/lib/icalss.lib #LIBS += atls.lib -LIBS += mfc71u.lib QMAKE_LINK += /NODEFAULTLIB:LIBC #QMAKE_LINK += /NODEFAULTLIB:MSVCRT #QMAKE_LINK += /NODEFAULTLIB:uafxcw.lib OBJECTS_DIR = obj/win MOC_DIR = moc/win +#olimport section +#blabla: { +LIBS += mfc71u.lib +DEFINES += _OL_IMPORT_ + +HEADERS += ../outport/msoutl9.h \ + koimportoldialog.h +SOURCES += ../outport/msoutl9.cpp \ + koimportoldialog.cpp +#} +#olimport section end + } INTERFACES = kofilterview_base.ui #filteredit_base.ui # kdateedit.h \ -HEADERS = \ +HEADERS += \ filteredit_base.h \ alarmclient.h \ calendarview.h \ customlistviewitem.h \ datenavigator.h \ docprefs.h \ filtereditdialog.h \ incomingdialog.h \ incomingdialog_base.h \ interfaces/korganizer/baseview.h \ interfaces/korganizer/calendarviewbase.h \ journalentry.h \ kdatenavigator.h \ koagenda.h \ koagendaitem.h \ koagendaview.h \ kocounterdialog.h \ kodaymatrix.h \ kodialogmanager.h \ koeditordetails.h \ koeditorgeneral.h \ koeditorgeneralevent.h \ koeditorgeneraltodo.h \ koeditorrecurrence.h \ @@ -92,49 +103,49 @@ HEADERS = \ kotimespanview.h \ kotodoeditor.h \ kotodoview.h \ kotodoviewitem.h \ koviewmanager.h \ kowhatsnextview.h \ ktimeedit.h \ lineview.h \ mainwindow.h \ navigatorbar.h \ outgoingdialog.h \ outgoingdialog_base.h \ publishdialog.h \ publishdialog_base.h \ savetemplatedialog.h \ searchdialog.h \ simplealarmclient.h \ statusdialog.h \ timeline.h \ timespanview.h \ version.h \ ../kalarmd/alarmdialog.h \ -SOURCES = \ +SOURCES += \ filteredit_base.cpp \ calendarview.cpp \ datenavigator.cpp \ docprefs.cpp \ filtereditdialog.cpp \ incomingdialog.cpp \ incomingdialog_base.cpp \ journalentry.cpp \ kdatenavigator.cpp \ koagenda.cpp \ koagendaitem.cpp \ koagendaview.cpp \ kocounterdialog.cpp \ kodaymatrix.cpp \ kodialogmanager.cpp \ koeditordetails.cpp \ koeditorgeneral.cpp \ koeditorgeneralevent.cpp \ koeditorgeneraltodo.cpp \ koeditorrecurrence.cpp \ koeventeditor.cpp \ koeventpopupmenu.cpp \ koeventview.cpp \ koeventviewer.cpp \ @@ -157,37 +168,24 @@ filteredit_base.cpp \ ktimeedit.cpp \ lineview.cpp \ main.cpp \ mainwindow.cpp \ navigatorbar.cpp \ outgoingdialog.cpp \ outgoingdialog_base.cpp \ publishdialog.cpp \ publishdialog_base.cpp \ savetemplatedialog.cpp \ searchdialog.cpp \ simplealarmclient.cpp \ statusdialog.cpp \ timeline.cpp \ timespanview.cpp \ ../kalarmd/alarmdialog.cpp HEADERS += calprintbase.h calprinter.h calprintplugins.h cellitem.h INTERFACES += calprintdayconfig_base.ui \ calprintmonthconfig_base.ui \ calprinttodoconfig_base.ui \ calprintweekconfig_base.ui SOURCES += calprintbase.cpp calprinter.cpp calprintplugins.cpp cellitem.cpp - - -win32: { -HEADERS += ../outport/msoutl9.h \ - koimportoldialog.h - - -SOURCES += ../outport/msoutl9.cpp \ - koimportoldialog.cpp - - -} - diff --git a/korganizer/main.cpp b/korganizer/main.cpp index 2481ca4..4b207d9 100644 --- a/korganizer/main.cpp +++ b/korganizer/main.cpp @@ -1,71 +1,72 @@ #ifndef DESKTOP_VERSION #include <qpe/qpeapplication.h> #include <qcopchannel_qws.h> #include <qpe/global.h> #include <stdlib.h> #else #include <qapplication.h> #include <qstring.h> #include <qwindowsstyle.h> #include <qplatinumstyle.h> #include <qsgistyle.h> +#include <stdlib.h> #endif #include <qtextcodec.h> #include <qdir.h> #include <kstandarddirs.h> #include <kglobal.h> #include <stdio.h> #include "mainwindow.h" #include <libkdepim/kpimglobalprefs.h> void dumpMissing(); int main( int argc, char **argv ) { #ifndef DESKTOP_VERSION QPEApplication a( argc, argv ); a.setKeepRunning (); #else QApplication a( argc, argv ); QApplication::setStyle( new QPlatinumStyle ()); - QString hdir = QDir::homeDirPath(); - // there is a bug when creating dirs for WIN 98 - // it is difficult to fix, because we have no WIN 98 runnung - // such that we try it to create the dirs at startup here - if ( hdir == "C:\\" ) { // win 98 or ME +#ifdef _WIN32_ + QString hdir ( getenv( "HOME") ); + if ( hdir.isEmpty() ) { + QString hd ("C:/" ); + //QMessageBox::information(0,"hh",QDir::homeDirPath()+" xx" +hd ); + if ( QDir::homeDirPath().lower() == hd.lower() ) { + _putenv( "HOME=C:"); + //QMessageBox::information(0,"hh",QString ( getenv( "HOME") ) ); + } + } else { QDir app_dir; - if ( !app_dir.exists("C:\\kdepim") ) - app_dir.mkdir ("C:\\kdepim"); - if ( !app_dir.exists("C:\\kdepim\\apps") ) - app_dir.mkdir ("C:\\kdepim\\apps"); - if ( !app_dir.exists("C:\\kdepim\\config") ) - app_dir.mkdir ("C:\\kdepim\\config"); - if ( !app_dir.exists("C:\\kdepim\\apps\\korganizer") ) - app_dir.mkdir ("C:\\kdepim\\apps\\korganizer"); + if ( !app_dir.exists(hdir) ) + app_dir.mkdir (hdir); } #endif +#endif bool exitHelp = false; if ( argc > 1 ) { QString command = argv[1]; if ( command == "-help" ){ printf("KO/Pi command line commands:\n"); printf(" no command: Start KO/Pi in usual way\n"); printf(" -help: This output\n"); printf("Next Option: Open or Show after start:\n"); printf(" -newTodo: New Todo dialog\n"); printf(" -newEvent: New Event dialog\n"); printf(" -showList: List view\n"); printf(" -showDay: Day view\n"); printf(" -showWWeek: Work Week view\n"); printf(" -showWeek: Week view\n"); printf(" -showTodo: Todo view\n"); printf(" -showJournal: Journal view\n"); printf(" -showKO: Next Days view\n"); printf(" -showWNext: What's Next view\n"); printf(" -showNextXView: Next X View\n"); printf(" -new[Y] and -show[X] may be used togehther\n"); printf(" KO/Pi is exiting now. Bye!\n"); exitHelp = true; } } diff --git a/korganizer/mainwindow.cpp b/korganizer/mainwindow.cpp index 7b07a2e..26ea1e2 100644 --- a/korganizer/mainwindow.cpp +++ b/korganizer/mainwindow.cpp @@ -45,50 +45,52 @@ #include "calendarview.h" #include "koviewmanager.h" #include "datenavigator.h" #include "koagendaview.h" #include "koagenda.h" #include "kodialogmanager.h" #include "kdialogbase.h" #include "kapplication.h" #include "kofilterview.h" #include "kstandarddirs.h" #include "koprefs.h" #include "kfiledialog.h" #include "koglobals.h" #include "kglobal.h" #include "klocale.h" #include "kconfig.h" #include "simplealarmclient.h" #include "externalapphandler.h" using namespace KCal; #ifndef _WIN32_ #include <unistd.h> #else +#ifdef _OL_IMPORT_ #include "koimportoldialog.h" #endif +#endif #include "mainwindow.h" class KOex2phonePrefs : public QDialog { public: KOex2phonePrefs( QWidget *parent=0, const char *name=0 ) : QDialog( parent, name, true ) { setCaption( i18n("Export to phone options") ); QVBoxLayout* lay = new QVBoxLayout( this ); lay->setSpacing( 3 ); lay->setMargin( 3 ); QLabel *lab; lay->addWidget(lab = new QLabel( i18n("Please read Help-Sync Howto\nto know what settings to use."), this ) ); lab->setAlignment (AlignHCenter ); QHBox* temphb; temphb = new QHBox( this ); new QLabel( i18n("I/O device: "), temphb ); mPhoneDevice = new QLineEdit( temphb); lay->addWidget( temphb ); temphb = new QHBox( this ); new QLabel( i18n("Connection: "), temphb ); mPhoneConnection = new QLineEdit( temphb); lay->addWidget( temphb ); @@ -757,49 +759,49 @@ void MainWindow::initActions() actionMenu->insertItem( i18n("Configure Toolbar"),configureToolBarMenu ); } // actionMenu->insertSeparator(); action = new QAction( "import_qtopia", i18n("Import (*.ics/*.vcs) file"), 0, this ); action->addTo( importMenu ); connect( action, SIGNAL( activated() ), SLOT( importIcal() ) ); action = new QAction( "import_quick", i18n("Import last file"), 0, this ); action->addTo( importMenu ); connect( action, SIGNAL( activated() ), SLOT( quickImportIcal() ) ); importMenu->insertSeparator(); action = new QAction( "import_bday", i18n("Import Birthdays (KA/Pi)"), 0, this ); action->addTo( importMenu ); connect( action, SIGNAL( activated() ), SLOT( importBday() ) ); #ifndef DESKTOP_VERSION importMenu->insertSeparator(); action = new QAction( "import_qtopia", i18n("Import Opie/Qtopia Cal."), 0, this ); action->addTo( importMenu ); connect( action, SIGNAL( activated() ), SLOT( importQtopia() ) ); #else -#ifdef _WIN32_ +#ifdef _OL_IMPORT_ importMenu->insertSeparator(); action = new QAction( "import_ol", i18n("Import from OL"), 0, this ); action->addTo( importMenu ); connect( action, SIGNAL( activated() ), SLOT( importOL() ) ); #endif #endif importMenu->insertSeparator(); action = new QAction( "load_cal", i18n("Load Calendar Backup"), 0, this ); action->addTo( importMenu ); connect( action, SIGNAL( activated() ), SLOT( loadCalendar() ) ); action = new QAction( "save_cal", i18n("Save Calendar Backup"), 0, this ); action->addTo( importMenu ); connect( action, SIGNAL( activated() ), SLOT( saveCalendar() ) ); importMenu->insertSeparator(); action = new QAction( "import_qtopia", i18n("Export VCalendar"), 0, this ); action->addTo( importMenu ); connect( action, SIGNAL( activated() ), SLOT( exportVCalendar() ) ); @@ -1347,49 +1349,49 @@ void MainWindow::processIncidenceSelection( Incidence *incidence ) mNewSubTodoAction->setEnabled( true ); } else { mShowAction->setText( i18n("Show...") ); mShowAction->setText( i18n("Edit...") ); mShowAction->setText( i18n("Delete...") ); mNewSubTodoAction->setEnabled( false ); } } void MainWindow::enableIncidenceActions( bool enabled ) { mShowAction->setEnabled( enabled ); mEditAction->setEnabled( enabled ); mDeleteAction->setEnabled( enabled ); mCloneAction->setEnabled( enabled ); mMoveAction->setEnabled( enabled ); mBeamAction->setEnabled( enabled ); mCancelAction->setEnabled( enabled ); } void MainWindow::importOL() { -#ifdef _WIN32_ +#ifdef _OL_IMPORT_ KOImportOLdialog *id = new KOImportOLdialog("Import from OL - select folder!" , mView->calendar(),this ); id->exec(); delete id; mView->updateView(); #endif } void MainWindow::importBday() { int result = QMessageBox::warning( this, i18n("KO/Pi: Warning!"), i18n("When importing birthdays twice\nduplicated events will be ignored,\nif the event has not been\nchanged in KO/Pi!\n"), i18n("Import!"), i18n("Cancel"), 0, 0, 1 ); if ( result == 0 ) { mView->importBday(); } } void MainWindow::importQtopia() { #ifndef DESKTOP_VERSION int result = QMessageBox::warning( this, i18n("KO/Pi: Warning!"), i18n("When importing a calendar twice\nduplicated events will be ignored!\nYou can create a backup file with\nFile - Save Calendar Backup\nto revert importing"), |