From 9755bc969d17fc683791abc5c6fbd50fa3112486 Mon Sep 17 00:00:00 2001 From: alwin Date: Sun, 24 Oct 2004 00:55:14 +0000 Subject: new options for pop3 accounts KATE eated a lot of last spaces in files some tryouts --- (limited to 'noncore/net/mail/libmailwrapper/genericwrapper.cpp') diff --git a/noncore/net/mail/libmailwrapper/genericwrapper.cpp b/noncore/net/mail/libmailwrapper/genericwrapper.cpp index 1caa375..5ec9415 100644 --- a/noncore/net/mail/libmailwrapper/genericwrapper.cpp +++ b/noncore/net/mail/libmailwrapper/genericwrapper.cpp @@ -3,6 +3,8 @@ #include "mailtypes.h" #include +#include +#include using namespace Opie::Core; Genericwrapper::Genericwrapper() @@ -243,12 +245,11 @@ RecBodyP Genericwrapper::parseMail( mailmessage * msg ) QString Genericwrapper::parseDateTime( mailimf_date_time *date ) { - char tmp[23]; - - snprintf( tmp, 23, "%02i.%02i.%04i %02i:%02i:%02i %+05i", - date->dt_day, date->dt_month, date->dt_year, date->dt_hour, date->dt_min, date->dt_sec, date->dt_zone ); - - return QString( tmp ); + QDateTime da(QDate(date->dt_year,date->dt_month,date->dt_day),QTime(date->dt_hour,date->dt_min,date->dt_sec)); + QString timestring = TimeString::numberDateString(QDate(date->dt_year,date->dt_month,date->dt_day))+" "; + timestring+=TimeString::timeString(QTime(date->dt_hour,date->dt_min,date->dt_sec))+" "; + timestring.sprintf(timestring+" %+05i",date->dt_zone); + return timestring; } QString Genericwrapper::parseAddressList( mailimf_address_list *list ) -- cgit v0.9.0.2