mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2025-01-16 07:04:29 +00:00
Use g_strtod when converting strings for GtkCellRendererSpin
These strings are likely user-provided values, so we should respect locale settings. Reported in bug 637189.
This commit is contained in:
parent
a9753ef5c6
commit
183bf8ac9d
@ -323,9 +323,11 @@ gtk_cell_renderer_spin_start_editing (GtkCellRenderer *cell,
|
||||
|
||||
g_object_get (cell_text, "text", &text, NULL);
|
||||
if (text)
|
||||
gtk_spin_button_set_value (GTK_SPIN_BUTTON (spin),
|
||||
g_ascii_strtod (text, NULL));
|
||||
g_free (text);
|
||||
{
|
||||
gtk_spin_button_set_value (GTK_SPIN_BUTTON (spin),
|
||||
g_strtod (text, NULL));
|
||||
g_free (text);
|
||||
}
|
||||
|
||||
g_object_set_data_full (G_OBJECT (spin), GTK_CELL_RENDERER_SPIN_PATH,
|
||||
g_strdup (path), g_free);
|
||||
|
Loading…
Reference in New Issue
Block a user