]> git.saurik.com Git - wxWidgets.git/blobdiff - wxPython/src/_intl.i
Some error recovery and other tweaks
[wxWidgets.git] / wxPython / src / _intl.i
index 0bdca6fa44d1af6214a7f17c669e6ebda1aba84c..22f868cf08712004336505d148e5b24125245435 100644 (file)
@@ -308,8 +308,15 @@ class wxLocale
 public:
     // ctor & dtor
     // -----------
-    wxLocale(int language = wxLANGUAGE_DEFAULT,
-             int flags = wxLOCALE_LOAD_DEFAULT | wxLOCALE_CONV_ENCODING);
+    %extend {
+        wxLocale(int language = -1,
+                 int flags = wxLOCALE_LOAD_DEFAULT | wxLOCALE_CONV_ENCODING) {
+            if (language == -1)
+                return new wxLocale();
+            else
+                return new wxLocale(language, flags);
+        }
+    }
 
         // restores old locale
     ~wxLocale();