guion/widget/
imp.rs

1//! redirective implementation for references of widgets
2use super::*;
3
4impl<E> Widget<E> for &(dyn Widget<E>+'_) where E: Env {
5    #[inline]
6    fn id(&self) -> E::WidgetID {
7        (**self).id()
8    }
9    #[inline]
10    fn _render(&self, l: Link<E>, r: &mut RenderLink<E>) {
11        (**self)._render(l,r)
12    }
13    #[inline]
14    fn _event_direct(&self, l: Link<E>, e: &EventCompound<E>) -> EventResp {
15        (**self)._event_direct(l,e)
16    }
17    #[inline]
18    fn _size(&self, l: Link<E>, e: &EStyle<E>) -> ESize<E> {
19        (**self)._size(l,e)
20    }
21    #[inline]
22    fn childs(&self) -> usize {
23        (**self).childs()
24    }
25    #[allow(deprecated)]
26    #[inline]
27    fn childs_ref(&self) -> Vec<Resolvable<E>> {
28        (**self).childs_ref()
29    }
30    #[allow(deprecated)]
31    #[inline]
32    fn into_childs<'w>(self: Box<Self>) -> Vec<Resolvable<'w,E>> where Self: 'w {
33        (**self).childs_ref()
34    }
35    #[inline]
36    fn child_bounds(&self, l: Link<E>, b: &Bounds, e: &EStyle<E>, force: bool) -> Result<Vec<Bounds>,()> {
37        (**self).child_bounds(l, b,e, force)
38    }
39    #[inline]
40    fn focusable(&self) -> bool {
41        (**self).focusable()
42    }
43
44    #[allow(deprecated)]
45    #[inline]
46    fn child_paths(&self, own_path: E::WidgetPath) -> Vec<E::WidgetPath> {
47        (**self).child_paths(own_path)
48    }
49    #[inline]
50    fn resolve(&self, i: E::WidgetPath) -> Result<Resolvable<E>,GuionError<E>> {
51        (**self).resolve(i)
52    }
53    #[inline]
54    fn into_resolve<'w>(self: Box<Self>, i: E::WidgetPath) -> Result<Resolvable<'w,E>,GuionError<E>> where Self: 'w {
55        (**self).resolve(i)
56    }
57    #[inline]
58    fn resolve_child(&self, p: &E::WidgetPath) -> Result<(usize,E::WidgetPath),GuionError<E>>  {
59        (**self).resolve_child(p)
60    }
61    #[inline]
62    fn trace_bounds(&self, l: Link<E>, i: E::WidgetPath, b: &Bounds, e: &EStyle<E>, force: bool) -> Result<Bounds,GuionError<E>> {
63        (**self).trace_bounds(l, i, b,e, force)
64    }
65    #[allow(deprecated)]
66    #[inline]
67    fn in_parent_path(&self, parent: E::WidgetPath) -> E::WidgetPath {
68        (**self).in_parent_path(parent)
69    }
70    #[allow(deprecated)]
71    #[inline]
72    fn resolved_by_path(&self, sub_path: &E::WidgetPath) -> Option<ResolvesThruResult<E>> {
73        (**self).resolved_by_path(sub_path)
74    }
75    #[inline]
76    fn _focus_on_mouse_down(&self) -> bool {
77        (**self)._focus_on_mouse_down()
78    }
79    #[inline]
80    fn _tabulate_by_tab(&self) -> bool {
81        (**self)._tabulate_by_tab()
82    }
83    fn debug_type_name(&self, dest: &mut Vec<&'static str>) {
84        dest.push(self.type_name());
85        (**self).debug_type_name(dest);
86    }
87    #[inline]
88    fn inner(&self) -> Option<&dyn Widget<E>> {
89        Some(&(**self))
90    }
91    #[inline]
92    fn child(&self, i: usize) -> Result<Resolvable<E>,()> {
93        (**self).child(i)
94    }
95    #[inline]
96    fn into_child<'w>(self: Box<Self>, i: usize) -> Result<Resolvable<'w,E>,()> where Self: 'w {
97        (**self).child(i)
98    }
99    #[inline]
100    fn box_ref(&self) -> WidgetRef<E> {
101        (**self).box_ref()
102    }
103    #[inline]
104    fn box_box<'w>(self: Box<Self>) -> WidgetRef<'w,E> where Self: 'w {
105        (**self).box_ref()
106    }
107    #[inline]
108    fn boxed<'w>(self) -> WidgetRef<'w,E> where Self: Sized+'w {
109        (*self).box_ref()
110    }
111}
112impl<E> Widget<E> for &mut (dyn Widget<E>+'_) where E: Env {
113    #[inline]
114    fn id(&self) -> E::WidgetID {
115        (**self).id()
116    }
117    #[inline]
118    fn _render(&self, l: Link<E>, r: &mut RenderLink<E>) {
119        (**self)._render(l,r)
120    }
121    #[inline]
122    fn _event_direct(&self, l: Link<E>, e: &EventCompound<E>) -> EventResp {
123        (**self)._event_direct(l,e)
124    }
125    #[inline]
126    fn _size(&self, l: Link<E>, e: &EStyle<E>) -> ESize<E> {
127        (**self)._size(l,e)
128    }
129    #[inline]
130    fn childs(&self) -> usize {
131        (**self).childs()
132    }
133    #[allow(deprecated)]
134    #[inline]
135    fn childs_ref(&self) -> Vec<Resolvable<E>> {
136        (**self).childs_ref()
137    }
138    #[allow(deprecated)]
139    #[inline]
140    fn into_childs<'w>(self: Box<Self>) -> Vec<Resolvable<'w,E>> where Self: 'w {
141        (**self).childs_ref()
142    }
143    #[inline]
144    fn child_bounds(&self, l: Link<E>, b: &Bounds, e: &EStyle<E>, force: bool) -> Result<Vec<Bounds>,()> {
145        (**self).child_bounds(l, b,e, force)
146    }
147    #[inline]
148    fn focusable(&self) -> bool {
149        (**self).focusable()
150    }
151
152    #[allow(deprecated)]
153    #[inline]
154    fn child_paths(&self, own_path: E::WidgetPath) -> Vec<E::WidgetPath> {
155        (**self).child_paths(own_path)
156    }
157    #[inline]
158    fn resolve(&self, i: E::WidgetPath) -> Result<Resolvable<E>,GuionError<E>> {
159        (**self).resolve(i)
160    }
161    #[inline]
162    fn into_resolve<'w>(self: Box<Self>, i: E::WidgetPath) -> Result<Resolvable<'w,E>,GuionError<E>> where Self: 'w {
163        (**self).resolve(i)
164    }
165    #[inline]
166    fn resolve_child(&self, p: &E::WidgetPath) -> Result<(usize,E::WidgetPath),GuionError<E>>  {
167        (**self).resolve_child(p)
168    }
169    #[inline]
170    fn trace_bounds(&self, l: Link<E>, i: E::WidgetPath, b: &Bounds, e: &EStyle<E>, force: bool) -> Result<Bounds,GuionError<E>> {
171        (**self).trace_bounds(l, i, b,e, force)
172    }
173    #[allow(deprecated)]
174    #[inline]
175    fn in_parent_path(&self, parent: E::WidgetPath) -> E::WidgetPath {
176        (**self).in_parent_path(parent)
177    }
178    #[allow(deprecated)]
179    #[inline]
180    fn resolved_by_path(&self, sub_path: &E::WidgetPath) -> Option<ResolvesThruResult<E>> {
181        (**self).resolved_by_path(sub_path)
182    }
183    #[inline]
184    fn _focus_on_mouse_down(&self) -> bool {
185        (**self)._focus_on_mouse_down()
186    }
187    #[inline]
188    fn _tabulate_by_tab(&self) -> bool {
189        (**self)._tabulate_by_tab()
190    }
191    fn debug_type_name(&self, dest: &mut Vec<&'static str>) {
192        dest.push(self.type_name());
193        (**self).debug_type_name(dest);
194    }
195    #[inline]
196    fn inner(&self) -> Option<&dyn Widget<E>> {
197        Some(&(**self))
198    }
199    #[inline]
200    fn child(&self, i: usize) -> Result<Resolvable<E>,()> { // fn child<'a>(&'a self, i: usize) -> Result<Resolvable<'a,E>,()>
201        (**self).child(i)
202    }
203    #[inline]
204    fn into_child<'w>(self: Box<Self>, i: usize) -> Result<Resolvable<'w,E>,()> where Self: 'w {
205        (**self).child(i)
206    }
207    #[inline]
208    fn box_ref(&self) -> WidgetRef<E> {
209        (**self).box_ref()
210    }
211    #[inline]
212    fn box_box<'w>(self: Box<Self>) -> WidgetRef<'w,E> where Self: 'w {
213        (**self).box_ref()
214    }
215    #[inline]
216    fn boxed<'w>(self) -> WidgetRef<'w,E> where Self: Sized+'w {
217        (*self).box_ref()
218    }
219}
220impl<E> Widget<E> for &(dyn WidgetMut<E>+'_) where E: Env {
221    #[inline]
222    fn id(&self) -> E::WidgetID {
223        (**self).id()
224    }
225    #[inline]
226    fn _render(&self, l: Link<E>, r: &mut RenderLink<E>) {
227        (**self)._render(l,r)
228    }
229    #[inline]
230    fn _event_direct(&self, l: Link<E>, e: &EventCompound<E>) -> EventResp {
231        (**self)._event_direct(l,e)
232    }
233    #[inline]
234    fn _size(&self, l: Link<E>, e: &EStyle<E>) -> ESize<E> {
235        (**self)._size(l,e)
236    }
237    #[inline]
238    fn childs(&self) -> usize {
239        (**self).childs()
240    }
241    #[allow(deprecated)]
242    #[inline]
243    fn childs_ref(&self) -> Vec<Resolvable<E>> {
244        (**self).childs_ref()
245    }
246    #[allow(deprecated)]
247    #[inline]
248    fn into_childs<'w>(self: Box<Self>) -> Vec<Resolvable<'w,E>> where Self: 'w {
249        (**self).childs_ref()
250    }
251    #[inline]
252    fn child_bounds(&self, l: Link<E>, b: &Bounds, e: &EStyle<E>, force: bool) -> Result<Vec<Bounds>,()> {
253        (**self).child_bounds(l, b,e, force)
254    }
255    #[inline]
256    fn focusable(&self) -> bool {
257        (**self).focusable()
258    }
259
260    #[allow(deprecated)]
261    #[inline]
262    fn child_paths(&self, own_path: E::WidgetPath) -> Vec<E::WidgetPath> {
263        (**self).child_paths(own_path)
264    }
265    #[inline]
266    fn resolve(&self, i: E::WidgetPath) -> Result<Resolvable<E>,GuionError<E>> {
267        (**self).resolve(i)
268    }
269    #[inline]
270    fn into_resolve<'w>(self: Box<Self>, i: E::WidgetPath) -> Result<Resolvable<'w,E>,GuionError<E>> where Self: 'w {
271        (**self).resolve(i)
272    }
273    #[inline]
274    fn resolve_child(&self, p: &E::WidgetPath) -> Result<(usize,E::WidgetPath),GuionError<E>>  {
275        (**self).resolve_child(p)
276    }
277    #[inline]
278    fn trace_bounds(&self, l: Link<E>, i: E::WidgetPath, b: &Bounds, e: &EStyle<E>, force: bool) -> Result<Bounds,GuionError<E>> {
279        (**self).trace_bounds(l, i, b,e, force)
280    }
281    #[allow(deprecated)]
282    #[inline]
283    fn in_parent_path(&self, parent: E::WidgetPath) -> E::WidgetPath {
284        (**self).in_parent_path(parent)
285    }
286    #[allow(deprecated)]
287    #[inline]
288    fn resolved_by_path(&self, sub_path: &E::WidgetPath) -> Option<ResolvesThruResult<E>> {
289        (**self).resolved_by_path(sub_path)
290    }
291    #[inline]
292    fn _focus_on_mouse_down(&self) -> bool {
293        (**self)._focus_on_mouse_down()
294    }
295    #[inline]
296    fn _tabulate_by_tab(&self) -> bool {
297        (**self)._tabulate_by_tab()
298    }
299    fn debug_type_name(&self, dest: &mut Vec<&'static str>) {
300        dest.push(self.type_name());
301        (**self).debug_type_name(dest);
302    }
303    #[inline]
304    fn inner(&self) -> Option<&dyn Widget<E>> {
305        Some((**self).base())
306    }
307    #[inline]
308    fn child(&self, i: usize) -> Result<Resolvable<E>,()> {
309        (**self).child(i)
310    }
311    #[inline]
312    fn into_child<'w>(self: Box<Self>, i: usize) -> Result<Resolvable<'w,E>,()> where Self: 'w {
313        let r: &dyn Widget<E> = (**self).base();
314        r.child(i)
315    }
316    #[inline]
317    fn box_ref(&self) -> WidgetRef<E> {
318        (**self).box_ref()
319    }
320    #[inline]
321    fn box_box<'w>(self: Box<Self>) -> WidgetRef<'w,E> where Self: 'w {
322        (**self).box_ref()
323    }
324    #[inline]
325    fn boxed<'w>(self) -> WidgetRef<'w,E> where Self: Sized+'w {
326        (*self).box_ref()
327    }
328}
329impl<E> Widget<E> for &mut (dyn WidgetMut<E>+'_) where E: Env {
330    #[inline]
331    fn id(&self) -> E::WidgetID {
332        (**self).id()
333    }
334    #[inline]
335    fn _render(&self, l: Link<E>, r: &mut RenderLink<E>) {
336        (**self)._render(l,r)
337    }
338    #[inline]
339    fn _event_direct(&self, l: Link<E>, e: &EventCompound<E>) -> EventResp {
340        (**self)._event_direct(l,e)
341    }
342    #[inline]
343    fn _size(&self, l: Link<E>, e: &EStyle<E>) -> ESize<E> {
344        (**self)._size(l,e)
345    }
346    #[inline]
347    fn childs(&self) -> usize {
348        (**self).childs()
349    }
350    #[allow(deprecated)]
351    #[inline]
352    fn childs_ref(&self) -> Vec<Resolvable<E>> {
353        (**self).childs_ref()
354    }
355    #[allow(deprecated)]
356    #[inline]
357    fn into_childs<'w>(self: Box<Self>) -> Vec<Resolvable<'w,E>> where Self: 'w {
358        (**self).childs_ref()
359    }
360    #[inline]
361    fn child_bounds(&self, l: Link<E>, b: &Bounds, e: &EStyle<E>, force: bool) -> Result<Vec<Bounds>,()> {
362        (**self).child_bounds(l, b,e, force)
363    }
364    #[inline]
365    fn focusable(&self) -> bool {
366        (**self).focusable()
367    }
368
369    #[allow(deprecated)]
370    #[inline]
371    fn child_paths(&self, own_path: E::WidgetPath) -> Vec<E::WidgetPath> {
372        (**self).child_paths(own_path)
373    }
374    #[inline]
375    fn resolve(&self, i: E::WidgetPath) -> Result<Resolvable<E>,GuionError<E>> {
376        (**self).resolve(i)
377    }
378    #[inline]
379    fn into_resolve<'w>(self: Box<Self>, i: E::WidgetPath) -> Result<Resolvable<'w,E>,GuionError<E>> where Self: 'w {
380        (**self).resolve(i)
381    }
382    #[inline]
383    fn resolve_child(&self, p: &E::WidgetPath) -> Result<(usize,E::WidgetPath),GuionError<E>>  {
384        (**self).resolve_child(p)
385    }
386    #[inline]
387    fn trace_bounds(&self, l: Link<E>, i: E::WidgetPath, b: &Bounds, e: &EStyle<E>, force: bool) -> Result<Bounds,GuionError<E>> {
388        (**self).trace_bounds(l, i, b,e, force)
389    }
390    #[allow(deprecated)]
391    #[inline]
392    fn in_parent_path(&self, parent: E::WidgetPath) -> E::WidgetPath {
393        (**self).in_parent_path(parent)
394    }
395    #[allow(deprecated)]
396    #[inline]
397    fn resolved_by_path(&self, sub_path: &E::WidgetPath) -> Option<ResolvesThruResult<E>> {
398        (**self).resolved_by_path(sub_path)
399    }
400    #[inline]
401    fn _focus_on_mouse_down(&self) -> bool {
402        (**self)._focus_on_mouse_down()
403    }
404    #[inline]
405    fn _tabulate_by_tab(&self) -> bool {
406        (**self)._tabulate_by_tab()
407    }
408    fn debug_type_name(&self, dest: &mut Vec<&'static str>) {
409        dest.push(self.type_name());
410        (**self).debug_type_name(dest);
411    }
412    #[inline]
413    fn inner(&self) -> Option<&dyn Widget<E>> {
414        Some((**self).base())
415    }
416    #[inline]
417    fn child(&self, i: usize) -> Result<Resolvable<E>,()> {
418        (**self).child(i)
419    }
420    #[inline]
421    fn into_child<'w>(self: Box<Self>, i: usize) -> Result<Resolvable<'w,E>,()> where Self: 'w {
422        let r: &dyn Widget<E> = (**self).base();
423        r.child(i)
424    }
425    #[inline]
426    fn box_ref(&self) -> WidgetRef<E> {
427        (**self).box_ref()
428    }
429    #[inline]
430    fn box_box<'w>(self: Box<Self>) -> WidgetRef<'w,E> where Self: 'w {
431        (**self).box_ref()
432    }
433    #[inline]
434    fn boxed<'w>(self) -> WidgetRef<'w,E> where Self: Sized+'w {
435        (*self).box_ref()
436    }
437}
438impl<E> WidgetMut<E> for &mut (dyn WidgetMut<E>+'_) where E: Env {
439    #[allow(deprecated)]
440    #[inline]
441    fn childs_mut(&mut self) -> Vec<ResolvableMut<E>> {
442        (**self).childs_mut()
443    }
444    #[allow(deprecated)]
445    #[inline]
446    fn into_childs_mut<'w>(self: Box<Self>) -> Vec<ResolvableMut<'w,E>> where Self: 'w {
447        (**self).childs_mut()
448    }
449    #[inline]
450    fn _set_invalid(&mut self, v: bool) {
451        (**self)._set_invalid(v)
452    }
453    #[inline]
454    fn resolve_mut(&mut self, i: E::WidgetPath) -> Result<ResolvableMut<E>,GuionError<E>> { //TODO eventually use reverse "dont_invaldiate"/"keep_valid" bool
455        (**self).resolve_mut(i)
456    }
457    #[inline]
458    fn into_resolve_mut<'w>(self: Box<Self>, i: E::WidgetPath) -> Result<ResolvableMut<'w,E>,GuionError<E>> where Self: 'w {
459        (**self).resolve_mut(i)
460    }
461    #[inline]
462    fn resolve_child_mut(&mut self, p: &E::WidgetPath) -> Result<(usize,E::WidgetPath),GuionError<E>>  {
463        (**self).resolve_child_mut(p)
464    }
465    #[inline]
466    fn inner_mut(&mut self) -> Option<&mut dyn WidgetMut<E>> {
467        Some(&mut(**self))
468    }
469    #[inline]
470    fn child_mut(&mut self, i: usize) -> Result<ResolvableMut<E>,()> {
471        (**self).child_mut(i)
472    }
473    #[inline]
474    fn into_child_mut<'w>(self: Box<Self>, i: usize) -> Result<ResolvableMut<'w,E>,()> where Self: 'w {
475        (**self).child_mut(i)
476    }
477    #[inline]
478    fn message(&mut self, m: E::Message) {
479        (**self).message(m)
480    }
481    fn debug_type_name_mut(&mut self, dest: &mut Vec<&'static str>) {
482        dest.push(self.type_name());
483        (**self).debug_type_name_mut(dest);
484    }
485    #[inline]
486    fn box_mut(&mut self) -> WidgetRefMut<E> {
487        (**self).box_mut()
488    }
489    #[inline]
490    fn box_box_mut<'w>(self: Box<Self>) -> WidgetRefMut<'w,E> where Self: 'w {
491        (**self).box_mut()
492    }
493    #[inline]
494    fn boxed_mut<'w>(self) -> WidgetRefMut<'w,E> where Self: Sized+'w {
495        (*self).box_mut()
496    }
497}
498impl<E> Widget<E> for Box<(dyn Widget<E>+'_)> where E: Env {
499    #[inline]
500    fn id(&self) -> E::WidgetID {
501        (**self).id()
502    }
503    #[inline]
504    fn _render(&self, l: Link<E>, r: &mut RenderLink<E>) {
505        (**self)._render(l,r)
506    }
507    #[inline]
508    fn _event_direct(&self, l: Link<E>, e: &EventCompound<E>) -> EventResp {
509        (**self)._event_direct(l,e)
510    }
511    #[inline]
512    fn _size(&self, l: Link<E>, e: &EStyle<E>) -> ESize<E> {
513        (**self)._size(l,e)
514    }
515    #[inline]
516    fn childs(&self) -> usize {
517        (**self).childs()
518    }
519    #[allow(deprecated)]
520    #[inline]
521    fn childs_ref(&self) -> Vec<Resolvable<E>> {
522        (**self).childs_ref()
523    }
524    #[inline]
525    fn into_childs<'w>(self: Box<Self>) -> Vec<Resolvable<'w,E>> where Self: 'w {
526        (*self).into_childs()
527    }
528    #[inline]
529    fn child_bounds(&self, l: Link<E>, b: &Bounds, e: &EStyle<E>, force: bool) -> Result<Vec<Bounds>,()> {
530        (**self).child_bounds(l, b,e, force)
531    }
532    #[inline]
533    fn focusable(&self) -> bool {
534        (**self).focusable()
535    }
536
537    #[allow(deprecated)]
538    #[inline]
539    fn child_paths(&self, own_path: E::WidgetPath) -> Vec<E::WidgetPath> {
540        (**self).child_paths(own_path)
541    }
542    #[inline]
543    fn resolve(&self, i: E::WidgetPath) -> Result<Resolvable<E>,GuionError<E>> {
544        (**self).resolve(i)
545    }
546    #[inline]
547    fn into_resolve<'w>(self: Box<Self>, i: E::WidgetPath) -> Result<Resolvable<'w,E>,GuionError<E>> where Self: 'w {
548        (*self).into_resolve(i)
549    }
550    #[inline]
551    fn resolve_child(&self, p: &E::WidgetPath) -> Result<(usize,E::WidgetPath),GuionError<E>>  {
552        (**self).resolve_child(p)
553    }
554    #[inline]
555    fn trace_bounds(&self, l: Link<E>, i: E::WidgetPath, b: &Bounds, e: &EStyle<E>, force: bool) -> Result<Bounds,GuionError<E>> {
556        (**self).trace_bounds(l, i, b,e, force)
557    }
558    #[allow(deprecated)]
559    #[inline]
560    fn in_parent_path(&self, parent: E::WidgetPath) -> E::WidgetPath {
561        (**self).in_parent_path(parent)
562    }
563    #[allow(deprecated)]
564    #[inline]
565    fn resolved_by_path(&self, sub_path: &E::WidgetPath) -> Option<ResolvesThruResult<E>> {
566        (**self).resolved_by_path(sub_path)
567    }
568    #[inline]
569    fn _focus_on_mouse_down(&self) -> bool {
570        (**self)._focus_on_mouse_down()
571    }
572    #[inline]
573    fn _tabulate_by_tab(&self) -> bool {
574        (**self)._tabulate_by_tab()
575    }
576    fn debug_type_name(&self, dest: &mut Vec<&'static str>) {
577        dest.push(self.type_name());
578        (**self).debug_type_name(dest);
579    }
580    #[inline]
581    fn inner(&self) -> Option<&dyn Widget<E>> {
582        Some(&**self)
583    }
584    #[inline]
585    fn child(&self, i: usize) -> Result<Resolvable<E>,()> {
586        (**self).child(i)
587    }
588    #[inline]
589    fn into_child<'w>(self: Box<Self>, i: usize) -> Result<Resolvable<'w,E>,()> where Self: 'w {
590        (*self).into_child(i)
591    }
592    #[inline]
593    fn box_ref(&self) -> WidgetRef<E> {
594        (**self).box_ref()
595    }
596    #[inline]
597    fn box_box<'w>(self: Box<Self>) -> WidgetRef<'w,E> where Self: 'w {
598        (*self).box_box()
599    }
600    #[inline]
601    fn boxed<'w>(self) -> WidgetRef<'w,E> where Self: Sized+'w {
602        self.box_box()
603    }
604}
605impl<E> Widget<E> for Box<(dyn WidgetMut<E>+'_)> where E: Env {
606    #[inline]
607    fn id(&self) -> E::WidgetID {
608        (**self).id()
609    }
610    #[inline]
611    fn _render(&self, l: Link<E>, r: &mut RenderLink<E>) {
612        (**self)._render(l,r)
613    }
614    #[inline]
615    fn _event_direct(&self, l: Link<E>, e: &EventCompound<E>) -> EventResp {
616        (**self)._event_direct(l,e)
617    }
618    #[inline]
619    fn _size(&self, l: Link<E>, e: &EStyle<E>) -> ESize<E> {
620        (**self)._size(l,e)
621    }
622    #[inline]
623    fn childs(&self) -> usize {
624        (**self).childs()
625    }
626    #[allow(deprecated)]
627    #[inline]
628    fn childs_ref(&self) -> Vec<Resolvable<E>> {
629        (**self).childs_ref()
630    }
631    #[inline]
632    fn into_childs<'w>(self: Box<Self>) -> Vec<Resolvable<'w,E>> where Self: 'w {
633        (*self).into_childs()
634    }
635    #[inline]
636    fn child_bounds(&self, l: Link<E>, b: &Bounds, e: &EStyle<E>, force: bool) -> Result<Vec<Bounds>,()> {
637        (**self).child_bounds(l, b,e, force)
638    }
639    #[inline]
640    fn focusable(&self) -> bool {
641        (**self).focusable()
642    }
643
644    #[allow(deprecated)]
645    #[inline]
646    fn child_paths(&self, own_path: E::WidgetPath) -> Vec<E::WidgetPath> {
647        (**self).child_paths(own_path)
648    }
649    #[inline]
650    fn resolve(&self, i: E::WidgetPath) -> Result<Resolvable<E>,GuionError<E>> where {
651        (**self).resolve(i)
652    }
653    #[inline]
654    fn into_resolve<'w>(self: Box<Self>, i: E::WidgetPath) -> Result<Resolvable<'w,E>,GuionError<E>> where Self: 'w {
655        (*self).into_resolve(i)
656    }
657    #[inline]
658    fn resolve_child(&self, p: &E::WidgetPath) -> Result<(usize,E::WidgetPath),GuionError<E>>  {
659        (**self).resolve_child(p)
660    }
661    #[inline]
662    fn trace_bounds(&self, l: Link<E>, i: E::WidgetPath, b: &Bounds, e: &EStyle<E>, force: bool) -> Result<Bounds,GuionError<E>> {
663        (**self).trace_bounds(l, i, b,e, force)
664    }
665    #[allow(deprecated)]
666    #[inline]
667    fn in_parent_path(&self, parent: E::WidgetPath) -> E::WidgetPath {
668        (**self).in_parent_path(parent)
669    }
670    #[allow(deprecated)]
671    #[inline]
672    fn resolved_by_path(&self, sub_path: &E::WidgetPath) -> Option<ResolvesThruResult<E>> {
673        (**self).resolved_by_path(sub_path)
674    }
675    #[inline]
676    fn _focus_on_mouse_down(&self) -> bool {
677        (**self)._focus_on_mouse_down()
678    }
679    #[inline]
680    fn _tabulate_by_tab(&self) -> bool {
681        (**self)._tabulate_by_tab()
682    }
683    fn debug_type_name(&self, dest: &mut Vec<&'static str>) {
684        dest.push(self.type_name());
685        (**self).debug_type_name(dest);
686    }
687    #[inline]
688    fn inner(&self) -> Option<&dyn Widget<E>> {
689        Some((**self).base())
690    }
691    #[inline]
692    fn child(&self, i: usize) -> Result<Resolvable<E>,()> {
693        (**self).child(i)
694    }
695    #[inline]
696    fn into_child<'w>(self: Box<Self>, i: usize) -> Result<Resolvable<'w,E>,()> where Self: 'w {
697        (*self).into_child(i)
698    }
699    #[inline]
700    fn box_ref(&self) -> WidgetRef<E> {
701       (**self).box_ref()
702    }
703    #[inline]
704    fn box_box<'w>(self: Box<Self>) -> WidgetRef<'w,E> where Self: 'w {
705        (*self).box_box()
706    }
707    #[inline]
708    fn boxed<'w>(self) -> WidgetRef<'w,E> where Self: Sized+'w {
709        self.box_box()
710    }
711}
712impl<E> WidgetMut<E> for Box<(dyn WidgetMut<E>+'_)> where E: Env {
713    #[allow(deprecated)]
714    #[inline]
715    fn childs_mut(&mut self) -> Vec<ResolvableMut<E>> {
716        (**self).childs_mut()
717    }
718    #[inline]
719    fn into_childs_mut<'w>(self: Box<Self>) -> Vec<ResolvableMut<'w,E>> where Self: 'w {
720        (*self).into_childs_mut()
721    }
722    #[inline]
723    fn _set_invalid(&mut self, v: bool) {
724        (**self)._set_invalid(v)
725    }
726    #[inline]
727    fn resolve_mut(&mut self, i: E::WidgetPath) -> Result<ResolvableMut<E>,GuionError<E>> { //TODO eventually use reverse "dont_invaldiate"/"keep_valid" bool
728        (**self).resolve_mut(i)
729    }
730    #[inline]
731    fn into_resolve_mut<'w>(self: Box<Self>, i: E::WidgetPath) -> Result<ResolvableMut<'w,E>,GuionError<E>> where Self: 'w {
732        (*self).into_resolve_mut(i)
733    }
734    #[inline]
735    fn resolve_child_mut(&mut self, p: &E::WidgetPath) -> Result<(usize,E::WidgetPath),GuionError<E>>  {
736        (**self).resolve_child_mut(p)
737    }
738    #[inline]
739    fn inner_mut(&mut self) -> Option<&mut dyn WidgetMut<E>> {
740        Some(&mut(**self))
741    }
742    #[inline]
743    fn child_mut(&mut self, i: usize) -> Result<ResolvableMut<E>,()> {
744        (**self).child_mut(i)
745    }
746    #[inline]
747    fn into_child_mut<'w>(self: Box<Self>, i: usize) -> Result<ResolvableMut<'w,E>,()> where Self: 'w {
748        (*self).into_child_mut(i)
749    }
750    #[inline]
751    fn message(&mut self, m: E::Message) {
752        (**self).message(m)
753    }
754    fn debug_type_name_mut(&mut self, dest: &mut Vec<&'static str>) {
755        dest.push(self.type_name());
756        (**self).debug_type_name_mut(dest);
757    }
758    #[inline]
759    fn box_mut(&mut self) -> WidgetRefMut<E> {
760        (**self).box_mut()
761    }
762    #[inline]
763    fn box_box_mut<'w>(self: Box<Self>) -> WidgetRefMut<'w,E> where Self: 'w {
764        (*self).box_box_mut()
765    }
766    #[inline]
767    fn boxed_mut<'w>(self) -> WidgetRefMut<'w,E> where Self: Sized+'w {
768        self.box_box_mut()
769    }
770}