зеркало из
https://github.com/glebtv/tui-textarea.git
synced 2026-09-08 00:15:50 +03:00
do not remove yanked text after paste
Этот коммит содержится в:
@@ -842,8 +842,7 @@ impl<'a> TextArea<'a> {
|
|||||||
/// assert_eq!(textarea.lines(), [" bbb cccaaa"]);
|
/// assert_eq!(textarea.lines(), [" bbb cccaaa"]);
|
||||||
/// ```
|
/// ```
|
||||||
pub fn paste(&mut self) -> bool {
|
pub fn paste(&mut self) -> bool {
|
||||||
let yank = std::mem::take(&mut self.yank);
|
self.insert_str(self.yank.to_string())
|
||||||
self.insert_str(yank)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Move the cursor to the position specified by the [`CursorMove`] parameter. For each kind of cursor moves, see
|
/// Move the cursor to the position specified by the [`CursorMove`] parameter. For each kind of cursor moves, see
|
||||||
|
|||||||
Ссылка в новой задаче
Block a user