From 4587f8a2744ed8286aa8912de75516deaf217f4e Mon Sep 17 00:00:00 2001 From: Dirk Hohndel Date: Wed, 24 Apr 2013 21:05:57 -0700 Subject: Call the get_date functions with timestamp_t instead of struct tm This is the much more natural way to use this function, now that I look at it... Signed-off-by: Dirk Hohndel --- divelist-gtk.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'divelist-gtk.c') diff --git a/divelist-gtk.c b/divelist-gtk.c index e1482ee06..a5d70f348 100644 --- a/divelist-gtk.c +++ b/divelist-gtk.c @@ -258,7 +258,6 @@ static void date_data_func(GtkTreeViewColumn *col, gpointer data) { int idx, nr; - struct tm tm; timestamp_t when; /* this should be enought for most languages. if not increase the value. */ char *buffer; @@ -266,11 +265,10 @@ static void date_data_func(GtkTreeViewColumn *col, gtk_tree_model_get(model, iter, DIVE_INDEX, &idx, DIVE_DATE, &when, -1); nr = gtk_tree_model_iter_n_children(model, iter); - utc_mkdate(when, &tm); if (idx < 0) { - buffer = get_trip_date_string(&tm, nr); + buffer = get_trip_date_string(when, nr); } else { - buffer = get_dive_date_string(&tm); + buffer = get_dive_date_string(when); } g_object_set(renderer, "text", buffer, NULL); free(buffer); -- cgit v1.2.3-70-g09d2