projects
/
zakform
/
cgi
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0f0d216
)
Setting of long-name on setting label only if it is null.
author
Andrea Zagli
<azagli@libero.it>
Sun, 7 May 2017 13:33:09 +0000
(15:33 +0200)
committer
Andrea Zagli
<azagli@libero.it>
Sun, 7 May 2017 13:33:09 +0000
(15:33 +0200)
src/formelement.c
patch
|
blob
|
history
diff --git
a/src/formelement.c
b/src/formelement.c
index 9a2717cfebd1ce8473741202ff598217176dc9bf..b3a790a1308500fdc84cc201bd24f0023a989aa9 100644
(file)
--- a/
src/formelement.c
+++ b/
src/formelement.c
@@
-140,7
+140,10
@@
zak_form_cgi_form_element_set_label (ZakFormCgiFormElement *element, const gchar
g_hash_table_replace (priv->ht_label_attrs, "for", priv->id != NULL ? g_strdup (priv->id) : g_strdup (""));
g_hash_table_replace (priv->ht_label_attrs, "class", g_strdup ("control-label"));
- zak_form_element_set_long_name (ZAK_FORM_ELEMENT (element), label);
+ if (zak_form_element_get_long_name (ZAK_FORM_ELEMENT (element)) == NULL)
+ {
+ zak_form_element_set_long_name (ZAK_FORM_ELEMENT (element), label);
+ }
}
}