mirror of https://github.com/PCSX2/pcsx2.git
GSdx: capture dialog - actually remember the last used codec
Previously it was saving the display name to the config but trying to restore according to the friendly name. Now store and restore according to the "displayName" which is more unique than "friendlyName" since it includes GUID[s], and handle it consistently as _bstr_t.
This commit is contained in:
parent
051a7f3451
commit
94c5eab776
|
@ -64,7 +64,7 @@ void GSCaptureDlg::OnInit()
|
|||
|
||||
m_codecs.clear();
|
||||
|
||||
string selected = theApp.GetConfig("CaptureVideoCodecDisplayName", "");
|
||||
_bstr_t selected = theApp.GetConfig("CaptureVideoCodecDisplayName", "").c_str();
|
||||
|
||||
ComboBoxAppend(IDC_CODECS, "Uncompressed", 0, true);
|
||||
|
||||
|
@ -110,7 +110,7 @@ void GSCaptureDlg::OnInit()
|
|||
|
||||
string s(c.FriendlyName.begin(), c.FriendlyName.end());
|
||||
|
||||
ComboBoxAppend(IDC_CODECS, s.c_str(), (LPARAM)&m_codecs.back(), s == selected);
|
||||
ComboBoxAppend(IDC_CODECS, s.c_str(), (LPARAM)&m_codecs.back(), c.DisplayName == selected);
|
||||
}
|
||||
EndEnumSysDev
|
||||
}
|
||||
|
@ -199,9 +199,7 @@ bool GSCaptureDlg::OnCommand(HWND hWnd, UINT id, UINT code)
|
|||
|
||||
if (ris != 2)
|
||||
{
|
||||
wstring s = wstring(c.DisplayName);
|
||||
|
||||
theApp.SetConfig("CaptureVideoCodecDisplayName", string(s.begin(), s.end()).c_str());
|
||||
theApp.SetConfig("CaptureVideoCodecDisplayName", c.DisplayName);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue