add scroll fn to traits
This commit is contained in:
@@ -129,15 +129,7 @@ impl Client {
|
||||
.add_static(&mut ui);
|
||||
|
||||
let texts = Span::empty(Dir::DOWN).add_static(&mut ui);
|
||||
let msg_area = (
|
||||
Rect::new(Color::SKY),
|
||||
texts
|
||||
.offset(UiVec2::ZERO)
|
||||
.edit_on(Sense::Scroll, |w, data| {
|
||||
w.amt += UiVec2::abs(data.scroll_delta * 50.0);
|
||||
}),
|
||||
)
|
||||
.stack();
|
||||
let msg_area = (Rect::new(Color::SKY), texts.scroll()).stack();
|
||||
let add_text = text_edit("add")
|
||||
.text_align(Align::Left)
|
||||
.size(30)
|
||||
|
||||
Reference in New Issue
Block a user