Don't append itemname to itemname in tooltip (#8176)
authorWuzzy <wuzzy2@mail.ru>
Sat, 9 Feb 2019 14:46:02 +0000 (15:46 +0100)
committerSmallJoker <SmallJoker@users.noreply.github.com>
Sat, 9 Feb 2019 14:46:02 +0000 (15:46 +0100)
src/gui/guiFormSpecMenu.cpp

index c52a6ee2716900c11238630d1b915b333742436a..6c404728fcc7a8ea15a945c2c0f6b5d396b4cfe0 100644 (file)
@@ -2424,7 +2424,7 @@ void GUIFormSpecMenu::drawList(const ListDrawSpec &s, int layer,
                                if (!item.name.empty()) {
                                        if (tooltip_text.empty())
                                                tooltip_text = utf8_to_wide(item.name);
-                                       if (m_tooltip_append_itemname)
+                                       else if (m_tooltip_append_itemname)
                                                tooltip_text += utf8_to_wide(" [" + item.name + "]");
                                }
                        }