@@ -29,8 +29,8 @@ macro_rules! check_recursion {
2929 to the same widget.\n Inspect the stack trace to determine which call it is.\n Then you can either \
3030 refactor your code to avoid a cyclic event dependency or block events from being emitted by doing \
3131 the following:\n {\n let _lock = self.model.relm.stream().lock();\n // Your panicking call.\n }\
32- \n See this example:\
33- https://github.com/antoyo/relm/blob/feature/futures-glib/examples/checkboxes.rs#L88\n
32+ \n See this example: \
33+ https://github.com/antoyo/relm/blob/feature/futures-glib/examples/checkboxes.rs#L88\
3434 This issue can also happen when emitting a signal to the same widget, in which case you need to\
3535 refactor your code to avoid this cyclic event dependency.") ;
3636 }
@@ -60,7 +60,7 @@ macro_rules! connect {
6060 ( $widget: expr, $event: ident( $( $args: pat) ,* ) , $other_component: expr, $msg: expr) => {
6161 let stream = $other_component. stream( ) . clone( ) ;
6262 $widget. $event( move |$( $args) ,* | {
63- let msg: Option <_> = $msg. into ( ) ;
63+ let msg: Option <_> = :: relm :: IntoOption :: into_option ( $msg) ;
6464 if let Some ( msg) = msg {
6565 stream. emit( msg) ;
6666 }
@@ -75,7 +75,7 @@ macro_rules! connect {
7575 let stream = $relm. stream( ) . clone( ) ;
7676 $widget. $event( move |$( $args) ,* | {
7777 let ( msg, return_value) = $msg;
78- let msg: Option <_> = msg . into ( ) ;
78+ let msg: Option <_> = :: relm :: IntoOption :: into_option ( msg ) ;
7979 if let Some ( msg) = msg {
8080 stream. emit( msg) ;
8181 }
@@ -97,7 +97,7 @@ macro_rules! connect {
9797 check_recursion!( $widget_clone) ;
9898 let mut $widget_clone = $widget_clone. borrow_mut( ) ;
9999 let ( msg, return_value) = $msg;
100- let msg: Option <_> = msg . into ( ) ;
100+ let msg: Option <_> = :: relm :: IntoOption :: into_option ( msg ) ;
101101 if let Some ( msg) = msg {
102102 stream. emit( msg) ;
103103 }
@@ -117,7 +117,7 @@ macro_rules! connect {
117117 let $widget_clone = $widget_clone. upgrade( ) . expect( "upgrade should always work" ) ;
118118 check_recursion!( $widget_clone) ;
119119 let mut $widget_clone = $widget_clone. borrow_mut( ) ;
120- let msg: Option <_> = $msg. into ( ) ;
120+ let msg: Option <_> = :: relm :: IntoOption :: into_option ( $msg) ;
121121 if let Some ( msg) = msg {
122122 stream. emit( msg) ;
123123 }
@@ -136,7 +136,7 @@ macro_rules! connect {
136136 let $widget = $widget. upgrade( ) . expect( "upgrade should always work" ) ;
137137 check_recursion!( $widget) ;
138138 let mut $widget = $widget. borrow_mut( ) ;
139- let msg: Option <_> = $msg. into ( ) ;
139+ let msg: Option <_> = :: relm :: IntoOption :: into_option ( $msg) ;
140140 if let Some ( msg) = msg {
141141 stream. emit( msg) ;
142142 }
@@ -150,7 +150,7 @@ macro_rules! connect {
150150 ( $relm: expr, $widget: expr, $event: ident( $( $args: pat) ,* ) , $msg: expr) => { {
151151 let stream = $relm. stream( ) . clone( ) ;
152152 $widget. $event( move |$( $args) ,* | {
153- let msg: Option <_> = $msg. into ( ) ;
153+ let msg: Option <_> = :: relm :: IntoOption :: into_option ( $msg) ;
154154 if let Some ( msg) = msg {
155155 stream. emit( msg) ;
156156 }
@@ -165,7 +165,7 @@ macro_rules! connect {
165165 #[ allow( unreachable_patterns) ]
166166 match msg {
167167 $message => {
168- let msg: Option <_> = $msg. into ( ) ;
168+ let msg: Option <_> = :: relm :: IntoOption :: into_option ( $msg) ;
169169 if let Some ( msg) = msg {
170170 stream. emit( msg) ;
171171 }
0 commit comments