Set SM_DBCSENABLED according to the current locale instead of
authorAlexandre Julliard <julliard@winehq.org>
Mon, 7 Mar 2005 17:16:26 +0000 (17:16 +0000)
committerAlexandre Julliard <julliard@winehq.org>
Mon, 7 Mar 2005 17:16:26 +0000 (17:16 +0000)
hardcoding it to 0 (found by Mike McCormack).

dlls/user/sysparams.c

index 5c591df7183dbd202bffd37e6a55db107ec254f1..0918f0bf67d1787f0515f166c28685cef40caa7a 100644 (file)
@@ -602,6 +602,7 @@ void SYSPARAMS_Init(void)
     HKEY hkey; /* key to the window metrics area of the registry */
     WCHAR buf[10];
     INT border;
+    CPINFO cpinfo;
 
     display_dc = CreateICW( DISPLAY, NULL, NULL, NULL );
     assert( display_dc );
@@ -681,7 +682,8 @@ void SYSPARAMS_Init(void)
 
     SystemParametersInfoW( SPI_GETMENUDROPALIGNMENT, 0, &sysMetrics[SM_MENUDROPALIGNMENT], 0 );
     sysMetrics[SM_PENWINDOWS] = 0;
-    sysMetrics[SM_DBCSENABLED] = 0;
+    GetCPInfo( CP_ACP, &cpinfo );
+    sysMetrics[SM_DBCSENABLED] = (cpinfo.MaxCharSize > 1);
 
     /* FIXME: Need to query X for the following */
     sysMetrics[SM_CMOUSEBUTTONS] = 3;