diff options
Diffstat (limited to 'src/text/rich.rs')
| -rw-r--r-- | src/text/rich.rs | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/src/text/rich.rs b/src/text/rich.rs index c148566..60e2637 100644 --- a/src/text/rich.rs +++ b/src/text/rich.rs @@ -3,7 +3,6 @@ use iced_widget::graphics::text::cosmic_text; use crate::click; use crate::core::alignment; -use crate::core::clipboard; use crate::core::keyboard; use crate::core::keyboard::key; use crate::core::layout; @@ -15,8 +14,8 @@ use crate::core::touch; use crate::core::widget::text::{Alignment, LineHeight, Shaping, Wrapping}; use crate::core::widget::tree::{self, Tree}; use crate::core::{ - self, Clipboard, Element, Event, Font, Layout, Length, Pixels, Point, - Rectangle, Shell, Size, Vector, Widget, + self, Element, Event, Font, Layout, Length, Pixels, Point, Rectangle, + Shell, Size, Vector, Widget, }; use crate::selection::{Selection, SelectionEnd}; use crate::text::{Catalog, Dragging, Style, StyleFn}; @@ -557,7 +556,6 @@ where layout: Layout<'_>, cursor: mouse::Cursor, _renderer: &Renderer, - clipboard: &mut dyn Clipboard, shell: &mut Shell<'_, Message>, viewport: &Rectangle, ) { @@ -711,9 +709,8 @@ where if state.keyboard_modifiers.command() && !state.selection.is_empty() => { - clipboard.write( - clipboard::Kind::Standard, - state.selection.text(&state.paragraph), + shell.write_clipboard( + state.selection.text(&state.paragraph).into(), ); shell.capture_event(); |
