Show date in chat messages and small style changes.

Save and restore window position of the Historiy Browser.

git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@3446 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
thunder2 2010-09-05 10:32:32 +00:00
parent e635e5a026
commit c63905fefc
13 changed files with 44 additions and 52 deletions

View file

@ -325,8 +325,16 @@ QString ChatStyle::formatMessage(enumFormatMessage type, QString &name, QDateTim
// }
// }
// if the message is on same date show only time
QString timeFormat;
// if (timestamp.daysTo(QDateTime::currentDateTime()) == 0) {
// timeFormat = "hh:mm:ss";
// } else {
timeFormat = "dd.MM.yyyy hh:mm:ss";
// }
QString formatMsg = style.replace("%name%", name)
.replace("%timestamp%", timestamp.toString("hh:mm:ss"))
.replace("%timestamp%", timestamp.toString(timeFormat))
.replace("%message%", msg);
return formatMsg;