Skip to content

Commit

Permalink
Show itemstring as tooltip if no item description
Browse files Browse the repository at this point in the history
  • Loading branch information
Wuzzy authored and SmallJoker committed Mar 18, 2017
1 parent 9f4916a commit 2cc518d
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/guiFormSpecMenu.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2394,6 +2394,9 @@ void GUIFormSpecMenu::drawList(const ListDrawSpec &s, int phase,
utf8_to_wide(item.getDefinition(m_client->idef()).description);
else
tooltip_text = utf8_to_wide(desc);
// Show itemstring as fallback for easier debugging
if (!item.name.empty() && tooltip_text.empty())
tooltip_text = utf8_to_wide(item.name);
}
if (tooltip_text != L"") {
std::vector<std::wstring> tt_rows = str_split(tooltip_text, L'\n');
Expand Down

0 comments on commit 2cc518d

Please sign in to comment.