X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/02df379910a86bdde7e81b7f62d890cc314b4554..bfdc04a9bb95e6865570d59192718052b6229221:/src/xrc/xh_listb.cpp?ds=inline diff --git a/src/xrc/xh_listb.cpp b/src/xrc/xh_listb.cpp index 50790fbb34..68caf3c1b8 100644 --- a/src/xrc/xh_listb.cpp +++ b/src/xrc/xh_listb.cpp @@ -23,6 +23,8 @@ #include "wx/listbox.h" #include "wx/intl.h" +IMPLEMENT_DYNAMIC_CLASS(wxListBoxXmlHandler, wxXmlResourceHandler) + wxListBoxXmlHandler::wxListBoxXmlHandler() : wxXmlResourceHandler() , m_insideBox(FALSE) { @@ -83,7 +85,10 @@ wxObject *wxListBoxXmlHandler::DoCreateResource() // handle Label // add to the list - strList.Add(wxGetTranslation(GetNodeContent(m_node))); + wxString str = GetNodeContent(m_node); + if (m_resource->GetFlags() & wxXRC_USE_LOCALE) + str = wxGetTranslation(str); + strList.Add(str); return NULL; }