mirror of
https://github.com/YGGverse/Yoda.git
synced 2026-04-02 01:25:27 +00:00
implement resend form ability on request failure
This commit is contained in:
parent
c4e8f2ff61
commit
afc33c1a03
8 changed files with 406 additions and 445 deletions
|
|
@ -4,7 +4,7 @@ mod titan;
|
|||
|
||||
use super::ItemAction;
|
||||
use adw::Clamp;
|
||||
use gtk::{glib::Uri, prelude::WidgetExt, Box, Label};
|
||||
use gtk::{glib::Uri, prelude::WidgetExt};
|
||||
use response::Response;
|
||||
use sensitive::Sensitive;
|
||||
use std::rc::Rc;
|
||||
|
|
@ -40,7 +40,7 @@ impl Input {
|
|||
self.update(None);
|
||||
}
|
||||
|
||||
pub fn update(&self, child: Option<&Box>) {
|
||||
pub fn update(&self, child: Option<>k::Box>) {
|
||||
if child.is_some() {
|
||||
self.clamp.set_visible(true); // widget may be hidden, make it visible to child redraw
|
||||
self.clamp.set_child(child);
|
||||
|
|
@ -74,7 +74,7 @@ impl Input {
|
|||
));
|
||||
}
|
||||
|
||||
pub fn set_new_titan(&self, on_send: impl Fn(&[u8], &Label) + 'static) {
|
||||
self.update(Some(&Titan::build(on_send).g_box));
|
||||
pub fn set_new_titan(&self, on_send: impl Fn(&[u8], Box<dyn Fn()>) + 'static) {
|
||||
self.update(Some(>k::Box::titan(on_send)));
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue