mirror of
https://github.com/YGGverse/Yoda.git
synced 2025-02-11 02:44:15 +00:00
delegate is_sensitive_input argument to the form component
This commit is contained in:
parent
7fc6cad8b5
commit
a15738f391
@ -37,7 +37,14 @@ impl Input {
|
|||||||
is_sensitive_input: bool,
|
is_sensitive_input: bool,
|
||||||
) {
|
) {
|
||||||
self.widget.update(Some(
|
self.widget.update(Some(
|
||||||
&Response::new_arc(action_page_open, base, title, size_limit).gobject(),
|
&Response::new_arc(
|
||||||
|
action_page_open,
|
||||||
|
base,
|
||||||
|
title,
|
||||||
|
size_limit,
|
||||||
|
is_sensitive_input,
|
||||||
|
)
|
||||||
|
.gobject(),
|
||||||
));
|
));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -28,6 +28,7 @@ impl Response {
|
|||||||
base: Uri,
|
base: Uri,
|
||||||
title: Option<&str>,
|
title: Option<&str>,
|
||||||
size_limit: Option<usize>,
|
size_limit: Option<usize>,
|
||||||
|
is_sensitive_input: bool,
|
||||||
) -> Arc<Self> {
|
) -> Arc<Self> {
|
||||||
// Init local actions
|
// Init local actions
|
||||||
let action_update = Arc::new(SimpleAction::new(&uuid_string_random(), None));
|
let action_update = Arc::new(SimpleAction::new(&uuid_string_random(), None));
|
||||||
@ -35,7 +36,7 @@ impl Response {
|
|||||||
|
|
||||||
// Init components
|
// Init components
|
||||||
let control = Control::new_arc(action_send.clone());
|
let control = Control::new_arc(action_send.clone());
|
||||||
let form = Form::new_arc(action_update.clone());
|
let form = Form::new_arc(action_update.clone(), is_sensitive_input);
|
||||||
let title = Title::new_arc(title);
|
let title = Title::new_arc(title);
|
||||||
|
|
||||||
// Init widget
|
// Init widget
|
||||||
|
@ -11,7 +11,7 @@ pub struct Form {
|
|||||||
|
|
||||||
impl Form {
|
impl Form {
|
||||||
// Construct
|
// Construct
|
||||||
pub fn new_arc(action_update: Arc<SimpleAction>) -> Arc<Self> {
|
pub fn new_arc(action_update: Arc<SimpleAction>, is_sensitive_input: bool) -> Arc<Self> {
|
||||||
// Init widget
|
// Init widget
|
||||||
let widget = Widget::new_arc(action_update);
|
let widget = Widget::new_arc(action_update);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user