mirror of
https://gitlab.gnome.org/GNOME/nautilus
synced 2024-07-04 17:30:47 +00:00
Don't move past end of string (#569165).
2009-03-09 Alexander Larsson <alexl@redhat.com> * eel-editable-label.c: (eel_editable_label_move_forward_word): Don't move past end of string (#569165). svn path=/trunk/; revision=15073
This commit is contained in:
parent
61de29e5d9
commit
ccba144639
|
@ -1,3 +1,9 @@
|
|||
2009-03-09 Alexander Larsson <alexl@redhat.com>
|
||||
|
||||
* eel-editable-label.c:
|
||||
(eel_editable_label_move_forward_word):
|
||||
Don't move past end of string (#569165).
|
||||
|
||||
2009-03-09 Alexander Larsson <alexl@redhat.com>
|
||||
|
||||
* eel-editable-label.c:
|
||||
|
|
|
@ -2756,10 +2756,11 @@ eel_editable_label_move_forward_word (EelEditableLabel *label,
|
|||
eel_editable_label_ensure_layout (label, FALSE);
|
||||
|
||||
pango_layout_get_log_attrs (label->layout, &log_attrs, &n_attrs);
|
||||
|
||||
/* Find the next word end */
|
||||
|
||||
/* Find the next word end,
|
||||
(remember, n_attrs is one more than the number of of chars) */
|
||||
new_pos++;
|
||||
while (new_pos < n_attrs && !log_attrs[new_pos].is_word_end)
|
||||
while (new_pos < (n_attrs - 1) && !log_attrs[new_pos].is_word_end)
|
||||
new_pos++;
|
||||
|
||||
g_free (log_attrs);
|
||||
|
|
Loading…
Reference in New Issue
Block a user