From c7de70d0c7c42144803e5c2cc6b11c5c5e2b4885 Mon Sep 17 00:00:00 2001 From: Stefan Seyfried Date: Sat, 4 Mar 2017 19:55:59 +0100 Subject: [PATCH] msgbox: remove duplicated code Origin commit data ------------------ Branch: ni/coolstream Commit: https://github.com/neutrino-images/ni-neutrino/commit/c3ab1b91d8f8f37db510106cb321d5c9a1c8cde0 Author: Stefan Seyfried Date: 2017-03-04 (Sat, 04 Mar 2017) ------------------ No further description and justification available within origin commit message! ------------------ This commit was generated by Migit --- src/gui/widget/msgbox.cpp | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/src/gui/widget/msgbox.cpp b/src/gui/widget/msgbox.cpp index 12caa52ef..4bed64224 100644 --- a/src/gui/widget/msgbox.cpp +++ b/src/gui/widget/msgbox.cpp @@ -279,14 +279,11 @@ int CMsgBox::exec() //***navi buttons for button selection*** else if(msg == CRCInput::RC_right || msg == CRCInput::RC_left) { - if (msg == CRCInput::RC_right) { + if (msg == CRCInput::RC_right) ccw_footer->setSelectedButton(selected+1); - mb_show_button = ccw_footer->getSelectedButtonObject()->getButtonAlias(); - } - if (msg == CRCInput::RC_left) { + else ccw_footer->setSelectedButton(selected-1); - mb_show_button = ccw_footer->getSelectedButtonObject()->getButtonAlias(); - } + mb_show_button = ccw_footer->getSelectedButtonObject()->getButtonAlias(); selected = ccw_footer->getSelectedButton(); //***refresh buttons only if we have more than one button, this avoids unnecessary repaints with possible flicker effects***