Added and modified patch from Henry

Modified the date format according to the chosen language (locale).

git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@5798 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
thunder2 2012-11-10 18:59:58 +00:00
parent 59ed165c81
commit a573211629
27 changed files with 159 additions and 129 deletions

View file

@ -40,6 +40,7 @@
#include "gui/notifyqt.h"
#include "gui/common/AvatarDefs.h"
#include "gui/MainWindow.h"
#include "rshare.h"
static QMap<std::string, ConfCertDialog*> instances;
@ -56,9 +57,6 @@ ConfCertDialog *ConfCertDialog::instance(const std::string& peer_id)
return d;
}
/* Define the format used for displaying the date and time */
#define DATETIME_FMT "MMM dd hh:mm:ss"
/** Default constructor */
ConfCertDialog::ConfCertDialog(const std::string& id, QWidget *parent, Qt::WFlags flags)
: QDialog(parent, flags), mId(id)
@ -167,9 +165,7 @@ void ConfCertDialog::load()
ui.loc->setText(QString::fromUtf8(detail.location.c_str()));
// Dont Show a timestamp in RS calculate the day
QDateTime date = QDateTime::fromTime_t(detail.lastConnect);
QString stime = date.toString(Qt::LocalDate);
ui.lastcontact-> setText(stime);
ui.lastcontact->setText(Rshare::customLongDate(detail.lastConnect));
/* set retroshare version */
std::map<std::string, std::string>::iterator vit;