Merge branch 'michaelweghorn/a11y_convert_negative_index_on_text_deletion' into 'main'
a11y: Convert negative text deletion index to actual offset Closes #6149 See merge request GNOME/gtk!6473
This commit is contained in:
@@ -1629,6 +1629,10 @@ delete_text_cb (GtkEditable *editable,
|
||||
return;
|
||||
|
||||
text = gtk_editable_get_chars (editable, start, end);
|
||||
|
||||
if (end < 0)
|
||||
end = g_utf8_strlen(text, -1);
|
||||
|
||||
changed->text_changed (changed->data, "delete", start, end - start, text);
|
||||
g_free (text);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user