user-menu: avoid empty headers in user-menu

Signed-off-by: Thilo Graf <dbt@novatux.de>


Origin commit data
------------------
Branch: ni/coolstream
Commit: 3fef93574a
Author: vanhofen <vanhofen@gmx.de>
Date: 2017-12-20 (Wed, 20 Dec 2017)

Origin message was:
------------------
- user-menu: avoid empty headers in user-menu

Signed-off-by: Thilo Graf <dbt@novatux.de>


------------------
This commit was generated by Migit
This commit is contained in:
vanhofen
2017-12-20 10:55:33 +01:00
committed by Thilo Graf
parent ec600df09a
commit 594d66db51

View File

@@ -164,6 +164,8 @@ bool CUserMenu::showUserMenu(neutrino_msg_t msg)
std::string txt = g_settings.usermenu[button]->title;
if (button < COL_BUTTONMAX && txt.empty())
txt = g_Locale->getText(user_menu[button].caption);
if (txt.empty())
txt = g_Locale->getText(LOCALE_USERMENU_HEAD);
CMenuWidget *menu = new CMenuWidget(txt, (button < COL_BUTTONMAX) ? user_menu[button].menu_icon_def : "", width);
if (menu == NULL)