Mostly refactored out the common things for drag/drop so now just to refine how it's used and bring back moving the sprite around.

This commit is contained in:
Zed A. Shaw 2025-06-10 00:52:38 -04:00
parent 570b70ab0c
commit be7b86a913
6 changed files with 17 additions and 13 deletions

View file

@ -145,7 +145,7 @@ namespace gui {
auto& grab = $loot_ui.get_grab_source(*$grab_source);
if(drop.commit(grab.world_entity)) {
$loot_ui.commit_grab(*$grab_source);
grab.commit();
$grab_source = std::nullopt;
}
@ -193,7 +193,7 @@ namespace gui {
auto& grab = $status_ui.get_grab_source(*$grab_source);
if(drop.commit(grab.world_entity)) {
$status_ui.commit_grab(*$grab_source);
grab.commit();
$grab_source = std::nullopt;
}