From fb76ad8f55cfee41237cd41220e8b51267c4a8a2 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Tue, 8 Feb 2011 17:24:45 +0000 Subject: [PATCH] Use wxLocale instead of setlocale() to change the locale in the tests. Numeric validator tests rely on wxLocale::GetInfo() returning the decimal point and calling setlocale() is not enough to ensure this under MSW, we must use wxLocale for this currently. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66865 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- tests/validators/valnum.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/validators/valnum.cpp b/tests/validators/valnum.cpp index 3b2369c518..531dd0e66a 100644 --- a/tests/validators/valnum.cpp +++ b/tests/validators/valnum.cpp @@ -136,7 +136,7 @@ void NumValidatorTestCase::TransferUnsigned() void NumValidatorTestCase::TransferFloat() { // We need a locale with point as decimal separator. - CLocaleSetter cloc; + wxLocale loc(wxLANGUAGE_ENGLISH_UK, wxLOCALE_DONT_LOAD_DEFAULT); float value = 0; wxFloatingPointValidator valFloat(3, &value); @@ -184,7 +184,7 @@ void NumValidatorTestCase::ZeroAsBlank() void NumValidatorTestCase::NoTrailingZeroes() { // We need a locale with point as decimal separator. - CLocaleSetter cloc; + wxLocale loc(wxLANGUAGE_ENGLISH_UK, wxLOCALE_DONT_LOAD_DEFAULT); double value = 1.2; m_text->SetValidator( -- 2.45.2