mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-28 16:01:20 +02:00
Messages: try to fix API message handling
Passed timeout for messeages an popup's fired by yWeb API was not really ok. For popups now we have a setting with default value of 6 seconds timeout Popups fired with ShowHint() use this as default. Value of 0 and -1 are ignored. Messages fired with ShowMsg() should be fixed and interpret value 0 or -1 as no timeout and will remain on the screen.
This commit is contained in:
@@ -236,6 +236,9 @@ int CMsgBox::exec()
|
||||
|
||||
ccw_footer->getSelectedButtonObject()->setButtonAlias(mb_show_button);
|
||||
int selected = ccw_footer->getSelectedButton();
|
||||
if (timeout == NO_TIMEOUT)
|
||||
timeout = 0;
|
||||
|
||||
uint64_t timeoutEnd = CRCInput::calcTimeoutEnd(timeout);
|
||||
|
||||
if (timeout > 0)
|
||||
@@ -432,7 +435,7 @@ int ShowMsg2UTF( const neutrino_locale_t Title,
|
||||
const int& Text_mode,
|
||||
fb_pixel_t color_frame)
|
||||
{
|
||||
int result = ShowMsg( g_Locale->getText(Title), Text, Default, ShowButtons, Icon, Width, Timeout, returnDefaultOnTimeout, Text_mode, color_frame);
|
||||
int result = ShowMsg2UTF(g_Locale->getText(Title), Text, Default, ShowButtons, Icon, Width, Timeout, returnDefaultOnTimeout, Text_mode, color_frame);
|
||||
|
||||
return (result);
|
||||
}
|
||||
|
Reference in New Issue
Block a user