]> git.saurik.com Git - wxWidgets.git/blobdiff - src/xrc/xh_listb.cpp
mention ShouldInheritColours() change
[wxWidgets.git] / src / xrc / xh_listb.cpp
index 50790fbb34fe89717984b3b8bce3f4c96d1d8005..68caf3c1b8df06862ec0050240728625cfe8bab8 100644 (file)
@@ -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 <item>Label</item>
         
         // 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;
     }