From 69a3e5f3c364418afaf2a015bde15bb7c15bc9b3 Mon Sep 17 00:00:00 2001 From: Soren Jorvang Date: Sat, 19 Feb 2011 22:56:51 +0000 Subject: [PATCH] wxConvCurrent in wxWidgets is not always initialized at startup like it is supposed to and depending on the linking method used this shows up as the inability to use it in an initializer. I think this may be a wxWidgets bug (ticket #12927), but I haven't fully debugged it yet. For now, apply a workaround here. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7208 8ced0084-cf51-0410-be5f-012b33b47a6e --- Source/Core/DolphinWX/Src/LogWindow.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Source/Core/DolphinWX/Src/LogWindow.cpp b/Source/Core/DolphinWX/Src/LogWindow.cpp index e263f1a790..3438b05178 100644 --- a/Source/Core/DolphinWX/Src/LogWindow.cpp +++ b/Source/Core/DolphinWX/Src/LogWindow.cpp @@ -43,7 +43,7 @@ CLogWindow::CLogWindow(CFrame *parent, wxWindowID id, const wxPoint& pos, , Parent(parent) , m_LogAccess(true) , m_Log(NULL), m_cmdline(NULL), m_FontChoice(NULL) , m_LogSection(1) - , m_SJISConv(*(wxCSConv*)wxConvCurrent) + , m_SJISConv(wxT("")) { #ifdef _WIN32 static bool validCP932 = ::IsValidCodePage(932) != 0; @@ -54,6 +54,7 @@ CLogWindow::CLogWindow(CFrame *parent, wxWindowID id, const wxPoint& pos, else { WARN_LOG(COMMON, "Cannot Convert from Charset Windows Japanese cp 932"); + m_SJISConv = *(wxCSConv*)wxConvCurrent; } #else m_SJISConv = wxCSConv(wxFontMapper::GetEncodingName(wxFONTENCODING_EUC_JP));