From 4ad5ce65e2dec80eb25fd948aa229e41816bf25f Mon Sep 17 00:00:00 2001 From: Thilo Graf Date: Sun, 8 Oct 2017 17:48:32 +0200 Subject: [PATCH 1/4] CMenuWidget: small clean ups --- src/gui/widget/menue.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/gui/widget/menue.cpp b/src/gui/widget/menue.cpp index 07aaed0e6..3b71a6490 100644 --- a/src/gui/widget/menue.cpp +++ b/src/gui/widget/menue.cpp @@ -1455,10 +1455,8 @@ void CMenuWidget::enableSaveScreen(bool enable) void CMenuWidget::paintHint(int pos) { - if (!g_settings.show_menu_hints){ - //ResetModules(); //ensure clean up on changed setting + if (!g_settings.show_menu_hints) return; - } if (pos < 0 && !hint_painted) return; From 6b28013da1801b7b55403391251adecc22f74c92 Mon Sep 17 00:00:00 2001 From: Thilo Graf Date: Sun, 8 Oct 2017 17:48:32 +0200 Subject: [PATCH 2/4] CTimerList: increase width of remote menu eg: With oversized font sizes the buttons inside footer are squeezed. --- src/gui/timerlist.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gui/timerlist.cpp b/src/gui/timerlist.cpp index 30abd3eda..a189ce33b 100644 --- a/src/gui/timerlist.cpp +++ b/src/gui/timerlist.cpp @@ -1097,7 +1097,7 @@ void CTimerList::hide() bool CTimerList::RemoteBoxSetup() { bool ret = false; - remboxmenu = new CMenuWidget(LOCALE_REMOTEBOX_HEAD, NEUTRINO_ICON_TIMER); + remboxmenu = new CMenuWidget(LOCALE_REMOTEBOX_HEAD, NEUTRINO_ICON_TIMER, 50); remboxmenu->addKey(CRCInput::RC_red, this, "del_ip"); remboxmenu->addKey(CRCInput::RC_green, this, "add_ip"); From 3d9b7c1360c09a0c161199bb61fcf45b61c2319e Mon Sep 17 00:00:00 2001 From: Thilo Graf Date: Sun, 8 Oct 2017 17:48:32 +0200 Subject: [PATCH 3/4] CTimerList: fix behavior of hide() for remotebox sub menus After hide() the the background was not fully restored or was partially damaged the corners beside the header. --- src/gui/timerlist.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/gui/timerlist.cpp b/src/gui/timerlist.cpp index a189ce33b..1249c2e1c 100644 --- a/src/gui/timerlist.cpp +++ b/src/gui/timerlist.cpp @@ -315,6 +315,8 @@ int CTimerList::exec(CMenuTarget* parent, const std::string & actionKey) remotebox_user.forceSaveScreen(true); CKeyboardInput remotebox_pass(LOCALE_REMOTEBOX_PASS, &pass, 15); remotebox_pass.forceSaveScreen(true); + + //menu add remote box CMenuWidget * rbsetup = new CMenuWidget(LOCALE_REMOTEBOX_HEAD, NEUTRINO_ICON_TIMER); rbsetup->addItem(new CMenuForwarder(LOCALE_REMOTEBOX_RBNAME, true, rbname, &remotebox_name)); rbsetup->addItem(new CMenuForwarder(LOCALE_REMOTEBOX_RBADDR, true, rbaddress, &remotebox_address)); @@ -325,8 +327,6 @@ int CTimerList::exec(CMenuTarget* parent, const std::string & actionKey) if ((rbsetup->exec(NULL,"") == true) && (!rbaddress.empty())) { remboxmenu->addItem(new CMenuForwarder(rbname, true, NULL, this, "cha_ip")); - rbsetup->hide(); - remboxmenu->enableSaveScreen(false); remboxmenu->hide(); timer_remotebox_item timer_rb; timer_rb.rbaddress = rbaddress; @@ -377,6 +377,8 @@ int CTimerList::exec(CMenuTarget* parent, const std::string & actionKey) remotebox_user.forceSaveScreen(true); CKeyboardInput remotebox_pass(LOCALE_REMOTEBOX_PASS, &it->pass, 15); remotebox_pass.forceSaveScreen(true); + + //remote box edit CMenuWidget * rbsetup = new CMenuWidget(LOCALE_REMOTEBOX_HEAD, NEUTRINO_ICON_TIMER); rbsetup->addItem(new CMenuForwarder(LOCALE_REMOTEBOX_RBNAME, true, it->rbname, &remotebox_name)); rbsetup->addItem(new CMenuForwarder(LOCALE_REMOTEBOX_RBADDR, true, it->rbaddress, &remotebox_address)); @@ -388,8 +390,6 @@ int CTimerList::exec(CMenuTarget* parent, const std::string & actionKey) { it->port = atoi(port); f->setName(it->rbname); - rbsetup->hide(); - remboxmenu->enableSaveScreen(false); remboxmenu->hide(); changed = true; } From cbe21aade71b95e1a90cfba249f8ec5344fa3d68 Mon Sep 17 00:00:00 2001 From: Thilo Graf Date: Sun, 8 Oct 2017 17:48:32 +0200 Subject: [PATCH 4/4] CUpnpBrowserGui: fix possible compile errot MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit error: suggest parentheses around ‘&&’ within ‘||’ [-Werror=parentheses] --- src/gui/upnpbrowser.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/gui/upnpbrowser.cpp b/src/gui/upnpbrowser.cpp index b06d3ce83..2d33021c7 100644 --- a/src/gui/upnpbrowser.cpp +++ b/src/gui/upnpbrowser.cpp @@ -869,8 +869,7 @@ bool CUpnpBrowserGui::selectItem(std::string id) m_frameBuffer->Clear(); refresh = true; } - else if (m_folderplay && (msg == (neutrino_msg_t) CRCInput::RC_prev) - || video_key_msg == CMoviePlayerGui::PLUGIN_PLAYSTATE_PREV){ + else if (m_folderplay && ((msg == (neutrino_msg_t) CRCInput::RC_prev) || video_key_msg == CMoviePlayerGui::PLUGIN_PLAYSTATE_PREV)){ timeout = 0; m_playid -= 2; if (m_playid < 0)