mirror of
https://gitlab.com/veloren/veloren.git
synced 2024-08-30 18:12:32 +00:00
Merge branch 'ifreund-drop-items' into 'master'
Allow dropping items See merge request veloren/veloren!615
This commit is contained in:
commit
4815a096fd
@ -248,6 +248,13 @@ impl<'a> Widget for Bag<'a> {
|
||||
}
|
||||
}
|
||||
|
||||
// Drop selected item
|
||||
if let Some(to_drop) = state.selected_slot {
|
||||
if ui.widget_input(ui.window).clicks().left().next().is_some() {
|
||||
event = Some(Event::HudEvent(HudEvent::DropInventorySlot(to_drop)));
|
||||
}
|
||||
}
|
||||
|
||||
// Close button
|
||||
if Button::image(self.imgs.close_button)
|
||||
.w_h(28.0, 28.0)
|
||||
|
Loading…
Reference in New Issue
Block a user