Kill some unnecessary c_str and use StrToWxStr in a few places that I missed.

This commit is contained in:
Jordan Woyak
2013-02-28 02:39:06 -06:00
parent 56f09d3b91
commit 03ec9a2e08
20 changed files with 53 additions and 52 deletions

View File

@ -212,9 +212,9 @@ VideoConfigDiag::VideoConfigDiag(wxWindow* parent, const std::string &title, con
it = g_available_video_backends.begin(),
itend = g_available_video_backends.end();
for (; it != itend; ++it)
choice_backend->AppendString(wxGetTranslation(StrToWxStr((*it)->GetName().c_str())));
choice_backend->AppendString(wxGetTranslation(StrToWxStr((*it)->GetName())));
choice_backend->SetStringSelection(wxGetTranslation(StrToWxStr(g_video_backend->GetName().c_str())));
choice_backend->SetStringSelection(wxGetTranslation(StrToWxStr(g_video_backend->GetName())));
choice_backend->Bind(wxEVT_COMMAND_CHOICE_SELECTED, &VideoConfigDiag::Event_Backend, this);
szr_basic->Add(label_backend, 1, wxALIGN_CENTER_VERTICAL, 5);
@ -236,7 +236,7 @@ VideoConfigDiag::VideoConfigDiag(wxWindow* parent, const std::string &title, con
it = vconfig.backend_info.Adapters.begin(),
itend = vconfig.backend_info.Adapters.end();
for (; it != itend; ++it)
choice_adapter->AppendString(StrToWxStr(it->c_str()));
choice_adapter->AppendString(StrToWxStr(*it));
choice_adapter->Select(vconfig.iAdapter);
@ -259,7 +259,7 @@ VideoConfigDiag::VideoConfigDiag(wxWindow* parent, const std::string &title, con
RegisterControl(choice_display_resolution, wxGetTranslation(display_res_desc));
choice_display_resolution->Bind(wxEVT_COMMAND_CHOICE_SELECTED, &VideoConfigDiag::Event_DisplayResolution, this);
choice_display_resolution->SetStringSelection(StrToWxStr(SConfig::GetInstance().m_LocalCoreStartupParameter.strFullscreenResolution.c_str()));
choice_display_resolution->SetStringSelection(StrToWxStr(SConfig::GetInstance().m_LocalCoreStartupParameter.strFullscreenResolution));
szr_display->Add(label_display_resolution, 1, wxALIGN_CENTER_VERTICAL, 0);
szr_display->Add(choice_display_resolution);
@ -355,7 +355,7 @@ VideoConfigDiag::VideoConfigDiag(wxWindow* parent, const std::string &title, con
it = vconfig.backend_info.AAModes.begin(),
itend = vconfig.backend_info.AAModes.end();
for (; it != itend; ++it)
choice_aamode->AppendString(wxGetTranslation(StrToWxStr(it->c_str())));
choice_aamode->AppendString(wxGetTranslation(StrToWxStr(*it)));
choice_aamode->Select(vconfig.iMultisampleMode);
szr_enh->Add(text_aamode, 1, wxALIGN_CENTER_VERTICAL, 0);
@ -380,12 +380,12 @@ VideoConfigDiag::VideoConfigDiag(wxWindow* parent, const std::string &title, con
it = vconfig.backend_info.PPShaders.begin(),
itend = vconfig.backend_info.PPShaders.end();
for (; it != itend; ++it)
choice_ppshader->AppendString(StrToWxStr(it->c_str()));
choice_ppshader->AppendString(StrToWxStr(*it));
if (vconfig.sPostProcessingShader.empty())
choice_ppshader->Select(0);
else
choice_ppshader->SetStringSelection(StrToWxStr(vconfig.sPostProcessingShader.c_str()));
choice_ppshader->SetStringSelection(StrToWxStr(vconfig.sPostProcessingShader));
choice_ppshader->Bind(wxEVT_COMMAND_CHOICE_SELECTED, &VideoConfigDiag::Event_PPShader, this);