[gnome-desktop/wip/hadess/ci-improvements: 7/9] wall-clock: More debug in format function



commit 063682f27bac72bc014f84c88a2543581c9be80c
Author: Bastien Nocera <hadess hadess net>
Date:   Fri Jan 11 01:06:16 2019 +0100

    wall-clock: More debug in format function

 libgnome-desktop/gnome-wall-clock.c | 11 +++++++++++
 1 file changed, 11 insertions(+)
---
diff --git a/libgnome-desktop/gnome-wall-clock.c b/libgnome-desktop/gnome-wall-clock.c
index 19f416a6..f9083894 100644
--- a/libgnome-desktop/gnome-wall-clock.c
+++ b/libgnome-desktop/gnome-wall-clock.c
@@ -241,7 +241,9 @@ date_time_format (GDateTime *datetime,
        /* Then do the same with en-space and underscore before passing it to
         * g_date_time_format.  */
        no_enspace = string_replace (no_ratio, " ", "_");
+       g_debug ("no_enspace: %s", no_enspace);
        replaced_format = g_date_time_format (datetime, no_enspace);
+       g_debug ("replaced_format: %s", replaced_format);
 
        g_free (no_ratio);
        g_free (no_enspace);
@@ -263,6 +265,8 @@ date_time_format (GDateTime *datetime,
        }
 
        g_free (replaced_format);
+       g_debug ("is_utf8: %s", is_utf8 ? "TRUE" : "FALSE");
+       g_debug ("ret: %s", ret);
        return ret;
 }
 
@@ -314,6 +318,11 @@ gnome_wall_clock_string_for_datetime (GnomeWallClock      *self,
 {
        const char *format_string;
 
+       g_debug ("clock_format: %s", clock_format == G_DESKTOP_CLOCK_FORMAT_24H ? "24h" : "12h");
+       g_debug ("show_weekday: %s", show_weekday ? "TRUE" : "FALSE");
+       g_debug ("show_full_date: %s", show_full_date ? "TRUE" : "FALSE");
+       g_debug ("show_seconds: %s", show_seconds ? "TRUE" : "FALSE");
+
        if (clock_format == G_DESKTOP_CLOCK_FORMAT_24H) {
                if (show_full_date) {
                        if (show_weekday)
@@ -366,6 +375,8 @@ gnome_wall_clock_string_for_datetime (GnomeWallClock      *self,
                }
        }
 
+       g_debug ("format_string: %s", format_string);
+
        return date_time_format (now, format_string);
 }
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]