update iris & get button working again
This commit is contained in:
@@ -4,7 +4,7 @@ use super::*;
|
||||
|
||||
pub const SIZE: u32 = 20;
|
||||
|
||||
pub fn main_view(rsc: &mut Rsc) -> WidgetRef {
|
||||
pub fn main_view(rsc: &mut Rsc) -> WeakWidget {
|
||||
let msg_panel = msg_panel(rsc);
|
||||
let side_bar = rect(Color::BLACK.brighter(0.05)).width(80);
|
||||
|
||||
@@ -33,7 +33,7 @@ pub fn msg_widget(username: &str, content: &str) -> impl WidgetIdFn<Rsc> {
|
||||
.to_any()
|
||||
}
|
||||
|
||||
pub fn msg_panel(rsc: &mut Rsc) -> WidgetRef {
|
||||
pub fn msg_panel(rsc: &mut Rsc) -> WeakWidget {
|
||||
let msg_area = Span::empty(Dir::DOWN).gap(15);
|
||||
|
||||
let send_text = wtext("")
|
||||
@@ -54,7 +54,7 @@ pub fn msg_panel(rsc: &mut Rsc) -> WidgetRef {
|
||||
.on(Submit, move |ctx, rsc| {
|
||||
let content = ctx.widget.edit(rsc).take();
|
||||
let msg = msg_widget("ur mothe:", &content).add_strong(rsc);
|
||||
rsc.ui[msg_area].children.push(msg);
|
||||
rsc[msg_area].children.push(msg);
|
||||
})
|
||||
.pad(15)
|
||||
.attr::<Selector>(send_text)
|
||||
|
||||
Reference in New Issue
Block a user