mirror of
https://gitea.wildfiregames.com/0ad/0ad
synced 2026-06-16 05:13:58 -07:00
27 lines
545 B
C++
27 lines
545 B
C++
|
|
#include "stdafx.h"
|
||
|
|
|
||
|
|
#include "FileHistory.h"
|
||
|
|
|
||
|
|
#include "wx/confbase.h"
|
||
|
|
|
||
|
|
FileHistory::FileHistory(const wxString& configSubdir)
|
||
|
|
: wxFileHistory(9), m_configSubdir(configSubdir)
|
||
|
|
{
|
||
|
|
}
|
||
|
|
|
||
|
|
void FileHistory::Load(wxConfigBase& config)
|
||
|
|
{
|
||
|
|
wxString old = config.GetPath();
|
||
|
|
config.SetPath(m_configSubdir);
|
||
|
|
wxFileHistory::Load(config);
|
||
|
|
config.SetPath(old);
|
||
|
|
}
|
||
|
|
|
||
|
|
void FileHistory::Save(wxConfigBase& config)
|
||
|
|
{
|
||
|
|
wxString old = config.GetPath();
|
||
|
|
config.SetPath(m_configSubdir);
|
||
|
|
wxFileHistory::Save(config);
|
||
|
|
config.SetPath(old);
|
||
|
|
}
|