Planeshift

pawsconfigsound.h

Go to the documentation of this file.
00001 /*
00002  * pawsconfigsound.h - Author: Christian Svensson
00003  *
00004  * Copyright (C) 2004 Atomic Blue ([email protected], http://www.atomicblue.org)
00005  *
00006  *
00007  * This program is free software; you can redistribute it and/or
00008  * modify it under the terms of the GNU General Public License
00009  * as published by the Free Software Foundation (version 2 of the License)
00010  * This program is distributed in the hope that it will be useful,
00011  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00012  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00013  * GNU General Public License for more details.
00014  * You should have received a copy of the GNU General Public License
00015  * along with this program; if not, write to the Free Software
00016  * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
00017  *
00018  */
00019 
00020 #ifndef PAWS_CONFIG_SOUND_HEADER
00021 #define PAWS_CONFIG_SOUND_HEADER
00022 
00023 // CS INCLUDES
00024 #include <csutil/array.h>
00025 #include <iutil/document.h>
00026 
00027 // PAWS INCLUDES
00028 #include "paws/pawswidget.h"
00029 #include "paws/pawscombo.h"
00030 #include "pawsconfigwindow.h"
00031 #include "util/psxmlparser.h"
00032 
00033 class pawsCheckBox;
00034 class pawsScrollBar;
00035 
00036 class pawsRadioButtonGroup;
00037 
00041 class pawsConfigSound : public pawsConfigSectionWindow
00042 {
00043 public:
00044     pawsConfigSound();
00045 
00046     //from pawsWidget:
00047     virtual bool PostSetup();
00048     virtual bool OnScroll(int,pawsScrollBar*);
00049     virtual bool OnButtonPressed(int, int, pawsWidget*);
00050     virtual void OnListAction(pawsListBox* selected, int status);
00051     virtual void Show();
00052     virtual void Hide();
00053 
00054     // from pawsConfigSectionWindow:
00055     virtual bool Initialize();
00056     virtual bool LoadConfig();
00057     virtual bool SaveConfig();
00058     virtual void SetDefault();
00059 
00060 protected:
00061 
00062     pawsScrollBar* generalVol;
00063     pawsScrollBar* musicVol;
00064     pawsScrollBar* ambientVol;
00065     pawsScrollBar* actionsVol;
00066     pawsScrollBar* effectsVol;
00067     pawsScrollBar* guiVol;
00068     pawsScrollBar* voicesVol;
00069     pawsScrollBar* instrumentsVol;
00070 
00071     pawsCheckBox* ambient;
00072     pawsCheckBox* actions;
00073     pawsCheckBox* effects;
00074     pawsCheckBox* music;
00075     pawsCheckBox* gui;
00076     pawsCheckBox* voices;
00077     pawsCheckBox* instruments;
00078 
00079     pawsCheckBox* muteOnFocusLoss;
00080     pawsCheckBox* loopBGM;
00081     pawsCheckBox* combatMusic;
00082     pawsCheckBox* chatSound;
00083     
00084     pawsComboBox* soundLocation;
00085 
00086     bool loaded;
00087 
00088     bool oldambient, oldactions, oldeffects, oldmusic, oldgui, oldvoices, oldInstruments, oldlisteneroncamerapos, oldchatsound;
00089     float oldvol, oldmusicvol, oldambientvol, oldactionsvol, oldeffectsvol, oldguivol, oldvoicesvol, oldInstrumentsVol;
00090 };
00091 
00092 
00093 CREATE_PAWS_FACTORY(pawsConfigSound);
00094 
00095 
00096 #endif
00097