egui
egui copied to clipboard
possible regression in 0.28 vs 0.27 in dnd_drag_source
Describe the bug
To Reproduce Steps to reproduce the behavior:
- In tutorial
https://github.com/emilk/egui/blob/master/crates/egui_demo_lib/src/demo/drag_and_drop.rs#L72C1-L75C1
,
replace
let response = ui
.dnd_drag_source(item_id, item_location, |ui| {
ui.label(item);
})
.response;
with
let response = ui
.dnd_drag_source(item_id, item_location, |ui| {
ui.vertical(|ui| {
ui.label("--");
ui.label(item);
});
})
.response;
-
Click on it
-
Error
thread 'main' panicked at /Users/egx/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui-0.28.1/src/widget_rect.rs:142:17:
Widget changed layer_id during the frame
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
thread 'main' panicked at /Users/egx/.cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.29.15/src/platform_impl/macos/app_state.rs:387:33:
called `Result::unwrap()` on an `Err` value: PoisonError { .. }
Expected behavior Can be dragged with 0.27
Screenshots
Desktop (please complete the following information):
- OS: MacOS 14.5