Skip to content

Commit

Permalink
add help text to favorite's menu tooltip when the list is empty
Browse files Browse the repository at this point in the history
  • Loading branch information
jacob1 committed Jul 23, 2016
1 parent ecb0895 commit 8fe78ea
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/gui/game/GameView.cpp
Expand Up @@ -612,7 +612,10 @@ void GameView::NotifyMenuListChanged(GameModel * sender)
{
std::string tempString = "";
tempString += menuList[i]->GetIcon();
ui::Button * tempButton = new ui::Button(ui::Point(WINDOWW-16, currentY), ui::Point(15, 15), tempString, menuList[i]->GetDescription());
std::string description = menuList[i]->GetDescription();
if (i == SC_FAVORITES && Favorite::Ref().GetFavoritesList()->size() == 0)
description += " (Use ctrl+shift+click to favorite an element)";
ui::Button * tempButton = new ui::Button(ui::Point(WINDOWW-16, currentY), ui::Point(15, 15), tempString, description);
tempButton->Appearance.Margin = ui::Border(0, 2, 3, 2);
tempButton->SetTogglable(true);
tempButton->SetActionCallback(new MenuAction(this, i));
Expand Down

0 comments on commit 8fe78ea

Please sign in to comment.