summaryrefslogtreecommitdiffabout
path: root/kmicromail
Unidiff
Diffstat (limited to 'kmicromail') (more/less context) (ignore whitespace changes)
-rw-r--r--kmicromail/libmailwrapper/genericwrapper.cpp18
-rw-r--r--kmicromail/opiemail.cpp2
2 files changed, 2 insertions, 18 deletions
diff --git a/kmicromail/libmailwrapper/genericwrapper.cpp b/kmicromail/libmailwrapper/genericwrapper.cpp
index 09a6447..e691082 100644
--- a/kmicromail/libmailwrapper/genericwrapper.cpp
+++ b/kmicromail/libmailwrapper/genericwrapper.cpp
@@ -26,31 +26,13 @@ Genericwrapper::~Genericwrapper()
26 mailstorage_free(m_storage); 26 mailstorage_free(m_storage);
27 } 27 }
28 cleanMimeCache(); 28 cleanMimeCache();
29} 29}
30const QDateTime Genericwrapper::parseDateTime( mailimf_date_time *date ) 30const QDateTime Genericwrapper::parseDateTime( mailimf_date_time *date )
31{ 31{
32 static bool init = false ;
33 if ( ! init ) {
34 KConfig kon ( locateLocal( "config", "korganizerrc" ) );
35 kon.setGroup("Locale");
36 KGlobal::locale()->setIntDateFormat( (KLocale::IntDateFormat)kon.readNumEntry( "PreferredDate",0) );
37 QString dummy = kon.readEntry( "UserDateFormatShort","%aK %d.%m.%y" );// kon.readEntry( "");
38 KGlobal::locale()->setHore24Format( !kon.readNumEntry( "PreferredTime",0 ) );
39 KGlobal::locale()->setDateFormatShort(dummy.replace( QRegExp("K"), QString(",") ));
40 dummy = kon.readEntry( "UserDateFormatLong","%A %d %b %y" );
41 KGlobal::locale()->setDateFormat(dummy.replace( QRegExp("K"), QString(",") ));
42 kon.setGroup("Time & Date");
43 KGlobal::locale()->setDaylightSaving( kon.readBoolEntry( "UseDaylightsaving", true ),
44 kon.readNumEntry( "DaylightsavingStart", 90),
45 kon.readNumEntry( "DaylightsavingEnd",304) );
46 KGlobal::locale()->setTimezone( kon.readEntry( "TimeZoneName" ," 00:00 Europe/London(UTC)") );
47
48 init = true;
49 32
50 }
51 QDate da (date->dt_year,date->dt_month, date->dt_day ); 33 QDate da (date->dt_year,date->dt_month, date->dt_day );
52 QTime ti ( date->dt_hour, date->dt_min, date->dt_sec ); 34 QTime ti ( date->dt_hour, date->dt_min, date->dt_sec );
53 QDateTime dt ( da ,ti ); 35 QDateTime dt ( da ,ti );
54 int addsec = -date->dt_zone*36; 36 int addsec = -date->dt_zone*36;
55 //qDebug("adsec1 %d ",addsec ); 37 //qDebug("adsec1 %d ",addsec );
56 dt = dt.addSecs( addsec ); 38 dt = dt.addSecs( addsec );
diff --git a/kmicromail/opiemail.cpp b/kmicromail/opiemail.cpp
index 9a1a750..164988c 100644
--- a/kmicromail/opiemail.cpp
+++ b/kmicromail/opiemail.cpp
@@ -12,12 +12,13 @@
12#include "accountitem.h" 12#include "accountitem.h"
13#include "koprefsdialog.h" 13#include "koprefsdialog.h"
14 14
15#include <qmessagebox.h> 15#include <qmessagebox.h>
16#include <qtimer.h> 16#include <qtimer.h>
17#include <libkdepim/externalapphandler.h> 17#include <libkdepim/externalapphandler.h>
18#include <libkdepim/kpimglobalprefs.h>
18 19
19#include <qpe/qpeapplication.h> 20#include <qpe/qpeapplication.h>
20#include <libmailwrapper/smtpwrapper.h> 21#include <libmailwrapper/smtpwrapper.h>
21#include <libmailwrapper/mailtypes.h> 22#include <libmailwrapper/mailtypes.h>
22#include <libmailwrapper/abstractmail.h> 23#include <libmailwrapper/abstractmail.h>
23/* OPIE */ 24/* OPIE */
@@ -29,12 +30,13 @@
29//using namespace Opie::Core; 30//using namespace Opie::Core;
30 31
31OpieMail::OpieMail( QWidget *parent, const char *name ) 32OpieMail::OpieMail( QWidget *parent, const char *name )
32 : MainWindow( parent, name) //, WStyle_ContextHelp ) 33 : MainWindow( parent, name) //, WStyle_ContextHelp )
33{ 34{
34 settings = new Settings(); 35 settings = new Settings();
36 KPimGlobalPrefs::instance()->setGlobalConfig();
35 37
36 folderView->populate( settings->getAccounts() ); 38 folderView->populate( settings->getAccounts() );
37 39
38} 40}
39 41
40OpieMail::~OpieMail() 42OpieMail::~OpieMail()