Commit 5a64f285 authored by Aric Stewart's avatar Aric Stewart Committed by Alexandre Julliard

Fix to GetItemW to stop whiping out the items text.

parent 419b4da3
...@@ -1970,18 +1970,18 @@ TREEVIEW_GetItemW(TREEVIEW_INFO *infoPtr, LPTVITEMEXA tvItem) ...@@ -1970,18 +1970,18 @@ TREEVIEW_GetItemW(TREEVIEW_INFO *infoPtr, LPTVITEMEXA tvItem)
if (tvItem->mask & TVIF_STATE) { if (tvItem->mask & TVIF_STATE) {
tvItem->state = wineItem->state & tvItem->stateMask; tvItem->state = wineItem->state & tvItem->stateMask;
} }
#if 0
if (tvItem->mask & TVIF_TEXT) { if (tvItem->mask & TVIF_TEXT) {
if (wineItem->pszText == LPSTR_TEXTCALLBACKW) { if (wineItem->pszText == LPSTR_TEXTCALLBACKA) {
tvItem->pszText = LPSTR_TEXTCALLBACKW; /* FIXME:send notification? */ tvItem->pszText = LPSTR_TEXTCALLBACKA;
ERR(" GetItem called with LPSTR_TEXTCALLBACK\n"); FIXME(" GetItem called with LPSTR_TEXTCALLBACK\n");
} }
else if (wineItem->pszText) { else if (wineItem->pszText) {
lstrcpynAtoW(tvItem->pszText, wineItem->pszText, tvItem->cchTextMax); MultiByteToWideChar(CP_ACP, 0, wineItem->pszText,
-1 , (LPWSTR)tvItem->pszText, tvItem->cchTextMax);
} }
} }
#endif
wineItem->pszText = NULL;
TRACE("item %d<%p>, txt %p, img %p, action %x\n", TRACE("item %d<%p>, txt %p, img %p, action %x\n",
iItem, tvItem, tvItem->pszText, &tvItem->iImage, tvItem->mask); iItem, tvItem, tvItem->pszText, &tvItem->iImage, tvItem->mask);
return TRUE; return TRUE;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment