From c0b07c73529012f9df3c1f4a1f5fcb087fd0a1ec Mon Sep 17 00:00:00 2001 From: Patrick McDermott Date: Sat, 04 Nov 2017 13:25:59 -0400 Subject: mq_html_input_number_d(): Allow label to be disabled --- (limited to 'src/utils/html.c') diff --git a/src/utils/html.c b/src/utils/html.c index 3b5be2c..9632baa 100644 --- a/src/utils/html.c +++ b/src/utils/html.c @@ -664,11 +664,21 @@ gchar * mq_html_input_number_d(const gchar *name, const gchar *label, gdouble min, gdouble step, gdouble max, gdouble value) { - return g_strdup_printf("\n", - name, label, name, name, min, step, max, value); + if (label && label[0]) { + return g_strdup_printf( + "\n", + name, label, name, name, min, step, max, value); + } else { + return g_strdup_printf( + "\n", + name, name, min, step, max, value); + } } gchar * -- cgit v0.9.1