Listview: flip notify formats

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



	Huw D M Davies <hdavies@codeweavers.com>
	Flip A<->W conversion in dispinfo_notifyT
Index: dlls/comctl32/listview.c
===================================================================
RCS file: /home/wine/wine/dlls/comctl32/listview.c,v
retrieving revision 1.112
diff -u -r1.112 listview.c
--- dlls/comctl32/listview.c	2002/01/31 20:38:25	1.112
+++ dlls/comctl32/listview.c	2002/02/01 12:32:20
@@ -365,8 +365,8 @@
     if (notificationCode != LVN_GETDISPINFOW)
     { /* length of existing text */
       cchTempBufMax = convertToUnicode ?
-      WideCharToMultiByte(CP_ACP, 0, pdi->item.pszText, -1, NULL, 0, NULL, NULL) :
-      MultiByteToWideChar(CP_ACP, 0, (LPCSTR)pdi->item.pszText, -1, NULL, 0);
+      MultiByteToWideChar(CP_ACP, 0, (LPCSTR)pdi->item.pszText, -1, NULL, 0):
+      WideCharToMultiByte(CP_ACP, 0, pdi->item.pszText, -1, NULL, 0, NULL, NULL);
     }
     else
       cchTempBufMax = pdi->item.cchTextMax;
@@ -375,11 +375,11 @@
         (convertToUnicode ? sizeof(WCHAR) : sizeof(CHAR)) * cchTempBufMax);
     if (!pszTempBuf) return FALSE;
     if (convertToUnicode)
-      WideCharToMultiByte(CP_ACP, 0, pdi->item.pszText, -1, (LPSTR) pszTempBuf,
-                          cchTempBufMax, NULL, NULL);
-    else
       MultiByteToWideChar(CP_ACP, 0, (LPCSTR)pdi->item.pszText, -1, 
                           pszTempBuf, cchTempBufMax);
+    else
+      WideCharToMultiByte(CP_ACP, 0, pdi->item.pszText, -1, (LPSTR) pszTempBuf,
+                          cchTempBufMax, NULL, NULL);
     TRACE("   text=%s\n", debugstr_t(pszTempBuf, convertToUnicode));
     savCchTextMax = pdi->item.cchTextMax;
     savPszText = pdi->item.pszText;

[Index of Archives]     [Gimp for Windows]     [Red Hat]     [Samba]     [Yosemite Camping]     [Graphics Cards]     [Wine Home]

  Powered by Linux