testimages verfügbar
http://dietmarw.trale.de
Benutzerabhängige MenüStruktur
-
- Interessierter
- Beiträge: 27
- Registriert: Donnerstag 29. Dezember 2005, 22:14
-
- Tuxboxer
- Beiträge: 2331
- Registriert: Donnerstag 24. März 2005, 21:52
ich hab nun auch den pincode aktiviert. es nimmt den selben code, wie im jugendschutz drin steht. einfach den vorhanden code durch den neuen codeabschnitt ersetzen.
Code: Alles auswählen
alt
mainSettings.addItem(new CMenuForwarder(LOCALE_USERLEVEL , true, NULL, &userSettings , NULL, CRCInput::RC_help, NEUTRINO_ICON_BUTTON_HELP_SMALL));
Code: Alles auswählen
neu
mainSettings.addItem(new CLockedMenuForwarder(LOCALE_USERLEVEL, g_settings.parentallock_pincode, true, true, NULL, &userSettings, NULL, CRCInput::RC_help, NEUTRINO_ICON_BUTTON_HELP_SMALL));
-
- Neugieriger
- Beiträge: 10
- Registriert: Mittwoch 19. April 2006, 11:28
A few small changes ?
menu seperator moved as in expert mode there were 2 ?
games not hidden in child mode
sleeptimer hidden unless in expert mode
sorry my bad german I use google translator
------------------------------------------------------------------
Einige kleine änderungen?
das Menü seperator, das wie in sachverständigen Modus dort verschoben wurde, waren 2?
Spiele versteckt nicht im Kindmodus sleeptimer versteckt, es sei denn im sachverständigen traurigen Modus
mein schlechter Deutscher ich google übersetzer benutzen
-------------------------------------------------------------------
menu seperator moved as in expert mode there were 2 ?
games not hidden in child mode
sleeptimer hidden unless in expert mode
sorry my bad german I use google translator
------------------------------------------------------------------
Einige kleine änderungen?
das Menü seperator, das wie in sachverständigen Modus dort verschoben wurde, waren 2?
Spiele versteckt nicht im Kindmodus sleeptimer versteckt, es sei denn im sachverständigen traurigen Modus
mein schlechter Deutscher ich google übersetzer benutzen
-------------------------------------------------------------------
Code: Alles auswählen
--- /home/ubuntu/orig-cvs/apps/tuxbox/neutrino/data/locale/deutsch.locale 2006-09-12 19:56:38.000000000 +0000
+++ /home/ubuntu/tuxbox-cvs/apps/tuxbox/neutrino/data/locale/deutsch.locale 2006-10-09 18:24:13.000000000 +0000
@@ -539,6 +539,7 @@
miscsettings.general Allgemein
miscsettings.head Diverse Einstellungen
miscsettings.infobar_sat_display Infobar Satellitenanzeige
+miscsettings.infobar_show Info bei EPG Änderung
miscsettings.shutdown_count Komplett ausschalten nach
miscsettings.shutdown_count_hint1 Zeit (in Minuten) nach dem vom Standbymodus
miscsettings.shutdown_count_hint2 komplett ausgeschaltet wird (0 = aus).
@@ -926,6 +927,7 @@
servicemenu.restart Neutrino neu starten
servicemenu.restart_failed Neustart von Neutrino schlug fehl.
servicemenu.restart_hint Neutrino wird neu gestartet...
+servicemenu.restart_hint2 Einige Einstellungen erfordern den Neutrino neustart.\nMöchten Sie Neutrino neu starten?
servicemenu.restart_refused_recording Aufnahme läuft. Restart nicht möglich.
servicemenu.scants Kanalsuche
servicemenu.ucodecheck UCodes überprüfen
@@ -1077,6 +1079,10 @@
ucodecheck.cam-alpha Cam-Alpha
ucodecheck.head UCode Überprüfung
ucodecheck.ucode UCode
+userlevel.menu Userlevel
+userlevel.0 Anfänger
+userlevel.1 Normaluser
+userlevel.2 Profi
ucodes.failure Achtung, die µCodes wurden NICHT gefunden!\n\nBitte per FTP (oder DBox-BootManager)\nuploaden, und die DBox neu starten!
videomenu.csync Sync.-Korrektur
videomenu.head Video-Einstellungen
diff -ur /home/ubuntu/orig-cvs/apps/tuxbox/neutrino/data/locale/english.locale /home/ubuntu/tuxbox-cvs/apps/tuxbox/neutrino/data/locale/english.locale
--- /home/ubuntu/orig-cvs/apps/tuxbox/neutrino/data/locale/english.locale 2006-09-14 21:20:11.000000000 +0000
+++ /home/ubuntu/tuxbox-cvs/apps/tuxbox/neutrino/data/locale/english.locale 2006-10-09 18:37:25.000000000 +0000
@@ -539,6 +539,7 @@
miscsettings.general General
miscsettings.head Misc settings
miscsettings.infobar_sat_display Satellite display on infobar
+miscsettings.infobar_show EPG Info
miscsettings.shutdown_count switch off after
miscsettings.shutdown_count_hint1 time (in minutes) to switch from standby
miscsettings.shutdown_count_hint2 to deep standby (0 = off).
@@ -926,6 +927,7 @@
servicemenu.restart Restart Neutrino
servicemenu.restart_failed Restarting Neutrino went wrong.
servicemenu.restart_hint Restarting Neutrino...
+servicemenu.restart_hint2 You need to restart Neutrino.\nWould you like to restart Neutrino?
servicemenu.restart_refused_recording Recording runs. Restart not possible.
servicemenu.scants Servicescan
servicemenu.ucodecheck Check ucodes
@@ -1077,6 +1079,10 @@
ucodecheck.cam-alpha Cam-Alpha
ucodecheck.head UCode check
ucodecheck.ucode UCode
+userlevel.menu Userlevel
+userlevel.0 Kids
+userlevel.1 Normal
+userlevel.2 Expert
ucodes.failure ATTENTION, µCodes could NOT be found!\n\nPlease upload them via FTP (or DBox-BootManager),\nthen restart your DBox!
videomenu.csync sync correction
videomenu.head Video Settings
diff -ur /home/ubuntu/orig-cvs/apps/tuxbox/neutrino/src/daemonc/remotecontrol.cpp /home/ubuntu/tuxbox-cvs/apps/tuxbox/neutrino/src/daemonc/remotecontrol.cpp
--- /home/ubuntu/orig-cvs/apps/tuxbox/neutrino/src/daemonc/remotecontrol.cpp 2006-05-19 21:28:17.000000000 +0000
+++ /home/ubuntu/tuxbox-cvs/apps/tuxbox/neutrino/src/daemonc/remotecontrol.cpp 2006-10-09 18:23:55.000000000 +0000
@@ -184,6 +184,18 @@
// APID Bearbeitung neu anstossen
has_unresolved_ctags = true;
+
+ //infobar anzeigen bei epg wechsel
+ if(g_settings.infobar_show == 1) //eine info mit nur den daten zum laufenden programm
+ {
+ //hier der funktionsaufruf fr das anzeigen einer
+ //abgespeckten infoanzeige
+ //g_InfoViewer->xxfunktionxx(true);
+ }
+ if(g_settings.infobar_show == 2) //nur die Infobar einblenden
+ {
+ g_RCInput->postMsg( NeutrinoMessages::SHOW_INFOBAR , 0 );
+ }
}
current_EPGid= info_CN->current_uniqueKey;
diff -ur /home/ubuntu/orig-cvs/apps/tuxbox/neutrino/src/driver/lcdd.cpp /home/ubuntu/tuxbox-cvs/apps/tuxbox/neutrino/src/driver/lcdd.cpp
--- /home/ubuntu/orig-cvs/apps/tuxbox/neutrino/src/driver/lcdd.cpp 2005-11-27 13:14:45.000000000 +0000
+++ /home/ubuntu/tuxbox-cvs/apps/tuxbox/neutrino/src/driver/lcdd.cpp 2006-10-09 18:24:13.000000000 +0000
@@ -47,6 +47,11 @@
CLCD::CLCD()
: configfile('\t')
{
+ m_progressShowEscape = 0;
+ m_progressHeaderGlobal = "";
+ m_progressHeaderLocal = "";
+ m_progressGlobal = 0;
+ m_progressLocal = 0;
}
CLCD* CLCD::getInstance()
@@ -595,6 +600,11 @@
showTime(); /* "showclock = true;" implies that "showTime();" does a "displayUpdate();" */
/* "showTime()" clears the whole lcd in MODE_STANDBY */
break;
+ case MODE_UPDATEPROZESS:
+ showclock = false;
+ display.load_screen(&(background[BACKGROUND_SETUP]));
+ showUpdateProzess();
+ break;
}
wake_up();
}
@@ -704,3 +714,77 @@
{
display.pause();
}
+
+/*############## Updateanzeige auf LCD ########################*/
+#define PROG2_LOCAL_POS_X 10
+#define PROG2_LOCAL_POS_Y 24
+#define PROG2_LOCAL_POS_WIDTH 100
+#define PROG2_LOCAL_POS_HEIGTH 10
+
+#define PROG2_GLOB_POS_X 10
+#define PROG2_GLOB_POS_Y 37
+#define PROG2_GLOB_POS_WIDTH PROG2_LOCAL_POS_WIDTH
+#define PROG2_GLOB_POS_HEIGTH PROG2_LOCAL_POS_HEIGTH
+
+void CLCD::showUpdateProzess(int local,const char * const text_local ,int global ,const char * const text_global ,int show_escape )
+{
+ if(text_local != NULL)
+ m_progressHeaderLocal = text_local;
+ if(text_global != NULL)
+ m_progressHeaderGlobal = text_global;
+ if(global >= 0)
+ {
+ if(global > 100)
+ m_progressGlobal =100;
+ else
+ m_progressGlobal = global;
+ }
+ if(local >= 0)
+ {
+ if(local > 100)
+ m_progressLocal =100;
+ else
+ m_progressLocal = local;
+ }
+ if(show_escape != -1)
+ m_progressShowEscape = show_escape;
+
+ if (mode != MODE_UPDATEPROZESS)
+ return;
+
+ // Clear Display
+ display.draw_fill_rect (0,12,120,64, CLCDDisplay::PIXEL_OFF);
+
+ // paint local header
+ int width = fonts.menu->getRenderWidth(m_progressHeaderLocal.c_str(),true);
+ if(width > 100)
+ width = 100;
+ int start_pos = (120-width) /2;
+ fonts.menu->RenderString(start_pos, PROG2_LOCAL_POS_Y-3, width+10, m_progressHeaderLocal.c_str(), CLCDDisplay::PIXEL_ON,0,true);
+
+ // paint global bar
+ int marker_length = (PROG2_LOCAL_POS_WIDTH * m_progressLocal)/100;
+
+ display.draw_fill_rect (PROG2_LOCAL_POS_X, PROG2_LOCAL_POS_Y,PROG2_LOCAL_POS_X+PROG2_LOCAL_POS_WIDTH, PROG2_LOCAL_POS_Y+PROG2_LOCAL_POS_HEIGTH,CLCDDisplay::PIXEL_ON);
+ display.draw_fill_rect (PROG2_LOCAL_POS_X+1+marker_length, PROG2_LOCAL_POS_Y+1, PROG2_LOCAL_POS_X+PROG2_LOCAL_POS_WIDTH-1, PROG2_LOCAL_POS_Y+PROG2_LOCAL_POS_HEIGTH-1, CLCDDisplay::PIXEL_OFF);
+
+ // paint global header
+ width = fonts.menu->getRenderWidth(m_progressHeaderGlobal.c_str(),true);
+ if(width > 100)
+ width = 100;
+ start_pos = (120-width) /2;
+ fonts.menu->RenderString(start_pos, PROG2_GLOB_POS_Y + PROG2_GLOB_POS_HEIGTH +10 , width+10, m_progressHeaderGlobal.c_str(), CLCDDisplay::PIXEL_ON,0,true);
+
+ // paint global bar
+ marker_length = (PROG2_GLOB_POS_WIDTH * m_progressGlobal)/100;
+
+ display.draw_fill_rect (PROG2_GLOB_POS_X, PROG2_GLOB_POS_Y, PROG2_GLOB_POS_X+PROG2_GLOB_POS_WIDTH, PROG2_GLOB_POS_Y+PROG2_GLOB_POS_HEIGTH, CLCDDisplay::PIXEL_ON);
+ display.draw_fill_rect (PROG2_GLOB_POS_X+1+marker_length, PROG2_GLOB_POS_Y+1, PROG2_GLOB_POS_X+PROG2_GLOB_POS_WIDTH-1, PROG2_GLOB_POS_Y+PROG2_GLOB_POS_HEIGTH-1, CLCDDisplay::PIXEL_OFF);
+
+ // paint foot
+ if(m_progressShowEscape == true)
+ {
+ fonts.menu->RenderString(90, 64, 40, "Home", CLCDDisplay::PIXEL_ON);
+ }
+ displayUpdate();
+}
diff -ur /home/ubuntu/orig-cvs/apps/tuxbox/neutrino/src/driver/lcdd.h /home/ubuntu/tuxbox-cvs/apps/tuxbox/neutrino/src/driver/lcdd.h
--- /home/ubuntu/orig-cvs/apps/tuxbox/neutrino/src/driver/lcdd.h 2005-03-28 16:52:32.000000000 +0000
+++ /home/ubuntu/tuxbox-cvs/apps/tuxbox/neutrino/src/driver/lcdd.h 2006-10-09 18:24:13.000000000 +0000
@@ -45,7 +45,8 @@
MODE_SHUTDOWN,
MODE_STANDBY,
MODE_MENU_UTF8,
- MODE_AUDIO
+ MODE_AUDIO,
+ MODE_UPDATEPROZESS
};
enum AUDIOMODES
{
@@ -99,6 +100,11 @@
const char * fontfile3=NULL, const char * fontname3=NULL);
void setlcdparameter(int dimm, int contrast, int power, int inverse);
void displayUpdate();
+ bool m_progressShowEscape;
+ std::string m_progressHeaderGlobal;
+ std::string m_progressHeaderLocal;
+ int m_progressGlobal;
+ int m_progressLocal;
public:
void setlcdparameter(void);
@@ -144,6 +150,7 @@
void resume();
void pause();
+ void showUpdateProzess(int local = -1,const char * const text_local = NULL,int global = -1,const char * const text_global = NULL,int show_escape = -1);
};
diff -ur /home/ubuntu/orig-cvs/apps/tuxbox/neutrino/src/gui/update.cpp /home/ubuntu/tuxbox-cvs/apps/tuxbox/neutrino/src/gui/update.cpp
--- /home/ubuntu/orig-cvs/apps/tuxbox/neutrino/src/gui/update.cpp 2006-05-06 09:09:44.000000000 +0000
+++ /home/ubuntu/tuxbox-cvs/apps/tuxbox/neutrino/src/gui/update.cpp 2006-10-09 18:24:13.000000000 +0000
@@ -360,6 +360,11 @@
hide();
return menu_return::RETURN_REPAINT;
}
+ std::string text_global ="Neutrino Akt.";
+ std::string text_local ="Teste";
+ CLCD::getInstance()->showUpdateProzess(0,text_local.c_str(),0,text_global.c_str());
+ CLCD::getInstance()->setMode(CLCD::MODE_UPDATEPROZESS);
+
showGlobalStatus(19);
paint();
showGlobalStatus(20);
@@ -499,6 +504,12 @@
filename = "/tmp/flashimage.img"; // US-ASCII (subset of UTF-8 and ISO8859-1)
readmtd = CMTDInfo::getInstance()->findMTDNumberFromDescription(MTD_TEXT_OF_WHOLE_IMAGE); //MTD_OF_WHOLE_IMAGE;
}
+
+ std::string text_global ="Neutrino";
+ std::string text_local ="Lesen";
+ CLCD::getInstance()->showUpdateProzess(0,text_local.c_str(),0,text_global.c_str());
+ CLCD::getInstance()->setMode(CLCD::MODE_UPDATEPROZESS);
+
setTitle(LOCALE_FLASHUPDATE_TITLEREADFLASH);
paint();
showGlobalStatus(0);
@@ -535,6 +546,11 @@
if (ShowMsgUTF(LOCALE_MESSAGEBOX_INFO, message, CMessageBox::mbrNo, CMessageBox::mbYes | CMessageBox::mbNo, "softupdate.raw") != CMessageBox::mbrYes) // UTF-8
return;
+ std::string text_global ="Neutrino Akt.";
+ std::string text_local ="Teste";
+ CLCD::getInstance()->showUpdateProzess(0,text_local.c_str(),0,text_global.c_str());
+ CLCD::getInstance()->setMode(CLCD::MODE_UPDATEPROZESS);
+
setTitle(LOCALE_FLASHUPDATE_TITLEWRITEFLASH);
paint();
showGlobalStatus(0);
diff -ur /home/ubuntu/orig-cvs/apps/tuxbox/neutrino/src/gui/widget/progresswindow.cpp /home/ubuntu/tuxbox-cvs/apps/tuxbox/neutrino/src/gui/widget/progresswindow.cpp
--- /home/ubuntu/orig-cvs/apps/tuxbox/neutrino/src/gui/widget/progresswindow.cpp 2004-06-06 12:19:38.000000000 +0000
+++ /home/ubuntu/tuxbox-cvs/apps/tuxbox/neutrino/src/gui/widget/progresswindow.cpp 2006-10-09 18:24:13.000000000 +0000
@@ -56,6 +56,8 @@
void CProgressWindow::setTitle(const neutrino_locale_t title)
{
caption = title;
+
+ CLCD::getInstance()->showUpdateProzess(-1,NULL,-1,g_Locale->getText(caption)); // set global text in LCD
}
@@ -79,6 +81,8 @@
}
//hintergrund
frameBuffer->paintBox(pos, globalstatusY, x+width-10, globalstatusY+10, COL_MENUCONTENT_PLUS_2);
+
+ CLCD::getInstance()->showUpdateProzess(-1,NULL,global_progress);
}
void CProgressWindow::showLocalStatus(const unsigned int prog)
@@ -101,6 +105,8 @@
}
//hintergrund
frameBuffer->paintBox(pos, localstatusY, x+width-10, localstatusY+10, COL_MENUCONTENT_PLUS_2);
+
+ CLCD::getInstance()->showUpdateProzess(local_progress);
}
void CProgressWindow::showStatusMessageUTF(const std::string & text)
@@ -108,6 +114,8 @@
statusText = text;
frameBuffer->paintBox(x, statusTextY-mheight, x+width, statusTextY, COL_MENUCONTENT_PLUS_0);
g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->RenderString(x+10, statusTextY, width-20, text, COL_MENUCONTENT, 0, true); // UTF-8
+
+ CLCD::getInstance()->showUpdateProzess(-1,text.c_str()); // set local text in LCD
}
diff -ur /home/ubuntu/orig-cvs/apps/tuxbox/neutrino/src/neutrino.cpp /home/ubuntu/tuxbox-cvs/apps/tuxbox/neutrino/src/neutrino.cpp
--- /home/ubuntu/orig-cvs/apps/tuxbox/neutrino/src/neutrino.cpp 2006-09-06 17:24:43.000000000 +0000
+++ /home/ubuntu/tuxbox-cvs/apps/tuxbox/neutrino/src/neutrino.cpp 2006-10-09 23:16:15.000000000 +0000
@@ -581,6 +581,10 @@
g_settings.tuxtxt_cache = configfile.getBool("tuxtxt_cache" , false );
#endif
g_settings.virtual_zap_mode = configfile.getBool("virtual_zap_mode" , false);
+ g_settings.infobar_show = configfile.getBool("infobar_show" , false);
+
+ //user
+ g_settings.userlevel = configfile.getInt32( "userlevel" , 2 );
//audio
g_settings.audio_AnalogMode = configfile.getInt32( "audio_AnalogMode", 0 );
@@ -870,6 +874,9 @@
}
g_settings.uboot_console_bak = g_settings.uboot_console;
}
+
+ //user
+ old_userlevel = g_settings.userlevel;
return erg;
}
@@ -948,6 +955,10 @@
configfile.setBool("tuxtxt_cache" , g_settings.tuxtxt_cache);
#endif
configfile.setBool("virtual_zap_mode" , g_settings.virtual_zap_mode);
+ configfile.setBool("infobar_show" , g_settings.infobar_show);
+
+ //user
+ configfile.setInt32("userlevel" , g_settings.userlevel);
//audio
configfile.setInt32( "audio_AnalogMode", g_settings.audio_AnalogMode );
@@ -1179,6 +1190,24 @@
dprintf(DEBUG_INFO, "saving neutrino txt-config\n");
configfile.saveConfig(NEUTRINO_SETTINGS_FILE);
}
+
+ //user
+ if(old_userlevel != g_settings.userlevel)
+ neutrinoRestart();
+}
+
+void CNeutrinoApp::neutrinoRestart()
+{
+ if (ShowLocalizedMessage(LOCALE_MESSAGEBOX_INFO, LOCALE_SERVICEMENU_RESTART_HINT2, CMessageBox::mbrNo, CMessageBox::mbYes | CMessageBox::mbNo, "softupdate.raw") != CMessageBox::mbrNo)
+ {
+ CHintBox * hintBox = new CHintBox(LOCALE_MESSAGEBOX_INFO, g_Locale->getText(LOCALE_SERVICEMENU_RESTART_HINT));
+ hintBox->paint();
+ execvp(global_argv[0], global_argv); // no return if successful
+ DisplayErrorMessage(g_Locale->getText(LOCALE_SERVICEMENU_RESTART_FAILED));
+
+ hintBox->hide();
+ delete hintBox;
+ }
}
/**************************************************************************************
@@ -1438,6 +1467,7 @@
void CNeutrinoApp::InitMainMenu(CMenuWidget &mainMenu,
CMenuWidget &mainSettings,
+ CMenuWidget &userSettings,
CMenuWidget &audioSettings,
CMenuWidget &parentallockSettings,
CMenuWidget &networkSettings,
@@ -1461,13 +1491,20 @@
mainMenu.addItem(new CMenuForwarder(LOCALE_MAINMENU_TVMODE, true, NULL, this, "tv", CRCInput::RC_red, NEUTRINO_ICON_BUTTON_RED), true);
mainMenu.addItem(new CMenuForwarder(LOCALE_MAINMENU_RADIOMODE, true, NULL, this, "radio", CRCInput::RC_green, NEUTRINO_ICON_BUTTON_GREEN));
mainMenu.addItem(new CMenuForwarder(LOCALE_MAINMENU_SCARTMODE, true, NULL, this, "scart", CRCInput::RC_yellow, NEUTRINO_ICON_BUTTON_YELLOW));
- mainMenu.addItem(new CMenuForwarder(LOCALE_MAINMENU_GAMES, true, NULL, new CPluginList(LOCALE_MAINMENU_GAMES,CPlugins::P_TYPE_GAME), "", CRCInput::RC_blue, NEUTRINO_ICON_BUTTON_BLUE));
+
+ if (g_PluginList->hasPlugin(CPlugins::P_TYPE_GAME))
+ mainMenu.addItem(new CMenuForwarder(LOCALE_MAINMENU_GAMES, true, NULL, new CPluginList(LOCALE_MAINMENU_GAMES,CPlugins::P_TYPE_GAME), "", CRCInput::RC_blue, NEUTRINO_ICON_BUTTON_BLUE));
+
+ int shortcut = 1;
+
+ if(g_settings.userlevel > 0 ) { //Start userlevel 1+2
+ //Menüpunkt Spiele nur da, wenn welche installiert.
mainMenu.addItem(GenericMenuSeparatorLine);
- mainMenu.addItem(new CMenuForwarder(LOCALE_MAINMENU_AUDIOPLAYER, true, NULL, new CAudioPlayerGui(), NULL, CRCInput::RC_1));
+ mainMenu.addItem(new CMenuForwarder(LOCALE_MAINMENU_AUDIOPLAYER, true, NULL, new CAudioPlayerGui(), NULL, CRCInput::convertDigitToKey(shortcut++)));
#if HAVE_DVB_API_VERSION >= 3
//mainMenu.addItem(new CMenuForwarder(LOCALE_MAINMENU_MOVIEPLAYER, true, NULL, new CMoviePlayerGui()));
- mainMenu.addItem(new CMenuForwarder(LOCALE_MAINMENU_MOVIEPLAYER, true, NULL, &moviePlayer, NULL, CRCInput::RC_2));
+ mainMenu.addItem(new CMenuForwarder(LOCALE_MAINMENU_MOVIEPLAYER, true, NULL, &moviePlayer, NULL, CRCInput::convertDigitToKey(shortcut++)));
moviePlayer.addItem(GenericMenuSeparator);
moviePlayer.addItem(GenericMenuBack);
@@ -1490,11 +1527,12 @@
moviePlayer.addItem(new CMenuForwarder(LOCALE_NFSMENU_HEAD, true, NULL, new CNFSSmallMenu(), NULL, CRCInput::RC_setup, NEUTRINO_ICON_BUTTON_DBOX_SMALL));
#endif
- mainMenu.addItem(new CMenuForwarder(LOCALE_MAINMENU_PICTUREVIEWER, true, NULL, new CPictureViewerGui(), NULL, CRCInput::RC_3));
- int shortcut = 4;
+ mainMenu.addItem(new CMenuForwarder(LOCALE_MAINMENU_PICTUREVIEWER, true, NULL, new CPictureViewerGui(), NULL, CRCInput::convertDigitToKey(shortcut++)));
+ //int shortcut = 4;
if (g_PluginList->hasPlugin(CPlugins::P_TYPE_SCRIPT))
mainMenu.addItem(new CMenuForwarder(LOCALE_MAINMENU_SCRIPTS, true, NULL, new CPluginList(LOCALE_MAINMENU_SCRIPTS,CPlugins::P_TYPE_SCRIPT), "",
CRCInput::convertDigitToKey(shortcut++)));
+ } //End userlevel 1+2
mainMenu.addItem(GenericMenuSeparatorLine);
mainMenu.addItem(new CMenuForwarder(LOCALE_MAINMENU_SETTINGS, true, NULL, &mainSettings, NULL,
@@ -1502,9 +1540,10 @@
mainMenu.addItem(new CLockedMenuForwarder(LOCALE_MAINMENU_SERVICE, g_settings.parentallock_pincode, false, true, NULL, &service, NULL,
CRCInput::convertDigitToKey(shortcut++)));
mainMenu.addItem(GenericMenuSeparatorLine);
-
+ if(g_settings.userlevel > 1 ) { //Start userlevel 2
mainMenu.addItem(new CMenuForwarder(LOCALE_MAINMENU_SLEEPTIMER, true, NULL, new CSleepTimerWidget, NULL,
CRCInput::convertDigitToKey(shortcut++)));
+ } //End userlevel 2
mainMenu.addItem(new CMenuForwarder(LOCALE_MAINMENU_REBOOT, true, NULL, this, "reboot",
CRCInput::convertDigitToKey(shortcut++)));
mainMenu.addItem(new CMenuForwarder(LOCALE_MAINMENU_SHUTDOWN, true, NULL, this, "shutdown", CRCInput::RC_standby, "power.raw"));
@@ -1514,8 +1553,10 @@
mainSettings.addItem(GenericMenuSeparatorLine);
mainSettings.addItem(new CMenuForwarder(LOCALE_MAINSETTINGS_SAVESETTINGSNOW, true, NULL, this, "savesettings", CRCInput::RC_red, NEUTRINO_ICON_BUTTON_RED));
mainSettings.addItem(GenericMenuSeparatorLine);
+ mainSettings.addItem(new CMenuForwarder(LOCALE_USERLEVEL , true, NULL, &userSettings , NULL, CRCInput::RC_help, NEUTRINO_ICON_BUTTON_HELP_SMALL));
mainSettings.addItem(new CMenuForwarder(LOCALE_MAINSETTINGS_VIDEO , true, NULL, &videoSettings , NULL, CRCInput::RC_1));
mainSettings.addItem(new CMenuForwarder(LOCALE_MAINSETTINGS_AUDIO , true, NULL, &audioSettings , NULL, CRCInput::RC_2));
+ if(g_settings.userlevel > 1 ) { //Start userlevel 2!
if(g_settings.parentallock_prompt)
mainSettings.addItem(new CLockedMenuForwarder(LOCALE_PARENTALLOCK_PARENTALLOCK, g_settings.parentallock_pincode, true, true, NULL, &parentallockSettings, NULL, CRCInput::RC_3));
else
@@ -1530,6 +1571,7 @@
mainSettings.addItem(new CMenuForwarder(LOCALE_AUDIOPLAYERPICSETTINGS_GENERAL , true, NULL, &audiopl_picSettings , NULL, CRCInput::RC_blue, NEUTRINO_ICON_BUTTON_BLUE));
mainSettings.addItem(new CMenuForwarder(LOCALE_MAINSETTINGS_DRIVER , true, NULL, &driverSettings , NULL, CRCInput::RC_green, NEUTRINO_ICON_BUTTON_GREEN));
mainSettings.addItem(new CMenuForwarder(LOCALE_MAINSETTINGS_MISC , true, NULL, &miscSettings , NULL, CRCInput::RC_yellow, NEUTRINO_ICON_BUTTON_YELLOW ));
+ } //End userlevel 2!
}
#define SCANTS_BOUQUET_OPTION_COUNT 5
@@ -1940,6 +1982,14 @@
{ 3 , LOCALE_SETTINGS_POS_BOTTOM_RIGHT }
};
+#define INFOBAR_SHOW_OPTIONS_COUNT 3
+const CMenuOptionChooser::keyval INFOBAR_SHOW_OPTIONS[INFOBAR_SHOW_OPTIONS_COUNT]=
+{
+ { 0 , LOCALE_OPTIONS_OFF },
+ { 1 , LOCALE_PICTUREVIEWER_RESIZE_SIMPLE },
+ { 2 , LOCALE_PICTUREVIEWER_RESIZE_COLOR_AVERAGE }
+};
+
void CNeutrinoApp::InitMiscSettings(CMenuWidget &miscSettings)
{
dprintf(DEBUG_DEBUG, "init miscsettings\n");
@@ -1969,6 +2019,7 @@
#endif
miscSettings.addItem(new CMenuOptionChooser(LOCALE_MISCSETTINGS_VIRTUAL_ZAP_MODE, &g_settings.virtual_zap_mode, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF0_ON1_OPTION_COUNT, true));
+ miscSettings.addItem(new CMenuOptionChooser(LOCALE_MISCSETTINGS_INFOBAR_SHOW, &g_settings.infobar_show, INFOBAR_SHOW_OPTIONS, INFOBAR_SHOW_OPTIONS_COUNT, true));
miscSettings.addItem(new CMenuSeparator(CMenuSeparator::LINE | CMenuSeparator::STRING, LOCALE_MISCSETTINGS_EPG_HEAD));
CStringInput * miscSettings_epg_cache = new CStringInput(LOCALE_MISCSETTINGS_EPG_CACHE, g_settings.epg_cache, 2,LOCALE_MISCSETTINGS_EPG_CACHE_HINT1, LOCALE_MISCSETTINGS_EPG_CACHE_HINT2 , "0123456789 ");
@@ -2730,6 +2781,23 @@
fontSettings.addItem(new CMenuForwarder(LOCALE_OPTIONS_DEFAULT, true, NULL, this, font_sizes_groups[5].actionkey));
}
+#define USER_OPTION_COUNT 3
+const CMenuOptionChooser::keyval USER_OPTIONS[USER_OPTION_COUNT] =
+{
+ { 0, LOCALE_USERLEVEL_0 },
+ { 1, LOCALE_USERLEVEL_1 },
+ { 2, LOCALE_USERLEVEL_2 }
+};
+
+void CNeutrinoApp::InitUserSettings(CMenuWidget &userSettings )
+{
+ userSettings.addItem(GenericMenuSeparator);
+ userSettings.addItem(GenericMenuBack);
+ userSettings.addItem(GenericMenuSeparatorLine);
+ userSettings.addItem(new CMenuOptionChooser(LOCALE_USERLEVEL, &g_settings.userlevel, USER_OPTIONS, USER_OPTION_COUNT, true));
+
+}
+
void CNeutrinoApp::InitColorSettings(CMenuWidget &colorSettings, CMenuWidget &fontSettings )
{
colorSettings.addItem(GenericMenuSeparator);
@@ -3361,7 +3429,7 @@
CLocaleManager::loadLocale_ret_t loadLocale_ret = g_Locale->loadLocale(g_settings.language);
if (loadLocale_ret == CLocaleManager::NO_SUCH_LOCALE)
{
- strcpy(g_settings.language, "deutsch"); // Fallback if rest fails
+ strcpy(g_settings.language, "english"); // Fallback if rest fails
FILE *f = fopen(NEUTRINO_DEFAULTLOCALE_FILE, "r");
if (f)
{
@@ -3450,6 +3518,7 @@
CMenuWidget mainSettings (LOCALE_MAINSETTINGS_HEAD , NEUTRINO_ICON_SETTINGS);
CMenuWidget languageSettings (LOCALE_LANGUAGESETUP_HEAD , "language.raw" );
CVideoSettings videoSettings ;
+ CMenuWidget userSettings (LOCALE_USERLEVEL , "lock.raw" );
CMenuWidget audioSettings (LOCALE_AUDIOMENU_HEAD , "audio.raw" );
CMenuWidget parentallockSettings(LOCALE_PARENTALLOCK_PARENTALLOCK , "lock.raw" , 500);
CMenuWidget networkSettings (LOCALE_NETWORKMENU_HEAD , "network.raw" , 430);
@@ -3468,6 +3537,7 @@
InitMainMenu( mainMenu,
mainSettings,
+ userSettings,
audioSettings,
parentallockSettings,
networkSettings,
@@ -3628,6 +3698,9 @@
//keySettings
InitKeySettings(keySettings);
+
+ //user Setup
+ InitUserSettings(userSettings);
AudioMute( g_Controld->getMute((CControld::volume_type)g_settings.audio_avs_Control), true );
diff -ur /home/ubuntu/orig-cvs/apps/tuxbox/neutrino/src/neutrino.h /home/ubuntu/tuxbox-cvs/apps/tuxbox/neutrino/src/neutrino.h
--- /home/ubuntu/orig-cvs/apps/tuxbox/neutrino/src/neutrino.h 2006-08-01 21:36:05.000000000 +0000
+++ /home/ubuntu/tuxbox-cvs/apps/tuxbox/neutrino/src/neutrino.h 2006-10-09 18:24:13.000000000 +0000
@@ -161,6 +161,7 @@
void InitKeySettings(CMenuWidget &);
void InitServiceSettings(CMenuWidget &, CMenuWidget &);
void InitColorSettingsMenuColors(CMenuWidget &);
+ void InitUserSettings(CMenuWidget &userSettings);
void InitAudioSettings(CMenuWidget &audioSettings, CAudioSetupNotifier* audioSetupNotifier);
void InitColorSettings(CMenuWidget &, CMenuWidget &);
void InitLanguageSettings(CMenuWidget &);
@@ -181,6 +182,7 @@
void InitParentalLockSettings(CMenuWidget &);
void CNeutrinoApp::InitMainMenu(CMenuWidget &mainMenu,
CMenuWidget &mainSettings,
+ CMenuWidget &userSettings,
CMenuWidget &audioSettings,
CMenuWidget &parentallockSettings,
CMenuWidget &networkSettings,
@@ -232,6 +234,9 @@
int getLastMode() {return lastMode;}
bool isMuted() {return current_muted;}
int recordingstatus;
+
+ int old_userlevel;
+ void neutrinoRestart();
};
diff -ur /home/ubuntu/orig-cvs/apps/tuxbox/neutrino/src/system/locals.h /home/ubuntu/tuxbox-cvs/apps/tuxbox/neutrino/src/system/locals.h
--- /home/ubuntu/orig-cvs/apps/tuxbox/neutrino/src/system/locals.h 2006-09-11 21:11:35.000000000 +0000
+++ /home/ubuntu/tuxbox-cvs/apps/tuxbox/neutrino/src/system/locals.h 2006-10-09 18:24:13.000000000 +0000
@@ -566,6 +566,7 @@
LOCALE_MISCSETTINGS_GENERAL,
LOCALE_MISCSETTINGS_HEAD,
LOCALE_MISCSETTINGS_INFOBAR_SAT_DISPLAY,
+ LOCALE_MISCSETTINGS_INFOBAR_SHOW,
LOCALE_MISCSETTINGS_SHUTDOWN_COUNT,
LOCALE_MISCSETTINGS_SHUTDOWN_COUNT_HINT1,
LOCALE_MISCSETTINGS_SHUTDOWN_COUNT_HINT2,
@@ -953,6 +954,7 @@
LOCALE_SERVICEMENU_RESTART,
LOCALE_SERVICEMENU_RESTART_FAILED,
LOCALE_SERVICEMENU_RESTART_HINT,
+ LOCALE_SERVICEMENU_RESTART_HINT2,
LOCALE_SERVICEMENU_RESTART_REFUSED_RECORDING,
LOCALE_SERVICEMENU_SCANTS,
LOCALE_SERVICEMENU_UCODECHECK,
@@ -1105,6 +1107,10 @@
LOCALE_UCODECHECK_HEAD,
LOCALE_UCODECHECK_UCODE,
LOCALE_UCODES_FAILURE,
+ LOCALE_USERLEVEL,
+ LOCALE_USERLEVEL_0,
+ LOCALE_USERLEVEL_1,
+ LOCALE_USERLEVEL_2,
LOCALE_VIDEOMENU_CSYNC,
LOCALE_VIDEOMENU_HEAD,
LOCALE_VIDEOMENU_OSD,
diff -ur /home/ubuntu/orig-cvs/apps/tuxbox/neutrino/src/system/locals_intern.h /home/ubuntu/tuxbox-cvs/apps/tuxbox/neutrino/src/system/locals_intern.h
--- /home/ubuntu/orig-cvs/apps/tuxbox/neutrino/src/system/locals_intern.h 2006-09-11 21:11:35.000000000 +0000
+++ /home/ubuntu/tuxbox-cvs/apps/tuxbox/neutrino/src/system/locals_intern.h 2006-10-09 18:24:13.000000000 +0000
@@ -566,6 +566,7 @@
"miscsettings.general",
"miscsettings.head",
"miscsettings.infobar_sat_display",
+ "miscsettings.infobar_show",
"miscsettings.shutdown_count",
"miscsettings.shutdown_count_hint1",
"miscsettings.shutdown_count_hint2",
@@ -953,6 +954,7 @@
"servicemenu.restart",
"servicemenu.restart_failed",
"servicemenu.restart_hint",
+ "servicemenu.restart_hint2",
"servicemenu.restart_refused_recording",
"servicemenu.scants",
"servicemenu.ucodecheck",
@@ -1105,6 +1107,10 @@
"ucodecheck.head",
"ucodecheck.ucode",
"ucodes.failure",
+ "userlevel.menu",
+ "userlevel.0",
+ "userlevel.1",
+ "userlevel.2",
"videomenu.csync",
"videomenu.head",
"videomenu.osd",
diff -ur /home/ubuntu/orig-cvs/apps/tuxbox/neutrino/src/system/settings.h /home/ubuntu/tuxbox-cvs/apps/tuxbox/neutrino/src/system/settings.h
--- /home/ubuntu/orig-cvs/apps/tuxbox/neutrino/src/system/settings.h 2006-08-28 00:27:57.000000000 +0000
+++ /home/ubuntu/tuxbox-cvs/apps/tuxbox/neutrino/src/system/settings.h 2006-10-09 18:24:13.000000000 +0000
@@ -60,11 +60,15 @@
int tuxtxt_cache;
#endif
int virtual_zap_mode;
+ int infobar_show;
// EPG
char epg_cache[3];
char epg_old_events[3];
char epg_max_events[6];
+
+ //user
+ int userlevel;
//audio
int audio_AnalogMode;
-
- Tuxboxer
- Beiträge: 2331
- Registriert: Donnerstag 24. März 2005, 21:52
was bei bestimmten einstellungen ausgeklammert wird, muss ja erst mal festgelegt werden. jeder imagebauer hat da so seine vorlieben und ideen.
ich hab auch noch nen fehler gefunden.
nfobar_show ist ja als bool deklariert. das ist falsch. das sollte als int deklariert werden, da ja mehr optionen als 0 und 1 nötig sind
ich hab auch noch nen fehler gefunden.
nfobar_show ist ja als bool deklariert. das ist falsch. das sollte als int deklariert werden, da ja mehr optionen als 0 und 1 nötig sind
-
- Moderator english
- Beiträge: 2458
- Registriert: Donnerstag 20. Dezember 2001, 00:00
What we delcare as settings that should not show up needs to be clarified first . Every Imagecreator has his/her own choice and ideas.mb405 hat geschrieben:was bei bestimmten einstellungen ausgeklammert wird, muss ja erst mal festgelegt werden. jeder imagebauer hat da so seine vorlieben und ideen.
ich hab auch noch nen fehler gefunden.
nfobar_show ist ja als bool deklariert. das ist falsch. das sollte als int deklariert werden, da ja mehr optionen als 0 und 1 nötig sind
One more fault is the nfobar_show as it should be bool as it has more options than 1 and 2.
THX&Danke ;-)