fix: request redraw when editor needs to redraw
chore: update libcosmic fix: redraw when deleting text where cursor doesn't move editor only redraws if the action causes the cursor to move. ctrl+a+backspace or presseing delete doesn't move the cursor.
This commit is contained in:
parent
4ac0da3af9
commit
aad6c21ab4
2 changed files with 24 additions and 18 deletions
|
|
@ -1089,11 +1089,13 @@ where
|
|||
Named::Backspace => {
|
||||
delete_modifiers(&mut editor, Motion::LeftWord, *modifiers);
|
||||
editor.action(Action::Backspace);
|
||||
editor.set_redraw(true);
|
||||
shell.capture_event();
|
||||
}
|
||||
Named::Delete => {
|
||||
delete_modifiers(&mut editor, Motion::RightWord, *modifiers);
|
||||
editor.action(Action::Delete);
|
||||
editor.set_redraw(true);
|
||||
shell.capture_event();
|
||||
}
|
||||
Named::Tab => {
|
||||
|
|
@ -1412,6 +1414,10 @@ where
|
|||
shell.publish(on_changed.clone());
|
||||
}
|
||||
}
|
||||
|
||||
if editor.redraw() {
|
||||
shell.request_redraw();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue