Fixed setting the initial offset of the cursor in a list menu

This commit is contained in:
Klaus Schmidinger
2018-03-24 11:58:00 +01:00
parent 53aea17949
commit e1a71ce7cc
4 changed files with 11 additions and 5 deletions

View File

@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
* $Id: osdbase.c 4.4 2018/03/06 10:38:18 kls Exp $
* $Id: osdbase.c 4.5 2018/03/24 11:47:45 kls Exp $
*/
#include "osdbase.h"
@@ -330,7 +330,8 @@ void cOsdMenu::Clear(void)
{
if (marked >= 0)
SetStatus(NULL);
lastOffset = (current > first) ? current - first : 0;
if (current >= 0)
lastOffset = (current > first) ? current - first : 0;
first = 0;
current = marked = -1;
cList<cOsdItem>::Clear();