space changes, merge #defines, language fix, and code reorder/cleanup :P

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5614 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
luisr142004 2010-06-05 01:38:22 +00:00
commit 2e783d9769
42 changed files with 1870 additions and 1793 deletions

View file

@ -22,12 +22,12 @@
struct CConfig
{
bool m_EnableHLEAudio;
bool m_EnableHLEAudio;
CConfig();
void Load();
void Save();
CConfig();
void Load();
void Save();
};
extern CConfig g_Config;

View file

@ -95,7 +95,7 @@ DSPConfigDialogHLE::DSPConfigDialogHLE(wxWindow *parent, wxWindowID id, const wx
void DSPConfigDialogHLE::AddBackend(const char* backend)
{
// Update values
m_BackendSelection->Append(wxString::FromAscii(backend));
m_BackendSelection->Append(wxString::FromAscii(backend));
#ifdef __APPLE__
int num = m_BackendSelection->FindString(wxString::FromAscii(ac_Config.sBackend));
#else
@ -145,7 +145,7 @@ bool DSPConfigDialogHLE::SupportsVolumeChanges(std::string backend)
// but getting the backend from string etc. is probably
// too much just to enable/disable a stupid slider...
return (backend == BACKEND_DIRECTSOUND ||
backend == BACKEND_OPENAL);
backend == BACKEND_OPENAL);
}
void DSPConfigDialogHLE::BackendChanged(wxCommandEvent& event)

View file

@ -28,38 +28,38 @@ class DSPConfigDialogHLE : public wxDialog
{
public:
DSPConfigDialogHLE(wxWindow *parent,
wxWindowID id = wxID_ANY,
const wxString &title = wxT("Dolphin DSP-HLE Plugin Settings"),
const wxPoint& pos = wxDefaultPosition,
const wxSize& size = wxDefaultSize,
long style = wxDEFAULT_DIALOG_STYLE);
virtual ~DSPConfigDialogHLE();
void AddBackend(const char *backend);
wxWindowID id = wxID_ANY,
const wxString &title = wxT("Dolphin DSP-HLE Plugin Settings"),
const wxPoint& pos = wxDefaultPosition,
const wxSize& size = wxDefaultSize,
long style = wxDEFAULT_DIALOG_STYLE);
virtual ~DSPConfigDialogHLE();
void AddBackend(const char *backend);
void ClearBackends();
private:
DECLARE_EVENT_TABLE();
wxSlider *m_volumeSlider;
wxStaticText *m_volumeText;
wxButton *m_OK;
wxCheckBox *m_buttonEnableHLEAudio;
wxCheckBox *m_buttonEnableDTKMusic;
wxCheckBox *m_buttonEnableThrottle;
DECLARE_EVENT_TABLE();
wxSlider* m_volumeSlider;
wxStaticText* m_volumeText;
wxButton* m_OK;
wxCheckBox* m_buttonEnableHLEAudio;
wxCheckBox* m_buttonEnableDTKMusic;
wxCheckBox* m_buttonEnableThrottle;
wxArrayString wxArrayBackends;
wxChoice *m_BackendSelection;
wxChoice* m_BackendSelection;
enum
enum
{
ID_ENABLE_HLE_AUDIO,
ID_ENABLE_DTK_MUSIC,
ID_ENABLE_THROTTLE,
ID_BACKEND,
ID_ENABLE_HLE_AUDIO,
ID_ENABLE_DTK_MUSIC,
ID_ENABLE_THROTTLE,
ID_BACKEND,
ID_VOLUME
};
void OnOK(wxCommandEvent& event);
void SettingsChanged(wxCommandEvent& event);
void OnOK(wxCommandEvent& event);
void SettingsChanged(wxCommandEvent& event);
void VolumeChanged(wxScrollEvent& event);
bool SupportsVolumeChanges(std::string backend);
void BackendChanged(wxCommandEvent& event);

View file

@ -72,7 +72,7 @@ class wxDLLApp : public wxApp
return true;
}
};
IMPLEMENT_APP_NO_MAIN(wxDLLApp)
IMPLEMENT_APP_NO_MAIN(wxDLLApp)
WXDLLIMPEXP_BASE void wxSetInstance(HINSTANCE hInst);
#endif
@ -89,7 +89,7 @@ BOOL APIENTRY DllMain(HINSTANCE hinstDLL, // DLL module handle
wxInitialize();
#endif
}
break;
break;
case DLL_PROCESS_DETACH:
#if defined(HAVE_WX) && HAVE_WX
@ -129,13 +129,11 @@ void GetDllInfo(PLUGIN_INFO* _PluginInfo)
_PluginInfo->Version = 0x0100;
_PluginInfo->Type = PLUGIN_TYPE_DSP;
#ifdef DEBUGFAST
sprintf(_PluginInfo->Name, "Dolphin DSP-HLE Plugin (DebugFast) ");
sprintf(_PluginInfo->Name, "Dolphin DSP-HLE Plugin (DebugFast)");
#elif defined _DEBUG
sprintf(_PluginInfo->Name, "Dolphin DSP-HLE Plugin (Debug)");
#else
#ifndef _DEBUG
sprintf(_PluginInfo->Name, "Dolphin DSP-HLE Plugin ");
#else
sprintf(_PluginInfo->Name, "Dolphin DSP-HLE Plugin (Debug) ");
#endif
sprintf(_PluginInfo->Name, "Dolphin DSP-HLE Plugin");
#endif
}
@ -143,7 +141,7 @@ void GetDllInfo(PLUGIN_INFO* _PluginInfo)
void SetDllGlobals(PLUGIN_GLOBALS* _pPluginGlobals)
{
globals = _pPluginGlobals;
LogManager::SetInstance((LogManager *)globals->logManager);
LogManager::SetInstance((LogManager*)globals->logManager);
}
void DllConfig(HWND _hParent)
@ -198,10 +196,6 @@ void Initialize(void *init)
CDSPHandler::CreateInstance();
}
void DSP_StopSoundStream()
{
}
void Shutdown()
{
AudioCommon::ShutdownSoundStream();
@ -285,7 +279,7 @@ unsigned short DSP_WriteControlRegister(unsigned short _Value)
{
unsigned int AISampleRate, DACSampleRate;
g_dspInitialize.pGetSampleRate(AISampleRate, DACSampleRate);
soundStream = AudioCommon::InitSoundStream(new HLEMixer(AISampleRate, DACSampleRate));
soundStream = AudioCommon::InitSoundStream(new HLEMixer(AISampleRate, DACSampleRate));
if(!soundStream) PanicAlert("Error starting up sound stream");
// Mixer is initialized
g_InitMixer = true;