mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-08-29 16:31:05 +02:00
neutrino infomenu: add widget index
Replaces getSelect(), setSelect() in this context.
git-svn-id: file:///home/bas/coolstream_public_svn/THIRDPARTY/applications/neutrino-beta@1921 e54a6e83-5905-42d5-8d5c-058d10e6a962
Origin commit data
------------------
Commit: e663e1e0c5
Author: Thilo Graf <dbt@novatux.de>
Date: 2011-11-28 (Mon, 28 Nov 2011)
Origin message was:
------------------
*neutrino infomenu: add widget index
Replaces getSelect(), setSelect() in this context.
git-svn-id: file:///home/bas/coolstream_public_svn/THIRDPARTY/applications/neutrino-beta@1921 e54a6e83-5905-42d5-8d5c-058d10e6a962
This commit is contained in:
@@ -32,6 +32,7 @@
|
|||||||
|
|
||||||
#include <global.h>
|
#include <global.h>
|
||||||
#include <neutrino.h>
|
#include <neutrino.h>
|
||||||
|
#include <neutrino_menue.h>
|
||||||
|
|
||||||
#include "gui/info_menue.h"
|
#include "gui/info_menue.h"
|
||||||
#include "gui/imageinfo.h"
|
#include "gui/imageinfo.h"
|
||||||
@@ -43,7 +44,6 @@
|
|||||||
CInfoMenu::CInfoMenu()
|
CInfoMenu::CInfoMenu()
|
||||||
{
|
{
|
||||||
width = w_max (40, 10);
|
width = w_max (40, 10);
|
||||||
selected = -1;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
CInfoMenu::~CInfoMenu()
|
CInfoMenu::~CInfoMenu()
|
||||||
@@ -54,7 +54,6 @@ CInfoMenu::~CInfoMenu()
|
|||||||
|
|
||||||
int CInfoMenu::exec(CMenuTarget* parent, const std::string &/*actionKey*/)
|
int CInfoMenu::exec(CMenuTarget* parent, const std::string &/*actionKey*/)
|
||||||
{
|
{
|
||||||
printf("[neutrino] CInfoMenu %s: init...\n",__FUNCTION__);
|
|
||||||
int res = menu_return::RETURN_REPAINT;
|
int res = menu_return::RETURN_REPAINT;
|
||||||
|
|
||||||
if (parent != NULL)
|
if (parent != NULL)
|
||||||
@@ -67,10 +66,7 @@ int CInfoMenu::exec(CMenuTarget* parent, const std::string &/*actionKey*/)
|
|||||||
|
|
||||||
int CInfoMenu::showMenu()
|
int CInfoMenu::showMenu()
|
||||||
{
|
{
|
||||||
printf("[neutrino] CInfoMenu call %s...\n", __FUNCTION__);
|
CMenuWidget *info = new CMenuWidget(LOCALE_MESSAGEBOX_INFO, NEUTRINO_ICON_INFO, width, MN_WIDGET_ID_INFOMENUE);
|
||||||
|
|
||||||
CMenuWidget *info = new CMenuWidget(LOCALE_MESSAGEBOX_INFO, NEUTRINO_ICON_INFO);
|
|
||||||
info->setSelected(selected);
|
|
||||||
|
|
||||||
info->addIntroItems();
|
info->addIntroItems();
|
||||||
info->addItem(new CMenuForwarder(LOCALE_SERVICEMENU_IMAGEINFO, true, NULL, new CImageInfo(), NULL, CRCInput::RC_red, NEUTRINO_ICON_BUTTON_RED ), false);
|
info->addItem(new CMenuForwarder(LOCALE_SERVICEMENU_IMAGEINFO, true, NULL, new CImageInfo(), NULL, CRCInput::RC_red, NEUTRINO_ICON_BUTTON_RED ), false);
|
||||||
@@ -79,7 +75,6 @@ int CInfoMenu::showMenu()
|
|||||||
|
|
||||||
int res = info->exec(NULL, "");
|
int res = info->exec(NULL, "");
|
||||||
info->hide();
|
info->hide();
|
||||||
selected = info->getSelected();
|
|
||||||
delete info;
|
delete info;
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
|
@@ -38,7 +38,7 @@
|
|||||||
class CInfoMenu : public CMenuTarget
|
class CInfoMenu : public CMenuTarget
|
||||||
{
|
{
|
||||||
private:
|
private:
|
||||||
int width, selected;
|
int width;
|
||||||
|
|
||||||
int showMenu();
|
int showMenu();
|
||||||
|
|
||||||
|
@@ -119,6 +119,9 @@ enum MN_WIDGET_ID
|
|||||||
//cec setup
|
//cec setup
|
||||||
MN_WIDGET_ID_CEC,
|
MN_WIDGET_ID_CEC,
|
||||||
|
|
||||||
|
//infomenue
|
||||||
|
MN_WIDGET_ID_INFOMENUE,
|
||||||
|
|
||||||
MN_WIDGET_ID_MAX
|
MN_WIDGET_ID_MAX
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user