]> git.sesse.net Git - vlc/commitdiff
one more fix :) -- courmisch approved ...
authorAntoine Cellerier <dionoea@videolan.org>
Tue, 25 Oct 2005 10:32:49 +0000 (10:32 +0000)
committerAntoine Cellerier <dionoea@videolan.org>
Tue, 25 Oct 2005 10:32:49 +0000 (10:32 +0000)
modules/gui/wxwidgets/wxwidgets.cpp

index 3ca4de17301f400800515fd5fc1c1f2dd5f51e0a..ef9a718619ffc369c2e46140f62b4a8335d6424b 100644 (file)
@@ -303,6 +303,7 @@ static void Init( intf_thread_t *p_intf )
 #else
     wxEntry( i_args, p_args );
 #endif
+    setlocale( LC_NUMERIC, "C" );
 }
 
 /* following functions are local */
@@ -332,24 +333,8 @@ bool Instance::OnInit()
 {
     /* Initialization of i18n stuff.
      * Usefull for things we don't have any control over, like wxWidgets
-     * provided facilities (eg. open file dialog)
-     * 
-     * FIXME FIXME FIXME
-     * Note that gettext is already initialized by the VLC core, that it
-     * handles charset conversion and that we DO NOT want wxWidgets to set
-     * our LC_NUMERIC to non-C. However, it always does it anyway :-(
-     * Strangely, when calling the "obsoleted" locale.Init() prototype
-     * setlocale( LC_NUMERIC, "C" ) afterward works, while it is not the
-     * case with the newer locale.Init() prototype.
-     *
-     * In any case, that's ugly and thread-safe. The proper solution would
-     * be to reimplement an atof() version that is locale-independant and
-     * use in the many places that expect C/American float numbers. Even
-     * then, there might be some buggy underlying libraries breakage
-     * (e.g. Live555).
-     */
-    //locale.Init( wxLANGUAGE_DEFAULT, wxLOCALE_LOAD_DEFAULT );
-    locale.Init( NULL, NULL, NULL, true, false );
+     * provided facilities (eg. open file dialog) */
+    locale.Init( wxLANGUAGE_DEFAULT, wxLOCALE_LOAD_DEFAULT );
     setlocale( LC_NUMERIC, "C" );
 
     /* Load saved window settings */