AppName has to be set before ?user can be used

Originally committed to SVN as r5195.
This commit is contained in:
Thomas Goyne 2011-01-16 07:15:18 +00:00
parent f604e0bacd
commit 7afbce439d

View file

@ -161,6 +161,12 @@ static void wxAssertHandler(const wxString &file, int line, const wxString &func
/// @brief Gets called when application starts. /// @brief Gets called when application starts.
/// @return bool /// @return bool
bool AegisubApp::OnInit() { bool AegisubApp::OnInit() {
// App name (yeah, this is a little weird to get rid of an odd warning)
#if defined(__WXMSW__) || defined(__WXMAC__)
SetAppName(_T("Aegisub"));
#else
SetAppName(_T("aegisub"));
#endif
// logging. // logging.
const std::string path_log(StandardPaths::DecodePath(_T("?user/log/"))); const std::string path_log(StandardPaths::DecodePath(_T("?user/log/")));
@ -198,13 +204,6 @@ bool AegisubApp::OnInit() {
// Install assertion handler // Install assertion handler
// wxSetAssertHandler(wxAssertHandler); // wxSetAssertHandler(wxAssertHandler);
// App name (yeah, this is a little weird to get rid of an odd warning)
#if defined(__WXMSW__) || defined(__WXMAC__)
SetAppName(_T("Aegisub"));
#else
SetAppName(_T("aegisub"));
#endif
const std::string conf_mru(StandardPaths::DecodePath(_T("?user/mru.json"))); const std::string conf_mru(StandardPaths::DecodePath(_T("?user/mru.json")));
config::mru = new agi::MRUManager(conf_mru, GET_DEFAULT_CONFIG(default_mru)); config::mru = new agi::MRUManager(conf_mru, GET_DEFAULT_CONFIG(default_mru));