mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-29 16:31:11 +02:00
*neutrino audio_setup: optional wizard mode functionality added
git-svn-id: file:///home/bas/coolstream_public_svn/THIRDPARTY/applications/neutrino-experimental@981 e54a6e83-5905-42d5-8d5c-058d10e6a962
This commit is contained in:
@@ -48,10 +48,12 @@
|
||||
|
||||
extern CAudioSetupNotifier * audioSetupNotifier;
|
||||
|
||||
CAudioSetup::CAudioSetup()
|
||||
CAudioSetup::CAudioSetup(bool wizard_mode)
|
||||
{
|
||||
frameBuffer = CFrameBuffer::getInstance();
|
||||
|
||||
is_wizard = wizard_mode;
|
||||
|
||||
width = w_max (40, 10);
|
||||
hheight = g_Font[SNeutrinoSettings::FONT_TYPE_MENU_TITLE]->getHeight();
|
||||
mheight = g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->getHeight();
|
||||
@@ -123,6 +125,7 @@ void CAudioSetup::showAudioSetup()
|
||||
//menue init
|
||||
CMenuWidget* audioSettings = new CMenuWidget(LOCALE_MAINSETTINGS_HEAD, NEUTRINO_ICON_SETTINGS, width);
|
||||
audioSettings->setSelected(selected);
|
||||
audioSettings->setWizardMode(is_wizard);
|
||||
|
||||
//analog modes (stereo, mono l/r...)
|
||||
CMenuOptionChooser * as_oj_analogmode = new CMenuOptionChooser(LOCALE_AUDIOMENU_ANALOG_MODE, &g_settings.audio_AnalogMode, AUDIOMENU_ANALOGOUT_OPTIONS, AUDIOMENU_ANALOGOUT_OPTION_COUNT, true, audioSetupNotifier);
|
||||
@@ -195,3 +198,10 @@ void CAudioSetup::showAudioSetup()
|
||||
delete audioSettings;
|
||||
}
|
||||
|
||||
//sets menu mode to "wizard" or "default"
|
||||
void CAudioSetup::setWizardMode(bool mode)
|
||||
{
|
||||
printf("[neutrino audio setup] %s set audio settings menu to mode %d...\n", __FUNCTION__, mode);
|
||||
is_wizard = mode;
|
||||
}
|
||||
|
||||
|
@@ -42,15 +42,26 @@ class CAudioSetup : public CMenuTarget
|
||||
private:
|
||||
CFrameBuffer *frameBuffer;
|
||||
|
||||
int x, y, width, height, menue_width, hheight, mheight, selected;
|
||||
int x, y, width, height, hheight, mheight, selected;
|
||||
|
||||
void hide();
|
||||
void showAudioSetup();
|
||||
|
||||
|
||||
bool is_wizard;
|
||||
|
||||
public:
|
||||
CAudioSetup();
|
||||
enum AUDIO_SETUP_MODE
|
||||
{
|
||||
AUDIO_SETUP_MODE_WIZARD_NO = 0,
|
||||
AUDIO_SETUP_MODE_WIZARD = 1
|
||||
};
|
||||
|
||||
CAudioSetup(bool wizard_mode = AUDIO_SETUP_MODE_WIZARD_NO);
|
||||
~CAudioSetup();
|
||||
|
||||
bool getWizardMode() {return is_wizard;};
|
||||
void setWizardMode(bool mode);
|
||||
|
||||
int exec(CMenuTarget* parent, const std::string & actionKey);
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user