Add creation date and Subsurface version to planner output

Signed-off-by: Stefan Fuchs <sfuchs@gmx.de>
This commit is contained in:
Stefan Fuchs 2017-03-31 08:14:36 +02:00 committed by Dirk Hohndel
parent 385816be2e
commit c9c9b1b399
3 changed files with 19 additions and 1 deletions

View file

@ -959,6 +959,16 @@ const char *get_dive_date_c_string(timestamp_t when)
return strdup(text.toUtf8().data());
}
extern "C" const char *get_current_date()
{
QDateTime ts(QDateTime::currentDateTime());;
QString current_date;
current_date = loc.toString(ts, QString(prefs.date_format_short));
return strdup(current_date.toUtf8().data());
}
bool is_same_day(timestamp_t trip_when, timestamp_t dive_when)
{
static timestamp_t twhen = (timestamp_t) 0;