diff --git a/src/gui/vfd_setup.cpp b/src/gui/vfd_setup.cpp index a30df06a1..181b99207 100644 --- a/src/gui/vfd_setup.cpp +++ b/src/gui/vfd_setup.cpp @@ -57,6 +57,7 @@ CVfdSetup::CVfdSetup() hheight = g_Font[SNeutrinoSettings::FONT_TYPE_MENU_TITLE]->getHeight(); mheight = g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->getHeight(); height = hheight+13*mheight+ 10; + selected = -1; x = getScreenStartX (width); y = getScreenStartY (height); } @@ -105,6 +106,7 @@ void CVfdSetup::showSetup() { CMenuWidget *vfds = new CMenuWidget(LOCALE_MAINMENU_SETTINGS, NEUTRINO_ICON_LCD, width); vfds->addIntroItems(LOCALE_LCDMENU_HEAD); + vfds->setSelected(selected); CVfdControler* lcdsliders = new CVfdControler(LOCALE_LCDMENU_HEAD, NULL); bool vfd_enabled = (cs_get_revision() != 10); @@ -136,6 +138,7 @@ void CVfdSetup::showSetup() vfds->exec(NULL, ""); vfds->hide(); + selected = vfds->getSelected(); delete vfds; } diff --git a/src/gui/vfd_setup.h b/src/gui/vfd_setup.h index 0161254ce..ee090d7d7 100644 --- a/src/gui/vfd_setup.h +++ b/src/gui/vfd_setup.h @@ -43,7 +43,7 @@ CFrameBuffer *frameBuffer; - int x, y, width, height, hheight, mheight; + int x, y, width, height, hheight, mheight, selected; void hide(); void showSetup();