mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-06 03:21:49 +00:00
fix: update tooltip handling to display caption only when description is empty
This commit is contained in:
parent
a784a68c44
commit
7893338b67
1 changed files with 5 additions and 1 deletions
|
|
@ -152,7 +152,11 @@ void SlotView::refreshTooltip(const ItemStack& stack, const ItemDef& item) {
|
|||
);
|
||||
}
|
||||
|
||||
tooltip = captionText + L"\n" + descriptionText;
|
||||
if (descriptionText.length() > 0) {
|
||||
tooltip = captionText + L"\n" + descriptionText;
|
||||
} else {
|
||||
tooltip = captionText;
|
||||
}
|
||||
} else {
|
||||
tooltip.clear();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue