@@ -9,7 +9,9 @@ use data::rate_limit::TokenPriority;
99use data:: target:: Target ;
1010use data:: user:: Nick ;
1111use data:: { Config , User , client, command} ;
12- use iced:: widget:: { column, container, row, text, text_input, vertical_rule} ;
12+ use iced:: widget:: {
13+ self , column, container, operation, row, rule, text, text_input,
14+ } ;
1315use iced:: { Alignment , Task , padding} ;
1416use tokio:: time;
1517
@@ -125,7 +127,7 @@ pub fn view<'a>(
125127 } ) ;
126128
127129 let maybe_vertical_rule =
128- maybe_our_user. is_some ( ) . then ( move || vertical_rule ( 1.0 ) ) ;
130+ maybe_our_user. is_some ( ) . then ( move || rule :: vertical ( 1.0 ) ) ;
129131
130132 let mut content = column ! [
131133 container(
@@ -190,7 +192,7 @@ fn error<'a, 'b, Message: 'a>(
190192
191193#[ derive( Debug , Clone ) ]
192194pub struct State {
193- input_id : text_input :: Id ,
195+ input_id : widget :: Id ,
194196 error : Option < String > ,
195197 completion : Completion ,
196198 selected_history : Option < usize > ,
@@ -205,7 +207,7 @@ impl Default for State {
205207impl State {
206208 pub fn new ( ) -> Self {
207209 Self {
208- input_id : text_input :: Id :: unique ( ) ,
210+ input_id : widget :: Id :: unique ( ) ,
209211 error : None ,
210212 completion : Completion :: default ( ) ,
211213 selected_history : None ,
@@ -851,17 +853,17 @@ impl State {
851853 } ) ;
852854 }
853855
854- ( text_input :: move_cursor_to_end ( self . input_id . clone ( ) ) , None )
856+ ( operation :: move_cursor_to_end ( self . input_id . clone ( ) ) , None )
855857 }
856858
857859 pub fn focus ( & self ) -> Task < Message > {
858860 let input_id = self . input_id . clone ( ) ;
859861
860- text_input :: is_focused ( input_id. clone ( ) ) . then ( move |is_focused| {
862+ operation :: is_focused ( input_id. clone ( ) ) . then ( move |is_focused| {
861863 if is_focused {
862864 Task :: none ( )
863865 } else {
864- text_input :: focus ( input_id. clone ( ) )
866+ operation :: focus ( input_id. clone ( ) )
865867 }
866868 } )
867869 }
@@ -903,7 +905,7 @@ impl State {
903905
904906 history. record_draft ( RawInput { buffer, text } ) ;
905907
906- text_input :: move_cursor_to_end ( self . input_id . clone ( ) )
908+ operation :: move_cursor_to_end ( self . input_id . clone ( ) )
907909 }
908910
909911 pub fn close_picker ( & mut self ) -> bool {
0 commit comments