Converted to the new debug interface, using script written by Patrik

Stridvall.
This commit is contained in:
Alexandre Julliard 1999-06-12 15:45:58 +00:00
parent fdcfdb9a6d
commit a099a555c3
66 changed files with 1696 additions and 1698 deletions

View file

@ -17,7 +17,7 @@
#include "winbase.h" #include "winbase.h"
#include "commctrl.h" #include "commctrl.h"
#include "animate.h" #include "animate.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(animate) DEFAULT_DEBUG_CHANNEL(animate)
@ -109,38 +109,38 @@ ANIMATE_OpenA (HWND hwnd, WPARAM wParam, LPARAM lParam)
ANIMATE_Free (infoPtr); ANIMATE_Free (infoPtr);
if (!lParam) { if (!lParam) {
TRACE (animate, "closing avi!\n"); TRACE("closing avi!\n");
return TRUE; return TRUE;
} }
if (HIWORD(lParam)) { if (HIWORD(lParam)) {
FIXME (animate, "(\"%s\") empty stub!\n", (LPSTR)lParam); FIXME("(\"%s\") empty stub!\n", (LPSTR)lParam);
if (ANIMATE_LoadResA (infoPtr, hInstance, (LPSTR)lParam)) { if (ANIMATE_LoadResA (infoPtr, hInstance, (LPSTR)lParam)) {
FIXME (animate, "AVI resource found!\n"); FIXME("AVI resource found!\n");
} }
else { else {
FIXME (animate, "No AVI resource found!\n"); FIXME("No AVI resource found!\n");
if (ANIMATE_LoadFileA (infoPtr, (LPSTR)lParam)) { if (ANIMATE_LoadFileA (infoPtr, (LPSTR)lParam)) {
FIXME (animate, "AVI file found!\n"); FIXME("AVI file found!\n");
} }
else { else {
FIXME (animate, "No AVI file found!\n"); FIXME("No AVI file found!\n");
return FALSE; return FALSE;
} }
} }
} }
else { else {
FIXME (animate, "(%u) empty stub!\n", (WORD)LOWORD(lParam)); FIXME("(%u) empty stub!\n", (WORD)LOWORD(lParam));
if (ANIMATE_LoadResA (infoPtr, hInstance, if (ANIMATE_LoadResA (infoPtr, hInstance,
MAKEINTRESOURCEA((INT)lParam))) { MAKEINTRESOURCEA((INT)lParam))) {
FIXME (animate, "AVI resource found!\n"); FIXME("AVI resource found!\n");
} }
else { else {
FIXME (animate, "No AVI resource found!\n"); FIXME("No AVI resource found!\n");
return FALSE; return FALSE;
} }
} }
@ -170,13 +170,13 @@ ANIMATE_Play (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (nRepeat == -1) { if (nRepeat == -1) {
FIXME (animate, "(loop from=%d to=%d) empty stub!\n", FIXME("(loop from=%d to=%d) empty stub!\n",
nFrom, nTo); nFrom, nTo);
} }
else { else {
FIXME (animate, "(repeat=%d from=%d to=%d) empty stub!\n", FIXME("(repeat=%d from=%d to=%d) empty stub!\n",
nRepeat, nFrom, nTo); nRepeat, nFrom, nTo);
} }
@ -210,7 +210,7 @@ ANIMATE_Create (HWND hwnd, WPARAM wParam, LPARAM lParam)
/* allocate memory for info structure */ /* allocate memory for info structure */
infoPtr = (ANIMATE_INFO *)COMCTL32_Alloc (sizeof(ANIMATE_INFO)); infoPtr = (ANIMATE_INFO *)COMCTL32_Alloc (sizeof(ANIMATE_INFO));
if (!infoPtr) { if (!infoPtr) {
ERR (animate, "could not allocate info memory!\n"); ERR("could not allocate info memory!\n");
return 0; return 0;
} }
@ -296,7 +296,7 @@ ANIMATE_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
default: default:
if (uMsg >= WM_USER) if (uMsg >= WM_USER)
ERR (animate, "unknown msg %04x wp=%08x lp=%08lx\n", ERR("unknown msg %04x wp=%08x lp=%08lx\n",
uMsg, wParam, lParam); uMsg, wParam, lParam);
return DefWindowProcA (hwnd, uMsg, wParam, lParam); return DefWindowProcA (hwnd, uMsg, wParam, lParam);
} }

View file

@ -19,7 +19,7 @@
#include "winbase.h" #include "winbase.h"
#include "commctrl.h" #include "commctrl.h"
#include "comboex.h" #include "comboex.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(comboex) DEFAULT_DEBUG_CHANNEL(comboex)
@ -36,7 +36,7 @@ COMBOEX_GetComboControl (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
COMBOEX_INFO *infoPtr = COMBOEX_GetInfoPtr (hwnd); COMBOEX_INFO *infoPtr = COMBOEX_GetInfoPtr (hwnd);
TRACE (comboex, "\n"); TRACE("\n");
return (LRESULT)infoPtr->hwndCombo; return (LRESULT)infoPtr->hwndCombo;
} }
@ -50,7 +50,7 @@ COMBOEX_GetEditControl (HWND hwnd, WPARAM wParam, LPARAM lParam)
if ((GetWindowLongA (hwnd, GWL_STYLE) & CBS_DROPDOWNLIST) != CBS_DROPDOWN) if ((GetWindowLongA (hwnd, GWL_STYLE) & CBS_DROPDOWNLIST) != CBS_DROPDOWN)
return 0; return 0;
TRACE (comboex, "-- 0x%x\n", GetDlgItem (infoPtr->hwndCombo, ID_CB_EDIT)); TRACE("-- 0x%x\n", GetDlgItem (infoPtr->hwndCombo, ID_CB_EDIT));
return (LRESULT)GetDlgItem (infoPtr->hwndCombo, ID_CB_EDIT); return (LRESULT)GetDlgItem (infoPtr->hwndCombo, ID_CB_EDIT);
} }
@ -70,7 +70,7 @@ COMBOEX_GetImageList (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
COMBOEX_INFO *infoPtr = COMBOEX_GetInfoPtr (hwnd); COMBOEX_INFO *infoPtr = COMBOEX_GetInfoPtr (hwnd);
TRACE (comboex, "(0x%08x 0x%08lx)\n", wParam, lParam); TRACE("(0x%08x 0x%08lx)\n", wParam, lParam);
return (LRESULT)infoPtr->himl; return (LRESULT)infoPtr->himl;
} }
@ -83,7 +83,7 @@ COMBOEX_InsertItemA (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
/* COMBOEX_INFO *infoPtr = COMBOEX_GetInfoPtr (hwnd); */ /* COMBOEX_INFO *infoPtr = COMBOEX_GetInfoPtr (hwnd); */
FIXME (comboex, "(0x%08x 0x%08lx)\n", wParam, lParam); FIXME("(0x%08x 0x%08lx)\n", wParam, lParam);
return -1; return -1;
} }
@ -96,7 +96,7 @@ COMBOEX_SetExtendedStyle (HWND hwnd, WPARAM wParam, LPARAM lParam)
COMBOEX_INFO *infoPtr = COMBOEX_GetInfoPtr (hwnd); COMBOEX_INFO *infoPtr = COMBOEX_GetInfoPtr (hwnd);
DWORD dwTemp; DWORD dwTemp;
TRACE (comboex, "(0x%08x 0x%08lx)\n", wParam, lParam); TRACE("(0x%08x 0x%08lx)\n", wParam, lParam);
dwTemp = infoPtr->dwExtStyle; dwTemp = infoPtr->dwExtStyle;
@ -118,7 +118,7 @@ COMBOEX_SetImageList (HWND hwnd, WPARAM wParam, LPARAM lParam)
COMBOEX_INFO *infoPtr = COMBOEX_GetInfoPtr (hwnd); COMBOEX_INFO *infoPtr = COMBOEX_GetInfoPtr (hwnd);
HIMAGELIST himlTemp; HIMAGELIST himlTemp;
TRACE (comboex, "(0x%08x 0x%08lx)\n", wParam, lParam); TRACE("(0x%08x 0x%08lx)\n", wParam, lParam);
himlTemp = infoPtr->himl; himlTemp = infoPtr->himl;
infoPtr->himl = (HIMAGELIST)lParam; infoPtr->himl = (HIMAGELIST)lParam;
@ -132,7 +132,7 @@ COMBOEX_SetItemA (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
/* COMBOEX_INFO *infoPtr = COMBOEX_GetInfoPtr (hwnd); */ /* COMBOEX_INFO *infoPtr = COMBOEX_GetInfoPtr (hwnd); */
FIXME (comboex, "(%p): stub\n", (LPVOID)lParam); FIXME("(%p): stub\n", (LPVOID)lParam);
return TRUE; return TRUE;
} }
@ -146,7 +146,7 @@ COMBOEX_Forward (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
{ {
COMBOEX_INFO *infoPtr = COMBOEX_GetInfoPtr (hwnd); COMBOEX_INFO *infoPtr = COMBOEX_GetInfoPtr (hwnd);
FIXME (comboex, "(0x%x 0x%x 0x%lx): stub\n", uMsg, wParam, lParam); FIXME("(0x%x 0x%x 0x%lx): stub\n", uMsg, wParam, lParam);
if (infoPtr->hwndCombo) if (infoPtr->hwndCombo)
return SendMessageA (infoPtr->hwndCombo, uMsg, wParam, lParam); return SendMessageA (infoPtr->hwndCombo, uMsg, wParam, lParam);
@ -164,7 +164,7 @@ COMBOEX_Create (HWND hwnd, WPARAM wParam, LPARAM lParam)
/* allocate memory for info structure */ /* allocate memory for info structure */
infoPtr = (COMBOEX_INFO *)COMCTL32_Alloc (sizeof(COMBOEX_INFO)); infoPtr = (COMBOEX_INFO *)COMCTL32_Alloc (sizeof(COMBOEX_INFO));
if (infoPtr == NULL) { if (infoPtr == NULL) {
ERR (comboex, "could not allocate info memory!\n"); ERR("could not allocate info memory!\n");
return 0; return 0;
} }
@ -298,7 +298,7 @@ COMBOEX_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
default: default:
if (uMsg >= WM_USER) if (uMsg >= WM_USER)
ERR (comboex, "unknown msg %04x wp=%08x lp=%08lx\n", ERR("unknown msg %04x wp=%08x lp=%08lx\n",
uMsg, wParam, lParam); uMsg, wParam, lParam);
return DefWindowProcA (hwnd, uMsg, wParam, lParam); return DefWindowProcA (hwnd, uMsg, wParam, lParam);
} }

View file

@ -20,7 +20,7 @@
#include "winbase.h" #include "winbase.h"
#include "commctrl.h" #include "commctrl.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(commctrl) DEFAULT_DEBUG_CHANNEL(commctrl)
@ -59,7 +59,7 @@ DPA_Merge (const HDPA hdpa1, const HDPA hdpa2, DWORD dwFlags,
/* LPVOID *pWork1, *pWork2; */ /* LPVOID *pWork1, *pWork2; */
INT nCount1, nCount2; INT nCount1, nCount2;
TRACE (commctrl, "(%p %p %08lx %p %p %08lx): stub!\n", TRACE("(%p %p %08lx %p %p %08lx): stub!\n",
hdpa1, hdpa2, dwFlags, pfnCompare, pfnParam5, lParam); hdpa1, hdpa2, dwFlags, pfnCompare, pfnParam5, lParam);
if (IsBadWritePtr (hdpa1, sizeof(DPA))) if (IsBadWritePtr (hdpa1, sizeof(DPA)))
@ -75,7 +75,7 @@ DPA_Merge (const HDPA hdpa1, const HDPA hdpa2, DWORD dwFlags,
return FALSE; return FALSE;
if (dwFlags & DPAM_SORT) { if (dwFlags & DPAM_SORT) {
TRACE (commctrl, "sorting dpa's!\n"); TRACE("sorting dpa's!\n");
DPA_Sort (hdpa1, pfnCompare, lParam); DPA_Sort (hdpa1, pfnCompare, lParam);
DPA_Sort (hdpa2, pfnCompare, lParam); DPA_Sort (hdpa2, pfnCompare, lParam);
} }
@ -87,8 +87,8 @@ DPA_Merge (const HDPA hdpa1, const HDPA hdpa2, DWORD dwFlags,
nCount2 = hdpa2->nItemCount - 1; nCount2 = hdpa2->nItemCount - 1;
FIXME (commctrl, "nCount1=%d nCount2=%d\n", nCount1, nCount2); FIXME("nCount1=%d nCount2=%d\n", nCount1, nCount2);
FIXME (commctrl, "semi stub!\n"); FIXME("semi stub!\n");
#if 0 #if 0
do { do {
@ -132,11 +132,11 @@ COMCTL32_Alloc (DWORD dwSize)
{ {
LPVOID lpPtr; LPVOID lpPtr;
TRACE (commctrl, "(0x%lx)\n", dwSize); TRACE("(0x%lx)\n", dwSize);
lpPtr = HeapAlloc (COMCTL32_hHeap, HEAP_ZERO_MEMORY, dwSize); lpPtr = HeapAlloc (COMCTL32_hHeap, HEAP_ZERO_MEMORY, dwSize);
TRACE (commctrl, "-- ret=%p\n", lpPtr); TRACE("-- ret=%p\n", lpPtr);
return lpPtr; return lpPtr;
} }
@ -166,14 +166,14 @@ COMCTL32_ReAlloc (LPVOID lpSrc, DWORD dwSize)
{ {
LPVOID lpDest; LPVOID lpDest;
TRACE (commctrl, "(%p 0x%08lx)\n", lpSrc, dwSize); TRACE("(%p 0x%08lx)\n", lpSrc, dwSize);
if (lpSrc) if (lpSrc)
lpDest = HeapReAlloc (COMCTL32_hHeap, HEAP_ZERO_MEMORY, lpSrc, dwSize); lpDest = HeapReAlloc (COMCTL32_hHeap, HEAP_ZERO_MEMORY, lpSrc, dwSize);
else else
lpDest = HeapAlloc (COMCTL32_hHeap, HEAP_ZERO_MEMORY, dwSize); lpDest = HeapAlloc (COMCTL32_hHeap, HEAP_ZERO_MEMORY, dwSize);
TRACE (commctrl, "-- ret=%p\n", lpDest); TRACE("-- ret=%p\n", lpDest);
return lpDest; return lpDest;
} }
@ -195,7 +195,7 @@ COMCTL32_ReAlloc (LPVOID lpSrc, DWORD dwSize)
BOOL WINAPI BOOL WINAPI
COMCTL32_Free (LPVOID lpMem) COMCTL32_Free (LPVOID lpMem)
{ {
TRACE (commctrl, "(%p)\n", lpMem); TRACE("(%p)\n", lpMem);
return HeapFree (COMCTL32_hHeap, 0, lpMem); return HeapFree (COMCTL32_hHeap, 0, lpMem);
} }
@ -218,7 +218,7 @@ COMCTL32_Free (LPVOID lpMem)
DWORD WINAPI DWORD WINAPI
COMCTL32_GetSize (LPVOID lpMem) COMCTL32_GetSize (LPVOID lpMem)
{ {
TRACE (commctrl, "(%p)\n", lpMem); TRACE("(%p)\n", lpMem);
return HeapSize (COMCTL32_hHeap, 0, lpMem); return HeapSize (COMCTL32_hHeap, 0, lpMem);
} }
@ -276,7 +276,7 @@ CreateMRUListA (LPMRUINFO lpmi)
DWORD WINAPI DWORD WINAPI
FreeMRUListA (HMRU hmru) FreeMRUListA (HMRU hmru)
{ {
FIXME (commctrl, "(%p) empty stub!\n", hmru); FIXME("(%p) empty stub!\n", hmru);
#if 0 #if 0
if (!(hmru->dwParam1 & 1001)) { if (!(hmru->dwParam1 & 1001)) {
@ -299,7 +299,7 @@ DWORD WINAPI
AddMRUData (DWORD dwParam1, DWORD dwParam2, DWORD dwParam3) AddMRUData (DWORD dwParam1, DWORD dwParam2, DWORD dwParam3)
{ {
FIXME (commctrl, "(%lx %lx %lx) empty stub!\n", FIXME("(%lx %lx %lx) empty stub!\n",
dwParam1, dwParam2, dwParam3); dwParam1, dwParam2, dwParam3);
return 0; return 0;
@ -310,7 +310,7 @@ DWORD WINAPI
FindMRUData (DWORD dwParam1, DWORD dwParam2, DWORD dwParam3, DWORD dwParam4) FindMRUData (DWORD dwParam1, DWORD dwParam2, DWORD dwParam3, DWORD dwParam4)
{ {
FIXME (commctrl, "(%lx %lx %lx %lx) empty stub!\n", FIXME("(%lx %lx %lx %lx) empty stub!\n",
dwParam1, dwParam2, dwParam3, dwParam4); dwParam1, dwParam2, dwParam3, dwParam4);
return TRUE; return TRUE;
@ -332,10 +332,10 @@ CreateMRUListLazyA (LPMRUINFO lpmi, DWORD dwParam2, DWORD dwParam3, DWORD dwPara
/* internal variables */ /* internal variables */
LPVOID ptr; LPVOID ptr;
FIXME (commctrl, "(%p) empty stub!\n", lpmi); FIXME("(%p) empty stub!\n", lpmi);
if (lpmi) { if (lpmi) {
FIXME (commctrl, "(%lx %lx %lx %lx \"%s\" %lx)\n", FIXME("(%lx %lx %lx %lx \"%s\" %lx)\n",
lpmi->dwParam1, lpmi->dwParam2, lpmi->dwParam3, lpmi->dwParam1, lpmi->dwParam2, lpmi->dwParam3,
(DWORD)lpmi->hkeyMain, lpmi->lpszSubKey, lpmi->dwParam6); (DWORD)lpmi->hkeyMain, lpmi->lpszSubKey, lpmi->dwParam6);
} }
@ -343,7 +343,7 @@ CreateMRUListLazyA (LPMRUINFO lpmi, DWORD dwParam2, DWORD dwParam3, DWORD dwPara
/* dummy pointer creation */ /* dummy pointer creation */
ptr = COMCTL32_Alloc (32); ptr = COMCTL32_Alloc (32);
FIXME (commctrl, "-- ret = %p\n", ptr); FIXME("-- ret = %p\n", ptr);
return ptr; return ptr;
} }
@ -367,7 +367,7 @@ Str_GetPtrA (LPCSTR lpSrc, LPSTR lpDest, INT nMaxLen)
{ {
INT len; INT len;
TRACE (commctrl, "(%p %p %d)\n", lpSrc, lpDest, nMaxLen); TRACE("(%p %p %d)\n", lpSrc, lpDest, nMaxLen);
if (!lpDest && lpSrc) if (!lpDest && lpSrc)
return lstrlenA (lpSrc); return lstrlenA (lpSrc);
@ -404,7 +404,7 @@ Str_GetPtrA (LPCSTR lpSrc, LPSTR lpDest, INT nMaxLen)
BOOL WINAPI BOOL WINAPI
Str_SetPtrA (LPSTR *lppDest, LPCSTR lpSrc) Str_SetPtrA (LPSTR *lppDest, LPCSTR lpSrc)
{ {
TRACE (commctrl, "(%p %p)\n", lppDest, lpSrc); TRACE("(%p %p)\n", lppDest, lpSrc);
if (lpSrc) { if (lpSrc) {
LPSTR ptr = COMCTL32_ReAlloc (*lppDest, lstrlenA (lpSrc) + 1); LPSTR ptr = COMCTL32_ReAlloc (*lppDest, lstrlenA (lpSrc) + 1);
@ -440,7 +440,7 @@ Str_GetPtrW (LPCWSTR lpSrc, LPWSTR lpDest, INT nMaxLen)
{ {
INT len; INT len;
TRACE (commctrl, "(%p %p %d)\n", lpSrc, lpDest, nMaxLen); TRACE("(%p %p %d)\n", lpSrc, lpDest, nMaxLen);
if (!lpDest && lpSrc) if (!lpDest && lpSrc)
return lstrlenW (lpSrc); return lstrlenW (lpSrc);
@ -477,7 +477,7 @@ Str_GetPtrW (LPCWSTR lpSrc, LPWSTR lpDest, INT nMaxLen)
BOOL WINAPI BOOL WINAPI
Str_SetPtrW (LPWSTR *lppDest, LPCWSTR lpSrc) Str_SetPtrW (LPWSTR *lppDest, LPCWSTR lpSrc)
{ {
TRACE (commctrl, "(%p %p)\n", lppDest, lpSrc); TRACE("(%p %p)\n", lppDest, lpSrc);
if (lpSrc) { if (lpSrc) {
INT len = lstrlenW (lpSrc) + 1; INT len = lstrlenW (lpSrc) + 1;
@ -521,7 +521,7 @@ DSA_Create (INT nSize, INT nGrow)
{ {
HDSA hdsa; HDSA hdsa;
TRACE (commctrl, "(size=%d grow=%d)\n", nSize, nGrow); TRACE("(size=%d grow=%d)\n", nSize, nGrow);
hdsa = (HDSA)COMCTL32_Alloc (sizeof(DSA)); hdsa = (HDSA)COMCTL32_Alloc (sizeof(DSA));
if (hdsa) if (hdsa)
@ -551,7 +551,7 @@ DSA_Create (INT nSize, INT nGrow)
BOOL WINAPI BOOL WINAPI
DSA_Destroy (const HDSA hdsa) DSA_Destroy (const HDSA hdsa)
{ {
TRACE (commctrl, "(%p)\n", hdsa); TRACE("(%p)\n", hdsa);
if (!hdsa) if (!hdsa)
return FALSE; return FALSE;
@ -581,7 +581,7 @@ DSA_GetItem (const HDSA hdsa, INT nIndex, LPVOID pDest)
{ {
LPVOID pSrc; LPVOID pSrc;
TRACE (commctrl, "(%p %d %p)\n", hdsa, nIndex, pDest); TRACE("(%p %d %p)\n", hdsa, nIndex, pDest);
if (!hdsa) if (!hdsa)
return FALSE; return FALSE;
@ -614,7 +614,7 @@ DSA_GetItemPtr (const HDSA hdsa, INT nIndex)
{ {
LPVOID pSrc; LPVOID pSrc;
TRACE (commctrl, "(%p %d)\n", hdsa, nIndex); TRACE("(%p %d)\n", hdsa, nIndex);
if (!hdsa) if (!hdsa)
return NULL; return NULL;
@ -623,7 +623,7 @@ DSA_GetItemPtr (const HDSA hdsa, INT nIndex)
pSrc = (char *) hdsa->pData + (hdsa->nItemSize * nIndex); pSrc = (char *) hdsa->pData + (hdsa->nItemSize * nIndex);
TRACE (commctrl, "-- ret=%p\n", pSrc); TRACE("-- ret=%p\n", pSrc);
return pSrc; return pSrc;
} }
@ -650,7 +650,7 @@ DSA_SetItem (const HDSA hdsa, INT nIndex, LPVOID pSrc)
INT nSize, nNewItems; INT nSize, nNewItems;
LPVOID pDest, lpTemp; LPVOID pDest, lpTemp;
TRACE (commctrl, "(%p %d %p)\n", hdsa, nIndex, pSrc); TRACE("(%p %d %p)\n", hdsa, nIndex, pSrc);
if ((!hdsa) || nIndex < 0) if ((!hdsa) || nIndex < 0)
return FALSE; return FALSE;
@ -679,7 +679,7 @@ DSA_SetItem (const HDSA hdsa, INT nIndex, LPVOID pSrc)
/* put the new entry in */ /* put the new entry in */
pDest = (char *) hdsa->pData + (hdsa->nItemSize * nIndex); pDest = (char *) hdsa->pData + (hdsa->nItemSize * nIndex);
TRACE (commctrl, "-- move dest=%p src=%p size=%d\n", TRACE("-- move dest=%p src=%p size=%d\n",
pDest, pSrc, hdsa->nItemSize); pDest, pSrc, hdsa->nItemSize);
memmove (pDest, pSrc, hdsa->nItemSize); memmove (pDest, pSrc, hdsa->nItemSize);
@ -707,7 +707,7 @@ DSA_InsertItem (const HDSA hdsa, INT nIndex, LPVOID pSrc)
LPVOID lpTemp, lpDest; LPVOID lpTemp, lpDest;
LPDWORD p; LPDWORD p;
TRACE(commctrl, "(%p %d %p)\n", hdsa, nIndex, pSrc); TRACE("(%p %d %p)\n", hdsa, nIndex, pSrc);
if ((!hdsa) || nIndex < 0) if ((!hdsa) || nIndex < 0)
return -1; return -1;
@ -715,9 +715,9 @@ DSA_InsertItem (const HDSA hdsa, INT nIndex, LPVOID pSrc)
for (i = 0; i < hdsa->nItemSize; i += 4) { for (i = 0; i < hdsa->nItemSize; i += 4) {
p = *(DWORD**)((char *) pSrc + i); p = *(DWORD**)((char *) pSrc + i);
if (IsBadStringPtrA ((char*)p, 256)) if (IsBadStringPtrA ((char*)p, 256))
TRACE (commctrl, "-- %d=%p\n", i, (DWORD*)p); TRACE("-- %d=%p\n", i, (DWORD*)p);
else else
TRACE (commctrl, "-- %d=%p [%s]\n", i, p, debugstr_a((char*)p)); TRACE("-- %d=%p [%s]\n", i, p, debugstr_a((char*)p));
} }
/* when nIndex > nItemCount then append */ /* when nIndex > nItemCount then append */
@ -742,7 +742,7 @@ DSA_InsertItem (const HDSA hdsa, INT nIndex, LPVOID pSrc)
lpTemp = (char *) hdsa->pData + (hdsa->nItemSize * nIndex); lpTemp = (char *) hdsa->pData + (hdsa->nItemSize * nIndex);
lpDest = (char *) lpTemp + hdsa->nItemSize; lpDest = (char *) lpTemp + hdsa->nItemSize;
nSize = (hdsa->nItemCount - nIndex) * hdsa->nItemSize; nSize = (hdsa->nItemCount - nIndex) * hdsa->nItemSize;
TRACE (commctrl, "-- move dest=%p src=%p size=%d\n", TRACE("-- move dest=%p src=%p size=%d\n",
lpDest, lpTemp, nSize); lpDest, lpTemp, nSize);
memmove (lpDest, lpTemp, nSize); memmove (lpDest, lpTemp, nSize);
} }
@ -750,7 +750,7 @@ DSA_InsertItem (const HDSA hdsa, INT nIndex, LPVOID pSrc)
/* ok, we can put the new Item in */ /* ok, we can put the new Item in */
hdsa->nItemCount++; hdsa->nItemCount++;
lpDest = (char *) hdsa->pData + (hdsa->nItemSize * nIndex); lpDest = (char *) hdsa->pData + (hdsa->nItemSize * nIndex);
TRACE (commctrl, "-- move dest=%p src=%p size=%d\n", TRACE("-- move dest=%p src=%p size=%d\n",
lpDest, pSrc, hdsa->nItemSize); lpDest, pSrc, hdsa->nItemSize);
memmove (lpDest, pSrc, hdsa->nItemSize); memmove (lpDest, pSrc, hdsa->nItemSize);
@ -776,7 +776,7 @@ DSA_DeleteItem (const HDSA hdsa, INT nIndex)
LPVOID lpDest,lpSrc; LPVOID lpDest,lpSrc;
INT nSize; INT nSize;
TRACE (commctrl, "(%p %d)\n", hdsa, nIndex); TRACE("(%p %d)\n", hdsa, nIndex);
if (!hdsa) if (!hdsa)
return -1; return -1;
@ -788,7 +788,7 @@ DSA_DeleteItem (const HDSA hdsa, INT nIndex)
lpDest = (char *) hdsa->pData + (hdsa->nItemSize * nIndex); lpDest = (char *) hdsa->pData + (hdsa->nItemSize * nIndex);
lpSrc = (char *) lpDest + hdsa->nItemSize; lpSrc = (char *) lpDest + hdsa->nItemSize;
nSize = hdsa->nItemSize * (hdsa->nItemCount - nIndex - 1); nSize = hdsa->nItemSize * (hdsa->nItemCount - nIndex - 1);
TRACE (commctrl, "-- move dest=%p src=%p size=%d\n", TRACE("-- move dest=%p src=%p size=%d\n",
lpDest, lpSrc, nSize); lpDest, lpSrc, nSize);
memmove (lpDest, lpSrc, nSize); memmove (lpDest, lpSrc, nSize);
} }
@ -827,7 +827,7 @@ DSA_DeleteItem (const HDSA hdsa, INT nIndex)
BOOL WINAPI BOOL WINAPI
DSA_DeleteAllItems (const HDSA hdsa) DSA_DeleteAllItems (const HDSA hdsa)
{ {
TRACE (commctrl, "(%p)\n", hdsa); TRACE("(%p)\n", hdsa);
if (!hdsa) if (!hdsa)
return FALSE; return FALSE;
@ -863,7 +863,7 @@ DPA_Create (INT nGrow)
{ {
HDPA hdpa; HDPA hdpa;
TRACE (commctrl, "(%d)\n", nGrow); TRACE("(%d)\n", nGrow);
hdpa = (HDPA)COMCTL32_Alloc (sizeof(DPA)); hdpa = (HDPA)COMCTL32_Alloc (sizeof(DPA));
if (hdpa) { if (hdpa) {
@ -874,7 +874,7 @@ DPA_Create (INT nGrow)
(LPVOID*)COMCTL32_Alloc (hdpa->nMaxCount * sizeof(LPVOID)); (LPVOID*)COMCTL32_Alloc (hdpa->nMaxCount * sizeof(LPVOID));
} }
TRACE (commctrl, "-- %p\n", hdpa); TRACE("-- %p\n", hdpa);
return hdpa; return hdpa;
} }
@ -894,7 +894,7 @@ DPA_Create (INT nGrow)
BOOL WINAPI BOOL WINAPI
DPA_Destroy (const HDPA hdpa) DPA_Destroy (const HDPA hdpa)
{ {
TRACE (commctrl, "(%p)\n", hdpa); TRACE("(%p)\n", hdpa);
if (!hdpa) if (!hdpa)
return FALSE; return FALSE;
@ -923,7 +923,7 @@ DPA_Destroy (const HDPA hdpa)
BOOL WINAPI BOOL WINAPI
DPA_Grow (const HDPA hdpa, INT nGrow) DPA_Grow (const HDPA hdpa, INT nGrow)
{ {
TRACE (commctrl, "(%p %d)\n", hdpa, nGrow); TRACE("(%p %d)\n", hdpa, nGrow);
if (!hdpa) if (!hdpa)
return FALSE; return FALSE;
@ -963,7 +963,7 @@ DPA_Clone (const HDPA hdpa, const HDPA hdpaNew)
if (!hdpa) if (!hdpa)
return NULL; return NULL;
TRACE (commctrl, "(%p %p)\n", hdpa, hdpaNew); TRACE("(%p %p)\n", hdpa, hdpaNew);
if (!hdpaNew) { if (!hdpaNew) {
/* create a new DPA */ /* create a new DPA */
@ -1017,7 +1017,7 @@ DPA_Clone (const HDPA hdpa, const HDPA hdpaNew)
LPVOID WINAPI LPVOID WINAPI
DPA_GetPtr (const HDPA hdpa, INT i) DPA_GetPtr (const HDPA hdpa, INT i)
{ {
TRACE (commctrl, "(%p %d)\n", hdpa, i); TRACE("(%p %d)\n", hdpa, i);
if (!hdpa) if (!hdpa)
return NULL; return NULL;
@ -1026,7 +1026,7 @@ DPA_GetPtr (const HDPA hdpa, INT i)
if ((i < 0) || (i >= hdpa->nItemCount)) if ((i < 0) || (i >= hdpa->nItemCount))
return NULL; return NULL;
TRACE (commctrl, "-- %p\n", hdpa->ptrs[i]); TRACE("-- %p\n", hdpa->ptrs[i]);
return hdpa->ptrs[i]; return hdpa->ptrs[i];
} }
@ -1084,7 +1084,7 @@ DPA_InsertPtr (const HDPA hdpa, INT i, LPVOID p)
INT nNewItems, nSize, nIndex = 0; INT nNewItems, nSize, nIndex = 0;
LPVOID *lpTemp, *lpDest; LPVOID *lpTemp, *lpDest;
TRACE (commctrl, "(%p %d %p)\n", hdpa, i, p); TRACE("(%p %d %p)\n", hdpa, i, p);
if ((!hdpa) || (i < 0)) if ((!hdpa) || (i < 0))
return -1; return -1;
@ -1100,7 +1100,7 @@ DPA_InsertPtr (const HDPA hdpa, INT i, LPVOID p)
} }
else { else {
if (hdpa->nItemCount >= hdpa->nMaxCount) { if (hdpa->nItemCount >= hdpa->nMaxCount) {
TRACE (commctrl, "-- resizing\n"); TRACE("-- resizing\n");
nNewItems = hdpa->nMaxCount + hdpa->nGrow; nNewItems = hdpa->nMaxCount + hdpa->nGrow;
nSize = nNewItems * sizeof(LPVOID); nSize = nNewItems * sizeof(LPVOID);
@ -1114,14 +1114,14 @@ DPA_InsertPtr (const HDPA hdpa, INT i, LPVOID p)
if (i >= hdpa->nItemCount) { if (i >= hdpa->nItemCount) {
nIndex = hdpa->nItemCount; nIndex = hdpa->nItemCount;
TRACE (commctrl, "-- appending at %d\n", nIndex); TRACE("-- appending at %d\n", nIndex);
} }
else { else {
TRACE (commctrl, "-- inserting at %d\n", i); TRACE("-- inserting at %d\n", i);
lpTemp = hdpa->ptrs + i; lpTemp = hdpa->ptrs + i;
lpDest = lpTemp + 1; lpDest = lpTemp + 1;
nSize = (hdpa->nItemCount - i) * sizeof(LPVOID); nSize = (hdpa->nItemCount - i) * sizeof(LPVOID);
TRACE (commctrl, "-- move dest=%p src=%p size=%x\n", TRACE("-- move dest=%p src=%p size=%x\n",
lpDest, lpTemp, nSize); lpDest, lpTemp, nSize);
memmove (lpDest, lpTemp, nSize); memmove (lpDest, lpTemp, nSize);
nIndex = i; nIndex = i;
@ -1156,7 +1156,7 @@ DPA_SetPtr (const HDPA hdpa, INT i, LPVOID p)
{ {
LPVOID *lpTemp; LPVOID *lpTemp;
TRACE (commctrl, "(%p %d %p)\n", hdpa, i, p); TRACE("(%p %d %p)\n", hdpa, i, p);
if ((!hdpa) || i < 0) if ((!hdpa) || i < 0)
return FALSE; return FALSE;
@ -1210,7 +1210,7 @@ DPA_DeletePtr (const HDPA hdpa, INT i)
LPVOID *lpDest, *lpSrc, lpTemp = NULL; LPVOID *lpDest, *lpSrc, lpTemp = NULL;
INT nSize; INT nSize;
TRACE (commctrl, "(%p %d)\n", hdpa, i); TRACE("(%p %d)\n", hdpa, i);
if ((!hdpa) || i < 0 || i >= hdpa->nItemCount) if ((!hdpa) || i < 0 || i >= hdpa->nItemCount)
return NULL; return NULL;
@ -1222,7 +1222,7 @@ DPA_DeletePtr (const HDPA hdpa, INT i)
lpDest = hdpa->ptrs + i; lpDest = hdpa->ptrs + i;
lpSrc = lpDest + 1; lpSrc = lpDest + 1;
nSize = (hdpa->nItemCount - i - 1) * sizeof(LPVOID); nSize = (hdpa->nItemCount - i - 1) * sizeof(LPVOID);
TRACE (commctrl,"-- move dest=%p src=%p size=%x\n", TRACE("-- move dest=%p src=%p size=%x\n",
lpDest, lpSrc, nSize); lpDest, lpSrc, nSize);
memmove (lpDest, lpSrc, nSize); memmove (lpDest, lpSrc, nSize);
} }
@ -1262,7 +1262,7 @@ DPA_DeletePtr (const HDPA hdpa, INT i)
BOOL WINAPI BOOL WINAPI
DPA_DeleteAllPtrs (const HDPA hdpa) DPA_DeleteAllPtrs (const HDPA hdpa)
{ {
TRACE (commctrl, "(%p)\n", hdpa); TRACE("(%p)\n", hdpa);
if (!hdpa) if (!hdpa)
return FALSE; return FALSE;
@ -1302,7 +1302,7 @@ DPA_QuickSort (LPVOID *lpPtrs, INT l, INT r,
LPVOID t, v; LPVOID t, v;
INT i, j; INT i, j;
TRACE (commctrl, "l=%i r=%i\n", l, r); TRACE("l=%i r=%i\n", l, r);
i = l; i = l;
j = r; j = r;
@ -1343,7 +1343,7 @@ DPA_Sort (const HDPA hdpa, PFNDPACOMPARE pfnCompare, LPARAM lParam)
if (!hdpa || !pfnCompare) if (!hdpa || !pfnCompare)
return FALSE; return FALSE;
TRACE (commctrl, "(%p %p 0x%lx)\n", hdpa, pfnCompare, lParam); TRACE("(%p %p 0x%lx)\n", hdpa, pfnCompare, lParam);
if ((hdpa->nItemCount > 1) && (hdpa->ptrs)) if ((hdpa->nItemCount > 1) && (hdpa->ptrs))
DPA_QuickSort (hdpa->ptrs, 0, hdpa->nItemCount - 1, DPA_QuickSort (hdpa->ptrs, 0, hdpa->nItemCount - 1,
@ -1383,7 +1383,7 @@ DPA_Search (const HDPA hdpa, LPVOID pFind, INT nStart,
if (!hdpa || !pfnCompare || !pFind) if (!hdpa || !pfnCompare || !pFind)
return -1; return -1;
TRACE (commctrl, "(%p %p %d %p 0x%08lx 0x%08x)\n", TRACE("(%p %p %d %p 0x%08lx 0x%08x)\n",
hdpa, pFind, nStart, pfnCompare, lParam, uOptions); hdpa, pFind, nStart, pfnCompare, lParam, uOptions);
if (uOptions & DPAS_SORTED) { if (uOptions & DPAS_SORTED) {
@ -1391,7 +1391,7 @@ DPA_Search (const HDPA hdpa, LPVOID pFind, INT nStart,
INT l, r, x, n; INT l, r, x, n;
LPVOID *lpPtr; LPVOID *lpPtr;
TRACE (commctrl, "binary search\n"); TRACE("binary search\n");
l = (nStart == -1) ? 0 : nStart; l = (nStart == -1) ? 0 : nStart;
r = hdpa->nItemCount - 1; r = hdpa->nItemCount - 1;
@ -1404,18 +1404,18 @@ DPA_Search (const HDPA hdpa, LPVOID pFind, INT nStart,
else else
l = x + 1; l = x + 1;
if (n == 0) { if (n == 0) {
TRACE (commctrl, "-- ret=%d\n", n); TRACE("-- ret=%d\n", n);
return n; return n;
} }
} }
if (uOptions & DPAS_INSERTBEFORE) { if (uOptions & DPAS_INSERTBEFORE) {
TRACE (commctrl, "-- ret=%d\n", r); TRACE("-- ret=%d\n", r);
return r; return r;
} }
if (uOptions & DPAS_INSERTAFTER) { if (uOptions & DPAS_INSERTAFTER) {
TRACE (commctrl, "-- ret=%d\n", l); TRACE("-- ret=%d\n", l);
return l; return l;
} }
} }
@ -1424,19 +1424,19 @@ DPA_Search (const HDPA hdpa, LPVOID pFind, INT nStart,
LPVOID *lpPtr; LPVOID *lpPtr;
INT nIndex; INT nIndex;
TRACE (commctrl, "linear search\n"); TRACE("linear search\n");
nIndex = (nStart == -1)? 0 : nStart; nIndex = (nStart == -1)? 0 : nStart;
lpPtr = hdpa->ptrs; lpPtr = hdpa->ptrs;
for (; nIndex < hdpa->nItemCount; nIndex++) { for (; nIndex < hdpa->nItemCount; nIndex++) {
if ((pfnCompare)(pFind, lpPtr[nIndex], lParam) == 0) { if ((pfnCompare)(pFind, lpPtr[nIndex], lParam) == 0) {
TRACE (commctrl, "-- ret=%d\n", nIndex); TRACE("-- ret=%d\n", nIndex);
return nIndex; return nIndex;
} }
} }
} }
TRACE (commctrl, "-- not found: ret=-1\n"); TRACE("-- not found: ret=-1\n");
return -1; return -1;
} }
@ -1460,7 +1460,7 @@ DPA_CreateEx (INT nGrow, HANDLE hHeap)
{ {
HDPA hdpa; HDPA hdpa;
TRACE (commctrl, "(%d 0x%x)\n", nGrow, hHeap); TRACE("(%d 0x%x)\n", nGrow, hHeap);
if (hHeap) if (hHeap)
hdpa = (HDPA)HeapAlloc (hHeap, HEAP_ZERO_MEMORY, sizeof(DPA)); hdpa = (HDPA)HeapAlloc (hHeap, HEAP_ZERO_MEMORY, sizeof(DPA));
@ -1476,7 +1476,7 @@ DPA_CreateEx (INT nGrow, HANDLE hHeap)
hdpa->nMaxCount * sizeof(LPVOID)); hdpa->nMaxCount * sizeof(LPVOID));
} }
TRACE (commctrl, "-- %p\n", hdpa); TRACE("-- %p\n", hdpa);
return hdpa; return hdpa;
} }
@ -1508,7 +1508,7 @@ DoNotify (LPNOTIFYDATA lpNotify, UINT uCode, LPNMHDR lpHdr)
LPNMHDR lpNmh = NULL; LPNMHDR lpNmh = NULL;
UINT idFrom = 0; UINT idFrom = 0;
TRACE (commctrl, "(0x%04x 0x%04x %d %p 0x%08lx)\n", TRACE("(0x%04x 0x%04x %d %p 0x%08lx)\n",
lpNotify->hwndFrom, lpNotify->hwndTo, uCode, lpHdr, lpNotify->hwndFrom, lpNotify->hwndTo, uCode, lpHdr,
lpNotify->dwParam5); lpNotify->dwParam5);
@ -1560,7 +1560,7 @@ COMCTL32_SendNotify (HWND hwndFrom, HWND hwndTo,
{ {
NOTIFYDATA notify; NOTIFYDATA notify;
TRACE (commctrl, "(0x%04x 0x%04x %d %p)\n", TRACE("(0x%04x 0x%04x %d %p)\n",
hwndFrom, hwndTo, uCode, lpHdr); hwndFrom, hwndTo, uCode, lpHdr);
notify.hwndFrom = hwndFrom; notify.hwndFrom = hwndFrom;
@ -1594,7 +1594,7 @@ COMCTL32_SendNotifyEx (HWND hwndTo, HWND hwndFrom, UINT uCode,
NOTIFYDATA notify; NOTIFYDATA notify;
HWND hwndNotify; HWND hwndNotify;
TRACE (commctrl, "(0x%04x 0x%04x %d %p 0x%08lx)\n", TRACE("(0x%04x 0x%04x %d %p 0x%08lx)\n",
hwndFrom, hwndTo, uCode, lpHdr, dwParam5); hwndFrom, hwndTo, uCode, lpHdr, dwParam5);
hwndNotify = hwndTo; hwndNotify = hwndTo;
@ -1690,7 +1690,7 @@ DPA_EnumCallback (const HDPA hdpa, DPAENUMPROC enumProc, LPARAM lParam)
{ {
INT i; INT i;
TRACE (commctrl, "(%p %p %08lx)\n", hdpa, enumProc, lParam); TRACE("(%p %p %08lx)\n", hdpa, enumProc, lParam);
if (!hdpa) if (!hdpa)
return; return;
@ -1724,7 +1724,7 @@ DPA_EnumCallback (const HDPA hdpa, DPAENUMPROC enumProc, LPARAM lParam)
BOOL WINAPI BOOL WINAPI
DPA_DestroyCallback (const HDPA hdpa, DPAENUMPROC enumProc, LPARAM lParam) DPA_DestroyCallback (const HDPA hdpa, DPAENUMPROC enumProc, LPARAM lParam)
{ {
TRACE (commctrl, "(%p %p %08lx)\n", hdpa, enumProc, lParam); TRACE("(%p %p %08lx)\n", hdpa, enumProc, lParam);
DPA_EnumCallback (hdpa, enumProc, lParam); DPA_EnumCallback (hdpa, enumProc, lParam);
@ -1751,7 +1751,7 @@ DSA_EnumCallback (const HDSA hdsa, DSAENUMPROC enumProc, LPARAM lParam)
{ {
INT i; INT i;
TRACE (commctrl, "(%p %p %08lx)\n", hdsa, enumProc, lParam); TRACE("(%p %p %08lx)\n", hdsa, enumProc, lParam);
if (!hdsa) if (!hdsa)
return; return;
@ -1786,7 +1786,7 @@ DSA_EnumCallback (const HDSA hdsa, DSAENUMPROC enumProc, LPARAM lParam)
BOOL WINAPI BOOL WINAPI
DSA_DestroyCallback (const HDSA hdsa, DSAENUMPROC enumProc, LPARAM lParam) DSA_DestroyCallback (const HDSA hdsa, DSAENUMPROC enumProc, LPARAM lParam)
{ {
TRACE (commctrl, "(%p %p %08lx)\n", hdsa, enumProc, lParam); TRACE("(%p %p %08lx)\n", hdsa, enumProc, lParam);
DSA_EnumCallback (hdsa, enumProc, lParam); DSA_EnumCallback (hdsa, enumProc, lParam);
@ -1884,7 +1884,7 @@ INT WINAPI COMCTL32_StrSpnW( LPWSTR lpStr, LPWSTR lpSet) {
DWORD WINAPI DPA_LoadStream(HDPA *hDpa, DWORD pfnDpaLoadCallback, DWORD param3, DWORD param4) DWORD WINAPI DPA_LoadStream(HDPA *hDpa, DWORD pfnDpaLoadCallback, DWORD param3, DWORD param4)
{ {
FIXME(commctrl, "(%p %lx %lx %lx): partial stub!\n", hDpa, pfnDpaLoadCallback, param3, param4); FIXME("(%p %lx %lx %lx): partial stub!\n", hDpa, pfnDpaLoadCallback, param3, param4);
*hDpa = DPA_Create(8); *hDpa = DPA_Create(8);
@ -1899,7 +1899,7 @@ DWORD WINAPI DPA_LoadStream(HDPA *hDpa, DWORD pfnDpaLoadCallback, DWORD param3,
DWORD WINAPI DPA_SaveStream(DWORD param1, DWORD param2, DWORD param3, DWORD param4) DWORD WINAPI DPA_SaveStream(DWORD param1, DWORD param2, DWORD param3, DWORD param4)
{ {
FIXME(commctrl, "(%lx %lx %lx %lx): stub!\n", param1, param2, param3, param4); FIXME("(%lx %lx %lx %lx): stub!\n", param1, param2, param3, param4);
return(0); return(0);
} }

View file

@ -29,7 +29,7 @@
#include "trackbar.h" #include "trackbar.h"
#include "treeview.h" #include "treeview.h"
#include "updown.h" #include "updown.h"
#include "debug.h" #include "debugtools.h"
#include "winerror.h" #include "winerror.h"
DEFAULT_DEBUG_CHANNEL(commctrl) DEFAULT_DEBUG_CHANNEL(commctrl)
@ -57,7 +57,7 @@ HMODULE COMCTL32_hModule = 0;
BOOL WINAPI BOOL WINAPI
COMCTL32_LibMain (HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved) COMCTL32_LibMain (HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved)
{ {
TRACE (commctrl, "%x,%lx,%p\n", hinstDLL, fdwReason, lpvReserved); TRACE("%x,%lx,%p\n", hinstDLL, fdwReason, lpvReserved);
switch (fdwReason) { switch (fdwReason) {
case DLL_PROCESS_ATTACH: case DLL_PROCESS_ATTACH:
@ -68,11 +68,11 @@ COMCTL32_LibMain (HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved)
/* create private heap */ /* create private heap */
COMCTL32_hHeap = HeapCreate (0, 0x10000, 0); COMCTL32_hHeap = HeapCreate (0, 0x10000, 0);
TRACE (commctrl, "Heap created: 0x%x\n", COMCTL32_hHeap); TRACE("Heap created: 0x%x\n", COMCTL32_hHeap);
/* add global subclassing atom (used by 'tooltip' and 'updown') */ /* add global subclassing atom (used by 'tooltip' and 'updown') */
COMCTL32_aSubclass = (LPSTR)(DWORD)GlobalAddAtomA ("CC32SubclassInfo"); COMCTL32_aSubclass = (LPSTR)(DWORD)GlobalAddAtomA ("CC32SubclassInfo");
TRACE (commctrl, "Subclassing atom added: %p\n", TRACE("Subclassing atom added: %p\n",
COMCTL32_aSubclass); COMCTL32_aSubclass);
/* register all Win95 common control classes */ /* register all Win95 common control classes */
@ -120,13 +120,13 @@ COMCTL32_LibMain (HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved)
/* delete global subclassing atom */ /* delete global subclassing atom */
GlobalDeleteAtom (LOWORD(COMCTL32_aSubclass)); GlobalDeleteAtom (LOWORD(COMCTL32_aSubclass));
TRACE (commctrl, "Subclassing atom deleted: %p\n", TRACE("Subclassing atom deleted: %p\n",
COMCTL32_aSubclass); COMCTL32_aSubclass);
COMCTL32_aSubclass = (LPSTR)NULL; COMCTL32_aSubclass = (LPSTR)NULL;
/* destroy private heap */ /* destroy private heap */
HeapDestroy (COMCTL32_hHeap); HeapDestroy (COMCTL32_hHeap);
TRACE (commctrl, "Heap destroyed: 0x%x\n", COMCTL32_hHeap); TRACE("Heap destroyed: 0x%x\n", COMCTL32_hHeap);
COMCTL32_hHeap = (HANDLE)NULL; COMCTL32_hHeap = (HANDLE)NULL;
} }
break; break;
@ -174,12 +174,12 @@ MenuHelp (UINT uMsg, WPARAM wParam, LPARAM lParam, HMENU hMainMenu,
switch (uMsg) { switch (uMsg) {
case WM_MENUSELECT: case WM_MENUSELECT:
TRACE (commctrl, "WM_MENUSELECT wParam=0x%X lParam=0x%lX\n", TRACE("WM_MENUSELECT wParam=0x%X lParam=0x%lX\n",
wParam, lParam); wParam, lParam);
if ((HIWORD(wParam) == 0xFFFF) && (lParam == 0)) { if ((HIWORD(wParam) == 0xFFFF) && (lParam == 0)) {
/* menu was closed */ /* menu was closed */
TRACE (commctrl, "menu was closed!\n"); TRACE("menu was closed!\n");
SendMessageA (hwndStatus, SB_SIMPLE, FALSE, 0); SendMessageA (hwndStatus, SB_SIMPLE, FALSE, 0);
} }
else { else {
@ -188,7 +188,7 @@ MenuHelp (UINT uMsg, WPARAM wParam, LPARAM lParam, HMENU hMainMenu,
uMenuID = (UINT)*(lpwIDs+1); uMenuID = (UINT)*(lpwIDs+1);
else else
uMenuID = (UINT)LOWORD(wParam); uMenuID = (UINT)LOWORD(wParam);
TRACE (commctrl, "uMenuID = %u\n", uMenuID); TRACE("uMenuID = %u\n", uMenuID);
if (uMenuID) { if (uMenuID) {
CHAR szText[256]; CHAR szText[256];
@ -204,7 +204,7 @@ MenuHelp (UINT uMsg, WPARAM wParam, LPARAM lParam, HMENU hMainMenu,
break; break;
default: default:
FIXME (commctrl, "Invalid Message 0x%x!\n", uMsg); FIXME("Invalid Message 0x%x!\n", uMsg);
break; break;
} }
} }
@ -245,7 +245,7 @@ ShowHideMenuCtl (HWND hwnd, UINT uFlags, LPINT lpInfo)
{ {
LPINT lpMenuId; LPINT lpMenuId;
TRACE (commctrl, "%x, %x, %p\n", hwnd, uFlags, lpInfo); TRACE("%x, %x, %p\n", hwnd, uFlags, lpInfo);
if (lpInfo == NULL) if (lpInfo == NULL)
return FALSE; return FALSE;
@ -307,7 +307,7 @@ GetEffectiveClientRect (HWND hwnd, LPRECT lpRect, LPINT lpInfo)
INT *lpRun; INT *lpRun;
HWND hwndCtrl; HWND hwndCtrl;
TRACE (commctrl, "(0x%08lx 0x%08lx 0x%08lx)\n", TRACE("(0x%08lx 0x%08lx 0x%08lx)\n",
(DWORD)hwnd, (DWORD)lpRect, (DWORD)lpInfo); (DWORD)hwnd, (DWORD)lpRect, (DWORD)lpInfo);
GetClientRect (hwnd, lpRect); GetClientRect (hwnd, lpRect);
@ -320,7 +320,7 @@ GetEffectiveClientRect (HWND hwnd, LPRECT lpRect, LPINT lpInfo)
lpRun++; lpRun++;
hwndCtrl = GetDlgItem (hwnd, *lpRun); hwndCtrl = GetDlgItem (hwnd, *lpRun);
if (GetWindowLongA (hwndCtrl, GWL_STYLE) & WS_VISIBLE) { if (GetWindowLongA (hwndCtrl, GWL_STYLE) & WS_VISIBLE) {
TRACE (commctrl, "control id 0x%x\n", *lpRun); TRACE("control id 0x%x\n", *lpRun);
GetWindowRect (hwndCtrl, &rcCtrl); GetWindowRect (hwndCtrl, &rcCtrl);
MapWindowPoints ((HWND)0, hwnd, (LPPOINT)&rcCtrl, 2); MapWindowPoints ((HWND)0, hwnd, (LPPOINT)&rcCtrl, 2);
SubtractRect (lpRect, lpRect, &rcCtrl); SubtractRect (lpRect, lpRect, &rcCtrl);
@ -539,7 +539,7 @@ InitCommonControlsEx (LPINITCOMMONCONTROLSEX lpInitCtrls)
if (lpInitCtrls->dwSize != sizeof(INITCOMMONCONTROLSEX)) if (lpInitCtrls->dwSize != sizeof(INITCOMMONCONTROLSEX))
return FALSE; return FALSE;
TRACE(commctrl,"(0x%08lx)\n", lpInitCtrls->dwICC); TRACE("(0x%08lx)\n", lpInitCtrls->dwICC);
for (cCount = 0; cCount < 32; cCount++) { for (cCount = 0; cCount < 32; cCount++) {
dwMask = 1 << cCount; dwMask = 1 << cCount;
@ -585,7 +585,7 @@ InitCommonControlsEx (LPINITCOMMONCONTROLSEX lpInitCtrls)
break; break;
default: default:
FIXME (commctrl, "Unknown class! dwICC=0x%lX\n", dwMask); FIXME("Unknown class! dwICC=0x%lX\n", dwMask);
break; break;
} }
} }
@ -819,7 +819,7 @@ HRESULT WINAPI
COMCTL32_DllGetVersion (DLLVERSIONINFO *pdvi) COMCTL32_DllGetVersion (DLLVERSIONINFO *pdvi)
{ {
if (pdvi->cbSize != sizeof(DLLVERSIONINFO)) { if (pdvi->cbSize != sizeof(DLLVERSIONINFO)) {
WARN (commctrl, "wrong DLLVERSIONINFO size from app"); WARN("wrong DLLVERSIONINFO size from app");
return E_INVALIDARG; return E_INVALIDARG;
} }
@ -828,7 +828,7 @@ COMCTL32_DllGetVersion (DLLVERSIONINFO *pdvi)
pdvi->dwBuildNumber = 3110; pdvi->dwBuildNumber = 3110;
pdvi->dwPlatformID = 1; pdvi->dwPlatformID = 1;
TRACE (commctrl, "%lu.%lu.%lu.%lu\n", TRACE("%lu.%lu.%lu.%lu\n",
pdvi->dwMajorVersion, pdvi->dwMinorVersion, pdvi->dwMajorVersion, pdvi->dwMinorVersion,
pdvi->dwBuildNumber, pdvi->dwPlatformID); pdvi->dwBuildNumber, pdvi->dwPlatformID);

View file

@ -17,7 +17,7 @@
#include "winbase.h" #include "winbase.h"
#include "commctrl.h" #include "commctrl.h"
#include "datetime.h" #include "datetime.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(datetime) DEFAULT_DEBUG_CHANNEL(datetime)
@ -37,7 +37,7 @@ DATETIME_Create (HWND hwnd, WPARAM wParam, LPARAM lParam)
/* allocate memory for info structure */ /* allocate memory for info structure */
infoPtr = (DATETIME_INFO *)COMCTL32_Alloc (sizeof(DATETIME_INFO)); infoPtr = (DATETIME_INFO *)COMCTL32_Alloc (sizeof(DATETIME_INFO));
if (infoPtr == NULL) { if (infoPtr == NULL) {
ERR (datetime, "could not allocate info memory!\n"); ERR("could not allocate info memory!\n");
return 0; return 0;
} }
@ -73,47 +73,47 @@ DATETIME_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
{ {
case DTM_GETSYSTEMTIME: case DTM_GETSYSTEMTIME:
FIXME (datetime, "Unimplemented msg DTM_GETSYSTEMTIME\n"); FIXME("Unimplemented msg DTM_GETSYSTEMTIME\n");
return GDT_VALID; return GDT_VALID;
case DTM_SETSYSTEMTIME: case DTM_SETSYSTEMTIME:
FIXME (datetime, "Unimplemented msg DTM_SETSYSTEMTIME\n"); FIXME("Unimplemented msg DTM_SETSYSTEMTIME\n");
return 1; return 1;
case DTM_GETRANGE: case DTM_GETRANGE:
FIXME (datetime, "Unimplemented msg DTM_GETRANGE\n"); FIXME("Unimplemented msg DTM_GETRANGE\n");
return 0; return 0;
case DTM_SETRANGE: case DTM_SETRANGE:
FIXME (datetime, "Unimplemented msg DTM_SETRANGE\n"); FIXME("Unimplemented msg DTM_SETRANGE\n");
return 1; return 1;
case DTM_SETFORMATA: case DTM_SETFORMATA:
FIXME (datetime, "Unimplemented msg DTM_SETFORMAT32A\n"); FIXME("Unimplemented msg DTM_SETFORMAT32A\n");
return 1; return 1;
case DTM_SETFORMATW: case DTM_SETFORMATW:
FIXME (datetime, "Unimplemented msg DTM_SETFORMAT32W\n"); FIXME("Unimplemented msg DTM_SETFORMAT32W\n");
return 1; return 1;
case DTM_SETMCCOLOR: case DTM_SETMCCOLOR:
FIXME (datetime, "Unimplemented msg DTM_SETMCCOLOR\n"); FIXME("Unimplemented msg DTM_SETMCCOLOR\n");
return 0; return 0;
case DTM_GETMCCOLOR: case DTM_GETMCCOLOR:
FIXME (datetime, "Unimplemented msg DTM_GETMCCOLOR\n"); FIXME("Unimplemented msg DTM_GETMCCOLOR\n");
return 0; return 0;
case DTM_GETMONTHCAL: case DTM_GETMONTHCAL:
FIXME (datetime, "Unimplemented msg DTM_GETMONTHCAL\n"); FIXME("Unimplemented msg DTM_GETMONTHCAL\n");
return 0; return 0;
case DTM_SETMCFONT: case DTM_SETMCFONT:
FIXME (datetime, "Unimplemented msg DTM_SETMCFONT\n"); FIXME("Unimplemented msg DTM_SETMCFONT\n");
return 0; return 0;
case DTM_GETMCFONT: case DTM_GETMCFONT:
FIXME (datetime, "Unimplemented msg DTM_GETMCFONT\n"); FIXME("Unimplemented msg DTM_GETMCFONT\n");
return 0; return 0;
case WM_CREATE: case WM_CREATE:
@ -124,7 +124,7 @@ DATETIME_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
default: default:
if (uMsg >= WM_USER) if (uMsg >= WM_USER)
ERR (datetime, "unknown msg %04x wp=%08x lp=%08lx\n", ERR("unknown msg %04x wp=%08x lp=%08lx\n",
uMsg, wParam, lParam); uMsg, wParam, lParam);
return DefWindowProcA (hwnd, uMsg, wParam, lParam); return DefWindowProcA (hwnd, uMsg, wParam, lParam);
} }

View file

@ -13,14 +13,14 @@
*/ */
#include "commctrl.h" #include "commctrl.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(commctrl) DEFAULT_DEBUG_CHANNEL(commctrl)
BOOL WINAPI MakeDragList (HWND hwndLB) BOOL WINAPI MakeDragList (HWND hwndLB)
{ {
FIXME (commctrl, "(0x%x)\n", hwndLB); FIXME("(0x%x)\n", hwndLB);
return FALSE; return FALSE;
@ -29,7 +29,7 @@ BOOL WINAPI MakeDragList (HWND hwndLB)
VOID WINAPI DrawInsert (HWND hwndParent, HWND hwndLB, INT nItem) VOID WINAPI DrawInsert (HWND hwndParent, HWND hwndLB, INT nItem)
{ {
FIXME (commctrl, "(0x%x 0x%x %d)\n", hwndParent, hwndLB, nItem); FIXME("(0x%x 0x%x %d)\n", hwndParent, hwndLB, nItem);
} }
@ -37,7 +37,7 @@ VOID WINAPI DrawInsert (HWND hwndParent, HWND hwndLB, INT nItem)
INT WINAPI LBItemFromPt (HWND hwndLB, POINT pt, BOOL bAutoScroll) INT WINAPI LBItemFromPt (HWND hwndLB, POINT pt, BOOL bAutoScroll)
{ {
FIXME (commctrl, "(0x%x %ld x %ld %s)\n", FIXME("(0x%x %ld x %ld %s)\n",
hwndLB, pt.x, pt.y, bAutoScroll ? "TRUE" : "FALSE"); hwndLB, pt.x, pt.y, bAutoScroll ? "TRUE" : "FALSE");

View file

@ -24,7 +24,7 @@
#include "winbase.h" #include "winbase.h"
#include "commctrl.h" #include "commctrl.h"
#include "header.h" #include "header.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(header) DEFAULT_DEBUG_CHANNEL(header)
@ -309,7 +309,7 @@ HEADER_InternalHitTest (HWND hwnd, LPPOINT lpPt, UINT *pFlags, INT *pItem)
if (infoPtr->uNumItem == 0) { if (infoPtr->uNumItem == 0) {
*pFlags |= HHT_NOWHERE; *pFlags |= HHT_NOWHERE;
*pItem = 1; *pItem = 1;
TRACE (header, "NOWHERE\n"); TRACE("NOWHERE\n");
return; return;
} }
else { else {
@ -325,7 +325,7 @@ HEADER_InternalHitTest (HWND hwnd, LPPOINT lpPt, UINT *pFlags, INT *pItem)
if (width <= 2 * DIVIDER_WIDTH) { if (width <= 2 * DIVIDER_WIDTH) {
*pFlags |= HHT_ONHEADER; *pFlags |= HHT_ONHEADER;
*pItem = iCount; *pItem = iCount;
TRACE (header, "ON HEADER %d\n", iCount); TRACE("ON HEADER %d\n", iCount);
return; return;
} }
if (iCount > 0) { if (iCount > 0) {
@ -335,13 +335,13 @@ HEADER_InternalHitTest (HWND hwnd, LPPOINT lpPt, UINT *pFlags, INT *pItem)
if (bNoWidth) { if (bNoWidth) {
*pFlags |= HHT_ONDIVOPEN; *pFlags |= HHT_ONDIVOPEN;
*pItem = iCount - 1; *pItem = iCount - 1;
TRACE (header, "ON DIVOPEN %d\n", *pItem); TRACE("ON DIVOPEN %d\n", *pItem);
return; return;
} }
else { else {
*pFlags |= HHT_ONDIVIDER; *pFlags |= HHT_ONDIVIDER;
*pItem = iCount - 1; *pItem = iCount - 1;
TRACE (header, "ON DIVIDER %d\n", *pItem); TRACE("ON DIVIDER %d\n", *pItem);
return; return;
} }
} }
@ -351,13 +351,13 @@ HEADER_InternalHitTest (HWND hwnd, LPPOINT lpPt, UINT *pFlags, INT *pItem)
if (PtInRect (&rcTest, *lpPt)) { if (PtInRect (&rcTest, *lpPt)) {
*pFlags |= HHT_ONDIVIDER; *pFlags |= HHT_ONDIVIDER;
*pItem = iCount; *pItem = iCount;
TRACE (header, "ON DIVIDER %d\n", *pItem); TRACE("ON DIVIDER %d\n", *pItem);
return; return;
} }
*pFlags |= HHT_ONHEADER; *pFlags |= HHT_ONHEADER;
*pItem = iCount; *pItem = iCount;
TRACE (header, "ON HEADER %d\n", iCount); TRACE("ON HEADER %d\n", iCount);
return; return;
} }
} }
@ -370,45 +370,45 @@ HEADER_InternalHitTest (HWND hwnd, LPPOINT lpPt, UINT *pFlags, INT *pItem)
if (bNoWidth) { if (bNoWidth) {
*pFlags |= HHT_ONDIVOPEN; *pFlags |= HHT_ONDIVOPEN;
*pItem = infoPtr->uNumItem - 1; *pItem = infoPtr->uNumItem - 1;
TRACE (header, "ON DIVOPEN %d\n", *pItem); TRACE("ON DIVOPEN %d\n", *pItem);
return; return;
} }
else { else {
*pFlags |= HHT_ONDIVIDER; *pFlags |= HHT_ONDIVIDER;
*pItem = infoPtr->uNumItem-1; *pItem = infoPtr->uNumItem-1;
TRACE (header, "ON DIVIDER %d\n", *pItem); TRACE("ON DIVIDER %d\n", *pItem);
return; return;
} }
} }
*pFlags |= HHT_NOWHERE; *pFlags |= HHT_NOWHERE;
*pItem = 1; *pItem = 1;
TRACE (header, "NOWHERE\n"); TRACE("NOWHERE\n");
return; return;
} }
} }
else { else {
if (lpPt->x < rect.left) { if (lpPt->x < rect.left) {
TRACE (header, "TO LEFT\n"); TRACE("TO LEFT\n");
*pFlags |= HHT_TOLEFT; *pFlags |= HHT_TOLEFT;
} }
else if (lpPt->x > rect.right) { else if (lpPt->x > rect.right) {
TRACE (header, "TO LEFT\n"); TRACE("TO LEFT\n");
*pFlags |= HHT_TORIGHT; *pFlags |= HHT_TORIGHT;
} }
if (lpPt->y < rect.top) { if (lpPt->y < rect.top) {
TRACE (header, "ABOVE\n"); TRACE("ABOVE\n");
*pFlags |= HHT_ABOVE; *pFlags |= HHT_ABOVE;
} }
else if (lpPt->y > rect.bottom) { else if (lpPt->y > rect.bottom) {
TRACE (header, "BELOW\n"); TRACE("BELOW\n");
*pFlags |= HHT_BELOW; *pFlags |= HHT_BELOW;
} }
} }
*pItem = 1; *pItem = 1;
TRACE (header, "flags=0x%X\n", *pFlags); TRACE("flags=0x%X\n", *pFlags);
return; return;
} }
@ -495,7 +495,7 @@ HEADER_SendClickNotify (HWND hwnd, UINT code, INT iItem)
static LRESULT static LRESULT
HEADER_CreateDragImage (HWND hwnd, WPARAM wParam) HEADER_CreateDragImage (HWND hwnd, WPARAM wParam)
{ {
FIXME (header, "empty stub!\n"); FIXME("empty stub!\n");
return 0; return 0;
} }
@ -507,13 +507,13 @@ HEADER_DeleteItem (HWND hwnd, WPARAM wParam)
INT iItem = (INT)wParam; INT iItem = (INT)wParam;
HDC hdc; HDC hdc;
TRACE(header, "[iItem=%d]\n", iItem); TRACE("[iItem=%d]\n", iItem);
if ((iItem < 0) || (iItem >= (INT)infoPtr->uNumItem)) if ((iItem < 0) || (iItem >= (INT)infoPtr->uNumItem))
return FALSE; return FALSE;
if (infoPtr->uNumItem == 1) { if (infoPtr->uNumItem == 1) {
TRACE(header, "Simple delete!\n"); TRACE("Simple delete!\n");
if (infoPtr->items[0].pszText) if (infoPtr->items[0].pszText)
COMCTL32_Free (infoPtr->items[0].pszText); COMCTL32_Free (infoPtr->items[0].pszText);
COMCTL32_Free (infoPtr->items); COMCTL32_Free (infoPtr->items);
@ -522,7 +522,7 @@ HEADER_DeleteItem (HWND hwnd, WPARAM wParam)
} }
else { else {
HEADER_ITEM *oldItems = infoPtr->items; HEADER_ITEM *oldItems = infoPtr->items;
TRACE(header, "Complex delete! [iItem=%d]\n", iItem); TRACE("Complex delete! [iItem=%d]\n", iItem);
if (infoPtr->items[iItem].pszText) if (infoPtr->items[iItem].pszText)
COMCTL32_Free (infoPtr->items[iItem].pszText); COMCTL32_Free (infoPtr->items[iItem].pszText);
@ -576,7 +576,7 @@ HEADER_GetItemA (HWND hwnd, WPARAM wParam, LPARAM lParam)
if ((nItem < 0) || (nItem >= (INT)infoPtr->uNumItem)) if ((nItem < 0) || (nItem >= (INT)infoPtr->uNumItem))
return FALSE; return FALSE;
TRACE (header, "[nItem=%d]\n", nItem); TRACE("[nItem=%d]\n", nItem);
if (phdi->mask == 0) if (phdi->mask == 0)
return TRUE; return TRUE;
@ -624,7 +624,7 @@ HEADER_GetItemW (HWND hwnd, WPARAM wParam, LPARAM lParam)
if ((nItem < 0) || (nItem >= (INT)infoPtr->uNumItem)) if ((nItem < 0) || (nItem >= (INT)infoPtr->uNumItem))
return FALSE; return FALSE;
TRACE (header, "[nItem=%d]\n", nItem); TRACE("[nItem=%d]\n", nItem);
if (phdi->mask == 0) if (phdi->mask == 0)
return TRUE; return TRUE;
@ -905,7 +905,7 @@ HEADER_Layout (HWND hwnd, WPARAM wParam, LPARAM lParam)
lpLayout->pwpos->cy = infoPtr->nHeight; lpLayout->pwpos->cy = infoPtr->nHeight;
lpLayout->pwpos->flags = SWP_NOZORDER; lpLayout->pwpos->flags = SWP_NOZORDER;
TRACE (header, "Layout x=%d y=%d cx=%d cy=%d\n", TRACE("Layout x=%d y=%d cx=%d cy=%d\n",
lpLayout->pwpos->x, lpLayout->pwpos->y, lpLayout->pwpos->x, lpLayout->pwpos->y,
lpLayout->pwpos->cx, lpLayout->pwpos->cy); lpLayout->pwpos->cx, lpLayout->pwpos->cy);
@ -950,7 +950,7 @@ HEADER_SetItemA (HWND hwnd, WPARAM wParam, LPARAM lParam)
if ((nItem < 0) || (nItem >= (INT)infoPtr->uNumItem)) if ((nItem < 0) || (nItem >= (INT)infoPtr->uNumItem))
return FALSE; return FALSE;
TRACE (header, "[nItem=%d]\n", nItem); TRACE("[nItem=%d]\n", nItem);
if (HEADER_SendHeaderNotify (hwnd, HDN_ITEMCHANGINGA, nItem)) if (HEADER_SendHeaderNotify (hwnd, HDN_ITEMCHANGINGA, nItem))
return FALSE; return FALSE;
@ -1015,7 +1015,7 @@ HEADER_SetItemW (HWND hwnd, WPARAM wParam, LPARAM lParam)
if ((nItem < 0) || (nItem >= (INT)infoPtr->uNumItem)) if ((nItem < 0) || (nItem >= (INT)infoPtr->uNumItem))
return FALSE; return FALSE;
TRACE (header, "[nItem=%d]\n", nItem); TRACE("[nItem=%d]\n", nItem);
if (HEADER_SendHeaderNotify (hwnd, HDN_ITEMCHANGINGA, nItem)) if (HEADER_SendHeaderNotify (hwnd, HDN_ITEMCHANGINGA, nItem))
return FALSE; return FALSE;
@ -1198,7 +1198,7 @@ HEADER_LButtonDown (HWND hwnd, WPARAM wParam, LPARAM lParam)
HEADER_RefreshItem (hwnd, hdc, nItem); HEADER_RefreshItem (hwnd, hdc, nItem);
ReleaseDC (hwnd, hdc); ReleaseDC (hwnd, hdc);
TRACE (header, "Pressed item %d!\n", nItem); TRACE("Pressed item %d!\n", nItem);
} }
else if ((flags == HHT_ONDIVIDER) || (flags == HHT_ONDIVOPEN)) { else if ((flags == HHT_ONDIVIDER) || (flags == HHT_ONDIVOPEN)) {
if (!(HEADER_SendHeaderNotify (hwnd, HDN_BEGINTRACKA, nItem))) { if (!(HEADER_SendHeaderNotify (hwnd, HDN_BEGINTRACKA, nItem))) {
@ -1216,7 +1216,7 @@ HEADER_LButtonDown (HWND hwnd, WPARAM wParam, LPARAM lParam)
ReleaseDC (hwnd, hdc); ReleaseDC (hwnd, hdc);
} }
TRACE (header, "Begin tracking item %d!\n", nItem); TRACE("Begin tracking item %d!\n", nItem);
} }
} }
@ -1247,11 +1247,11 @@ HEADER_LButtonUp (HWND hwnd, WPARAM wParam, LPARAM lParam)
HEADER_SendClickNotify (hwnd, HDN_ITEMCLICKA, infoPtr->iMoveItem); HEADER_SendClickNotify (hwnd, HDN_ITEMCLICKA, infoPtr->iMoveItem);
} }
TRACE (header, "Released item %d!\n", infoPtr->iMoveItem); TRACE("Released item %d!\n", infoPtr->iMoveItem);
infoPtr->bPressed = FALSE; infoPtr->bPressed = FALSE;
} }
else if (infoPtr->bTracking) { else if (infoPtr->bTracking) {
TRACE (header, "End tracking item %d!\n", infoPtr->iMoveItem); TRACE("End tracking item %d!\n", infoPtr->iMoveItem);
infoPtr->bTracking = FALSE; infoPtr->bTracking = FALSE;
HEADER_SendHeaderNotify (hwnd, HDN_ENDTRACKA, infoPtr->iMoveItem); HEADER_SendHeaderNotify (hwnd, HDN_ENDTRACKA, infoPtr->iMoveItem);
@ -1321,7 +1321,7 @@ HEADER_MouseMove (HWND hwnd, WPARAM wParam, LPARAM lParam)
HEADER_RefreshItem (hwnd, hdc, infoPtr->iMoveItem); HEADER_RefreshItem (hwnd, hdc, infoPtr->iMoveItem);
ReleaseDC (hwnd, hdc); ReleaseDC (hwnd, hdc);
TRACE (header, "Moving pressed item %d!\n", infoPtr->iMoveItem); TRACE("Moving pressed item %d!\n", infoPtr->iMoveItem);
} }
else if (infoPtr->bTracking) { else if (infoPtr->bTracking) {
if (dwStyle & HDS_FULLDRAG) { if (dwStyle & HDS_FULLDRAG) {
@ -1353,12 +1353,12 @@ HEADER_MouseMove (HWND hwnd, WPARAM wParam, LPARAM lParam)
} }
HEADER_SendHeaderNotify (hwnd, HDN_TRACKA, infoPtr->iMoveItem); HEADER_SendHeaderNotify (hwnd, HDN_TRACKA, infoPtr->iMoveItem);
TRACE (header, "Tracking item %d!\n", infoPtr->iMoveItem); TRACE("Tracking item %d!\n", infoPtr->iMoveItem);
} }
} }
if ((dwStyle & HDS_BUTTONS) && (dwStyle & HDS_HOTTRACK)) { if ((dwStyle & HDS_BUTTONS) && (dwStyle & HDS_HOTTRACK)) {
FIXME (header, "hot track support!\n"); FIXME("hot track support!\n");
} }
return 0; return 0;
@ -1394,7 +1394,7 @@ HEADER_SetCursor (HWND hwnd, WPARAM wParam, LPARAM lParam)
UINT flags; UINT flags;
INT nItem; INT nItem;
TRACE (header, "code=0x%X id=0x%X\n", LOWORD(lParam), HIWORD(lParam)); TRACE("code=0x%X id=0x%X\n", LOWORD(lParam), HIWORD(lParam));
GetCursorPos (&pt); GetCursorPos (&pt);
ScreenToClient (hwnd, &pt); ScreenToClient (hwnd, &pt);
@ -1542,7 +1542,7 @@ HEADER_WindowProc (HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
default: default:
if (msg >= WM_USER) if (msg >= WM_USER)
ERR (header, "unknown msg %04x wp=%04x lp=%08lx\n", ERR("unknown msg %04x wp=%04x lp=%08lx\n",
msg, wParam, lParam ); msg, wParam, lParam );
return DefWindowProcA (hwnd, msg, wParam, lParam); return DefWindowProcA (hwnd, msg, wParam, lParam);
} }

View file

@ -16,7 +16,7 @@
#include "winbase.h" #include "winbase.h"
#include "commctrl.h" #include "commctrl.h"
#include "hotkey.h" #include "hotkey.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(hotkey) DEFAULT_DEBUG_CHANNEL(hotkey)
@ -117,11 +117,11 @@ HOTKEY_KeyDown (HWND hwnd, WPARAM wParam, LPARAM lParam)
case VK_SHIFT: case VK_SHIFT:
case VK_CONTROL: case VK_CONTROL:
case VK_MENU: case VK_MENU:
FIXME (hotkey, "modifier key pressed!\n"); FIXME("modifier key pressed!\n");
break; break;
default: default:
FIXME (hotkey, " %d\n", wParam); FIXME(" %d\n", wParam);
break; break;
} }
@ -134,7 +134,7 @@ HOTKEY_KeyUp (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
/* HOTKEY_INFO *infoPtr = HOTKEY_GetInfoPtr (hwnd); */ /* HOTKEY_INFO *infoPtr = HOTKEY_GetInfoPtr (hwnd); */
FIXME (hotkey, " %d\n", wParam); FIXME(" %d\n", wParam);
return 0; return 0;
} }
@ -217,7 +217,7 @@ HOTKEY_SetFont (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (LOWORD(lParam)) { if (LOWORD(lParam)) {
FIXME (hotkey, "force redraw!\n"); FIXME("force redraw!\n");
} }
@ -242,11 +242,11 @@ HOTKEY_SysKeyDown (HWND hwnd, WPARAM wParam, LPARAM lParam)
case VK_SHIFT: case VK_SHIFT:
case VK_CONTROL: case VK_CONTROL:
case VK_MENU: case VK_MENU:
FIXME (hotkey, "modifier key pressed!\n"); FIXME("modifier key pressed!\n");
break; break;
default: default:
FIXME (hotkey, " %d\n", wParam); FIXME(" %d\n", wParam);
break; break;
} }
@ -259,7 +259,7 @@ HOTKEY_SysKeyUp (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
/* HOTKEY_INFO *infoPtr = HOTKEY_GetInfoPtr (hwnd); */ /* HOTKEY_INFO *infoPtr = HOTKEY_GetInfoPtr (hwnd); */
FIXME (hotkey, " %d\n", wParam); FIXME(" %d\n", wParam);
return 0; return 0;
} }
@ -321,7 +321,7 @@ HOTKEY_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
default: default:
if (uMsg >= WM_USER) if (uMsg >= WM_USER)
ERR (hotkey, "unknown msg %04x wp=%08x lp=%08lx\n", ERR("unknown msg %04x wp=%08x lp=%08lx\n",
uMsg, wParam, lParam); uMsg, wParam, lParam);
return DefWindowProcA (hwnd, uMsg, wParam, lParam); return DefWindowProcA (hwnd, uMsg, wParam, lParam);
} }

View file

@ -34,7 +34,7 @@
#include "wine/obj_storage.h" #include "wine/obj_storage.h"
#include "imagelist.h" #include "imagelist.h"
#include "commctrl.h" #include "commctrl.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(imagelist) DEFAULT_DEBUG_CHANNEL(imagelist)
@ -82,7 +82,7 @@ IMAGELIST_InternalExpandBitmaps (HIMAGELIST himl, INT nImageCount)
HBITMAP hbmNewBitmap; HBITMAP hbmNewBitmap;
INT nNewWidth, nNewCount; INT nNewWidth, nNewCount;
TRACE(imagelist, "Create expanded bitmaps!\n"); TRACE("Create expanded bitmaps!\n");
nNewCount = himl->cCurImage + nImageCount + himl->cGrow; nNewCount = himl->cCurImage + nImageCount + himl->cGrow;
nNewWidth = nNewCount * himl->cx; nNewWidth = nNewCount * himl->cx;
@ -93,7 +93,7 @@ IMAGELIST_InternalExpandBitmaps (HIMAGELIST himl, INT nImageCount)
hbmNewBitmap = hbmNewBitmap =
CreateBitmap (nNewWidth, himl->cy, 1, himl->uBitsPixel, NULL); CreateBitmap (nNewWidth, himl->cy, 1, himl->uBitsPixel, NULL);
if (hbmNewBitmap == 0) if (hbmNewBitmap == 0)
ERR (imagelist, "creating new image bitmap!\n"); ERR("creating new image bitmap!\n");
SelectObject (hdcImageList, himl->hbmImage); SelectObject (hdcImageList, himl->hbmImage);
SelectObject (hdcBitmap, hbmNewBitmap); SelectObject (hdcBitmap, hbmNewBitmap);
@ -108,7 +108,7 @@ IMAGELIST_InternalExpandBitmaps (HIMAGELIST himl, INT nImageCount)
CreateBitmap (nNewWidth, himl->cy, 1, 1, NULL); CreateBitmap (nNewWidth, himl->cy, 1, 1, NULL);
if (hbmNewBitmap == 0) if (hbmNewBitmap == 0)
ERR (imagelist, "creating new mask bitmap!"); ERR("creating new mask bitmap!");
SelectObject (hdcImageList, himl->hbmMask); SelectObject (hdcImageList, himl->hbmMask);
SelectObject (hdcBitmap, hbmNewBitmap); SelectObject (hdcBitmap, hbmNewBitmap);
@ -309,7 +309,7 @@ ImageList_BeginDrag (HIMAGELIST himlTrack, INT iTrack,
{ {
HDC hdcSrc, hdcDst; HDC hdcSrc, hdcDst;
FIXME(imagelist, "partially implemented!\n"); FIXME("partially implemented!\n");
if (himlTrack == NULL) if (himlTrack == NULL)
return FALSE; return FALSE;
@ -321,7 +321,7 @@ ImageList_BeginDrag (HIMAGELIST himlTrack, INT iTrack,
ImageList_Create (himlTrack->cx, himlTrack->cy, ImageList_Create (himlTrack->cx, himlTrack->cy,
himlTrack->flags, 1, 1); himlTrack->flags, 1, 1);
if (himlInternalDrag == NULL) { if (himlInternalDrag == NULL) {
ERR(imagelist, "Error creating drag image list!\n"); ERR("Error creating drag image list!\n");
return FALSE; return FALSE;
} }
@ -381,7 +381,7 @@ ImageList_Copy (HIMAGELIST himlDst, INT iDst, HIMAGELIST himlSrc,
{ {
HDC hdcSrc, hdcDst; HDC hdcSrc, hdcDst;
TRACE(imagelist, "iDst=%d iSrc=%d\n", iDst, iSrc); TRACE("iDst=%d iSrc=%d\n", iDst, iSrc);
if ((himlSrc == NULL) || (himlDst == NULL)) if ((himlSrc == NULL) || (himlDst == NULL))
return FALSE; return FALSE;
@ -509,7 +509,7 @@ ImageList_Create (INT cx, INT cy, UINT flags,
static WORD aBitBlend50[] = static WORD aBitBlend50[] =
{0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA}; {0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA};
TRACE (imagelist, "(%d %d 0x%x %d %d)\n", cx, cy, flags, cInitial, cGrow); TRACE("(%d %d 0x%x %d %d)\n", cx, cy, flags, cInitial, cGrow);
himl = (HIMAGELIST)COMCTL32_Alloc (sizeof(struct _IMAGELIST)); himl = (HIMAGELIST)COMCTL32_Alloc (sizeof(struct _IMAGELIST));
if (!himl) if (!himl)
@ -533,13 +533,13 @@ ImageList_Create (INT cx, INT cy, UINT flags,
himl->uBitsPixel = (UINT)GetDeviceCaps (hdc, BITSPIXEL); himl->uBitsPixel = (UINT)GetDeviceCaps (hdc, BITSPIXEL);
DeleteDC (hdc); DeleteDC (hdc);
TRACE(imagelist, "Image: %d Bits per Pixel\n", himl->uBitsPixel); TRACE("Image: %d Bits per Pixel\n", himl->uBitsPixel);
himl->hbmImage = himl->hbmImage =
CreateBitmap (himl->cx * himl->cMaxImage, himl->cy, CreateBitmap (himl->cx * himl->cMaxImage, himl->cy,
1, himl->uBitsPixel, NULL); 1, himl->uBitsPixel, NULL);
if (himl->hbmImage == 0) { if (himl->hbmImage == 0) {
ERR(imagelist, "Error creating image bitmap!\n"); ERR("Error creating image bitmap!\n");
return NULL; return NULL;
} }
@ -547,7 +547,7 @@ ImageList_Create (INT cx, INT cy, UINT flags,
himl->hbmMask = CreateBitmap (himl->cx * himl->cMaxImage, himl->cy, himl->hbmMask = CreateBitmap (himl->cx * himl->cMaxImage, himl->cy,
1, 1, NULL); 1, 1, NULL);
if (himl->hbmMask == 0) { if (himl->hbmMask == 0) {
ERR(imagelist, "Error creating mask bitmap!\n"); ERR("Error creating mask bitmap!\n");
if (himl->hbmImage) if (himl->hbmImage)
DeleteObject (himl->hbmImage); DeleteObject (himl->hbmImage);
return NULL; return NULL;
@ -732,8 +732,8 @@ ImageList_DragShowNolock (BOOL bShow)
{ {
HDC hdcDrag; HDC hdcDrag;
FIXME (imagelist, "semi-stub!\n"); FIXME("semi-stub!\n");
TRACE (imagelist, "bShow=0x%X!\n", bShow); TRACE("bShow=0x%X!\n", bShow);
hdcDrag = GetDCEx (hwndInternalDrag, 0, hdcDrag = GetDCEx (hwndInternalDrag, 0,
DCX_WINDOW | DCX_CACHE | DCX_LOCKWINDOWUPDATE); DCX_WINDOW | DCX_CACHE | DCX_LOCKWINDOWUPDATE);
@ -1069,7 +1069,7 @@ ImageList_Duplicate (HIMAGELIST himlSrc)
HDC hdcSrc, hdcDst; HDC hdcSrc, hdcDst;
if (himlSrc == NULL) { if (himlSrc == NULL) {
ERR (imagelist, "Invalid image list handle!\n"); ERR("Invalid image list handle!\n");
return NULL; return NULL;
} }
@ -1120,7 +1120,7 @@ ImageList_Duplicate (HIMAGELIST himlSrc)
BOOL WINAPI BOOL WINAPI
ImageList_EndDrag (void) ImageList_EndDrag (void)
{ {
FIXME (imagelist, "semi-stub!\n"); FIXME("semi-stub!\n");
if (himlInternalDrag) if (himlInternalDrag)
{ {
@ -1180,7 +1180,7 @@ ImageList_GetBkColor (HIMAGELIST himl)
HIMAGELIST WINAPI HIMAGELIST WINAPI
ImageList_GetDragImage (POINT *ppt, POINT *pptHotspot) ImageList_GetDragImage (POINT *ppt, POINT *pptHotspot)
{ {
FIXME (imagelist, "semi-stub!\n"); FIXME("semi-stub!\n");
if (himlInternalDrag) if (himlInternalDrag)
return (himlInternalDrag); return (himlInternalDrag);
@ -1409,7 +1409,7 @@ ImageList_LoadImageA (HINSTANCE hi, LPCSTR lpbmp, INT cx, INT cGrow,
handle = LoadImageA (hi, lpbmp, uType, 0, 0, uFlags); handle = LoadImageA (hi, lpbmp, uType, 0, 0, uFlags);
if (!handle) { if (!handle) {
ERR (imagelist, "Error loading image!\n"); ERR("Error loading image!\n");
return NULL; return NULL;
} }
@ -1473,7 +1473,7 @@ ImageList_LoadImageW (HINSTANCE hi, LPCWSTR lpbmp, INT cx, INT cGrow,
handle = LoadImageW (hi, lpbmp, uType, 0, 0, uFlags); handle = LoadImageW (hi, lpbmp, uType, 0, 0, uFlags);
if (!handle) { if (!handle) {
ERR (imagelist, "Error loading image!\n"); ERR("Error loading image!\n");
return NULL; return NULL;
} }
@ -1539,12 +1539,12 @@ ImageList_Merge (HIMAGELIST himl1, INT i1, HIMAGELIST himl2, INT i2,
/* check indices */ /* check indices */
if ((i1 < 0) || (i1 >= himl1->cCurImage)) { if ((i1 < 0) || (i1 >= himl1->cCurImage)) {
ERR (imagelist, "Index 1 out of range! %d\n", i1); ERR("Index 1 out of range! %d\n", i1);
return NULL; return NULL;
} }
if ((i2 < 0) || (i2 >= himl2->cCurImage)) { if ((i2 < 0) || (i2 >= himl2->cCurImage)) {
ERR (imagelist, "Index 2 out of range! %d\n", i2); ERR("Index 2 out of range! %d\n", i2);
return NULL; return NULL;
} }
@ -1646,7 +1646,7 @@ ImageList_Merge (HIMAGELIST himl1, INT i1, HIMAGELIST himl2, INT i2,
HIMAGELIST WINAPI ImageList_Read (LPSTREAM pstm) HIMAGELIST WINAPI ImageList_Read (LPSTREAM pstm)
{ {
FIXME (imagelist, "empty stub!\n"); FIXME("empty stub!\n");
return NULL; return NULL;
@ -1673,18 +1673,18 @@ ImageList_Remove (HIMAGELIST himl, INT i)
INT cxNew, nCount; INT cxNew, nCount;
if ((i < -1) || (i >= himl->cCurImage)) { if ((i < -1) || (i >= himl->cCurImage)) {
ERR (imagelist, "index out of range! %d\n", i); ERR("index out of range! %d\n", i);
return FALSE; return FALSE;
} }
if (himl->cCurImage == 0) { if (himl->cCurImage == 0) {
ERR (imagelist, "image list is already empty!\n"); ERR("image list is already empty!\n");
return FALSE; return FALSE;
} }
if (i == -1) { if (i == -1) {
/* remove all */ /* remove all */
TRACE (imagelist, "remove all!\n"); TRACE("remove all!\n");
himl->cMaxImage = himl->cInitial + himl->cGrow; himl->cMaxImage = himl->cInitial + himl->cGrow;
himl->cCurImage = 0; himl->cCurImage = 0;
@ -1705,14 +1705,14 @@ ImageList_Remove (HIMAGELIST himl, INT i)
} }
else { else {
/* delete one image */ /* delete one image */
TRACE (imagelist, "Remove single image! %d\n", i); TRACE("Remove single image! %d\n", i);
/* create new bitmap(s) */ /* create new bitmap(s) */
cxNew = (himl->cCurImage + himl->cGrow - 1) * himl->cx; cxNew = (himl->cCurImage + himl->cGrow - 1) * himl->cx;
TRACE(imagelist, " - Number of images: %d / %d (Old/New)\n", TRACE(" - Number of images: %d / %d (Old/New)\n",
himl->cCurImage, himl->cCurImage - 1); himl->cCurImage, himl->cCurImage - 1);
TRACE(imagelist, " - Max. number of images: %d / %d (Old/New)\n", TRACE(" - Max. number of images: %d / %d (Old/New)\n",
himl->cMaxImage, himl->cCurImage + himl->cGrow - 1); himl->cMaxImage, himl->cCurImage + himl->cGrow - 1);
hbmNewImage = hbmNewImage =
@ -1728,7 +1728,7 @@ ImageList_Remove (HIMAGELIST himl, INT i)
/* copy all images and masks prior to the "removed" image */ /* copy all images and masks prior to the "removed" image */
if (i > 0) { if (i > 0) {
TRACE (imagelist, "Pre image copy: Copy %d images\n", i); TRACE("Pre image copy: Copy %d images\n", i);
SelectObject (hdcSrc, himl->hbmImage); SelectObject (hdcSrc, himl->hbmImage);
SelectObject (hdcDst, hbmNewImage); SelectObject (hdcDst, hbmNewImage);
@ -1745,7 +1745,7 @@ ImageList_Remove (HIMAGELIST himl, INT i)
/* copy all images and masks behind the removed image */ /* copy all images and masks behind the removed image */
if (i < himl->cCurImage - 1) { if (i < himl->cCurImage - 1) {
TRACE (imagelist, "Post image copy!\n"); TRACE("Post image copy!\n");
SelectObject (hdcSrc, himl->hbmImage); SelectObject (hdcSrc, himl->hbmImage);
SelectObject (hdcDst, hbmNewImage); SelectObject (hdcDst, hbmNewImage);
BitBlt (hdcDst, i * himl->cx, 0, (himl->cCurImage - i - 1) * himl->cx, BitBlt (hdcDst, i * himl->cx, 0, (himl->cCurImage - i - 1) * himl->cx,
@ -1803,12 +1803,12 @@ ImageList_Replace (HIMAGELIST himl, INT i, HBITMAP hbmImage,
BITMAP bmp; BITMAP bmp;
if (himl == NULL) { if (himl == NULL) {
ERR (imagelist, "Invalid image list handle!\n"); ERR("Invalid image list handle!\n");
return FALSE; return FALSE;
} }
if ((i >= himl->cCurImage) || (i < 0)) { if ((i >= himl->cCurImage) || (i < 0)) {
ERR (imagelist, "Invalid image index!\n"); ERR("Invalid image index!\n");
return FALSE; return FALSE;
} }
@ -1864,7 +1864,7 @@ ImageList_ReplaceIcon (HIMAGELIST himl, INT i, HICON hIcon)
ICONINFO ii; ICONINFO ii;
BITMAP bmp; BITMAP bmp;
TRACE (imagelist, "(0x%lx 0x%x 0x%x)\n", (DWORD)himl, i, hIcon); TRACE("(0x%lx 0x%x 0x%x)\n", (DWORD)himl, i, hIcon);
if (himl == NULL) if (himl == NULL)
return -1; return -1;
@ -1873,9 +1873,9 @@ ImageList_ReplaceIcon (HIMAGELIST himl, INT i, HICON hIcon)
GetIconInfo (hIcon, &ii); GetIconInfo (hIcon, &ii);
if (ii.hbmMask == 0) if (ii.hbmMask == 0)
ERR (imagelist, "no mask!\n"); ERR("no mask!\n");
if (ii.hbmColor == 0) if (ii.hbmColor == 0)
ERR (imagelist, "no color!\n"); ERR("no color!\n");
GetObjectA (ii.hbmMask, sizeof(BITMAP), (LPVOID)&bmp); GetObjectA (ii.hbmMask, sizeof(BITMAP), (LPVOID)&bmp);
if (i == -1) { if (i == -1) {
@ -1889,14 +1889,14 @@ ImageList_ReplaceIcon (HIMAGELIST himl, INT i, HICON hIcon)
nIndex = i; nIndex = i;
hdcImageList = CreateCompatibleDC (0); hdcImageList = CreateCompatibleDC (0);
TRACE (imagelist, "hdcImageList=0x%x!\n", hdcImageList); TRACE("hdcImageList=0x%x!\n", hdcImageList);
if (hdcImageList == 0) if (hdcImageList == 0)
ERR (imagelist, "invalid hdcImageList!\n"); ERR("invalid hdcImageList!\n");
hdcImage = CreateCompatibleDC (0); hdcImage = CreateCompatibleDC (0);
TRACE (imagelist, "hdcImage=0x%x!\n", hdcImage); TRACE("hdcImage=0x%x!\n", hdcImage);
if (hdcImage == 0) if (hdcImage == 0)
ERR (imagelist, "invalid hdcImage!\n"); ERR("invalid hdcImage!\n");
hbmOldDst = SelectObject (hdcImageList, himl->hbmImage); hbmOldDst = SelectObject (hdcImageList, himl->hbmImage);
SetTextColor( hdcImageList, RGB(0,0,0)); SetTextColor( hdcImageList, RGB(0,0,0));
@ -1981,12 +1981,12 @@ ImageList_SetDragCursorImage (HIMAGELIST himlDrag, INT iDrag,
{ {
HIMAGELIST himlTemp; HIMAGELIST himlTemp;
FIXME (imagelist, "semi-stub!\n"); FIXME("semi-stub!\n");
if (himlInternalDrag == NULL) if (himlInternalDrag == NULL)
return FALSE; return FALSE;
TRACE (imagelist, " dxH=%d dyH=%d nX=%d nY=%d\n", TRACE(" dxH=%d dyH=%d nX=%d nY=%d\n",
dxHotspot, dyHotspot, nInternalDragHotspotX, nInternalDragHotspotY); dxHotspot, dyHotspot, nInternalDragHotspotX, nInternalDragHotspotY);
himlTemp = ImageList_Merge (himlInternalDrag, 0, himlDrag, iDrag, himlTemp = ImageList_Merge (himlInternalDrag, 0, himlDrag, iDrag,
@ -2024,7 +2024,7 @@ ImageList_SetDragCursorImage (HIMAGELIST himlDrag, INT iDrag,
BOOL WINAPI BOOL WINAPI
ImageList_SetFilter (HIMAGELIST himl, INT i, DWORD dwFilter) ImageList_SetFilter (HIMAGELIST himl, INT i, DWORD dwFilter)
{ {
FIXME (imagelist, "(%p 0x%x 0x%lx):empty stub!\n", FIXME("(%p 0x%x 0x%lx):empty stub!\n",
himl, i, dwFilter); himl, i, dwFilter);
return FALSE; return FALSE;
@ -2135,7 +2135,7 @@ ImageList_SetImageCount (HIMAGELIST himl, INT iImageCount)
himl->hbmImage = hbmNewBitmap; himl->hbmImage = hbmNewBitmap;
} }
else else
ERR (imagelist, "Could not create new image bitmap !\n"); ERR("Could not create new image bitmap !\n");
if (himl->hbmMask) if (himl->hbmMask)
{ {
@ -2160,7 +2160,7 @@ ImageList_SetImageCount (HIMAGELIST himl, INT iImageCount)
himl->hbmMask = hbmNewBitmap; himl->hbmMask = hbmNewBitmap;
} }
else else
ERR (imagelist, "Could not create new mask bitmap!\n"); ERR("Could not create new mask bitmap!\n");
} }
DeleteDC (hdcImageList); DeleteDC (hdcImageList);
@ -2232,7 +2232,7 @@ ImageList_Write (HIMAGELIST himl, LPSTREAM pstm)
if (!himl) if (!himl)
return FALSE; return FALSE;
FIXME (imagelist, "empty stub!\n"); FIXME("empty stub!\n");
return FALSE; return FALSE;
} }

View file

@ -27,7 +27,7 @@
#include "commctrl.h" #include "commctrl.h"
#include "ipaddress.h" #include "ipaddress.h"
#include "heap.h" #include "heap.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(ipaddress) DEFAULT_DEBUG_CHANNEL(ipaddress)
@ -112,7 +112,7 @@ IPADDRESS_Create (HWND hwnd, WPARAM wParam, LPARAM lParam)
(HANDLE)lpipsi); (HANDLE)lpipsi);
/* infoPtr->lpipsi= lpipsi; */ /* infoPtr->lpipsi= lpipsi; */
} else } else
WARN (ipaddress,"IP-create called twice\n"); WARN("IP-create called twice\n");
for (i=0; i<=3; i++) { for (i=0; i<=3; i++) {
infoPtr->LowerLimit[i]=0; infoPtr->LowerLimit[i]=0;
@ -159,7 +159,7 @@ IPADDRESS_KillFocus (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
HDC hdc; HDC hdc;
TRACE (ipaddress,"\n"); TRACE("\n");
hdc = GetDC (hwnd); hdc = GetDC (hwnd);
IPADDRESS_Refresh (hwnd, hdc); IPADDRESS_Refresh (hwnd, hdc);
ReleaseDC (hwnd, hdc); ReleaseDC (hwnd, hdc);
@ -191,7 +191,7 @@ IPADDRESS_SetFocus (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
HDC hdc; HDC hdc;
TRACE (ipaddress,"\n"); TRACE("\n");
hdc = GetDC (hwnd); hdc = GetDC (hwnd);
IPADDRESS_Refresh (hwnd, hdc); IPADDRESS_Refresh (hwnd, hdc);
@ -205,7 +205,7 @@ static LRESULT
IPADDRESS_Size (HWND hwnd, WPARAM wParam, LPARAM lParam) IPADDRESS_Size (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
/* IPADDRESS_INFO *infoPtr = IPADDRESS_GetInfoPtr (hwnd); */ /* IPADDRESS_INFO *infoPtr = IPADDRESS_GetInfoPtr (hwnd); */
TRACE (ipaddress,"\n"); TRACE("\n");
return 0; return 0;
} }
@ -214,7 +214,7 @@ static BOOL
IPADDRESS_SendNotify (HWND hwnd, UINT command) IPADDRESS_SendNotify (HWND hwnd, UINT command)
{ {
TRACE (ipaddress, "%x\n",command); TRACE("%x\n",command);
return (BOOL)SendMessageA (GetParent (hwnd), WM_COMMAND, return (BOOL)SendMessageA (GetParent (hwnd), WM_COMMAND,
MAKEWPARAM (GetWindowLongA (hwnd, GWL_ID),command), (LPARAM)hwnd); MAKEWPARAM (GetWindowLongA (hwnd, GWL_ID),command), (LPARAM)hwnd);
} }
@ -225,7 +225,7 @@ IPADDRESS_SendIPAddressNotify (HWND hwnd, UINT field, BYTE newValue)
{ {
NMIPADDRESS nmip; NMIPADDRESS nmip;
TRACE (ipaddress, "%x %x\n",field,newValue); TRACE("%x %x\n",field,newValue);
nmip.hdr.hwndFrom = hwnd; nmip.hdr.hwndFrom = hwnd;
nmip.hdr.idFrom = GetWindowLongA (hwnd, GWL_ID); nmip.hdr.idFrom = GetWindowLongA (hwnd, GWL_ID);
nmip.hdr.code = IPN_FIELDCHANGED; nmip.hdr.code = IPN_FIELDCHANGED;
@ -249,7 +249,7 @@ IPADDRESS_ClearAddress (HWND hwnd, WPARAM wParam, LPARAM lParam)
LPIP_SUBCLASS_INFO lpipsi=(LPIP_SUBCLASS_INFO) LPIP_SUBCLASS_INFO lpipsi=(LPIP_SUBCLASS_INFO)
GetPropA ((HWND)hwnd,IP_SUBCLASS_PROP); GetPropA ((HWND)hwnd,IP_SUBCLASS_PROP);
TRACE (ipaddress,"\n"); TRACE("\n");
buf[0]=0; buf[0]=0;
for (i=0; i<=3; i++) for (i=0; i<=3; i++)
@ -270,7 +270,7 @@ IPADDRESS_IsBlank (HWND hwnd, WPARAM wParam, LPARAM lParam)
LPIP_SUBCLASS_INFO lpipsi=(LPIP_SUBCLASS_INFO) LPIP_SUBCLASS_INFO lpipsi=(LPIP_SUBCLASS_INFO)
GetPropA ((HWND)hwnd, IP_SUBCLASS_PROP); GetPropA ((HWND)hwnd, IP_SUBCLASS_PROP);
TRACE (ipaddress,"\n"); TRACE("\n");
for (i=0; i<=3; i++) { for (i=0; i<=3; i++) {
GetWindowTextA (lpipsi->hwndIP[i],buf,5); GetWindowTextA (lpipsi->hwndIP[i],buf,5);
@ -291,7 +291,7 @@ IPADDRESS_GetAddress (HWND hwnd, WPARAM wParam, LPARAM lParam)
LPIP_SUBCLASS_INFO lpipsi=(LPIP_SUBCLASS_INFO) LPIP_SUBCLASS_INFO lpipsi=(LPIP_SUBCLASS_INFO)
GetPropA ((HWND)hwnd, IP_SUBCLASS_PROP); GetPropA ((HWND)hwnd, IP_SUBCLASS_PROP);
TRACE (ipaddress,"\n"); TRACE("\n");
valid=0; valid=0;
ip_addr=0; ip_addr=0;
@ -322,7 +322,7 @@ IPADDRESS_SetRange (HWND hwnd, WPARAM wParam, LPARAM lParam)
IPADDRESS_INFO *infoPtr = IPADDRESS_GetInfoPtr (hwnd); IPADDRESS_INFO *infoPtr = IPADDRESS_GetInfoPtr (hwnd);
INT index; INT index;
TRACE (ipaddress,"\n"); TRACE("\n");
index=(INT) wParam; index=(INT) wParam;
if ((index<0) || (index>3)) return 0; if ((index<0) || (index>3)) return 0;
@ -342,7 +342,7 @@ IPADDRESS_SetAddress (HWND hwnd, WPARAM wParam, LPARAM lParam)
int i,ip_address,value; int i,ip_address,value;
char buf[20]; char buf[20];
TRACE (ipaddress,"\n"); TRACE("\n");
ip_address=(DWORD) lParam; ip_address=(DWORD) lParam;
for (i=3; i>=0; i--) { for (i=3; i>=0; i--) {
@ -375,7 +375,7 @@ IPADDRESS_SetFocusToField (HWND hwnd, WPARAM wParam, LPARAM lParam)
INT index; INT index;
index=(INT) wParam; index=(INT) wParam;
TRACE (ipaddress," %d\n", index); TRACE(" %d\n", index);
if ((index<0) || (index>3)) return 0; if ((index<0) || (index>3)) return 0;
SetFocus (lpipsi->hwndIP[index]); SetFocus (lpipsi->hwndIP[index]);
@ -387,7 +387,7 @@ IPADDRESS_SetFocusToField (HWND hwnd, WPARAM wParam, LPARAM lParam)
static LRESULT static LRESULT
IPADDRESS_LButtonDown (HWND hwnd, WPARAM wParam, LPARAM lParam) IPADDRESS_LButtonDown (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
TRACE (ipaddress, "\n"); TRACE("\n");
SetFocus (hwnd); SetFocus (hwnd);
IPADDRESS_SendNotify (hwnd, EN_SETFOCUS); IPADDRESS_SendNotify (hwnd, EN_SETFOCUS);
@ -414,7 +414,7 @@ IPADDRESS_GotoNextField (LPIP_SUBCLASS_INFO lpipsi, int currentfield)
char field[20]; char field[20];
IPADDRESS_INFO *infoPtr=lpipsi->infoPtr; IPADDRESS_INFO *infoPtr=lpipsi->infoPtr;
TRACE (ipaddress,"\n"); TRACE("\n");
GetWindowTextA (lpipsi->hwndIP[currentfield],field,4); GetWindowTextA (lpipsi->hwndIP[currentfield],field,4);
if (field[0]) { if (field[0]) {
field[3]=0; field[3]=0;
@ -545,7 +545,7 @@ IPADDRESS_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
default: default:
if (uMsg >= WM_USER) if (uMsg >= WM_USER)
ERR (ipaddress, "unknown msg %04x wp=%08x lp=%08lx\n", ERR("unknown msg %04x wp=%08x lp=%08lx\n",
uMsg, wParam, lParam); uMsg, wParam, lParam);
return DefWindowProcA (hwnd, uMsg, wParam, lParam); return DefWindowProcA (hwnd, uMsg, wParam, lParam);
} }

View file

@ -44,7 +44,7 @@
#include "winbase.h" #include "winbase.h"
#include "commctrl.h" #include "commctrl.h"
#include "listview.h" #include "listview.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(listview) DEFAULT_DEBUG_CHANNEL(listview)
@ -313,42 +313,42 @@ static VOID LISTVIEW_UnsupportedStyles(LONG lStyle)
{ {
if ((LVS_TYPEMASK & lStyle) == LVS_EDITLABELS) if ((LVS_TYPEMASK & lStyle) == LVS_EDITLABELS)
{ {
FIXME( listview, " LVS_EDITLABELS\n"); FIXME(" LVS_EDITLABELS\n");
} }
if ((LVS_TYPEMASK & lStyle) == LVS_NOLABELWRAP) if ((LVS_TYPEMASK & lStyle) == LVS_NOLABELWRAP)
{ {
FIXME( listview, " LVS_NOLABELWRAP\n"); FIXME(" LVS_NOLABELWRAP\n");
} }
if ((LVS_TYPEMASK & lStyle) == LVS_NOSCROLL) if ((LVS_TYPEMASK & lStyle) == LVS_NOSCROLL)
{ {
FIXME( listview, " LVS_NOSCROLL\n"); FIXME(" LVS_NOSCROLL\n");
} }
if ((LVS_TYPEMASK & lStyle) == LVS_NOSORTHEADER) if ((LVS_TYPEMASK & lStyle) == LVS_NOSORTHEADER)
{ {
FIXME( listview, " LVS_NOSORTHEADER\n"); FIXME(" LVS_NOSORTHEADER\n");
} }
if ((LVS_TYPEMASK & lStyle) == LVS_OWNERDRAWFIXED) if ((LVS_TYPEMASK & lStyle) == LVS_OWNERDRAWFIXED)
{ {
FIXME( listview, " LVS_OWNERDRAWFIXED\n"); FIXME(" LVS_OWNERDRAWFIXED\n");
} }
if ((LVS_TYPEMASK & lStyle) == LVS_SHAREIMAGELISTS) if ((LVS_TYPEMASK & lStyle) == LVS_SHAREIMAGELISTS)
{ {
FIXME( listview, " LVS_SHAREIMAGELISTS\n"); FIXME(" LVS_SHAREIMAGELISTS\n");
} }
if ((LVS_TYPEMASK & lStyle) == LVS_SORTASCENDING) if ((LVS_TYPEMASK & lStyle) == LVS_SORTASCENDING)
{ {
FIXME( listview, " LVS_SORTASCENDING\n"); FIXME(" LVS_SORTASCENDING\n");
} }
if ((LVS_TYPEMASK & lStyle) == LVS_SORTDESCENDING) if ((LVS_TYPEMASK & lStyle) == LVS_SORTDESCENDING)
{ {
FIXME( listview, " LVS_SORTDESCENDING\n"); FIXME(" LVS_SORTDESCENDING\n");
} }
} }
@ -483,7 +483,7 @@ static LRESULT LISTVIEW_SetViewRect(HWND hwnd, LPRECT lprcView)
LISTVIEW_INFO *infoPtr = (LISTVIEW_INFO*)GetWindowLongA(hwnd, 0); LISTVIEW_INFO *infoPtr = (LISTVIEW_INFO*)GetWindowLongA(hwnd, 0);
BOOL bResult = FALSE; BOOL bResult = FALSE;
TRACE(listview, "(hwnd=%x, left=%d, top=%d, right=%d, bottom=%d)\n", hwnd, TRACE("(hwnd=%x, left=%d, top=%d, right=%d, bottom=%d)\n", hwnd,
lprcView->left, lprcView->top, lprcView->right, lprcView->bottom); lprcView->left, lprcView->top, lprcView->right, lprcView->bottom);
if (lprcView != NULL) if (lprcView != NULL)
@ -516,7 +516,7 @@ static LRESULT LISTVIEW_GetViewRect(HWND hwnd, LPRECT lprcView)
BOOL bResult = FALSE; BOOL bResult = FALSE;
POINT ptOrigin; POINT ptOrigin;
TRACE(listview, "(hwnd=%x, lprcView=%p)\n", hwnd, lprcView); TRACE("(hwnd=%x, lprcView=%p)\n", hwnd, lprcView);
if (lprcView != NULL) if (lprcView != NULL)
{ {
@ -529,7 +529,7 @@ static LRESULT LISTVIEW_GetViewRect(HWND hwnd, LPRECT lprcView)
lprcView->bottom = infoPtr->rcView.bottom + ptOrigin.y; lprcView->bottom = infoPtr->rcView.bottom + ptOrigin.y;
} }
TRACE(listview, "(left=%d, top=%d, right=%d, bottom=%d)\n", TRACE("(left=%d, top=%d, right=%d, bottom=%d)\n",
lprcView->left, lprcView->top, lprcView->right, lprcView->bottom); lprcView->left, lprcView->top, lprcView->right, lprcView->bottom);
} }
@ -590,7 +590,7 @@ static INT LISTVIEW_GetItemWidth(HWND hwnd)
INT nLabelWidth; INT nLabelWidth;
INT i; INT i;
TRACE(listview, "(hwnd=%x)\n", hwnd); TRACE("(hwnd=%x)\n", hwnd);
if (uView == LVS_ICON) if (uView == LVS_ICON)
{ {
@ -1683,7 +1683,7 @@ static VOID LISTVIEW_DrawSubItem(HWND hwnd, HDC hdc, INT nItem, INT nSubItem,
CHAR szDispText[DISP_TEXT_SIZE]; CHAR szDispText[DISP_TEXT_SIZE];
LVITEMA lvItem; LVITEMA lvItem;
TRACE(listview, "(hwnd=%x, hdc=%x, nItem=%d, nSubItem=%d\n", hwnd, hdc, TRACE("(hwnd=%x, hdc=%x, nItem=%d, nSubItem=%d\n", hwnd, hdc,
nItem, nSubItem); nItem, nSubItem);
/* get information needed for drawing the item */ /* get information needed for drawing the item */
@ -1727,7 +1727,7 @@ static VOID LISTVIEW_DrawItem(HWND hwnd, HDC hdc, INT nItem, RECT rcItem)
DWORD dwBkColor; DWORD dwBkColor;
DWORD dwTextColor; DWORD dwTextColor;
TRACE(listview, "(hwnd=%x, hdc=%x, nItem=%d\n", hwnd, hdc, nItem); TRACE("(hwnd=%x, hdc=%x, nItem=%d\n", hwnd, hdc, nItem);
/* get information needed for drawing the item */ /* get information needed for drawing the item */
ZeroMemory(&lvItem, sizeof(LVITEMA)); ZeroMemory(&lvItem, sizeof(LVITEMA));
@ -1842,7 +1842,7 @@ static VOID LISTVIEW_DrawLargeItem(HWND hwnd, HDC hdc, INT nItem, RECT rcItem)
TEXTMETRICA tm; TEXTMETRICA tm;
LVITEMA lvItem; LVITEMA lvItem;
TRACE(listview, "(hwnd=%x, hdc=%x, nItem=%d, left=%d, top=%d, right=%d, \ TRACE("(hwnd=%x, hdc=%x, nItem=%d, left=%d, top=%d, right=%d, \
bottom=%d)\n", hwnd, hdc, nItem, rcItem.left, rcItem.top, rcItem.right, bottom=%d)\n", hwnd, hdc, nItem, rcItem.left, rcItem.top, rcItem.right,
rcItem.bottom); rcItem.bottom);
@ -2361,7 +2361,7 @@ static LRESULT LISTVIEW_DeleteAllItems(HWND hwnd)
INT j; INT j;
HDPA hdpaSubItems; HDPA hdpaSubItems;
TRACE(listview, "(hwnd=%x,)\n", hwnd); TRACE("(hwnd=%x,)\n", hwnd);
if (GETITEMCOUNT(infoPtr) > 0) if (GETITEMCOUNT(infoPtr) > 0)
{ {
@ -2513,7 +2513,7 @@ static LRESULT LISTVIEW_DeleteItem(HWND hwnd, INT nItem)
LISTVIEW_SUBITEM *lpSubItem; LISTVIEW_SUBITEM *lpSubItem;
INT i; INT i;
TRACE(listview, "(hwnd=%x,nItem=%d)\n", hwnd, nItem); TRACE("(hwnd=%x,nItem=%d)\n", hwnd, nItem);
if ((nItem >= 0) && (nItem < GETITEMCOUNT(infoPtr))) if ((nItem >= 0) && (nItem < GETITEMCOUNT(infoPtr)))
{ {
@ -3237,7 +3237,7 @@ static LRESULT LISTVIEW_GetItemA(HWND hwnd, LPLVITEMA lpLVItem)
LISTVIEW_ITEM *lpItem; LISTVIEW_ITEM *lpItem;
HDPA hdpaSubItems; HDPA hdpaSubItems;
TRACE(listview, "(hwnd=%x, lpLVItem=%p)\n", hwnd, lpLVItem); TRACE("(hwnd=%x, lpLVItem=%p)\n", hwnd, lpLVItem);
if (lpLVItem != NULL) if (lpLVItem != NULL)
{ {
@ -3455,7 +3455,7 @@ static BOOL LISTVIEW_GetItemPosition(HWND hwnd, INT nItem,
INT nCountPerColumn; INT nCountPerColumn;
INT nRow; INT nRow;
TRACE(listview, "(hwnd=%x,nItem=%d,lpptPosition=%p)\n", hwnd, nItem, TRACE("(hwnd=%x,nItem=%d,lpptPosition=%p)\n", hwnd, nItem,
lpptPosition); lpptPosition);
if ((nItem >= 0) && (nItem < GETITEMCOUNT(infoPtr)) && if ((nItem >= 0) && (nItem < GETITEMCOUNT(infoPtr)) &&
@ -3538,7 +3538,7 @@ static LRESULT LISTVIEW_GetItemRect(HWND hwnd, INT nItem, LPRECT lprc)
INT nLabelWidth; INT nLabelWidth;
TEXTMETRICA tm; TEXTMETRICA tm;
TRACE(listview, "(hwnd=%x, nItem=%d, lprc=%p)\n", hwnd, nItem, lprc); TRACE("(hwnd=%x, nItem=%d, lprc=%p)\n", hwnd, nItem, lprc);
if ((nItem >= 0) && (nItem < GETITEMCOUNT(infoPtr)) && (lprc != NULL)) if ((nItem >= 0) && (nItem < GETITEMCOUNT(infoPtr)) && (lprc != NULL))
{ {
@ -3824,7 +3824,7 @@ static INT LISTVIEW_GetLabelWidth(HWND hwnd, INT nItem)
INT nLabelWidth = 0; INT nLabelWidth = 0;
LVITEMA lvItem; LVITEMA lvItem;
TRACE(listview, "(hwnd=%x, nItem=%d)\n", hwnd, nItem); TRACE("(hwnd=%x, nItem=%d)\n", hwnd, nItem);
ZeroMemory(&lvItem, sizeof(LVITEMA)); ZeroMemory(&lvItem, sizeof(LVITEMA));
lvItem.mask = LVIF_TEXT; lvItem.mask = LVIF_TEXT;
@ -4106,7 +4106,7 @@ static LRESULT LISTVIEW_GetOrigin(HWND hwnd, LPPOINT lpptOrigin)
INT nListHeight = infoPtr->rcList.bottom - infoPtr->rcList.top; INT nListHeight = infoPtr->rcList.bottom - infoPtr->rcList.top;
BOOL bResult = FALSE; BOOL bResult = FALSE;
TRACE(listview, "(hwnd=%x, lpptOrigin=%p)\n", hwnd, lpptOrigin); TRACE("(hwnd=%x, lpptOrigin=%p)\n", hwnd, lpptOrigin);
if ((uView == LVS_SMALLICON) || (uView == LVS_ICON)) if ((uView == LVS_SMALLICON) || (uView == LVS_ICON))
{ {
@ -4267,7 +4267,7 @@ static INT LISTVIEW_HitTestItem(HWND hwnd, LPLVHITTESTINFO lpHitTestInfo)
RECT rcItem; RECT rcItem;
INT i; INT i;
TRACE(listview,"(hwnd=%x, x=%ld, y=%ld)\n", hwnd, lpHitTestInfo->pt.x, TRACE("(hwnd=%x, x=%ld, y=%ld)\n", hwnd, lpHitTestInfo->pt.x,
lpHitTestInfo->pt.y); lpHitTestInfo->pt.y);
for (i = 0; i < GETITEMCOUNT(infoPtr); i++) for (i = 0; i < GETITEMCOUNT(infoPtr); i++)
@ -4378,7 +4378,7 @@ static LRESULT LISTVIEW_InsertColumnA(HWND hwnd, INT nColumn,
HDITEMA hdi; HDITEMA hdi;
INT nNewColumn = -1; INT nNewColumn = -1;
TRACE(listview,"(hwnd=%x, nColumn=%d, lpColumn=%p)\n",hwnd, nColumn, TRACE("(hwnd=%x, nColumn=%d, lpColumn=%p)\n",hwnd, nColumn,
lpColumn); lpColumn);
if (lpColumn != NULL) if (lpColumn != NULL)
@ -4492,7 +4492,7 @@ static LRESULT LISTVIEW_InsertItemA(HWND hwnd, LPLVITEMA lpLVItem)
HDPA hdpaSubItems; HDPA hdpaSubItems;
LISTVIEW_ITEM *lpItem = NULL; LISTVIEW_ITEM *lpItem = NULL;
TRACE(listview, "(hwnd=%x,lpLVItem=%p)\n", hwnd, lpLVItem); TRACE("(hwnd=%x,lpLVItem=%p)\n", hwnd, lpLVItem);
if (lpLVItem != NULL) if (lpLVItem != NULL)
{ {
@ -4892,7 +4892,7 @@ static LRESULT LISTVIEW_SetItemA(HWND hwnd, LPLVITEMA lpLVItem)
*/ */
static VOID LISTVIEW_SetItemCount(HWND hwnd, INT nItemCount) static VOID LISTVIEW_SetItemCount(HWND hwnd, INT nItemCount)
{ {
FIXME (listview, "empty stub!\n"); FIXME("empty stub!\n");
} }
/*** /***
@ -4918,7 +4918,7 @@ static BOOL LISTVIEW_SetItemPosition(HWND hwnd, INT nItem,
HDPA hdpaSubItems; HDPA hdpaSubItems;
BOOL bResult = FALSE; BOOL bResult = FALSE;
TRACE(listview, "(hwnd=%x,nItem=%d,X=%d,Y=%d)\n", hwnd, nItem, nPosX, nPosY); TRACE("(hwnd=%x,nItem=%d,X=%d,Y=%d)\n", hwnd, nItem, nPosX, nPosY);
if ((nItem >= 0) || (nItem < GETITEMCOUNT(infoPtr))) if ((nItem >= 0) || (nItem < GETITEMCOUNT(infoPtr)))
{ {
@ -5081,7 +5081,7 @@ static LRESULT LISTVIEW_SetTextColor (HWND hwnd, COLORREF clrText)
*/ */
static LRESULT LISTVIEW_SortItems(HWND hwnd, WPARAM wParam, LPARAM lParam) static LRESULT LISTVIEW_SortItems(HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
FIXME (listview, "empty stub!\n"); FIXME("empty stub!\n");
return TRUE; return TRUE;
} }
@ -5152,7 +5152,7 @@ static LRESULT LISTVIEW_Create(HWND hwnd, WPARAM wParam, LPARAM lParam)
(WPARAM)hwnd, (LPARAM)NF_QUERY); (WPARAM)hwnd, (LPARAM)NF_QUERY);
if (infoPtr->notifyFormat != NFR_ANSI) if (infoPtr->notifyFormat != NFR_ANSI)
{ {
FIXME (listview, "ANSI notify format is NOT used\n"); FIXME("ANSI notify format is NOT used\n");
} }
/* initialize color information */ /* initialize color information */
@ -5640,7 +5640,7 @@ static LRESULT LISTVIEW_LButtonDblClk(HWND hwnd, WORD wKey, WORD wPosX,
LONG nCtrlId = GetWindowLongA(hwnd, GWL_ID); LONG nCtrlId = GetWindowLongA(hwnd, GWL_ID);
NMHDR nmh; NMHDR nmh;
TRACE(listview, "(hwnd=%x,key=%hu,X=%hu,Y=%hu)\n", hwnd, wKey, wPosX, wPosY); TRACE("(hwnd=%x,key=%hu,X=%hu,Y=%hu)\n", hwnd, wKey, wPosX, wPosY);
/* send NM_DBLCLK notification */ /* send NM_DBLCLK notification */
nmh.hwndFrom = hwnd; nmh.hwndFrom = hwnd;
@ -5679,7 +5679,7 @@ static LRESULT LISTVIEW_LButtonDown(HWND hwnd, WORD wKey, WORD wPosX,
NMHDR nmh; NMHDR nmh;
INT nItem; INT nItem;
TRACE(listview, "(hwnd=%x, key=%hu, X=%hu, Y=%hu)\n", hwnd, wKey, wPosX, TRACE("(hwnd=%x, key=%hu, X=%hu, Y=%hu)\n", hwnd, wKey, wPosX,
wPosY); wPosY);
/* send NM_RELEASEDCAPTURE notification */ /* send NM_RELEASEDCAPTURE notification */
@ -5761,7 +5761,7 @@ static LRESULT LISTVIEW_LButtonUp(HWND hwnd, WORD wKey, WORD wPosX,
{ {
LISTVIEW_INFO *infoPtr = (LISTVIEW_INFO *)GetWindowLongA(hwnd, 0); LISTVIEW_INFO *infoPtr = (LISTVIEW_INFO *)GetWindowLongA(hwnd, 0);
TRACE(listview, "(hwnd=%x,key=%hu,X=%hu,Y=%hu)\n", hwnd, wKey, wPosX, wPosY); TRACE("(hwnd=%x,key=%hu,X=%hu,Y=%hu)\n", hwnd, wKey, wPosX, wPosY);
if (infoPtr->bLButtonDown != FALSE) if (infoPtr->bLButtonDown != FALSE)
{ {
@ -5797,20 +5797,20 @@ static LRESULT LISTVIEW_NCCreate(HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
LISTVIEW_INFO *infoPtr; LISTVIEW_INFO *infoPtr;
TRACE(listview, "(hwnd=%x,wParam=%x,lParam=%lx)\n", hwnd, wParam, lParam); TRACE("(hwnd=%x,wParam=%x,lParam=%lx)\n", hwnd, wParam, lParam);
/* allocate memory for info structure */ /* allocate memory for info structure */
infoPtr = (LISTVIEW_INFO *)COMCTL32_Alloc(sizeof(LISTVIEW_INFO)); infoPtr = (LISTVIEW_INFO *)COMCTL32_Alloc(sizeof(LISTVIEW_INFO));
SetWindowLongA(hwnd, 0, (LONG)infoPtr); SetWindowLongA(hwnd, 0, (LONG)infoPtr);
if (infoPtr == NULL) if (infoPtr == NULL)
{ {
ERR(listview, "could not allocate info memory!\n"); ERR("could not allocate info memory!\n");
return 0; return 0;
} }
if ((LISTVIEW_INFO *)GetWindowLongA(hwnd, 0) != infoPtr) if ((LISTVIEW_INFO *)GetWindowLongA(hwnd, 0) != infoPtr)
{ {
ERR(listview, "pointer assignment error!\n"); ERR("pointer assignment error!\n");
return 0; return 0;
} }
@ -5831,7 +5831,7 @@ static LRESULT LISTVIEW_NCDestroy(HWND hwnd)
{ {
LISTVIEW_INFO *infoPtr = (LISTVIEW_INFO *)GetWindowLongA(hwnd, 0); LISTVIEW_INFO *infoPtr = (LISTVIEW_INFO *)GetWindowLongA(hwnd, 0);
TRACE(listview, "(hwnd=%x)\n", hwnd); TRACE("(hwnd=%x)\n", hwnd);
/* delete all items */ /* delete all items */
LISTVIEW_DeleteAllItems(hwnd); LISTVIEW_DeleteAllItems(hwnd);
@ -5904,7 +5904,7 @@ static LRESULT LISTVIEW_NotifyFormat(HWND hwndFrom, HWND hwnd, INT nCommand)
(WPARAM)hwnd, (LPARAM)NF_QUERY); (WPARAM)hwnd, (LPARAM)NF_QUERY);
if (infoPtr->notifyFormat == NFR_UNICODE) if (infoPtr->notifyFormat == NFR_UNICODE)
{ {
FIXME (listview, "NO support for unicode structures"); FIXME("NO support for unicode structures");
} }
} }
@ -5926,7 +5926,7 @@ static LRESULT LISTVIEW_Paint(HWND hwnd, HDC hdc)
{ {
PAINTSTRUCT ps; PAINTSTRUCT ps;
TRACE(listview, "(hwnd=%x,hdc=%x)\n", hwnd, hdc); TRACE("(hwnd=%x,hdc=%x)\n", hwnd, hdc);
if (hdc == 0) if (hdc == 0)
{ {
@ -5961,7 +5961,7 @@ static LRESULT LISTVIEW_RButtonDblClk(HWND hwnd, WORD wKey, WORD wPosX,
INT nCtrlId = GetWindowLongA(hwnd, GWL_ID); INT nCtrlId = GetWindowLongA(hwnd, GWL_ID);
NMHDR nmh; NMHDR nmh;
TRACE(listview, "(hwnd=%x,key=%hu,X=%hu,Y=%hu)\n", hwnd, wKey, wPosX, wPosY); TRACE("(hwnd=%x,key=%hu,X=%hu,Y=%hu)\n", hwnd, wKey, wPosX, wPosY);
/* send NM_RELEASEDCAPTURE notification */ /* send NM_RELEASEDCAPTURE notification */
nmh.hwndFrom = hwnd; nmh.hwndFrom = hwnd;
@ -5998,7 +5998,7 @@ static LRESULT LISTVIEW_RButtonDown(HWND hwnd, WORD wKey, WORD wPosX,
NMHDR nmh; NMHDR nmh;
INT nItem; INT nItem;
TRACE(listview, "(hwnd=%x,key=%hu,X=%hu,Y=%hu)\n", hwnd, wKey, wPosX, wPosY); TRACE("(hwnd=%x,key=%hu,X=%hu,Y=%hu)\n", hwnd, wKey, wPosX, wPosY);
/* send NM_RELEASEDCAPTURE notification */ /* send NM_RELEASEDCAPTURE notification */
nmh.hwndFrom = hwnd; nmh.hwndFrom = hwnd;
@ -6054,7 +6054,7 @@ static LRESULT LISTVIEW_RButtonUp(HWND hwnd, WORD wKey, WORD wPosX,
INT nCtrlId = GetWindowLongA(hwnd, GWL_ID); INT nCtrlId = GetWindowLongA(hwnd, GWL_ID);
NMHDR nmh; NMHDR nmh;
TRACE(listview, "(hwnd=%x,key=%hu,X=%hu,Y=%hu)\n", hwnd, wKey, wPosX, wPosY); TRACE("(hwnd=%x,key=%hu,X=%hu,Y=%hu)\n", hwnd, wKey, wPosX, wPosY);
if (infoPtr->bRButtonDown != FALSE) if (infoPtr->bRButtonDown != FALSE)
{ {
@ -6118,7 +6118,7 @@ static LRESULT LISTVIEW_SetFont(HWND hwnd, HFONT hFont, WORD fRedraw)
LISTVIEW_INFO *infoPtr = (LISTVIEW_INFO *)GetWindowLongA(hwnd, 0); LISTVIEW_INFO *infoPtr = (LISTVIEW_INFO *)GetWindowLongA(hwnd, 0);
UINT uView = GetWindowLongA(hwnd, GWL_STYLE) & LVS_TYPEMASK; UINT uView = GetWindowLongA(hwnd, GWL_STYLE) & LVS_TYPEMASK;
TRACE(listview, "(hwnd=%x,hfont=%x,redraw=%hu)\n", hwnd, hFont, fRedraw); TRACE("(hwnd=%x,hfont=%x,redraw=%hu)\n", hwnd, hFont, fRedraw);
if (hFont == 0) if (hFont == 0)
{ {
@ -6165,7 +6165,7 @@ static LRESULT LISTVIEW_Size(HWND hwnd, int Width, int Height)
LONG lStyle = GetWindowLongA(hwnd, GWL_STYLE); LONG lStyle = GetWindowLongA(hwnd, GWL_STYLE);
UINT uView = lStyle & LVS_TYPEMASK; UINT uView = lStyle & LVS_TYPEMASK;
TRACE(listview, "(hwnd=%x, width=%d, height=%d)\n",hwnd, Width, Height); TRACE("(hwnd=%x, width=%d, height=%d)\n",hwnd, Width, Height);
LISTVIEW_UpdateSize(hwnd); LISTVIEW_UpdateSize(hwnd);
@ -6258,7 +6258,7 @@ static INT LISTVIEW_StyleChanged(HWND hwnd, WPARAM wStyleType,
UINT uOldView = lpss->styleOld & LVS_TYPEMASK; UINT uOldView = lpss->styleOld & LVS_TYPEMASK;
RECT rcList = infoPtr->rcList; RECT rcList = infoPtr->rcList;
TRACE(listview, "(hwnd=%x, styletype=%x, stylestruct=%p)\n", TRACE("(hwnd=%x, styletype=%x, stylestruct=%p)\n",
hwnd, wStyleType, lpss); hwnd, wStyleType, lpss);
if (wStyleType == GWL_STYLE) if (wStyleType == GWL_STYLE)
@ -6664,7 +6664,7 @@ LRESULT WINAPI LISTVIEW_WindowProc(HWND hwnd, UINT uMsg, WPARAM wParam,
default: default:
if (uMsg >= WM_USER) if (uMsg >= WM_USER)
{ {
ERR(listview, "unknown msg %04x wp=%08x lp=%08lx\n", uMsg, wParam, ERR("unknown msg %04x wp=%08x lp=%08lx\n", uMsg, wParam,
lParam); lParam);
} }

View file

@ -17,7 +17,7 @@
#include "winbase.h" #include "winbase.h"
#include "commctrl.h" #include "commctrl.h"
#include "monthcal.h" #include "monthcal.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(monthcal) DEFAULT_DEBUG_CHANNEL(monthcal)
@ -81,7 +81,7 @@ MONTHCAL_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
default: default:
if (uMsg >= WM_USER) if (uMsg >= WM_USER)
ERR (monthcal, "unknown msg %04x wp=%08x lp=%08lx\n", ERR("unknown msg %04x wp=%08x lp=%08lx\n",
uMsg, wParam, lParam); uMsg, wParam, lParam);
return DefWindowProcA (hwnd, uMsg, wParam, lParam); return DefWindowProcA (hwnd, uMsg, wParam, lParam);
} }

View file

@ -16,7 +16,7 @@
#include "winbase.h" #include "winbase.h"
#include "commctrl.h" #include "commctrl.h"
#include "nativefont.h" #include "nativefont.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(nativefont) DEFAULT_DEBUG_CHANNEL(nativefont)
@ -72,7 +72,7 @@ NATIVEFONT_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
return NATIVEFONT_Destroy (hwnd, wParam, lParam); return NATIVEFONT_Destroy (hwnd, wParam, lParam);
default: default:
ERR (nativefont, "unknown msg %04x wp=%08x lp=%08lx\n", ERR("unknown msg %04x wp=%08x lp=%08lx\n",
uMsg, wParam, lParam); uMsg, wParam, lParam);
return DefWindowProcA (hwnd, uMsg, wParam, lParam); return DefWindowProcA (hwnd, uMsg, wParam, lParam);
} }

View file

@ -16,7 +16,7 @@
#include "winbase.h" #include "winbase.h"
#include "commctrl.h" #include "commctrl.h"
#include "pager.h" #include "pager.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(pager) DEFAULT_DEBUG_CHANNEL(pager)
@ -67,7 +67,7 @@ PAGER_GetButtonState (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
/* PAGER_INFO *infoPtr = PAGER_GetInfoPtr (hwnd); */ /* PAGER_INFO *infoPtr = PAGER_GetInfoPtr (hwnd); */
FIXME (pager, "empty stub!\n"); FIXME("empty stub!\n");
return PGF_INVISIBLE; return PGF_INVISIBLE;
} }
@ -104,7 +104,7 @@ PAGER_RecalcSize (HWND hwnd, WPARAM wParam, LPARAM lParam)
infoPtr->nChildSize = (dwStyle & PGS_HORZ) ? nmpgcs.iWidth : nmpgcs.iHeight; infoPtr->nChildSize = (dwStyle & PGS_HORZ) ? nmpgcs.iWidth : nmpgcs.iHeight;
FIXME (pager, "Child size %d\n", infoPtr->nChildSize); FIXME("Child size %d\n", infoPtr->nChildSize);
} }
@ -149,7 +149,7 @@ PAGER_SetButtonSize (HWND hwnd, WPARAM wParam, LPARAM lParam)
infoPtr->nButtonSize = (INT)lParam; infoPtr->nButtonSize = (INT)lParam;
FIXME (pager, "size=%d\n", infoPtr->nButtonSize); FIXME("size=%d\n", infoPtr->nButtonSize);
/* FIXME: redraw */ /* FIXME: redraw */
@ -164,7 +164,7 @@ PAGER_SetChild (HWND hwnd, WPARAM wParam, LPARAM lParam)
infoPtr->hwndChild = IsWindow ((HWND)lParam) ? (HWND)lParam : 0; infoPtr->hwndChild = IsWindow ((HWND)lParam) ? (HWND)lParam : 0;
FIXME (pager, "hwnd=%x\n", infoPtr->hwndChild); FIXME("hwnd=%x\n", infoPtr->hwndChild);
/* FIXME: redraw */ /* FIXME: redraw */
if (infoPtr->hwndChild) { if (infoPtr->hwndChild) {
@ -184,7 +184,7 @@ PAGER_SetPos (HWND hwnd, WPARAM wParam, LPARAM lParam)
infoPtr->nPos = (INT)lParam; infoPtr->nPos = (INT)lParam;
FIXME (pager, "pos=%d\n", infoPtr->nPos); FIXME("pos=%d\n", infoPtr->nPos);
/* FIXME: redraw */ /* FIXME: redraw */
SetWindowPos (infoPtr->hwndChild, HWND_TOP, SetWindowPos (infoPtr->hwndChild, HWND_TOP,
@ -251,7 +251,7 @@ PAGER_MouseMove (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
/* PAGER_INFO *infoPtr = PAGER_GetInfoPtr (hwnd); */ /* PAGER_INFO *infoPtr = PAGER_GetInfoPtr (hwnd); */
TRACE (pager, "stub!\n"); TRACE("stub!\n");
return 0; return 0;
} }
@ -349,7 +349,7 @@ PAGER_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
default: default:
if (uMsg >= WM_USER) if (uMsg >= WM_USER)
ERR (pager, "unknown msg %04x wp=%08x lp=%08lx\n", ERR("unknown msg %04x wp=%08x lp=%08lx\n",
uMsg, wParam, lParam); uMsg, wParam, lParam);
return DefWindowProcA (hwnd, uMsg, wParam, lParam); return DefWindowProcA (hwnd, uMsg, wParam, lParam);
} }

View file

@ -9,7 +9,7 @@
#include "winbase.h" #include "winbase.h"
#include "commctrl.h" #include "commctrl.h"
#include "progress.h" #include "progress.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(progress) DEFAULT_DEBUG_CHANNEL(progress)
@ -20,7 +20,7 @@ DEFAULT_DEBUG_CHANNEL(progress)
/* Work constants */ /* Work constants */
#define UNKNOWN_PARAM(msg, wParam, lParam) WARN(progress, \ #define UNKNOWN_PARAM(msg, wParam, lParam) WARN(\
"Unknown parameter(s) for message " #msg \ "Unknown parameter(s) for message " #msg \
"(%04x): wp=%04x lp=%08lx\n", msg, wParam, lParam); "(%04x): wp=%04x lp=%08lx\n", msg, wParam, lParam);
@ -40,7 +40,7 @@ PROGRESS_Draw (HWND hwnd, HDC hdc)
RECT rect; RECT rect;
DWORD dwStyle; DWORD dwStyle;
TRACE(progress, "refresh pos=%d min=%d, max=%d\n", TRACE("refresh pos=%d min=%d, max=%d\n",
infoPtr->CurVal, infoPtr->MinVal, infoPtr->MaxVal); infoPtr->CurVal, infoPtr->MinVal, infoPtr->MaxVal);
/* get the required bar brush */ /* get the required bar brush */
@ -223,11 +223,11 @@ LRESULT WINAPI ProgressWindowProc(HWND hwnd, UINT message,
infoPtr->ColorBar=CLR_DEFAULT; infoPtr->ColorBar=CLR_DEFAULT;
infoPtr->ColorBk=CLR_DEFAULT; infoPtr->ColorBk=CLR_DEFAULT;
infoPtr->hFont=(HANDLE)NULL; infoPtr->hFont=(HANDLE)NULL;
TRACE(progress, "Progress Ctrl creation, hwnd=%04x\n", hwnd); TRACE("Progress Ctrl creation, hwnd=%04x\n", hwnd);
break; break;
case WM_DESTROY: case WM_DESTROY:
TRACE (progress, "Progress Ctrl destruction, hwnd=%04x\n", hwnd); TRACE("Progress Ctrl destruction, hwnd=%04x\n", hwnd);
COMCTL32_Free (infoPtr); COMCTL32_Free (infoPtr);
break; break;
@ -341,7 +341,7 @@ LRESULT WINAPI ProgressWindowProc(HWND hwnd, UINT message,
default: default:
if (message >= WM_USER) if (message >= WM_USER)
ERR(progress, "unknown msg %04x wp=%04x lp=%08lx\n", ERR("unknown msg %04x wp=%04x lp=%08lx\n",
message, wParam, lParam ); message, wParam, lParam );
return DefWindowProcA( hwnd, message, wParam, lParam ); return DefWindowProcA( hwnd, message, wParam, lParam );
} }

View file

@ -16,7 +16,7 @@
#include "prsht.h" #include "prsht.h"
#include "winnls.h" #include "winnls.h"
#include "comctl32.h" #include "comctl32.h"
#include "debug.h" #include "debugtools.h"
/****************************************************************************** /******************************************************************************
@ -144,7 +144,7 @@ static BOOL PROPSHEET_CollectSheetInfo(LPCPROPSHEETHEADERA lppsh,
if (dwFlags & PSH_USEPSTARTPAGE) if (dwFlags & PSH_USEPSTARTPAGE)
{ {
TRACE(propsheet, "PSH_USEPSTARTPAGE is on"); TRACE("PSH_USEPSTARTPAGE is on");
psInfo->active_page = 0; psInfo->active_page = 0;
} }
else else
@ -268,7 +268,7 @@ BOOL PROPSHEET_CollectPageInfo(LPCPROPSHEETPAGEA lppsp,
/* Extract the caption */ /* Extract the caption */
psInfo->proppage[index].pszText = (LPCWSTR)p; psInfo->proppage[index].pszText = (LPCWSTR)p;
TRACE(propsheet, "Tab %d %s\n",index,debugstr_w((LPCWSTR)p)); TRACE("Tab %d %s\n",index,debugstr_w((LPCWSTR)p));
p += lstrlenW((LPCWSTR)p) + 1; p += lstrlenW((LPCWSTR)p) + 1;
return TRUE; return TRUE;
@ -326,7 +326,7 @@ static BOOL PROPSHEET_IsTooSmall(HWND hwndDlg, PropSheetInfo* psInfo)
* Original tab size. * Original tab size.
*/ */
GetClientRect(hwndTabCtrl, &rcOrigTab); GetClientRect(hwndTabCtrl, &rcOrigTab);
TRACE(propsheet, "orig tab %d %d %d %d\n", rcOrigTab.left, rcOrigTab.top, TRACE("orig tab %d %d %d %d\n", rcOrigTab.left, rcOrigTab.top,
rcOrigTab.right, rcOrigTab.bottom); rcOrigTab.right, rcOrigTab.bottom);
/* /*
@ -338,7 +338,7 @@ static BOOL PROPSHEET_IsTooSmall(HWND hwndDlg, PropSheetInfo* psInfo)
rcPage.bottom = psInfo->height; rcPage.bottom = psInfo->height;
MapDialogRect(hwndDlg, &rcPage); MapDialogRect(hwndDlg, &rcPage);
TRACE(propsheet, "biggest page %d %d %d %d\n", rcPage.left, rcPage.top, TRACE("biggest page %d %d %d %d\n", rcPage.left, rcPage.top,
rcPage.right, rcPage.bottom); rcPage.right, rcPage.bottom);
if (rcPage.right > rcOrigTab.right) if (rcPage.right > rcOrigTab.right)
@ -392,7 +392,7 @@ static BOOL PROPSHEET_AdjustSize(HWND hwndDlg, PropSheetInfo* psInfo)
GetClientRect(hwndTabCtrl, &rc); GetClientRect(hwndTabCtrl, &rc);
TRACE(propsheet, "tab client rc %d %d %d %d\n", TRACE("tab client rc %d %d %d %d\n",
rc.left, rc.top, rc.right, rc.bottom); rc.left, rc.top, rc.right, rc.bottom);
rc.right += ((padding.x * 2) + tabOffsetX); rc.right += ((padding.x * 2) + tabOffsetX);
@ -576,7 +576,7 @@ static int PROPSHEET_CreatePage(HWND hwndParent,
PADDING_INFO padding = PROPSHEET_GetPaddingInfo(hwndParent); PADDING_INFO padding = PROPSHEET_GetPaddingInfo(hwndParent);
HWND hwndTabCtrl = GetDlgItem(hwndParent, IDC_TABCONTROL); HWND hwndTabCtrl = GetDlgItem(hwndParent, IDC_TABCONTROL);
TRACE(propsheet, "index %d\n", index); TRACE("index %d\n", index);
if (ppshpage->dwFlags & PSP_DLGINDIRECT) if (ppshpage->dwFlags & PSP_DLGINDIRECT)
pTemplate = (DLGTEMPLATE*)ppshpage->u1.pResource; pTemplate = (DLGTEMPLATE*)ppshpage->u1.pResource;
@ -821,25 +821,25 @@ static void PROPSHEET_PressButton(HWND hwndDlg, int buttonID)
SendMessageA(hwndDlg, WM_COMMAND, IDC_APPLY_BUTTON, 0); SendMessageA(hwndDlg, WM_COMMAND, IDC_APPLY_BUTTON, 0);
break; break;
case PSBTN_BACK: case PSBTN_BACK:
FIXME(propsheet, "Wizard mode not implemented.\n"); FIXME("Wizard mode not implemented.\n");
break; break;
case PSBTN_CANCEL: case PSBTN_CANCEL:
SendMessageA(hwndDlg, WM_COMMAND, IDCANCEL, 0); SendMessageA(hwndDlg, WM_COMMAND, IDCANCEL, 0);
break; break;
case PSBTN_FINISH: case PSBTN_FINISH:
FIXME(propsheet, "Wizard mode not implemented.\n"); FIXME("Wizard mode not implemented.\n");
break; break;
case PSBTN_HELP: case PSBTN_HELP:
SendMessageA(hwndDlg, WM_COMMAND, IDHELP, 0); SendMessageA(hwndDlg, WM_COMMAND, IDHELP, 0);
break; break;
case PSBTN_NEXT: case PSBTN_NEXT:
FIXME(propsheet, "Wizard mode not implemented.\n"); FIXME("Wizard mode not implemented.\n");
break; break;
case PSBTN_OK: case PSBTN_OK:
SendMessageA(hwndDlg, WM_COMMAND, IDOK, 0); SendMessageA(hwndDlg, WM_COMMAND, IDOK, 0);
break; break;
default: default:
FIXME(propsheet, "Invalid button index %d\n", buttonID); FIXME("Invalid button index %d\n", buttonID);
} }
} }
@ -868,7 +868,7 @@ static BOOL PROPSHEET_SetCurSel(HWND hwndDlg,
return FALSE; return FALSE;
if (hpage != NULL) if (hpage != NULL)
FIXME(propsheet, "Implement HPROPSHEETPAGE!\n"); FIXME("Implement HPROPSHEETPAGE!\n");
else else
hwndPage = psInfo->proppage[index].hwndPage; hwndPage = psInfo->proppage[index].hwndPage;
@ -1034,12 +1034,12 @@ static BOOL PROPSHEET_RemovePage(HWND hwndDlg,
if (index == -1) if (index == -1)
{ {
TRACE(propsheet, "Could not find page to remove!\n"); TRACE("Could not find page to remove!\n");
return FALSE; return FALSE;
} }
} }
TRACE(propsheet, "total pages %d removing page %d active page %d\n", TRACE("total pages %d removing page %d active page %d\n",
psInfo->nPages, index, psInfo->active_page); psInfo->nPages, index, psInfo->active_page);
/* /*
* Check if we're removing the active page. * Check if we're removing the active page.
@ -1061,7 +1061,7 @@ static BOOL PROPSHEET_RemovePage(HWND hwndDlg,
} }
else else
{ {
TRACE(propsheet, "Removing the only page, close the dialog!\n"); TRACE("Removing the only page, close the dialog!\n");
if (psInfo->isModeless) if (psInfo->isModeless)
psInfo->active_page = -1; psInfo->active_page = -1;
@ -1166,7 +1166,7 @@ INT WINAPI PropertySheetA(LPCPROPSHEETHEADERA lppsh)
*/ */
INT WINAPI PropertySheetW(LPCPROPSHEETHEADERW propertySheetHeader) INT WINAPI PropertySheetW(LPCPROPSHEETHEADERW propertySheetHeader)
{ {
FIXME(propsheet, "(%p): stub\n", propertySheetHeader); FIXME("(%p): stub\n", propertySheetHeader);
return -1; return -1;
} }
@ -1189,7 +1189,7 @@ HPROPSHEETPAGE WINAPI CreatePropertySheetPageA(
*/ */
HPROPSHEETPAGE WINAPI CreatePropertySheetPageW(LPCPROPSHEETPAGEW lpPropSheetPage) HPROPSHEETPAGE WINAPI CreatePropertySheetPageW(LPCPROPSHEETPAGEW lpPropSheetPage)
{ {
FIXME(propsheet, "(%p): stub\n", lpPropSheetPage); FIXME("(%p): stub\n", lpPropSheetPage);
return 0; return 0;
} }
@ -1429,7 +1429,7 @@ PROPSHEET_DialogProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
case PSM_ISDIALOGMESSAGE: case PSM_ISDIALOGMESSAGE:
{ {
FIXME (propsheet, "Unimplemented msg PSM_ISDIALOGMESSAGE\n"); FIXME("Unimplemented msg PSM_ISDIALOGMESSAGE\n");
return 0; return 0;
} }
@ -1438,19 +1438,19 @@ PROPSHEET_DialogProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
return TRUE; return TRUE;
case PSM_SETTITLEW: case PSM_SETTITLEW:
FIXME (propsheet, "Unimplemented msg PSM_SETTITLE32W\n"); FIXME("Unimplemented msg PSM_SETTITLE32W\n");
return 0; return 0;
case PSM_SETWIZBUTTONS: case PSM_SETWIZBUTTONS:
FIXME (propsheet, "Unimplemented msg PSM_SETWIZBUTTONS\n"); FIXME("Unimplemented msg PSM_SETWIZBUTTONS\n");
return 0; return 0;
case PSM_SETCURSELID: case PSM_SETCURSELID:
FIXME (propsheet, "Unimplemented msg PSM_SETCURSELID\n"); FIXME("Unimplemented msg PSM_SETCURSELID\n");
return 0; return 0;
case PSM_SETFINISHTEXTA: case PSM_SETFINISHTEXTA:
FIXME (propsheet, "Unimplemented msg PSM_SETFINISHTEXT32A\n"); FIXME("Unimplemented msg PSM_SETFINISHTEXT32A\n");
return 0; return 0;
case PSM_SETFINISHTEXTW: case PSM_SETFINISHTEXTW:
FIXME (propsheet, "Unimplemented msg PSM_SETFINISHTEXT32W\n"); FIXME("Unimplemented msg PSM_SETFINISHTEXT32W\n");
return 0; return 0;
default: default:

View file

@ -24,7 +24,7 @@
#include "wingdi.h" #include "wingdi.h"
#include "commctrl.h" #include "commctrl.h"
#include "rebar.h" #include "rebar.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(rebar) DEFAULT_DEBUG_CHANNEL(rebar)
@ -371,7 +371,7 @@ REBAR_ForceResize (HWND hwnd)
REBAR_INFO *infoPtr = REBAR_GetInfoPtr (hwnd); REBAR_INFO *infoPtr = REBAR_GetInfoPtr (hwnd);
RECT rc; RECT rc;
TRACE (rebar, " to [%d x %d]!\n", TRACE(" to [%d x %d]!\n",
infoPtr->calcSize.cx, infoPtr->calcSize.cy); infoPtr->calcSize.cx, infoPtr->calcSize.cy);
infoPtr->bAutoResize = TRUE; infoPtr->bAutoResize = TRUE;
@ -405,7 +405,7 @@ REBAR_MoveChildWindows (HWND hwnd)
if (lpBand->fStyle & RBBS_HIDDEN) if (lpBand->fStyle & RBBS_HIDDEN)
continue; continue;
if (lpBand->hwndChild) { if (lpBand->hwndChild) {
TRACE (rebar, "hwndChild = %x\n", lpBand->hwndChild); TRACE("hwndChild = %x\n", lpBand->hwndChild);
GetClassNameA (lpBand->hwndChild, szClassName, 40); GetClassNameA (lpBand->hwndChild, szClassName, 40);
if (!lstrcmpA (szClassName, "ComboBox")) { if (!lstrcmpA (szClassName, "ComboBox")) {
@ -463,7 +463,7 @@ REBAR_InternalHitTest (HWND hwnd, LPPOINT lpPt, UINT *pFlags, INT *pBand)
*pFlags = RBHT_NOWHERE; *pFlags = RBHT_NOWHERE;
if (pBand) if (pBand)
*pBand = -1; *pBand = -1;
TRACE (rebar, "NOWHERE\n"); TRACE("NOWHERE\n");
return; return;
} }
else { else {
@ -475,27 +475,27 @@ REBAR_InternalHitTest (HWND hwnd, LPPOINT lpPt, UINT *pFlags, INT *pBand)
*pBand = iCount; *pBand = iCount;
if (PtInRect (&lpBand->rcGripper, *lpPt)) { if (PtInRect (&lpBand->rcGripper, *lpPt)) {
*pFlags = RBHT_GRABBER; *pFlags = RBHT_GRABBER;
TRACE (rebar, "ON GRABBER %d\n", iCount); TRACE("ON GRABBER %d\n", iCount);
return; return;
} }
else if (PtInRect (&lpBand->rcCapImage, *lpPt)) { else if (PtInRect (&lpBand->rcCapImage, *lpPt)) {
*pFlags = RBHT_CAPTION; *pFlags = RBHT_CAPTION;
TRACE (rebar, "ON CAPTION %d\n", iCount); TRACE("ON CAPTION %d\n", iCount);
return; return;
} }
else if (PtInRect (&lpBand->rcCapText, *lpPt)) { else if (PtInRect (&lpBand->rcCapText, *lpPt)) {
*pFlags = RBHT_CAPTION; *pFlags = RBHT_CAPTION;
TRACE (rebar, "ON CAPTION %d\n", iCount); TRACE("ON CAPTION %d\n", iCount);
return; return;
} }
else if (PtInRect (&lpBand->rcChild, *lpPt)) { else if (PtInRect (&lpBand->rcChild, *lpPt)) {
*pFlags = RBHT_CLIENT; *pFlags = RBHT_CLIENT;
TRACE (rebar, "ON CLIENT %d\n", iCount); TRACE("ON CLIENT %d\n", iCount);
return; return;
} }
else { else {
*pFlags = RBHT_NOWHERE; *pFlags = RBHT_NOWHERE;
TRACE (rebar, "NOWHERE %d\n", iCount); TRACE("NOWHERE %d\n", iCount);
return; return;
} }
} }
@ -505,7 +505,7 @@ REBAR_InternalHitTest (HWND hwnd, LPPOINT lpPt, UINT *pFlags, INT *pBand)
if (pBand) if (pBand)
*pBand = -1; *pBand = -1;
TRACE (rebar, "NOWHERE\n"); TRACE("NOWHERE\n");
return; return;
} }
} }
@ -513,11 +513,11 @@ REBAR_InternalHitTest (HWND hwnd, LPPOINT lpPt, UINT *pFlags, INT *pBand)
*pFlags = RBHT_NOWHERE; *pFlags = RBHT_NOWHERE;
if (pBand) if (pBand)
*pBand = -1; *pBand = -1;
TRACE (rebar, "NOWHERE\n"); TRACE("NOWHERE\n");
return; return;
} }
TRACE (rebar, "flags=0x%X\n", *pFlags); TRACE("flags=0x%X\n", *pFlags);
return; return;
} }
@ -535,17 +535,17 @@ REBAR_DeleteBand (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (uBand >= infoPtr->uNumBands) if (uBand >= infoPtr->uNumBands)
return FALSE; return FALSE;
TRACE (rebar, "deleting band %u!\n", uBand); TRACE("deleting band %u!\n", uBand);
if (infoPtr->uNumBands == 1) { if (infoPtr->uNumBands == 1) {
TRACE (rebar, " simple delete!\n"); TRACE(" simple delete!\n");
COMCTL32_Free (infoPtr->bands); COMCTL32_Free (infoPtr->bands);
infoPtr->bands = NULL; infoPtr->bands = NULL;
infoPtr->uNumBands = 0; infoPtr->uNumBands = 0;
} }
else { else {
REBAR_BAND *oldBands = infoPtr->bands; REBAR_BAND *oldBands = infoPtr->bands;
TRACE(rebar, "complex delete! [uBand=%u]\n", uBand); TRACE("complex delete! [uBand=%u]\n", uBand);
infoPtr->uNumBands--; infoPtr->uNumBands--;
infoPtr->bands = COMCTL32_Alloc (sizeof (REBAR_BAND) * infoPtr->uNumBands); infoPtr->bands = COMCTL32_Alloc (sizeof (REBAR_BAND) * infoPtr->uNumBands);
@ -603,7 +603,7 @@ REBAR_GetBandCount (HWND hwnd)
{ {
REBAR_INFO *infoPtr = REBAR_GetInfoPtr (hwnd); REBAR_INFO *infoPtr = REBAR_GetInfoPtr (hwnd);
TRACE (rebar, "band count %u!\n", infoPtr->uNumBands); TRACE("band count %u!\n", infoPtr->uNumBands);
return infoPtr->uNumBands; return infoPtr->uNumBands;
} }
@ -623,7 +623,7 @@ REBAR_GetBandInfoA (HWND hwnd, WPARAM wParam, LPARAM lParam)
if ((UINT)wParam >= infoPtr->uNumBands) if ((UINT)wParam >= infoPtr->uNumBands)
return FALSE; return FALSE;
TRACE (rebar, "index %u\n", (UINT)wParam); TRACE("index %u\n", (UINT)wParam);
/* copy band information */ /* copy band information */
lpBand = &infoPtr->bands[(UINT)wParam]; lpBand = &infoPtr->bands[(UINT)wParam];
@ -694,7 +694,7 @@ REBAR_GetBandInfoW (HWND hwnd, WPARAM wParam, LPARAM lParam)
if ((UINT)wParam >= infoPtr->uNumBands) if ((UINT)wParam >= infoPtr->uNumBands)
return FALSE; return FALSE;
TRACE (rebar, "index %u\n", (UINT)wParam); TRACE("index %u\n", (UINT)wParam);
/* copy band information */ /* copy band information */
lpBand = &infoPtr->bands[(UINT)wParam]; lpBand = &infoPtr->bands[(UINT)wParam];
@ -764,7 +764,7 @@ REBAR_GetBarHeight (HWND hwnd, WPARAM wParam, LPARAM lParam)
nHeight += (2 * GetSystemMetrics(SM_CYEDGE)); nHeight += (2 * GetSystemMetrics(SM_CYEDGE));
FIXME (rebar, "height = %d\n", nHeight); FIXME("height = %d\n", nHeight);
return nHeight; return nHeight;
} }
@ -782,7 +782,7 @@ REBAR_GetBarInfo (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (lpInfo->cbSize < sizeof (REBARINFO)) if (lpInfo->cbSize < sizeof (REBARINFO))
return FALSE; return FALSE;
TRACE (rebar, "getting bar info!\n"); TRACE("getting bar info!\n");
if (infoPtr->himl) { if (infoPtr->himl) {
lpInfo->himl = infoPtr->himl; lpInfo->himl = infoPtr->himl;
@ -798,7 +798,7 @@ REBAR_GetBkColor (HWND hwnd)
{ {
REBAR_INFO *infoPtr = REBAR_GetInfoPtr (hwnd); REBAR_INFO *infoPtr = REBAR_GetInfoPtr (hwnd);
TRACE (rebar, "background color 0x%06lx!\n", infoPtr->clrBk); TRACE("background color 0x%06lx!\n", infoPtr->clrBk);
return infoPtr->clrBk; return infoPtr->clrBk;
} }
@ -811,7 +811,7 @@ REBAR_GetBkColor (HWND hwnd)
static LRESULT static LRESULT
REBAR_GetPalette (HWND hwnd, WPARAM wParam, LPARAM lParam) REBAR_GetPalette (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
FIXME (rebar, "empty stub!\n"); FIXME("empty stub!\n");
return 0; return 0;
} }
@ -830,7 +830,7 @@ REBAR_GetRect (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (!lprc) if (!lprc)
return FALSE; return FALSE;
TRACE (rebar, "band %d\n", iBand); TRACE("band %d\n", iBand);
lpBand = &infoPtr->bands[iBand]; lpBand = &infoPtr->bands[iBand];
CopyRect (lprc, &lpBand->rcBand); CopyRect (lprc, &lpBand->rcBand);
@ -850,7 +850,7 @@ REBAR_GetRowCount (HWND hwnd)
{ {
REBAR_INFO *infoPtr = REBAR_GetInfoPtr (hwnd); REBAR_INFO *infoPtr = REBAR_GetInfoPtr (hwnd);
FIXME (rebar, "%u : semi stub!\n", infoPtr->uNumBands); FIXME("%u : semi stub!\n", infoPtr->uNumBands);
return infoPtr->uNumBands; return infoPtr->uNumBands;
} }
@ -861,7 +861,7 @@ REBAR_GetRowHeight (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
/* REBAR_INFO *infoPtr = REBAR_GetInfoPtr (hwnd); */ /* REBAR_INFO *infoPtr = REBAR_GetInfoPtr (hwnd); */
FIXME (rebar, "-- height = 20: semi stub!\n"); FIXME("-- height = 20: semi stub!\n");
return 20; return 20;
} }
@ -872,7 +872,7 @@ REBAR_GetTextColor (HWND hwnd)
{ {
REBAR_INFO *infoPtr = REBAR_GetInfoPtr (hwnd); REBAR_INFO *infoPtr = REBAR_GetInfoPtr (hwnd);
TRACE (rebar, "text color 0x%06lx!\n", infoPtr->clrText); TRACE("text color 0x%06lx!\n", infoPtr->clrText);
return infoPtr->clrText; return infoPtr->clrText;
} }
@ -921,16 +921,16 @@ REBAR_IdToIndex (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (infoPtr->uNumBands < 1) if (infoPtr->uNumBands < 1)
return -1; return -1;
TRACE (rebar, "id %u\n", (UINT)wParam); TRACE("id %u\n", (UINT)wParam);
for (i = 0; i < infoPtr->uNumBands; i++) { for (i = 0; i < infoPtr->uNumBands; i++) {
if (infoPtr->bands[i].wID == (UINT)wParam) { if (infoPtr->bands[i].wID == (UINT)wParam) {
TRACE (rebar, "band %u found!\n", i); TRACE("band %u found!\n", i);
return i; return i;
} }
} }
TRACE (rebar, "no band found!\n"); TRACE("no band found!\n");
return -1; return -1;
} }
@ -950,7 +950,7 @@ REBAR_InsertBandA (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (lprbbi->cbSize < REBARBANDINFO_V3_SIZEA) if (lprbbi->cbSize < REBARBANDINFO_V3_SIZEA)
return FALSE; return FALSE;
TRACE (rebar, "insert band at %u!\n", uIndex); TRACE("insert band at %u!\n", uIndex);
if (infoPtr->uNumBands == 0) { if (infoPtr->uNumBands == 0) {
infoPtr->bands = (REBAR_BAND *)COMCTL32_Alloc (sizeof (REBAR_BAND)); infoPtr->bands = (REBAR_BAND *)COMCTL32_Alloc (sizeof (REBAR_BAND));
@ -980,7 +980,7 @@ REBAR_InsertBandA (HWND hwnd, WPARAM wParam, LPARAM lParam)
infoPtr->uNumBands++; infoPtr->uNumBands++;
TRACE (rebar, "index %u!\n", uIndex); TRACE("index %u!\n", uIndex);
/* initialize band (infoPtr->bands[uIndex])*/ /* initialize band (infoPtr->bands[uIndex])*/
lpBand = &infoPtr->bands[uIndex]; lpBand = &infoPtr->bands[uIndex];
@ -1011,7 +1011,7 @@ REBAR_InsertBandA (HWND hwnd, WPARAM wParam, LPARAM lParam)
lpBand->iImage = -1; lpBand->iImage = -1;
if (lprbbi->fMask & RBBIM_CHILD) { if (lprbbi->fMask & RBBIM_CHILD) {
TRACE (rebar, "hwndChild = %x\n", lprbbi->hwndChild); TRACE("hwndChild = %x\n", lprbbi->hwndChild);
lpBand->hwndChild = lprbbi->hwndChild; lpBand->hwndChild = lprbbi->hwndChild;
lpBand->hwndPrevParent = lpBand->hwndPrevParent =
SetParent (lpBand->hwndChild, hwnd); SetParent (lpBand->hwndChild, hwnd);
@ -1079,7 +1079,7 @@ REBAR_InsertBandW (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (lprbbi->cbSize < REBARBANDINFO_V3_SIZEW) if (lprbbi->cbSize < REBARBANDINFO_V3_SIZEW)
return FALSE; return FALSE;
TRACE (rebar, "insert band at %u!\n", uIndex); TRACE("insert band at %u!\n", uIndex);
if (infoPtr->uNumBands == 0) { if (infoPtr->uNumBands == 0) {
infoPtr->bands = (REBAR_BAND *)COMCTL32_Alloc (sizeof (REBAR_BAND)); infoPtr->bands = (REBAR_BAND *)COMCTL32_Alloc (sizeof (REBAR_BAND));
@ -1109,7 +1109,7 @@ REBAR_InsertBandW (HWND hwnd, WPARAM wParam, LPARAM lParam)
infoPtr->uNumBands++; infoPtr->uNumBands++;
TRACE (rebar, "index %u!\n", uIndex); TRACE("index %u!\n", uIndex);
/* initialize band (infoPtr->bands[uIndex])*/ /* initialize band (infoPtr->bands[uIndex])*/
lpBand = &infoPtr->bands[uIndex]; lpBand = &infoPtr->bands[uIndex];
@ -1140,7 +1140,7 @@ REBAR_InsertBandW (HWND hwnd, WPARAM wParam, LPARAM lParam)
lpBand->iImage = -1; lpBand->iImage = -1;
if (lprbbi->fMask & RBBIM_CHILD) { if (lprbbi->fMask & RBBIM_CHILD) {
TRACE (rebar, "hwndChild = %x\n", lprbbi->hwndChild); TRACE("hwndChild = %x\n", lprbbi->hwndChild);
lpBand->hwndChild = lprbbi->hwndChild; lpBand->hwndChild = lprbbi->hwndChild;
lpBand->hwndPrevParent = lpBand->hwndPrevParent =
SetParent (lpBand->hwndChild, hwnd); SetParent (lpBand->hwndChild, hwnd);
@ -1198,7 +1198,7 @@ REBAR_MaximizeBand (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
/* REBAR_INFO *infoPtr = REBAR_GetInfoPtr (hwnd); */ /* REBAR_INFO *infoPtr = REBAR_GetInfoPtr (hwnd); */
FIXME (rebar, "(uBand = %u fIdeal = %s)\n", FIXME("(uBand = %u fIdeal = %s)\n",
(UINT)wParam, lParam ? "TRUE" : "FALSE"); (UINT)wParam, lParam ? "TRUE" : "FALSE");
@ -1211,7 +1211,7 @@ REBAR_MinimizeBand (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
/* REBAR_INFO *infoPtr = REBAR_GetInfoPtr (hwnd); */ /* REBAR_INFO *infoPtr = REBAR_GetInfoPtr (hwnd); */
FIXME (rebar, "(uBand = %u)\n", (UINT)wParam); FIXME("(uBand = %u)\n", (UINT)wParam);
return 0; return 0;
@ -1223,7 +1223,7 @@ REBAR_MoveBand (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
/* REBAR_INFO *infoPtr = REBAR_GetInfoPtr (hwnd); */ /* REBAR_INFO *infoPtr = REBAR_GetInfoPtr (hwnd); */
FIXME (rebar, "(iFrom = %u iTof = %u)\n", FIXME("(iFrom = %u iTof = %u)\n",
(UINT)wParam, (UINT)lParam); (UINT)wParam, (UINT)lParam);
@ -1245,7 +1245,7 @@ REBAR_SetBandInfoA (HWND hwnd, WPARAM wParam, LPARAM lParam)
if ((UINT)wParam >= infoPtr->uNumBands) if ((UINT)wParam >= infoPtr->uNumBands)
return FALSE; return FALSE;
TRACE (rebar, "index %u\n", (UINT)wParam); TRACE("index %u\n", (UINT)wParam);
/* set band information */ /* set band information */
lpBand = &infoPtr->bands[(UINT)wParam]; lpBand = &infoPtr->bands[(UINT)wParam];
@ -1280,7 +1280,7 @@ REBAR_SetBandInfoA (HWND hwnd, WPARAM wParam, LPARAM lParam)
SetParent (lpBand->hwndChild, hwnd); SetParent (lpBand->hwndChild, hwnd);
} }
else { else {
TRACE (rebar, "child: 0x%x prev parent: 0x%x\n", TRACE("child: 0x%x prev parent: 0x%x\n",
lpBand->hwndChild, lpBand->hwndPrevParent); lpBand->hwndChild, lpBand->hwndPrevParent);
lpBand->hwndChild = 0; lpBand->hwndChild = 0;
lpBand->hwndPrevParent = 0; lpBand->hwndPrevParent = 0;
@ -1338,7 +1338,7 @@ REBAR_SetBandInfoW (HWND hwnd, WPARAM wParam, LPARAM lParam)
if ((UINT)wParam >= infoPtr->uNumBands) if ((UINT)wParam >= infoPtr->uNumBands)
return FALSE; return FALSE;
TRACE (rebar, "index %u\n", (UINT)wParam); TRACE("index %u\n", (UINT)wParam);
/* set band information */ /* set band information */
lpBand = &infoPtr->bands[(UINT)wParam]; lpBand = &infoPtr->bands[(UINT)wParam];
@ -1373,7 +1373,7 @@ REBAR_SetBandInfoW (HWND hwnd, WPARAM wParam, LPARAM lParam)
SetParent (lpBand->hwndChild, hwnd); SetParent (lpBand->hwndChild, hwnd);
} }
else { else {
TRACE (rebar, "child: 0x%x prev parent: 0x%x\n", TRACE("child: 0x%x prev parent: 0x%x\n",
lpBand->hwndChild, lpBand->hwndPrevParent); lpBand->hwndChild, lpBand->hwndPrevParent);
lpBand->hwndChild = 0; lpBand->hwndChild = 0;
lpBand->hwndPrevParent = 0; lpBand->hwndPrevParent = 0;
@ -1429,7 +1429,7 @@ REBAR_SetBarInfo (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (lpInfo->cbSize < sizeof (REBARINFO)) if (lpInfo->cbSize < sizeof (REBARINFO))
return FALSE; return FALSE;
TRACE (rebar, "setting bar info!\n"); TRACE("setting bar info!\n");
if (lpInfo->fMask & RBIM_IMAGELIST) { if (lpInfo->fMask & RBIM_IMAGELIST) {
infoPtr->himl = lpInfo->himl; infoPtr->himl = lpInfo->himl;
@ -1456,7 +1456,7 @@ REBAR_SetBkColor (HWND hwnd, WPARAM wParam, LPARAM lParam)
clrTemp = infoPtr->clrBk; clrTemp = infoPtr->clrBk;
infoPtr->clrBk = (COLORREF)lParam; infoPtr->clrBk = (COLORREF)lParam;
TRACE (rebar, "background color 0x%06lx!\n", infoPtr->clrBk); TRACE("background color 0x%06lx!\n", infoPtr->clrBk);
return clrTemp; return clrTemp;
} }
@ -1487,7 +1487,7 @@ REBAR_SetTextColor (HWND hwnd, WPARAM wParam, LPARAM lParam)
clrTemp = infoPtr->clrText; clrTemp = infoPtr->clrText;
infoPtr->clrText = (COLORREF)lParam; infoPtr->clrText = (COLORREF)lParam;
TRACE (rebar, "text color 0x%06lx!\n", infoPtr->clrText); TRACE("text color 0x%06lx!\n", infoPtr->clrText);
return clrTemp; return clrTemp;
} }
@ -1518,13 +1518,13 @@ REBAR_ShowBand (HWND hwnd, WPARAM wParam, LPARAM lParam)
lpBand = &infoPtr->bands[(INT)wParam]; lpBand = &infoPtr->bands[(INT)wParam];
if ((BOOL)lParam) { if ((BOOL)lParam) {
TRACE (rebar, "show band %d\n", (INT)wParam); TRACE("show band %d\n", (INT)wParam);
lpBand->fStyle = lpBand->fStyle & ~RBBS_HIDDEN; lpBand->fStyle = lpBand->fStyle & ~RBBS_HIDDEN;
if (IsWindow (lpBand->hwndChild)) if (IsWindow (lpBand->hwndChild))
ShowWindow (lpBand->hwndChild, SW_SHOW); ShowWindow (lpBand->hwndChild, SW_SHOW);
} }
else { else {
TRACE (rebar, "hide band %d\n", (INT)wParam); TRACE("hide band %d\n", (INT)wParam);
lpBand->fStyle = lpBand->fStyle | RBBS_HIDDEN; lpBand->fStyle = lpBand->fStyle | RBBS_HIDDEN;
if (IsWindow (lpBand->hwndChild)) if (IsWindow (lpBand->hwndChild))
ShowWindow (lpBand->hwndChild, SW_SHOW); ShowWindow (lpBand->hwndChild, SW_SHOW);
@ -1547,8 +1547,8 @@ REBAR_SizeToRect (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (lpRect == NULL) if (lpRect == NULL)
return FALSE; return FALSE;
FIXME (rebar, "layout change not implemented!\n"); FIXME("layout change not implemented!\n");
FIXME (rebar, "[%d %d %d %d]\n", FIXME("[%d %d %d %d]\n",
lpRect->left, lpRect->top, lpRect->right, lpRect->bottom); lpRect->left, lpRect->top, lpRect->right, lpRect->bottom);
#if 0 #if 0
@ -1588,13 +1588,13 @@ REBAR_Create (HWND hwnd, WPARAM wParam, LPARAM lParam)
infoPtr->bUnicode = IsWindowUnicode (hwnd); infoPtr->bUnicode = IsWindowUnicode (hwnd);
if (GetWindowLongA (hwnd, GWL_STYLE) & RBS_AUTOSIZE) if (GetWindowLongA (hwnd, GWL_STYLE) & RBS_AUTOSIZE)
FIXME (rebar, "style RBS_AUTOSIZE set!\n"); FIXME("style RBS_AUTOSIZE set!\n");
#if 0 #if 0
SendMessageA (hwnd, WM_NOTIFYFORMAT, (WPARAM)hwnd, NF_QUERY); SendMessageA (hwnd, WM_NOTIFYFORMAT, (WPARAM)hwnd, NF_QUERY);
#endif #endif
TRACE (rebar, "created!\n"); TRACE("created!\n");
return 0; return 0;
} }
@ -1641,7 +1641,7 @@ REBAR_Destroy (HWND hwnd, WPARAM wParam, LPARAM lParam)
/* free rebar info data */ /* free rebar info data */
COMCTL32_Free (infoPtr); COMCTL32_Free (infoPtr);
TRACE (rebar, "destroyed!\n"); TRACE("destroyed!\n");
return 0; return 0;
} }
@ -1729,7 +1729,7 @@ REBAR_SetCursor (HWND hwnd, WPARAM wParam, LPARAM lParam)
POINT pt; POINT pt;
UINT flags; UINT flags;
TRACE (rebar, "code=0x%X id=0x%X\n", LOWORD(lParam), HIWORD(lParam)); TRACE("code=0x%X id=0x%X\n", LOWORD(lParam), HIWORD(lParam));
GetCursorPos (&pt); GetCursorPos (&pt);
ScreenToClient (hwnd, &pt); ScreenToClient (hwnd, &pt);
@ -1796,7 +1796,7 @@ REBAR_Size (HWND hwnd, WPARAM wParam, LPARAM lParam)
return 0; return 0;
} }
TRACE (rebar, "sizing rebar!\n"); TRACE("sizing rebar!\n");
/* get parent rectangle */ /* get parent rectangle */
GetClientRect (GetParent (hwnd), &rcParent); GetClientRect (GetParent (hwnd), &rcParent);
@ -2000,7 +2000,7 @@ REBAR_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
default: default:
if (uMsg >= WM_USER) if (uMsg >= WM_USER)
ERR (rebar, "unknown msg %04x wp=%08x lp=%08lx\n", ERR("unknown msg %04x wp=%08x lp=%08lx\n",
uMsg, wParam, lParam); uMsg, wParam, lParam);
return DefWindowProcA (hwnd, uMsg, wParam, lParam); return DefWindowProcA (hwnd, uMsg, wParam, lParam);
} }

View file

@ -8,7 +8,7 @@
#include "winbase.h" #include "winbase.h"
#include "commctrl.h" #include "commctrl.h"
#include "status.h" #include "status.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(statusbar) DEFAULT_DEBUG_CHANNEL(statusbar)
@ -599,7 +599,7 @@ STATUSBAR_SetParts (HWND hwnd, WPARAM wParam, LPARAM lParam)
ti.cbSize = sizeof(TTTOOLINFOA); ti.cbSize = sizeof(TTTOOLINFOA);
ti.hwnd = hwnd; ti.hwnd = hwnd;
for (i = nTipCount; i < self->numParts; i++) { for (i = nTipCount; i < self->numParts; i++) {
TRACE (statusbar, "add tool %d\n", i); TRACE("add tool %d\n", i);
ti.uId = i; ti.uId = i;
SendMessageA (self->hwndToolTip, TTM_ADDTOOLA, SendMessageA (self->hwndToolTip, TTM_ADDTOOLA,
0, (LPARAM)&ti); 0, (LPARAM)&ti);
@ -611,7 +611,7 @@ STATUSBAR_SetParts (HWND hwnd, WPARAM wParam, LPARAM lParam)
for (i = nTipCount - 1; i >= self->numParts; i--) { for (i = nTipCount - 1; i >= self->numParts; i--) {
FIXME (statusbar, "delete tool %d\n", i); FIXME("delete tool %d\n", i);
} }
} }
@ -716,7 +716,7 @@ STATUSBAR_SetTipTextA (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
STATUSWINDOWINFO *infoPtr = STATUSBAR_GetInfoPtr (hwnd); STATUSWINDOWINFO *infoPtr = STATUSBAR_GetInfoPtr (hwnd);
TRACE (statusbar, "part %d: \"%s\"\n", (INT)wParam, (LPSTR)lParam); TRACE("part %d: \"%s\"\n", (INT)wParam, (LPSTR)lParam);
if (infoPtr->hwndToolTip) { if (infoPtr->hwndToolTip) {
TTTOOLINFOA ti; TTTOOLINFOA ti;
ti.cbSize = sizeof(TTTOOLINFOA); ti.cbSize = sizeof(TTTOOLINFOA);
@ -737,7 +737,7 @@ STATUSBAR_SetTipTextW (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
STATUSWINDOWINFO *infoPtr = STATUSBAR_GetInfoPtr (hwnd); STATUSWINDOWINFO *infoPtr = STATUSBAR_GetInfoPtr (hwnd);
TRACE (statusbar, "part %d: \"%s\"\n", (INT)wParam, (LPSTR)lParam); TRACE("part %d: \"%s\"\n", (INT)wParam, (LPSTR)lParam);
if (infoPtr->hwndToolTip) { if (infoPtr->hwndToolTip) {
TTTOOLINFOW ti; TTTOOLINFOW ti;
ti.cbSize = sizeof(TTTOOLINFOW); ti.cbSize = sizeof(TTTOOLINFOW);
@ -759,7 +759,7 @@ STATUSBAR_SetUnicodeFormat (HWND hwnd, WPARAM wParam)
STATUSWINDOWINFO *infoPtr = STATUSBAR_GetInfoPtr (hwnd); STATUSWINDOWINFO *infoPtr = STATUSBAR_GetInfoPtr (hwnd);
BOOL bTemp = infoPtr->bUnicode; BOOL bTemp = infoPtr->bUnicode;
TRACE (statusbar, "(0x%x)\n", (BOOL)wParam); TRACE("(0x%x)\n", (BOOL)wParam);
infoPtr->bUnicode = (BOOL)wParam; infoPtr->bUnicode = (BOOL)wParam;
return bTemp; return bTemp;
@ -1229,7 +1229,7 @@ StatusWindowProc (HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
default: default:
if (msg >= WM_USER) if (msg >= WM_USER)
ERR (statusbar, "unknown msg %04x wp=%04x lp=%08lx\n", ERR("unknown msg %04x wp=%04x lp=%08lx\n",
msg, wParam, lParam); msg, wParam, lParam);
return DefWindowProcA (hwnd, msg, wParam, lParam); return DefWindowProcA (hwnd, msg, wParam, lParam);
} }

View file

@ -16,7 +16,7 @@
#include "winbase.h" #include "winbase.h"
#include "commctrl.h" #include "commctrl.h"
#include "tab.h" #include "tab.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(tab) DEFAULT_DEBUG_CHANNEL(tab)
@ -129,7 +129,7 @@ TAB_SetCurFocus (HWND hwnd,WPARAM wParam)
infoPtr->uFocus=iItem; infoPtr->uFocus=iItem;
if (GetWindowLongA(hwnd, GWL_STYLE) & TCS_BUTTONS) { if (GetWindowLongA(hwnd, GWL_STYLE) & TCS_BUTTONS) {
FIXME (tab,"Should set input focus\n"); FIXME("Should set input focus\n");
} else { } else {
if (infoPtr->iSelected != iItem) { if (infoPtr->iSelected != iItem) {
if (TAB_SendSimpleNotify(hwnd, TCN_SELCHANGING)!=TRUE) { if (TAB_SendSimpleNotify(hwnd, TCN_SELCHANGING)!=TRUE) {
@ -398,7 +398,7 @@ TAB_LButtonUp (HWND hwnd, WPARAM wParam, LPARAM lParam)
newItem=TAB_InternalHitTest (hwnd, infoPtr,pt,&dummy); newItem=TAB_InternalHitTest (hwnd, infoPtr,pt,&dummy);
TRACE(tab, "On Tab, item %d\n", newItem); TRACE("On Tab, item %d\n", newItem);
if ( (newItem!=-1) && if ( (newItem!=-1) &&
(infoPtr->iSelected != newItem) ) (infoPtr->iSelected != newItem) )
@ -714,8 +714,8 @@ static void TAB_SetItemBounds (HWND hwnd)
size.cx + 2*HORIZONTAL_ITEM_PADDING; size.cx + 2*HORIZONTAL_ITEM_PADDING;
} }
TRACE(tab, "TextSize: %i\n ", size.cx); TRACE("TextSize: %i\n ", size.cx);
TRACE(tab, "Rect: T %i, L %i, B %i, R %i\n", TRACE("Rect: T %i, L %i, B %i, R %i\n",
infoPtr->items[curItem].rect.top, infoPtr->items[curItem].rect.top,
infoPtr->items[curItem].rect.left, infoPtr->items[curItem].rect.left,
infoPtr->items[curItem].rect.bottom, infoPtr->items[curItem].rect.bottom,
@ -1245,7 +1245,7 @@ TAB_InsertItem (HWND hwnd, WPARAM wParam, LPARAM lParam)
RECT rect; RECT rect;
GetClientRect (hwnd, &rect); GetClientRect (hwnd, &rect);
TRACE(tab, "Rect: %x T %i, L %i, B %i, R %i\n", hwnd, TRACE("Rect: %x T %i, L %i, B %i, R %i\n", hwnd,
rect.top, rect.left, rect.bottom, rect.right); rect.top, rect.left, rect.bottom, rect.right);
pti = (TCITEMA *)lParam; pti = (TCITEMA *)lParam;
@ -1297,7 +1297,7 @@ TAB_InsertItem (HWND hwnd, WPARAM wParam, LPARAM lParam)
TAB_InvalidateTabArea(hwnd, infoPtr); TAB_InvalidateTabArea(hwnd, infoPtr);
TRACE(tab, "[%04x]: added item %d '%s'\n", TRACE("[%04x]: added item %d '%s'\n",
hwnd, iItem, infoPtr->items[iItem].pszText); hwnd, iItem, infoPtr->items[iItem].pszText);
TAB_SetItemBounds(hwnd); TAB_SetItemBounds(hwnd);
@ -1331,7 +1331,7 @@ TAB_SetItemA (HWND hwnd, WPARAM wParam, LPARAM lParam)
iItem=(INT) wParam; iItem=(INT) wParam;
tabItem=(LPTCITEMA ) lParam; tabItem=(LPTCITEMA ) lParam;
TRACE (tab,"%d %p\n",iItem, tabItem); TRACE("%d %p\n",iItem, tabItem);
if ((iItem<0) || (iItem>infoPtr->uNumItem)) return FALSE; if ((iItem<0) || (iItem>infoPtr->uNumItem)) return FALSE;
wineItem=& infoPtr->items[iItem]; wineItem=& infoPtr->items[iItem];
@ -1343,7 +1343,7 @@ TAB_SetItemA (HWND hwnd, WPARAM wParam, LPARAM lParam)
wineItem->lParam=tabItem->lParam; wineItem->lParam=tabItem->lParam;
if (tabItem->mask & TCIF_RTLREADING) if (tabItem->mask & TCIF_RTLREADING)
FIXME (tab,"TCIF_RTLREADING\n"); FIXME("TCIF_RTLREADING\n");
if (tabItem->mask & TCIF_STATE) if (tabItem->mask & TCIF_STATE)
wineItem->dwState=tabItem->dwState; wineItem->dwState=tabItem->dwState;
@ -1377,7 +1377,7 @@ TAB_GetItemA (HWND hwnd, WPARAM wParam, LPARAM lParam)
iItem=(INT) wParam; iItem=(INT) wParam;
tabItem=(LPTCITEMA) lParam; tabItem=(LPTCITEMA) lParam;
TRACE (tab,"\n"); TRACE("\n");
if ((iItem<0) || (iItem>infoPtr->uNumItem)) return FALSE; if ((iItem<0) || (iItem>infoPtr->uNumItem)) return FALSE;
wineItem=& infoPtr->items[iItem]; wineItem=& infoPtr->items[iItem];
@ -1389,7 +1389,7 @@ TAB_GetItemA (HWND hwnd, WPARAM wParam, LPARAM lParam)
tabItem->lParam=wineItem->lParam; tabItem->lParam=wineItem->lParam;
if (tabItem->mask & TCIF_RTLREADING) if (tabItem->mask & TCIF_RTLREADING)
FIXME (tab, "TCIF_RTLREADING\n"); FIXME("TCIF_RTLREADING\n");
if (tabItem->mask & TCIF_STATE) if (tabItem->mask & TCIF_STATE)
tabItem->dwState=wineItem->dwState; tabItem->dwState=wineItem->dwState;
@ -1461,7 +1461,7 @@ TAB_GetFont (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
TAB_INFO *infoPtr = TAB_GetInfoPtr(hwnd); TAB_INFO *infoPtr = TAB_GetInfoPtr(hwnd);
TRACE (tab,"\n"); TRACE("\n");
return (LRESULT)infoPtr->hFont; return (LRESULT)infoPtr->hFont;
} }
@ -1471,7 +1471,7 @@ TAB_SetFont (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
TAB_INFO *infoPtr = TAB_GetInfoPtr(hwnd); TAB_INFO *infoPtr = TAB_GetInfoPtr(hwnd);
TRACE (tab,"%x %lx\n",wParam, lParam); TRACE("%x %lx\n",wParam, lParam);
infoPtr->hFont = (HFONT)wParam; infoPtr->hFont = (HFONT)wParam;
@ -1488,7 +1488,7 @@ TAB_GetImageList (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
TAB_INFO *infoPtr = TAB_GetInfoPtr(hwnd); TAB_INFO *infoPtr = TAB_GetInfoPtr(hwnd);
TRACE (tab,"\n"); TRACE("\n");
return (LRESULT)infoPtr->himl; return (LRESULT)infoPtr->himl;
} }
@ -1498,7 +1498,7 @@ TAB_SetImageList (HWND hwnd, WPARAM wParam, LPARAM lParam)
TAB_INFO *infoPtr = TAB_GetInfoPtr(hwnd); TAB_INFO *infoPtr = TAB_GetInfoPtr(hwnd);
HIMAGELIST himlPrev; HIMAGELIST himlPrev;
TRACE (tab,"\n"); TRACE("\n");
himlPrev = infoPtr->himl; himlPrev = infoPtr->himl;
infoPtr->himl= (HIMAGELIST)lParam; infoPtr->himl= (HIMAGELIST)lParam;
return (LRESULT)himlPrev; return (LRESULT)himlPrev;
@ -1571,7 +1571,7 @@ TAB_Create (HWND hwnd, WPARAM wParam, LPARAM lParam)
infoPtr->hwndUpDown = 0; infoPtr->hwndUpDown = 0;
infoPtr->leftmostVisible = 0; infoPtr->leftmostVisible = 0;
TRACE(tab, "Created tab control, hwnd [%04x]\n", hwnd); TRACE("Created tab control, hwnd [%04x]\n", hwnd);
if (GetWindowLongA(hwnd, GWL_STYLE) & TCS_TOOLTIPS) { if (GetWindowLongA(hwnd, GWL_STYLE) & TCS_TOOLTIPS) {
/* Create tooltip control */ /* Create tooltip control */
infoPtr->hwndToolTip = infoPtr->hwndToolTip =
@ -1666,14 +1666,14 @@ TAB_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
return TAB_GetItemA (hwnd, wParam, lParam); return TAB_GetItemA (hwnd, wParam, lParam);
case TCM_GETITEMW: case TCM_GETITEMW:
FIXME (tab, "Unimplemented msg TCM_GETITEMW\n"); FIXME("Unimplemented msg TCM_GETITEMW\n");
return 0; return 0;
case TCM_SETITEMA: case TCM_SETITEMA:
return TAB_SetItemA (hwnd, wParam, lParam); return TAB_SetItemA (hwnd, wParam, lParam);
case TCM_SETITEMW: case TCM_SETITEMW:
FIXME (tab, "Unimplemented msg TCM_SETITEMW\n"); FIXME("Unimplemented msg TCM_SETITEMW\n");
return 0; return 0;
case TCM_DELETEITEM: case TCM_DELETEITEM:
@ -1698,11 +1698,11 @@ TAB_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
return TAB_InsertItem (hwnd, wParam, lParam); return TAB_InsertItem (hwnd, wParam, lParam);
case TCM_INSERTITEMW: case TCM_INSERTITEMW:
FIXME (tab, "Unimplemented msg TCM_INSERTITEM32W\n"); FIXME("Unimplemented msg TCM_INSERTITEM32W\n");
return 0; return 0;
case TCM_SETITEMEXTRA: case TCM_SETITEMEXTRA:
FIXME (tab, "Unimplemented msg TCM_SETITEMEXTRA\n"); FIXME("Unimplemented msg TCM_SETITEMEXTRA\n");
return 0; return 0;
case TCM_ADJUSTRECT: case TCM_ADJUSTRECT:
@ -1712,27 +1712,27 @@ TAB_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
return TAB_SetItemSize (hwnd, wParam, lParam); return TAB_SetItemSize (hwnd, wParam, lParam);
case TCM_REMOVEIMAGE: case TCM_REMOVEIMAGE:
FIXME (tab, "Unimplemented msg TCM_REMOVEIMAGE\n"); FIXME("Unimplemented msg TCM_REMOVEIMAGE\n");
return 0; return 0;
case TCM_SETPADDING: case TCM_SETPADDING:
FIXME (tab, "Unimplemented msg TCM_SETPADDING\n"); FIXME("Unimplemented msg TCM_SETPADDING\n");
return 0; return 0;
case TCM_GETROWCOUNT: case TCM_GETROWCOUNT:
FIXME (tab, "Unimplemented msg TCM_GETROWCOUNT\n"); FIXME("Unimplemented msg TCM_GETROWCOUNT\n");
return 0; return 0;
case TCM_GETUNICODEFORMAT: case TCM_GETUNICODEFORMAT:
FIXME (tab, "Unimplemented msg TCM_GETUNICODEFORMAT\n"); FIXME("Unimplemented msg TCM_GETUNICODEFORMAT\n");
return 0; return 0;
case TCM_SETUNICODEFORMAT: case TCM_SETUNICODEFORMAT:
FIXME (tab, "Unimplemented msg TCM_SETUNICODEFORMAT\n"); FIXME("Unimplemented msg TCM_SETUNICODEFORMAT\n");
return 0; return 0;
case TCM_HIGHLIGHTITEM: case TCM_HIGHLIGHTITEM:
FIXME (tab, "Unimplemented msg TCM_HIGHLIGHTITEM\n"); FIXME("Unimplemented msg TCM_HIGHLIGHTITEM\n");
return 0; return 0;
case TCM_GETTOOLTIPS: case TCM_GETTOOLTIPS:
@ -1748,19 +1748,19 @@ TAB_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
return TAB_SetCurFocus (hwnd, wParam); return TAB_SetCurFocus (hwnd, wParam);
case TCM_SETMINTTABWIDTH: case TCM_SETMINTTABWIDTH:
FIXME (tab, "Unimplemented msg TCM_SETMINTTABWIDTH\n"); FIXME("Unimplemented msg TCM_SETMINTTABWIDTH\n");
return 0; return 0;
case TCM_DESELECTALL: case TCM_DESELECTALL:
FIXME (tab, "Unimplemented msg TCM_DESELECTALL\n"); FIXME("Unimplemented msg TCM_DESELECTALL\n");
return 0; return 0;
case TCM_GETEXTENDEDSTYLE: case TCM_GETEXTENDEDSTYLE:
FIXME (tab, "Unimplemented msg TCM_GETEXTENDEDSTYLE\n"); FIXME("Unimplemented msg TCM_GETEXTENDEDSTYLE\n");
return 0; return 0;
case TCM_SETEXTENDEDSTYLE: case TCM_SETEXTENDEDSTYLE:
FIXME (tab, "Unimplemented msg TCM_SETEXTENDEDSTYLE\n"); FIXME("Unimplemented msg TCM_SETEXTENDEDSTYLE\n");
return 0; return 0;
case WM_GETFONT: case WM_GETFONT:
@ -1814,7 +1814,7 @@ TAB_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
default: default:
if (uMsg >= WM_USER) if (uMsg >= WM_USER)
ERR (tab, "unknown msg %04x wp=%08x lp=%08lx\n", ERR("unknown msg %04x wp=%08x lp=%08lx\n",
uMsg, wParam, lParam); uMsg, wParam, lParam);
return DefWindowProcA (hwnd, uMsg, wParam, lParam); return DefWindowProcA (hwnd, uMsg, wParam, lParam);
} }

View file

@ -34,7 +34,7 @@
#include "cache.h" #include "cache.h"
#include "comctl32.h" #include "comctl32.h"
#include "toolbar.h" #include "toolbar.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(toolbar) DEFAULT_DEBUG_CHANNEL(toolbar)
@ -321,7 +321,7 @@ TOOLBAR_CalcStrings (HWND hwnd, LPSIZE lpSize)
SelectObject (hdc, hOldFont); SelectObject (hdc, hOldFont);
ReleaseDC (0, hdc); ReleaseDC (0, hdc);
TRACE (toolbar, "string size %d x %d!\n", lpSize->cx, lpSize->cy); TRACE("string size %d x %d!\n", lpSize->cx, lpSize->cy);
} }
/*********************************************************************** /***********************************************************************
@ -601,7 +601,7 @@ TOOLBAR_CalcToolbar (HWND hwnd)
nSepRows * SEPARATOR_WIDTH * 2 / 3 + nSepRows * SEPARATOR_WIDTH * 2 / 3 +
nSepRows * (infoPtr->nBitmapHeight + 1) + nSepRows * (infoPtr->nBitmapHeight + 1) +
BOTTOM_BORDER; BOTTOM_BORDER;
TRACE (toolbar, "toolbar height %d\n", infoPtr->nHeight); TRACE("toolbar height %d\n", infoPtr->nHeight);
} }
@ -619,19 +619,19 @@ TOOLBAR_InternalHitTest (HWND hwnd, LPPOINT lpPt)
if (btnPtr->fsStyle & TBSTYLE_SEP) { if (btnPtr->fsStyle & TBSTYLE_SEP) {
if (PtInRect (&btnPtr->rect, *lpPt)) { if (PtInRect (&btnPtr->rect, *lpPt)) {
TRACE (toolbar, " ON SEPARATOR %d!\n", i); TRACE(" ON SEPARATOR %d!\n", i);
return -i; return -i;
} }
} }
else { else {
if (PtInRect (&btnPtr->rect, *lpPt)) { if (PtInRect (&btnPtr->rect, *lpPt)) {
TRACE (toolbar, " ON BUTTON %d!\n", i); TRACE(" ON BUTTON %d!\n", i);
return i; return i;
} }
} }
} }
TRACE (toolbar, " NOWHERE!\n"); TRACE(" NOWHERE!\n");
return -1; return -1;
} }
@ -645,11 +645,11 @@ TOOLBAR_GetButtonIndex (TOOLBAR_INFO *infoPtr, INT idCommand)
btnPtr = infoPtr->buttons; btnPtr = infoPtr->buttons;
for (i = 0; i < infoPtr->nNumButtons; i++, btnPtr++) { for (i = 0; i < infoPtr->nNumButtons; i++, btnPtr++) {
if (btnPtr->idCommand == idCommand) { if (btnPtr->idCommand == idCommand) {
TRACE (toolbar, "command=%d index=%d\n", idCommand, i); TRACE("command=%d index=%d\n", idCommand, i);
return i; return i;
} }
} }
TRACE (toolbar, "no index found for command=%d\n", idCommand); TRACE("no index found for command=%d\n", idCommand);
return -1; return -1;
} }
@ -794,7 +794,7 @@ TOOLBAR_CustomizeDialogProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
COLORREF oldText = 0; COLORREF oldText = 0;
COLORREF oldBk = 0; COLORREF oldBk = 0;
FIXME(toolbar, "action: %x itemState: %x\n", FIXME("action: %x itemState: %x\n",
lpdis->itemAction, lpdis->itemState); lpdis->itemAction, lpdis->itemState);
if (lpdis->itemState & ODS_FOCUS) if (lpdis->itemState & ODS_FOCUS)
@ -876,12 +876,12 @@ TOOLBAR_AddBitmap (HWND hwnd, WPARAM wParam, LPARAM lParam)
if ((!lpAddBmp) || ((INT)wParam <= 0)) if ((!lpAddBmp) || ((INT)wParam <= 0))
return -1; return -1;
TRACE (toolbar, "adding %d bitmaps!\n", wParam); TRACE("adding %d bitmaps!\n", wParam);
if (!(infoPtr->himlStd)) { if (!(infoPtr->himlStd)) {
/* create new standard image list */ /* create new standard image list */
TRACE (toolbar, "creating standard image list!\n"); TRACE("creating standard image list!\n");
/* Windows resize all the buttons to the size of a newly added STandard Image*/ /* Windows resize all the buttons to the size of a newly added STandard Image*/
@ -922,7 +922,7 @@ TOOLBAR_AddBitmap (HWND hwnd, WPARAM wParam, LPARAM lParam)
else if (lpAddBmp->hInst == HINST_COMMCTRL) { else if (lpAddBmp->hInst == HINST_COMMCTRL) {
/* add internal bitmaps */ /* add internal bitmaps */
FIXME (toolbar, "internal bitmaps not supported!\n"); FIXME("internal bitmaps not supported!\n");
/* TODO: Resize all the buttons when a new standard image is added */ /* TODO: Resize all the buttons when a new standard image is added */
/* Hack to "add" some reserved images within the image list /* Hack to "add" some reserved images within the image list
@ -952,7 +952,7 @@ TOOLBAR_AddButtonsA (HWND hwnd, WPARAM wParam, LPARAM lParam)
LPTBBUTTON lpTbb = (LPTBBUTTON)lParam; LPTBBUTTON lpTbb = (LPTBBUTTON)lParam;
INT nOldButtons, nNewButtons, nAddButtons, nCount; INT nOldButtons, nNewButtons, nAddButtons, nCount;
TRACE (toolbar, "adding %d buttons!\n", wParam); TRACE("adding %d buttons!\n", wParam);
nAddButtons = (UINT)wParam; nAddButtons = (UINT)wParam;
nOldButtons = infoPtr->nNumButtons; nOldButtons = infoPtr->nNumButtons;
@ -1019,12 +1019,12 @@ TOOLBAR_AddStringA (HWND hwnd, WPARAM wParam, LPARAM lParam)
if ((wParam) && (HIWORD(lParam) == 0)) { if ((wParam) && (HIWORD(lParam) == 0)) {
char szString[256]; char szString[256];
INT len; INT len;
TRACE (toolbar, "adding string from resource!\n"); TRACE("adding string from resource!\n");
len = LoadStringA ((HINSTANCE)wParam, (UINT)lParam, len = LoadStringA ((HINSTANCE)wParam, (UINT)lParam,
szString, 256); szString, 256);
TRACE (toolbar, "len=%d \"%s\"\n", len, szString); TRACE("len=%d \"%s\"\n", len, szString);
nIndex = infoPtr->nNumStrings; nIndex = infoPtr->nNumStrings;
if (infoPtr->nNumStrings == 0) { if (infoPtr->nNumStrings == 0) {
infoPtr->strings = infoPtr->strings =
@ -1050,11 +1050,11 @@ TOOLBAR_AddStringA (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (p == NULL) if (p == NULL)
return -1; return -1;
TRACE (toolbar, "adding string(s) from array!\n"); TRACE("adding string(s) from array!\n");
nIndex = infoPtr->nNumStrings; nIndex = infoPtr->nNumStrings;
while (*p) { while (*p) {
len = lstrlenA (p); len = lstrlenA (p);
TRACE (toolbar, "len=%d \"%s\"\n", len, p); TRACE("len=%d \"%s\"\n", len, p);
if (infoPtr->nNumStrings == 0) { if (infoPtr->nNumStrings == 0) {
infoPtr->strings = infoPtr->strings =
@ -1091,12 +1091,12 @@ TOOLBAR_AddStringW (HWND hwnd, WPARAM wParam, LPARAM lParam)
if ((wParam) && (HIWORD(lParam) == 0)) { if ((wParam) && (HIWORD(lParam) == 0)) {
WCHAR szString[256]; WCHAR szString[256];
INT len; INT len;
TRACE (toolbar, "adding string from resource!\n"); TRACE("adding string from resource!\n");
len = LoadStringW ((HINSTANCE)wParam, (UINT)lParam, len = LoadStringW ((HINSTANCE)wParam, (UINT)lParam,
szString, 256); szString, 256);
TRACE (toolbar, "len=%d \"%s\"\n", len, debugstr_w(szString)); TRACE("len=%d \"%s\"\n", len, debugstr_w(szString));
nIndex = infoPtr->nNumStrings; nIndex = infoPtr->nNumStrings;
if (infoPtr->nNumStrings == 0) { if (infoPtr->nNumStrings == 0) {
infoPtr->strings = infoPtr->strings =
@ -1122,11 +1122,11 @@ TOOLBAR_AddStringW (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (p == NULL) if (p == NULL)
return -1; return -1;
TRACE (toolbar, "adding string(s) from array!\n"); TRACE("adding string(s) from array!\n");
nIndex = infoPtr->nNumStrings; nIndex = infoPtr->nNumStrings;
while (*p) { while (*p) {
len = lstrlenW (p); len = lstrlenW (p);
TRACE (toolbar, "len=%d \"%s\"\n", len, debugstr_w(p)); TRACE("len=%d \"%s\"\n", len, debugstr_w(p));
if (infoPtr->nNumStrings == 0) { if (infoPtr->nNumStrings == 0) {
infoPtr->strings = infoPtr->strings =
@ -1165,7 +1165,7 @@ TOOLBAR_AutoSize (HWND hwnd, WPARAM wParam, LPARAM lParam)
INT cx, cy; INT cx, cy;
UINT uPosFlags = 0; UINT uPosFlags = 0;
TRACE (toolbar, "resize forced!\n"); TRACE("resize forced!\n");
parent = GetParent (hwnd); parent = GetParent (hwnd);
GetClientRect(parent, &parent_rect); GetClientRect(parent, &parent_rect);
@ -1212,8 +1212,8 @@ TOOLBAR_ButtonStructSize (HWND hwnd, WPARAM wParam, LPARAM lParam)
TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd);
if (infoPtr == NULL) { if (infoPtr == NULL) {
ERR (toolbar, "(0x%x, 0x%x, 0x%lx)\n", hwnd, wParam, lParam); ERR("(0x%x, 0x%x, 0x%lx)\n", hwnd, wParam, lParam);
ERR (toolbar, "infoPtr == NULL!\n"); ERR("infoPtr == NULL!\n");
return 0; return 0;
} }
@ -1362,14 +1362,14 @@ TOOLBAR_DeleteButton (HWND hwnd, WPARAM wParam, LPARAM lParam)
} }
if (infoPtr->nNumButtons == 1) { if (infoPtr->nNumButtons == 1) {
TRACE (toolbar, " simple delete!\n"); TRACE(" simple delete!\n");
COMCTL32_Free (infoPtr->buttons); COMCTL32_Free (infoPtr->buttons);
infoPtr->buttons = NULL; infoPtr->buttons = NULL;
infoPtr->nNumButtons = 0; infoPtr->nNumButtons = 0;
} }
else { else {
TBUTTON_INFO *oldButtons = infoPtr->buttons; TBUTTON_INFO *oldButtons = infoPtr->buttons;
TRACE(toolbar, "complex delete! [nIndex=%d]\n", nIndex); TRACE("complex delete! [nIndex=%d]\n", nIndex);
infoPtr->nNumButtons--; infoPtr->nNumButtons--;
infoPtr->buttons = COMCTL32_Alloc (sizeof (TBUTTON_INFO) * infoPtr->nNumButtons); infoPtr->buttons = COMCTL32_Alloc (sizeof (TBUTTON_INFO) * infoPtr->nNumButtons);
@ -1542,7 +1542,7 @@ TOOLBAR_GetButtonTextA (HWND hwnd, WPARAM wParam, LPARAM lParam)
nStringIndex = infoPtr->buttons[nIndex].iString; nStringIndex = infoPtr->buttons[nIndex].iString;
TRACE (toolbar, "index=%d stringIndex=%d\n", nIndex, nStringIndex); TRACE("index=%d stringIndex=%d\n", nIndex, nStringIndex);
if ((nStringIndex < 0) || (nStringIndex >= infoPtr->nNumStrings)) if ((nStringIndex < 0) || (nStringIndex >= infoPtr->nNumStrings))
return -1; return -1;
@ -1654,7 +1654,7 @@ TOOLBAR_GetMaxSize (HWND hwnd, WPARAM wParam, LPARAM lParam)
lpSize->cx = infoPtr->rcBound.right - infoPtr->rcBound.left; lpSize->cx = infoPtr->rcBound.right - infoPtr->rcBound.left;
lpSize->cy = infoPtr->rcBound.bottom - infoPtr->rcBound.top; lpSize->cy = infoPtr->rcBound.bottom - infoPtr->rcBound.top;
TRACE (toolbar, "maximum size %d x %d\n", TRACE("maximum size %d x %d\n",
infoPtr->rcBound.right - infoPtr->rcBound.left, infoPtr->rcBound.right - infoPtr->rcBound.left,
infoPtr->rcBound.bottom - infoPtr->rcBound.top); infoPtr->rcBound.bottom - infoPtr->rcBound.top);
@ -1761,7 +1761,7 @@ TOOLBAR_GetUnicodeFormat (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd);
TRACE (toolbar, "%s hwnd=0x%x stub!\n", TRACE("%s hwnd=0x%x stub!\n",
infoPtr->bUnicode ? "TRUE" : "FALSE", hwnd); infoPtr->bUnicode ? "TRUE" : "FALSE", hwnd);
return infoPtr->bUnicode; return infoPtr->bUnicode;
@ -1839,10 +1839,10 @@ TOOLBAR_InsertButtonA (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (nIndex < 0) if (nIndex < 0)
return FALSE; return FALSE;
TRACE (toolbar, "inserting button index=%d\n", nIndex); TRACE("inserting button index=%d\n", nIndex);
if (nIndex > infoPtr->nNumButtons) { if (nIndex > infoPtr->nNumButtons) {
nIndex = infoPtr->nNumButtons; nIndex = infoPtr->nNumButtons;
TRACE (toolbar, "adjust index=%d\n", nIndex); TRACE("adjust index=%d\n", nIndex);
} }
oldButtons = infoPtr->buttons; oldButtons = infoPtr->buttons;
@ -2026,7 +2026,7 @@ TOOLBAR_SaveRestoreA (HWND hwnd, WPARAM wParam, LPARAM lParam)
if ((BOOL)wParam) { if ((BOOL)wParam) {
/* save toolbar information */ /* save toolbar information */
FIXME (toolbar, "save to \"%s\" \"%s\"\n", FIXME("save to \"%s\" \"%s\"\n",
lpSave->pszSubKey, lpSave->pszValueName); lpSave->pszSubKey, lpSave->pszValueName);
@ -2034,7 +2034,7 @@ TOOLBAR_SaveRestoreA (HWND hwnd, WPARAM wParam, LPARAM lParam)
else { else {
/* restore toolbar information */ /* restore toolbar information */
FIXME (toolbar, "restore from \"%s\" \"%s\"\n", FIXME("restore from \"%s\" \"%s\"\n",
lpSave->pszSubKey, lpSave->pszValueName); lpSave->pszSubKey, lpSave->pszValueName);
@ -2159,7 +2159,7 @@ TOOLBAR_SetCmdId (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (infoPtr->hwndToolTip) { if (infoPtr->hwndToolTip) {
FIXME (toolbar, "change tool tip!\n"); FIXME("change tool tip!\n");
} }
@ -2325,7 +2325,7 @@ TOOLBAR_SetRows (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (LOWORD(wParam) > 1) { if (LOWORD(wParam) > 1) {
FIXME (toolbar, "multiple rows not supported!\n"); FIXME("multiple rows not supported!\n");
} }
@ -2391,7 +2391,7 @@ TOOLBAR_SetStyle (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (infoPtr->hwndToolTip) { if (infoPtr->hwndToolTip) {
FIXME (toolbar, "change tool tip!\n"); FIXME("change tool tip!\n");
} }
@ -2417,7 +2417,7 @@ TOOLBAR_SetUnicodeFormat (HWND hwnd, WPARAM wParam, LPARAM lParam)
TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd);
BOOL bTemp; BOOL bTemp;
TRACE (toolbar, "%s hwnd=0x%04x stub!\n", TRACE("%s hwnd=0x%04x stub!\n",
((BOOL)wParam) ? "TRUE" : "FALSE", hwnd); ((BOOL)wParam) ? "TRUE" : "FALSE", hwnd);
bTemp = infoPtr->bUnicode; bTemp = infoPtr->bUnicode;
@ -2819,7 +2819,7 @@ TOOLBAR_Notify (HWND hwnd, WPARAM wParam, LPARAM lParam)
TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd);
LPNMHDR lpnmh = (LPNMHDR)lParam; LPNMHDR lpnmh = (LPNMHDR)lParam;
TRACE (toolbar, "passing WM_NOTIFY!\n"); TRACE("passing WM_NOTIFY!\n");
if ((infoPtr->hwndToolTip) && (lpnmh->hwndFrom == infoPtr->hwndToolTip)) { if ((infoPtr->hwndToolTip) && (lpnmh->hwndFrom == infoPtr->hwndToolTip)) {
SendMessageA (infoPtr->hwndNotify, WM_NOTIFY, wParam, lParam); SendMessageA (infoPtr->hwndNotify, WM_NOTIFY, wParam, lParam);
@ -2828,13 +2828,13 @@ TOOLBAR_Notify (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (lpnmh->code == TTN_GETDISPINFOA) { if (lpnmh->code == TTN_GETDISPINFOA) {
LPNMTTDISPINFOA lpdi = (LPNMTTDISPINFOA)lParam; LPNMTTDISPINFOA lpdi = (LPNMTTDISPINFOA)lParam;
FIXME (toolbar, "retrieving ASCII string\n"); FIXME("retrieving ASCII string\n");
} }
else if (lpnmh->code == TTN_GETDISPINFOW) { else if (lpnmh->code == TTN_GETDISPINFOW) {
LPNMTTDISPINFOW lpdi = (LPNMTTDISPINFOW)lParam; LPNMTTDISPINFOW lpdi = (LPNMTTDISPINFOW)lParam;
FIXME (toolbar, "retrieving UNICODE string\n"); FIXME("retrieving UNICODE string\n");
} }
#endif #endif
@ -2883,7 +2883,7 @@ TOOLBAR_Size (HWND hwnd, WPARAM wParam, LPARAM lParam)
* SIZE_MAXIMIZED, SIZE_MAXSHOW, SIZE_MINIMIZED * SIZE_MAXIMIZED, SIZE_MAXSHOW, SIZE_MINIMIZED
*/ */
TRACE (toolbar, "sizing toolbar!\n"); TRACE("sizing toolbar!\n");
if (flags == SIZE_RESTORED) { if (flags == SIZE_RESTORED) {
/* width and height don't apply */ /* width and height don't apply */
@ -3238,7 +3238,7 @@ ToolbarWindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
default: default:
if (uMsg >= WM_USER) if (uMsg >= WM_USER)
ERR (toolbar, "unknown msg %04x wp=%08x lp=%08lx\n", ERR("unknown msg %04x wp=%08x lp=%08lx\n",
uMsg, wParam, lParam); uMsg, wParam, lParam);
return DefWindowProcA (hwnd, uMsg, wParam, lParam); return DefWindowProcA (hwnd, uMsg, wParam, lParam);
} }

View file

@ -19,7 +19,7 @@
#include "winbase.h" #include "winbase.h"
#include "commctrl.h" #include "commctrl.h"
#include "tooltips.h" #include "tooltips.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(tooltips) DEFAULT_DEBUG_CHANNEL(tooltips)
@ -85,7 +85,7 @@ TOOLTIPS_GetTipText (HWND hwnd, TOOLTIPS_INFO *infoPtr, INT nTool)
if ((toolPtr->hinst) && (HIWORD((UINT)toolPtr->lpszText) == 0)) { if ((toolPtr->hinst) && (HIWORD((UINT)toolPtr->lpszText) == 0)) {
/* load a resource */ /* load a resource */
TRACE (tooltips, "load res string %x %x\n", TRACE("load res string %x %x\n",
toolPtr->hinst, (int)toolPtr->lpszText); toolPtr->hinst, (int)toolPtr->lpszText);
LoadStringW (toolPtr->hinst, (UINT)toolPtr->lpszText, LoadStringW (toolPtr->hinst, (UINT)toolPtr->lpszText,
infoPtr->szTipText, INFOTIPSIZE); infoPtr->szTipText, INFOTIPSIZE);
@ -103,7 +103,7 @@ TOOLTIPS_GetTipText (HWND hwnd, TOOLTIPS_INFO *infoPtr, INT nTool)
ttnmdi.uFlags = toolPtr->uFlags; ttnmdi.uFlags = toolPtr->uFlags;
ttnmdi.lParam = toolPtr->lParam; ttnmdi.lParam = toolPtr->lParam;
TRACE (tooltips, "hdr.idFrom = %x\n", ttnmdi.hdr.idFrom); TRACE("hdr.idFrom = %x\n", ttnmdi.hdr.idFrom);
SendMessageA (toolPtr->hwnd, WM_NOTIFY, SendMessageA (toolPtr->hwnd, WM_NOTIFY,
(WPARAM)toolPtr->uId, (LPARAM)&ttnmdi); (WPARAM)toolPtr->uId, (LPARAM)&ttnmdi);
@ -138,7 +138,7 @@ TOOLTIPS_GetTipText (HWND hwnd, TOOLTIPS_INFO *infoPtr, INT nTool)
} }
} }
else { else {
ERR (tooltips, "recursive text callback!\n"); ERR("recursive text callback!\n");
infoPtr->szTipText[0] = '\0'; infoPtr->szTipText[0] = '\0';
} }
} }
@ -152,7 +152,7 @@ TOOLTIPS_GetTipText (HWND hwnd, TOOLTIPS_INFO *infoPtr, INT nTool)
infoPtr->szTipText[0] = L'\0'; infoPtr->szTipText[0] = L'\0';
} }
TRACE (tooltips, "\"%s\"\n", debugstr_w(infoPtr->szTipText)); TRACE("\"%s\"\n", debugstr_w(infoPtr->szTipText));
} }
@ -170,7 +170,7 @@ TOOLTIPS_CalcTipSize (HWND hwnd, TOOLTIPS_INFO *infoPtr, LPSIZE lpSize)
} }
if (GetWindowLongA (hwnd, GWL_STYLE) & TTS_NOPREFIX) if (GetWindowLongA (hwnd, GWL_STYLE) & TTS_NOPREFIX)
uFlags |= DT_NOPREFIX; uFlags |= DT_NOPREFIX;
TRACE (tooltips, "\"%s\"\n", debugstr_w(infoPtr->szTipText)); TRACE("\"%s\"\n", debugstr_w(infoPtr->szTipText));
hdc = GetDC (hwnd); hdc = GetDC (hwnd);
hOldFont = SelectObject (hdc, infoPtr->hFont); hOldFont = SelectObject (hdc, infoPtr->hFont);
@ -195,13 +195,13 @@ TOOLTIPS_Show (HWND hwnd, TOOLTIPS_INFO *infoPtr)
NMHDR hdr; NMHDR hdr;
if (infoPtr->nTool == -1) { if (infoPtr->nTool == -1) {
TRACE (tooltips, "invalid tool (-1)!\n"); TRACE("invalid tool (-1)!\n");
return; return;
} }
infoPtr->nCurrentTool = infoPtr->nTool; infoPtr->nCurrentTool = infoPtr->nTool;
TRACE (tooltips, "Show tooltip pre %d!\n", infoPtr->nTool); TRACE("Show tooltip pre %d!\n", infoPtr->nTool);
TOOLTIPS_GetTipText (hwnd, infoPtr, infoPtr->nCurrentTool); TOOLTIPS_GetTipText (hwnd, infoPtr, infoPtr->nCurrentTool);
@ -210,7 +210,7 @@ TOOLTIPS_Show (HWND hwnd, TOOLTIPS_INFO *infoPtr)
return; return;
} }
TRACE (tooltips, "Show tooltip %d!\n", infoPtr->nCurrentTool); TRACE("Show tooltip %d!\n", infoPtr->nCurrentTool);
toolPtr = &infoPtr->tools[infoPtr->nCurrentTool]; toolPtr = &infoPtr->tools[infoPtr->nCurrentTool];
hdr.hwndFrom = hwnd; hdr.hwndFrom = hwnd;
@ -219,10 +219,10 @@ TOOLTIPS_Show (HWND hwnd, TOOLTIPS_INFO *infoPtr)
SendMessageA (toolPtr->hwnd, WM_NOTIFY, SendMessageA (toolPtr->hwnd, WM_NOTIFY,
(WPARAM)toolPtr->uId, (LPARAM)&hdr); (WPARAM)toolPtr->uId, (LPARAM)&hdr);
TRACE (tooltips, "\"%s\"\n", debugstr_w(infoPtr->szTipText)); TRACE("\"%s\"\n", debugstr_w(infoPtr->szTipText));
TOOLTIPS_CalcTipSize (hwnd, infoPtr, &size); TOOLTIPS_CalcTipSize (hwnd, infoPtr, &size);
TRACE (tooltips, "size %d - %d\n", size.cx, size.cy); TRACE("size %d - %d\n", size.cx, size.cy);
if (toolPtr->uFlags & TTF_CENTERTIP) { if (toolPtr->uFlags & TTF_CENTERTIP) {
RECT rc; RECT rc;
@ -243,7 +243,7 @@ TOOLTIPS_Show (HWND hwnd, TOOLTIPS_INFO *infoPtr)
/* FIXME: check position */ /* FIXME: check position */
TRACE (tooltips, "pos %d - %d\n", rect.left, rect.top); TRACE("pos %d - %d\n", rect.left, rect.top);
rect.right = rect.left + size.cx; rect.right = rect.left + size.cx;
rect.bottom = rect.top + size.cy; rect.bottom = rect.top + size.cy;
@ -274,7 +274,7 @@ TOOLTIPS_Hide (HWND hwnd, TOOLTIPS_INFO *infoPtr)
return; return;
toolPtr = &infoPtr->tools[infoPtr->nCurrentTool]; toolPtr = &infoPtr->tools[infoPtr->nCurrentTool];
TRACE (tooltips, "Hide tooltip %d!\n", infoPtr->nCurrentTool); TRACE("Hide tooltip %d!\n", infoPtr->nCurrentTool);
KillTimer (hwnd, ID_TIMERPOP); KillTimer (hwnd, ID_TIMERPOP);
hdr.hwndFrom = hwnd; hdr.hwndFrom = hwnd;
@ -300,11 +300,11 @@ TOOLTIPS_TrackShow (HWND hwnd, TOOLTIPS_INFO *infoPtr)
NMHDR hdr; NMHDR hdr;
if (infoPtr->nTrackTool == -1) { if (infoPtr->nTrackTool == -1) {
TRACE (tooltips, "invalid tracking tool (-1)!\n"); TRACE("invalid tracking tool (-1)!\n");
return; return;
} }
TRACE (tooltips, "show tracking tooltip pre %d!\n", infoPtr->nTrackTool); TRACE("show tracking tooltip pre %d!\n", infoPtr->nTrackTool);
TOOLTIPS_GetTipText (hwnd, infoPtr, infoPtr->nTrackTool); TOOLTIPS_GetTipText (hwnd, infoPtr, infoPtr->nTrackTool);
@ -313,7 +313,7 @@ TOOLTIPS_TrackShow (HWND hwnd, TOOLTIPS_INFO *infoPtr)
return; return;
} }
TRACE (tooltips, "show tracking tooltip %d!\n", infoPtr->nTrackTool); TRACE("show tracking tooltip %d!\n", infoPtr->nTrackTool);
toolPtr = &infoPtr->tools[infoPtr->nTrackTool]; toolPtr = &infoPtr->tools[infoPtr->nTrackTool];
hdr.hwndFrom = hwnd; hdr.hwndFrom = hwnd;
@ -322,10 +322,10 @@ TOOLTIPS_TrackShow (HWND hwnd, TOOLTIPS_INFO *infoPtr)
SendMessageA (toolPtr->hwnd, WM_NOTIFY, SendMessageA (toolPtr->hwnd, WM_NOTIFY,
(WPARAM)toolPtr->uId, (LPARAM)&hdr); (WPARAM)toolPtr->uId, (LPARAM)&hdr);
TRACE (tooltips, "\"%s\"\n", debugstr_w(infoPtr->szTipText)); TRACE("\"%s\"\n", debugstr_w(infoPtr->szTipText));
TOOLTIPS_CalcTipSize (hwnd, infoPtr, &size); TOOLTIPS_CalcTipSize (hwnd, infoPtr, &size);
TRACE (tooltips, "size %d - %d\n", size.cx, size.cy); TRACE("size %d - %d\n", size.cx, size.cy);
if (toolPtr->uFlags & TTF_ABSOLUTE) { if (toolPtr->uFlags & TTF_ABSOLUTE) {
rect.left = infoPtr->xTrackPos; rect.left = infoPtr->xTrackPos;
@ -360,7 +360,7 @@ TOOLTIPS_TrackShow (HWND hwnd, TOOLTIPS_INFO *infoPtr)
rect.left = rcTool.right; rect.left = rcTool.right;
} }
TRACE (tooltips, "pos %d - %d\n", rect.left, rect.top); TRACE("pos %d - %d\n", rect.left, rect.top);
rect.right = rect.left + size.cx; rect.right = rect.left + size.cx;
rect.bottom = rect.top + size.cy; rect.bottom = rect.top + size.cy;
@ -388,7 +388,7 @@ TOOLTIPS_TrackHide (HWND hwnd, TOOLTIPS_INFO *infoPtr)
return; return;
toolPtr = &infoPtr->tools[infoPtr->nTrackTool]; toolPtr = &infoPtr->tools[infoPtr->nTrackTool];
TRACE (tooltips, "hide tracking tooltip %d!\n", infoPtr->nTrackTool); TRACE("hide tracking tooltip %d!\n", infoPtr->nTrackTool);
hdr.hwndFrom = hwnd; hdr.hwndFrom = hwnd;
hdr.idFrom = toolPtr->uId; hdr.idFrom = toolPtr->uId;
@ -536,7 +536,7 @@ TOOLTIPS_CheckTool (HWND hwnd, BOOL bShowTest)
return -1; return -1;
} }
TRACE (tooltips, "tool %d\n", nTool); TRACE("tool %d\n", nTool);
return nTool; return nTool;
} }
@ -550,7 +550,7 @@ TOOLTIPS_Activate (HWND hwnd, WPARAM wParam, LPARAM lParam)
infoPtr->bActive = (BOOL)wParam; infoPtr->bActive = (BOOL)wParam;
if (infoPtr->bActive) if (infoPtr->bActive)
TRACE (tooltips, "activate!\n"); TRACE("activate!\n");
if (!(infoPtr->bActive) && (infoPtr->nCurrentTool != -1)) if (!(infoPtr->bActive) && (infoPtr->nCurrentTool != -1))
TOOLTIPS_Hide (hwnd, infoPtr); TOOLTIPS_Hide (hwnd, infoPtr);
@ -571,7 +571,7 @@ TOOLTIPS_AddToolA (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (lpToolInfo->cbSize < TTTOOLINFO_V1_SIZEA) if (lpToolInfo->cbSize < TTTOOLINFO_V1_SIZEA)
return FALSE; return FALSE;
TRACE (tooltips, "add tool (%x) %x %d%s!\n", TRACE("add tool (%x) %x %d%s!\n",
hwnd, lpToolInfo->hwnd, lpToolInfo->uId, hwnd, lpToolInfo->hwnd, lpToolInfo->uId,
(lpToolInfo->uFlags & TTF_IDISHWND) ? " TTF_IDISHWND" : ""); (lpToolInfo->uFlags & TTF_IDISHWND) ? " TTF_IDISHWND" : "");
@ -599,17 +599,17 @@ TOOLTIPS_AddToolA (HWND hwnd, WPARAM wParam, LPARAM lParam)
toolPtr->hinst = lpToolInfo->hinst; toolPtr->hinst = lpToolInfo->hinst;
if ((lpToolInfo->hinst) && (HIWORD((INT)lpToolInfo->lpszText) == 0)) { if ((lpToolInfo->hinst) && (HIWORD((INT)lpToolInfo->lpszText) == 0)) {
TRACE (tooltips, "add string id %x!\n", (int)lpToolInfo->lpszText); TRACE("add string id %x!\n", (int)lpToolInfo->lpszText);
toolPtr->lpszText = (LPWSTR)lpToolInfo->lpszText; toolPtr->lpszText = (LPWSTR)lpToolInfo->lpszText;
} }
else if (lpToolInfo->lpszText) { else if (lpToolInfo->lpszText) {
if (lpToolInfo->lpszText == LPSTR_TEXTCALLBACKA) { if (lpToolInfo->lpszText == LPSTR_TEXTCALLBACKA) {
TRACE (tooltips, "add CALLBACK!\n"); TRACE("add CALLBACK!\n");
toolPtr->lpszText = LPSTR_TEXTCALLBACKW; toolPtr->lpszText = LPSTR_TEXTCALLBACKW;
} }
else { else {
INT len = lstrlenA (lpToolInfo->lpszText); INT len = lstrlenA (lpToolInfo->lpszText);
TRACE (tooltips, "add text \"%s\"!\n", lpToolInfo->lpszText); TRACE("add text \"%s\"!\n", lpToolInfo->lpszText);
toolPtr->lpszText = COMCTL32_Alloc ((len + 1)*sizeof(WCHAR)); toolPtr->lpszText = COMCTL32_Alloc ((len + 1)*sizeof(WCHAR));
lstrcpyAtoW (toolPtr->lpszText, lpToolInfo->lpszText); lstrcpyAtoW (toolPtr->lpszText, lpToolInfo->lpszText);
} }
@ -635,7 +635,7 @@ TOOLTIPS_AddToolA (HWND hwnd, WPARAM wParam, LPARAM lParam)
(HANDLE)lpttsi); (HANDLE)lpttsi);
} }
else else
WARN (tooltips, "A window tool must only be listed once!\n"); WARN("A window tool must only be listed once!\n");
} }
else { else {
LPTT_SUBCLASS_INFO lpttsi = LPTT_SUBCLASS_INFO lpttsi =
@ -653,7 +653,7 @@ TOOLTIPS_AddToolA (HWND hwnd, WPARAM wParam, LPARAM lParam)
else else
lpttsi->uRefCount++; lpttsi->uRefCount++;
} }
TRACE (tooltips, "subclassing installed!\n"); TRACE("subclassing installed!\n");
} }
return TRUE; return TRUE;
@ -672,7 +672,7 @@ TOOLTIPS_AddToolW (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (lpToolInfo->cbSize < TTTOOLINFO_V1_SIZEW) if (lpToolInfo->cbSize < TTTOOLINFO_V1_SIZEW)
return FALSE; return FALSE;
TRACE (tooltips, "add tool (%x) %x %d%s!\n", TRACE("add tool (%x) %x %d%s!\n",
hwnd, lpToolInfo->hwnd, lpToolInfo->uId, hwnd, lpToolInfo->hwnd, lpToolInfo->uId,
(lpToolInfo->uFlags & TTF_IDISHWND) ? " TTF_IDISHWND" : ""); (lpToolInfo->uFlags & TTF_IDISHWND) ? " TTF_IDISHWND" : "");
@ -700,17 +700,17 @@ TOOLTIPS_AddToolW (HWND hwnd, WPARAM wParam, LPARAM lParam)
toolPtr->hinst = lpToolInfo->hinst; toolPtr->hinst = lpToolInfo->hinst;
if ((lpToolInfo->hinst) && (HIWORD((INT)lpToolInfo->lpszText) == 0)) { if ((lpToolInfo->hinst) && (HIWORD((INT)lpToolInfo->lpszText) == 0)) {
TRACE (tooltips, "add string id %x!\n", (int)lpToolInfo->lpszText); TRACE("add string id %x!\n", (int)lpToolInfo->lpszText);
toolPtr->lpszText = (LPWSTR)lpToolInfo->lpszText; toolPtr->lpszText = (LPWSTR)lpToolInfo->lpszText;
} }
else if (lpToolInfo->lpszText) { else if (lpToolInfo->lpszText) {
if (lpToolInfo->lpszText == LPSTR_TEXTCALLBACKW) { if (lpToolInfo->lpszText == LPSTR_TEXTCALLBACKW) {
TRACE (tooltips, "add CALLBACK!\n"); TRACE("add CALLBACK!\n");
toolPtr->lpszText = LPSTR_TEXTCALLBACKW; toolPtr->lpszText = LPSTR_TEXTCALLBACKW;
} }
else { else {
INT len = lstrlenW (lpToolInfo->lpszText); INT len = lstrlenW (lpToolInfo->lpszText);
TRACE (tooltips, "add text \"%s\"!\n", TRACE("add text \"%s\"!\n",
debugstr_w(lpToolInfo->lpszText)); debugstr_w(lpToolInfo->lpszText));
toolPtr->lpszText = COMCTL32_Alloc ((len + 1)*sizeof(WCHAR)); toolPtr->lpszText = COMCTL32_Alloc ((len + 1)*sizeof(WCHAR));
lstrcpyW (toolPtr->lpszText, lpToolInfo->lpszText); lstrcpyW (toolPtr->lpszText, lpToolInfo->lpszText);
@ -737,7 +737,7 @@ TOOLTIPS_AddToolW (HWND hwnd, WPARAM wParam, LPARAM lParam)
(HANDLE)lpttsi); (HANDLE)lpttsi);
} }
else else
WARN (tooltips, "A window tool must only be listed once!\n"); WARN("A window tool must only be listed once!\n");
} }
else { else {
LPTT_SUBCLASS_INFO lpttsi = LPTT_SUBCLASS_INFO lpttsi =
@ -755,7 +755,7 @@ TOOLTIPS_AddToolW (HWND hwnd, WPARAM wParam, LPARAM lParam)
else else
lpttsi->uRefCount++; lpttsi->uRefCount++;
} }
TRACE (tooltips, "subclassing installed!\n"); TRACE("subclassing installed!\n");
} }
return TRUE; return TRUE;
@ -780,7 +780,7 @@ TOOLTIPS_DelToolA (HWND hwnd, WPARAM wParam, LPARAM lParam)
nTool = TOOLTIPS_GetToolFromInfoA (infoPtr, lpToolInfo); nTool = TOOLTIPS_GetToolFromInfoA (infoPtr, lpToolInfo);
if (nTool == -1) return 0; if (nTool == -1) return 0;
TRACE (tooltips, "tool %d\n", nTool); TRACE("tool %d\n", nTool);
/* delete text string */ /* delete text string */
toolPtr = &infoPtr->tools[nTool]; toolPtr = &infoPtr->tools[nTool];
@ -801,7 +801,7 @@ TOOLTIPS_DelToolA (HWND hwnd, WPARAM wParam, LPARAM lParam)
COMCTL32_Free (&lpttsi); COMCTL32_Free (&lpttsi);
} }
else else
ERR (tooltips, "Invalid data handle!\n"); ERR("Invalid data handle!\n");
} }
else { else {
LPTT_SUBCLASS_INFO lpttsi = LPTT_SUBCLASS_INFO lpttsi =
@ -817,7 +817,7 @@ TOOLTIPS_DelToolA (HWND hwnd, WPARAM wParam, LPARAM lParam)
lpttsi->uRefCount--; lpttsi->uRefCount--;
} }
else else
ERR (tooltips, "Invalid data handle!\n"); ERR("Invalid data handle!\n");
} }
} }
@ -866,7 +866,7 @@ TOOLTIPS_DelToolW (HWND hwnd, WPARAM wParam, LPARAM lParam)
nTool = TOOLTIPS_GetToolFromInfoW (infoPtr, lpToolInfo); nTool = TOOLTIPS_GetToolFromInfoW (infoPtr, lpToolInfo);
if (nTool == -1) return 0; if (nTool == -1) return 0;
TRACE (tooltips, "tool %d\n", nTool); TRACE("tool %d\n", nTool);
/* delete text string */ /* delete text string */
toolPtr = &infoPtr->tools[nTool]; toolPtr = &infoPtr->tools[nTool];
@ -887,7 +887,7 @@ TOOLTIPS_DelToolW (HWND hwnd, WPARAM wParam, LPARAM lParam)
COMCTL32_Free (&lpttsi); COMCTL32_Free (&lpttsi);
} }
else else
ERR (tooltips, "Invalid data handle!\n"); ERR("Invalid data handle!\n");
} }
else { else {
LPTT_SUBCLASS_INFO lpttsi = LPTT_SUBCLASS_INFO lpttsi =
@ -903,7 +903,7 @@ TOOLTIPS_DelToolW (HWND hwnd, WPARAM wParam, LPARAM lParam)
lpttsi->uRefCount--; lpttsi->uRefCount--;
} }
else else
ERR (tooltips, "Invalid data handle!\n"); ERR("Invalid data handle!\n");
} }
} }
@ -949,7 +949,7 @@ TOOLTIPS_EnumToolsA (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (uIndex >= infoPtr->uNumTools) if (uIndex >= infoPtr->uNumTools)
return FALSE; return FALSE;
TRACE (tooltips, "index=%u\n", uIndex); TRACE("index=%u\n", uIndex);
toolPtr = &infoPtr->tools[uIndex]; toolPtr = &infoPtr->tools[uIndex];
@ -984,7 +984,7 @@ TOOLTIPS_EnumToolsW (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (uIndex >= infoPtr->uNumTools) if (uIndex >= infoPtr->uNumTools)
return FALSE; return FALSE;
TRACE (tooltips, "index=%u\n", uIndex); TRACE("index=%u\n", uIndex);
toolPtr = &infoPtr->tools[uIndex]; toolPtr = &infoPtr->tools[uIndex];
@ -1212,7 +1212,7 @@ TOOLTIPS_GetToolInfoA (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (nTool == -1) if (nTool == -1)
return FALSE; return FALSE;
TRACE (tooltips, "tool %d\n", nTool); TRACE("tool %d\n", nTool);
toolPtr = &infoPtr->tools[nTool]; toolPtr = &infoPtr->tools[nTool];
@ -1249,7 +1249,7 @@ TOOLTIPS_GetToolInfoW (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (nTool == -1) if (nTool == -1)
return FALSE; return FALSE;
TRACE (tooltips, "tool %d\n", nTool); TRACE("tool %d\n", nTool);
toolPtr = &infoPtr->tools[nTool]; toolPtr = &infoPtr->tools[nTool];
@ -1282,7 +1282,7 @@ TOOLTIPS_HitTestA (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (nTool == -1) if (nTool == -1)
return FALSE; return FALSE;
TRACE (tooltips, "tool %d!\n", nTool); TRACE("tool %d!\n", nTool);
/* copy tool data */ /* copy tool data */
if (lptthit->ti.cbSize >= sizeof(TTTOOLINFOA)) { if (lptthit->ti.cbSize >= sizeof(TTTOOLINFOA)) {
@ -1317,7 +1317,7 @@ TOOLTIPS_HitTestW (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (nTool == -1) if (nTool == -1)
return FALSE; return FALSE;
TRACE (tooltips, "tool %d!\n", nTool); TRACE("tool %d!\n", nTool);
/* copy tool data */ /* copy tool data */
if (lptthit->ti.cbSize >= sizeof(TTTOOLINFOW)) { if (lptthit->ti.cbSize >= sizeof(TTTOOLINFOW)) {
@ -1398,7 +1398,7 @@ TOOLTIPS_RelayEvent (HWND hwnd, WPARAM wParam, LPARAM lParam)
POINT pt; POINT pt;
if (lParam == 0) { if (lParam == 0) {
ERR (tooltips, "lpMsg == NULL!\n"); ERR("lpMsg == NULL!\n");
return 0; return 0;
} }
@ -1413,7 +1413,7 @@ TOOLTIPS_RelayEvent (HWND hwnd, WPARAM wParam, LPARAM lParam)
ScreenToClient (lpMsg->hwnd, &pt); ScreenToClient (lpMsg->hwnd, &pt);
infoPtr->nOldTool = infoPtr->nTool; infoPtr->nOldTool = infoPtr->nTool;
infoPtr->nTool = TOOLTIPS_GetToolFromPoint (infoPtr, lpMsg->hwnd, &pt); infoPtr->nTool = TOOLTIPS_GetToolFromPoint (infoPtr, lpMsg->hwnd, &pt);
TRACE (tooltips, "tool (%x) %d %d\n", TRACE("tool (%x) %d %d\n",
hwnd, infoPtr->nOldTool, infoPtr->nTool); hwnd, infoPtr->nOldTool, infoPtr->nTool);
TOOLTIPS_Hide (hwnd, infoPtr); TOOLTIPS_Hide (hwnd, infoPtr);
break; break;
@ -1423,24 +1423,24 @@ TOOLTIPS_RelayEvent (HWND hwnd, WPARAM wParam, LPARAM lParam)
ScreenToClient (lpMsg->hwnd, &pt); ScreenToClient (lpMsg->hwnd, &pt);
infoPtr->nOldTool = infoPtr->nTool; infoPtr->nOldTool = infoPtr->nTool;
infoPtr->nTool = TOOLTIPS_GetToolFromPoint (infoPtr, lpMsg->hwnd, &pt); infoPtr->nTool = TOOLTIPS_GetToolFromPoint (infoPtr, lpMsg->hwnd, &pt);
TRACE (tooltips, "tool (%x) %d %d\n", TRACE("tool (%x) %d %d\n",
hwnd, infoPtr->nOldTool, infoPtr->nTool); hwnd, infoPtr->nOldTool, infoPtr->nTool);
TRACE (tooltips, "WM_MOUSEMOVE (%04x %ld %ld)\n", TRACE("WM_MOUSEMOVE (%04x %ld %ld)\n",
hwnd, pt.x, pt.y); hwnd, pt.x, pt.y);
if ((infoPtr->bActive) && (infoPtr->nTool != infoPtr->nOldTool)) { if ((infoPtr->bActive) && (infoPtr->nTool != infoPtr->nOldTool)) {
if (infoPtr->nOldTool == -1) { if (infoPtr->nOldTool == -1) {
SetTimer (hwnd, ID_TIMERSHOW, infoPtr->nInitialTime, 0); SetTimer (hwnd, ID_TIMERSHOW, infoPtr->nInitialTime, 0);
TRACE (tooltips, "timer 1 started!\n"); TRACE("timer 1 started!\n");
} }
else { else {
TOOLTIPS_Hide (hwnd, infoPtr); TOOLTIPS_Hide (hwnd, infoPtr);
SetTimer (hwnd, ID_TIMERSHOW, infoPtr->nReshowTime, 0); SetTimer (hwnd, ID_TIMERSHOW, infoPtr->nReshowTime, 0);
TRACE (tooltips, "timer 2 started!\n"); TRACE("timer 2 started!\n");
} }
} }
if (infoPtr->nCurrentTool != -1) { if (infoPtr->nCurrentTool != -1) {
SetTimer (hwnd, ID_TIMERLEAVE, 100, 0); SetTimer (hwnd, ID_TIMERLEAVE, 100, 0);
TRACE (tooltips, "timer 3 started!\n"); TRACE("timer 3 started!\n");
} }
break; break;
} }
@ -1553,7 +1553,7 @@ TOOLTIPS_SetToolInfoA (HWND hwnd, WPARAM wParam, LPARAM lParam)
nTool = TOOLTIPS_GetToolFromInfoA (infoPtr, lpToolInfo); nTool = TOOLTIPS_GetToolFromInfoA (infoPtr, lpToolInfo);
if (nTool == -1) return 0; if (nTool == -1) return 0;
TRACE (tooltips, "tool %d\n", nTool); TRACE("tool %d\n", nTool);
toolPtr = &infoPtr->tools[nTool]; toolPtr = &infoPtr->tools[nTool];
@ -1565,7 +1565,7 @@ TOOLTIPS_SetToolInfoA (HWND hwnd, WPARAM wParam, LPARAM lParam)
toolPtr->hinst = lpToolInfo->hinst; toolPtr->hinst = lpToolInfo->hinst;
if ((lpToolInfo->hinst) && (HIWORD((INT)lpToolInfo->lpszText) == 0)) { if ((lpToolInfo->hinst) && (HIWORD((INT)lpToolInfo->lpszText) == 0)) {
TRACE (tooltips, "set string id %x!\n", (INT)lpToolInfo->lpszText); TRACE("set string id %x!\n", (INT)lpToolInfo->lpszText);
toolPtr->lpszText = (LPWSTR)lpToolInfo->lpszText; toolPtr->lpszText = (LPWSTR)lpToolInfo->lpszText;
} }
else if (lpToolInfo->lpszText) { else if (lpToolInfo->lpszText) {
@ -1607,7 +1607,7 @@ TOOLTIPS_SetToolInfoW (HWND hwnd, WPARAM wParam, LPARAM lParam)
nTool = TOOLTIPS_GetToolFromInfoW (infoPtr, lpToolInfo); nTool = TOOLTIPS_GetToolFromInfoW (infoPtr, lpToolInfo);
if (nTool == -1) return 0; if (nTool == -1) return 0;
TRACE (tooltips, "tool %d\n", nTool); TRACE("tool %d\n", nTool);
toolPtr = &infoPtr->tools[nTool]; toolPtr = &infoPtr->tools[nTool];
@ -1619,7 +1619,7 @@ TOOLTIPS_SetToolInfoW (HWND hwnd, WPARAM wParam, LPARAM lParam)
toolPtr->hinst = lpToolInfo->hinst; toolPtr->hinst = lpToolInfo->hinst;
if ((lpToolInfo->hinst) && (HIWORD((INT)lpToolInfo->lpszText) == 0)) { if ((lpToolInfo->hinst) && (HIWORD((INT)lpToolInfo->lpszText) == 0)) {
TRACE (tooltips, "set string id %x!\n", (INT)lpToolInfo->lpszText); TRACE("set string id %x!\n", (INT)lpToolInfo->lpszText);
toolPtr->lpszText = lpToolInfo->lpszText; toolPtr->lpszText = lpToolInfo->lpszText;
} }
else if (lpToolInfo->lpszText) { else if (lpToolInfo->lpszText) {
@ -1660,7 +1660,7 @@ TOOLTIPS_TrackActivate (HWND hwnd, WPARAM wParam, LPARAM lParam)
/* activate */ /* activate */
infoPtr->nTrackTool = TOOLTIPS_GetToolFromInfoA (infoPtr, lpToolInfo); infoPtr->nTrackTool = TOOLTIPS_GetToolFromInfoA (infoPtr, lpToolInfo);
if (infoPtr->nTrackTool != -1) { if (infoPtr->nTrackTool != -1) {
TRACE (tooltips, "activated!\n"); TRACE("activated!\n");
infoPtr->bTrackActive = TRUE; infoPtr->bTrackActive = TRUE;
TOOLTIPS_TrackShow (hwnd, infoPtr); TOOLTIPS_TrackShow (hwnd, infoPtr);
} }
@ -1672,7 +1672,7 @@ TOOLTIPS_TrackActivate (HWND hwnd, WPARAM wParam, LPARAM lParam)
infoPtr->bTrackActive = FALSE; infoPtr->bTrackActive = FALSE;
infoPtr->nTrackTool = -1; infoPtr->nTrackTool = -1;
TRACE (tooltips, "deactivated!\n"); TRACE("deactivated!\n");
} }
return 0; return 0;
@ -1688,7 +1688,7 @@ TOOLTIPS_TrackPosition (HWND hwnd, WPARAM wParam, LPARAM lParam)
infoPtr->yTrackPos = (INT)HIWORD(lParam); infoPtr->yTrackPos = (INT)HIWORD(lParam);
if (infoPtr->bTrackActive) { if (infoPtr->bTrackActive) {
TRACE (tooltips, "[%d %d]\n", TRACE("[%d %d]\n",
infoPtr->xTrackPos, infoPtr->yTrackPos); infoPtr->xTrackPos, infoPtr->yTrackPos);
TOOLTIPS_TrackShow (hwnd, infoPtr); TOOLTIPS_TrackShow (hwnd, infoPtr);
@ -1726,7 +1726,7 @@ TOOLTIPS_UpdateTipTextA (HWND hwnd, WPARAM wParam, LPARAM lParam)
nTool = TOOLTIPS_GetToolFromInfoA (infoPtr, lpToolInfo); nTool = TOOLTIPS_GetToolFromInfoA (infoPtr, lpToolInfo);
if (nTool == -1) return 0; if (nTool == -1) return 0;
TRACE (tooltips, "tool %d\n", nTool); TRACE("tool %d\n", nTool);
toolPtr = &infoPtr->tools[nTool]; toolPtr = &infoPtr->tools[nTool];
@ -1779,7 +1779,7 @@ TOOLTIPS_UpdateTipTextW (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (nTool == -1) if (nTool == -1)
return 0; return 0;
TRACE (tooltips, "tool %d\n", nTool); TRACE("tool %d\n", nTool);
toolPtr = &infoPtr->tools[nTool]; toolPtr = &infoPtr->tools[nTool];
@ -1858,11 +1858,11 @@ TOOLTIPS_Create (HWND hwnd, WPARAM wParam, LPARAM lParam)
nResult = (INT) SendMessageA (GetParent (hwnd), WM_NOTIFYFORMAT, nResult = (INT) SendMessageA (GetParent (hwnd), WM_NOTIFYFORMAT,
(WPARAM)hwnd, (LPARAM)NF_QUERY); (WPARAM)hwnd, (LPARAM)NF_QUERY);
if (nResult == NFR_ANSI) if (nResult == NFR_ANSI)
TRACE (tooltips, " -- WM_NOTIFYFORMAT returns: NFR_ANSI\n"); TRACE(" -- WM_NOTIFYFORMAT returns: NFR_ANSI\n");
else if (nResult == NFR_UNICODE) else if (nResult == NFR_UNICODE)
FIXME (tooltips, " -- WM_NOTIFYFORMAT returns: NFR_UNICODE\n"); FIXME(" -- WM_NOTIFYFORMAT returns: NFR_UNICODE\n");
else else
FIXME (tooltips, " -- WM_NOTIFYFORMAT returns: error!\n"); FIXME(" -- WM_NOTIFYFORMAT returns: error!\n");
SetWindowPos (hwnd, HWND_TOP, 0, 0, 0, 0, SWP_NOZORDER | SWP_HIDEWINDOW | SWP_NOACTIVATE); SetWindowPos (hwnd, HWND_TOP, 0, 0, 0, 0, SWP_NOZORDER | SWP_HIDEWINDOW | SWP_NOACTIVATE);
@ -1971,11 +1971,11 @@ TOOLTIPS_NCHitTest (HWND hwnd, WPARAM wParam, LPARAM lParam)
TOOLTIPS_INFO *infoPtr = TOOLTIPS_GetInfoPtr (hwnd); TOOLTIPS_INFO *infoPtr = TOOLTIPS_GetInfoPtr (hwnd);
INT nTool = (infoPtr->bTrackActive) ? infoPtr->nTrackTool : infoPtr->nTool; INT nTool = (infoPtr->bTrackActive) ? infoPtr->nTrackTool : infoPtr->nTool;
TRACE (tooltips, " nTool=%d\n", nTool); TRACE(" nTool=%d\n", nTool);
if ((nTool > -1) && (nTool < infoPtr->uNumTools)) { if ((nTool > -1) && (nTool < infoPtr->uNumTools)) {
if (infoPtr->tools[nTool].uFlags & TTF_TRANSPARENT) { if (infoPtr->tools[nTool].uFlags & TTF_TRANSPARENT) {
TRACE (tooltips, "-- in transparent mode!\n"); TRACE("-- in transparent mode!\n");
return HTTRANSPARENT; return HTTRANSPARENT;
} }
} }
@ -2006,7 +2006,7 @@ TOOLTIPS_SetFont (HWND hwnd, WPARAM wParam, LPARAM lParam)
infoPtr->hFont = (HFONT)wParam; infoPtr->hFont = (HFONT)wParam;
if ((LOWORD(lParam)) & (infoPtr->nCurrentTool != -1)) { if ((LOWORD(lParam)) & (infoPtr->nCurrentTool != -1)) {
FIXME (tooltips, "full redraw needed!\n"); FIXME("full redraw needed!\n");
} }
return 0; return 0;
@ -2065,7 +2065,7 @@ TOOLTIPS_Timer (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
TOOLTIPS_INFO *infoPtr = TOOLTIPS_GetInfoPtr (hwnd); TOOLTIPS_INFO *infoPtr = TOOLTIPS_GetInfoPtr (hwnd);
TRACE (tooltips, "timer %d (%x) expired!\n", wParam, hwnd); TRACE("timer %d (%x) expired!\n", wParam, hwnd);
switch (wParam) switch (wParam)
{ {
@ -2128,7 +2128,7 @@ TOOLTIPS_SubclassProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
infoPtr = TOOLTIPS_GetInfoPtr(lpttsi->hwndToolTip); infoPtr = TOOLTIPS_GetInfoPtr(lpttsi->hwndToolTip);
nTool = TOOLTIPS_GetToolFromMessage (infoPtr, hwnd); nTool = TOOLTIPS_GetToolFromMessage (infoPtr, hwnd);
TRACE (tooltips, "subclassed mouse message %04x\n", uMsg); TRACE("subclassed mouse message %04x\n", uMsg);
infoPtr->nOldTool = infoPtr->nTool; infoPtr->nOldTool = infoPtr->nTool;
infoPtr->nTool = nTool; infoPtr->nTool = nTool;
TOOLTIPS_Hide (lpttsi->hwndToolTip, infoPtr); TOOLTIPS_Hide (lpttsi->hwndToolTip, infoPtr);
@ -2138,7 +2138,7 @@ TOOLTIPS_SubclassProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
infoPtr = TOOLTIPS_GetInfoPtr (lpttsi->hwndToolTip); infoPtr = TOOLTIPS_GetInfoPtr (lpttsi->hwndToolTip);
nTool = TOOLTIPS_GetToolFromMessage (infoPtr, hwnd); nTool = TOOLTIPS_GetToolFromMessage (infoPtr, hwnd);
TRACE (tooltips, "subclassed WM_MOUSEMOVE\n"); TRACE("subclassed WM_MOUSEMOVE\n");
infoPtr->nOldTool = infoPtr->nTool; infoPtr->nOldTool = infoPtr->nTool;
infoPtr->nTool = nTool; infoPtr->nTool = nTool;
@ -2147,18 +2147,18 @@ TOOLTIPS_SubclassProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
if (infoPtr->nOldTool == -1) { if (infoPtr->nOldTool == -1) {
SetTimer (hwnd, ID_TIMERSHOW, SetTimer (hwnd, ID_TIMERSHOW,
infoPtr->nInitialTime, 0); infoPtr->nInitialTime, 0);
TRACE (tooltips, "timer 1 started!\n"); TRACE("timer 1 started!\n");
} }
else { else {
TOOLTIPS_Hide (lpttsi->hwndToolTip, infoPtr); TOOLTIPS_Hide (lpttsi->hwndToolTip, infoPtr);
SetTimer (hwnd, ID_TIMERSHOW, SetTimer (hwnd, ID_TIMERSHOW,
infoPtr->nReshowTime, 0); infoPtr->nReshowTime, 0);
TRACE (tooltips, "timer 2 started!\n"); TRACE("timer 2 started!\n");
} }
} }
if (infoPtr->nCurrentTool != -1) { if (infoPtr->nCurrentTool != -1) {
SetTimer (hwnd, ID_TIMERLEAVE, 100, 0); SetTimer (hwnd, ID_TIMERLEAVE, 100, 0);
TRACE (tooltips, "timer 3 started!\n"); TRACE("timer 3 started!\n");
} }
break; break;
} }
@ -2338,7 +2338,7 @@ TOOLTIPS_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
default: default:
if (uMsg >= WM_USER) if (uMsg >= WM_USER)
ERR (tooltips, "unknown msg %04x wp=%08x lp=%08lx\n", ERR("unknown msg %04x wp=%08x lp=%08lx\n",
uMsg, wParam, lParam); uMsg, wParam, lParam);
return DefWindowProcA (hwnd, uMsg, wParam, lParam); return DefWindowProcA (hwnd, uMsg, wParam, lParam);
} }

View file

@ -27,7 +27,7 @@
#include "winbase.h" #include "winbase.h"
#include "commctrl.h" #include "commctrl.h"
#include "trackbar.h" #include "trackbar.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(trackbar) DEFAULT_DEBUG_CHANNEL(trackbar)
@ -105,7 +105,7 @@ TRACKBAR_ConvertPlaceToPosition (TRACKBAR_INFO *infoPtr, int place,
else if (pos < infoPtr->nRangeMin) else if (pos < infoPtr->nRangeMin)
pos = infoPtr->nRangeMin; pos = infoPtr->nRangeMin;
TRACE (trackbar,"%.2f\n",pos); TRACE("%.2f\n",pos);
return pos; return pos;
} }
@ -764,14 +764,14 @@ TRACKBAR_SetBuddy (HWND hwnd, WPARAM wParam, LPARAM lParam)
hwndTemp = infoPtr->hwndBuddyLA; hwndTemp = infoPtr->hwndBuddyLA;
infoPtr->hwndBuddyLA = (HWND)lParam; infoPtr->hwndBuddyLA = (HWND)lParam;
FIXME (trackbar, "move buddy!\n"); FIXME("move buddy!\n");
} }
else { else {
/* buddy is right or below */ /* buddy is right or below */
hwndTemp = infoPtr->hwndBuddyRB; hwndTemp = infoPtr->hwndBuddyRB;
infoPtr->hwndBuddyRB = (HWND)lParam; infoPtr->hwndBuddyRB = (HWND)lParam;
FIXME (trackbar, "move buddy!\n"); FIXME("move buddy!\n");
} }
TRACKBAR_AlignBuddies (hwnd, infoPtr); TRACKBAR_AlignBuddies (hwnd, infoPtr);
@ -1142,7 +1142,7 @@ TRACKBAR_KillFocus (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
TRACKBAR_INFO *infoPtr = TRACKBAR_GetInfoPtr (hwnd); TRACKBAR_INFO *infoPtr = TRACKBAR_GetInfoPtr (hwnd);
TRACE (trackbar,"\n"); TRACE("\n");
infoPtr->bFocus = FALSE; infoPtr->bFocus = FALSE;
infoPtr->flags &= ~TB_DRAG_MODE; infoPtr->flags &= ~TB_DRAG_MODE;
@ -1287,7 +1287,7 @@ TRACKBAR_SetFocus (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
TRACKBAR_INFO *infoPtr = TRACKBAR_GetInfoPtr (hwnd); TRACKBAR_INFO *infoPtr = TRACKBAR_GetInfoPtr (hwnd);
TRACE (trackbar,"\n"); TRACE("\n");
infoPtr->bFocus = TRUE; infoPtr->bFocus = TRUE;
InvalidateRect (hwnd, NULL, FALSE); InvalidateRect (hwnd, NULL, FALSE);
@ -1311,7 +1311,7 @@ TRACKBAR_Size (HWND hwnd, WPARAM wParam, LPARAM lParam)
static BOOL static BOOL
TRACKBAR_SendNotify (HWND hwnd, UINT code) TRACKBAR_SendNotify (HWND hwnd, UINT code)
{ {
TRACE (trackbar, "%x\n",code); TRACE("%x\n",code);
if (GetWindowLongA (hwnd, GWL_STYLE) & TBS_VERT) if (GetWindowLongA (hwnd, GWL_STYLE) & TBS_VERT)
return (BOOL) SendMessageA (GetParent (hwnd), return (BOOL) SendMessageA (GetParent (hwnd),
@ -1331,7 +1331,7 @@ TRACKBAR_MouseMove (HWND hwnd, WPARAM wParam, LPARAM lParam)
DOUBLE dragPos; DOUBLE dragPos;
char buf[80]; char buf[80];
TRACE (trackbar, "%x\n",wParam); TRACE("%x\n",wParam);
if (dwStyle & TBS_VERT) if (dwStyle & TBS_VERT)
clickPlace=(SHORT)HIWORD(lParam); clickPlace=(SHORT)HIWORD(lParam);
@ -1388,7 +1388,7 @@ TRACKBAR_KeyDown (HWND hwnd, WPARAM wParam, LPARAM lParam)
TRACKBAR_INFO *infoPtr = TRACKBAR_GetInfoPtr (hwnd); TRACKBAR_INFO *infoPtr = TRACKBAR_GetInfoPtr (hwnd);
INT pos; INT pos;
TRACE (trackbar, "%x\n",wParam); TRACE("%x\n",wParam);
pos=infoPtr->nPos; pos=infoPtr->nPos;
switch (wParam) { switch (wParam) {
@ -1619,7 +1619,7 @@ TRACKBAR_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
default: default:
if (uMsg >= WM_USER) if (uMsg >= WM_USER)
ERR (trackbar, "unknown msg %04x wp=%08x lp=%08lx\n", ERR("unknown msg %04x wp=%08x lp=%08lx\n",
uMsg, wParam, lParam); uMsg, wParam, lParam);
return DefWindowProcA (hwnd, uMsg, wParam, lParam); return DefWindowProcA (hwnd, uMsg, wParam, lParam);
} }

View file

@ -44,7 +44,7 @@
#include "wingdi.h" #include "wingdi.h"
#include "commctrl.h" #include "commctrl.h"
#include "treeview.h" #include "treeview.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(treeview) DEFAULT_DEBUG_CHANNEL(treeview)
@ -323,7 +323,7 @@ TREEVIEW_RemoveItem (HWND hwnd, TREEVIEW_ITEM *wineItem)
parentItem=& infoPtr->items [(INT)wineItem->parent]; parentItem=& infoPtr->items [(INT)wineItem->parent];
switch (parentItem->cChildren) { switch (parentItem->cChildren) {
case I_CHILDRENCALLBACK: case I_CHILDRENCALLBACK:
FIXME (treeview,"we don't handle I_CHILDRENCALLBACK yet\n"); FIXME("we don't handle I_CHILDRENCALLBACK yet\n");
break; break;
case 1: case 1:
parentItem->cChildren=0; parentItem->cChildren=0;
@ -390,7 +390,7 @@ TREEVIEW_GetImageList (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd); TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd);
TRACE (treeview,"\n"); TRACE("\n");
if (infoPtr==NULL) return 0; if (infoPtr==NULL) return 0;
if ((INT)wParam == TVSIL_NORMAL) if ((INT)wParam == TVSIL_NORMAL)
@ -407,7 +407,7 @@ TREEVIEW_SetImageList (HWND hwnd, WPARAM wParam, LPARAM lParam)
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd); TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd);
HIMAGELIST himlTemp; HIMAGELIST himlTemp;
TRACE (treeview,"\n"); TRACE("\n");
switch ((INT)wParam) { switch ((INT)wParam) {
case TVSIL_NORMAL: case TVSIL_NORMAL:
himlTemp = infoPtr->himlNormal; himlTemp = infoPtr->himlNormal;
@ -432,7 +432,7 @@ TREEVIEW_SetItemHeight (HWND hwnd, WPARAM wParam)
INT cx,cy,prevHeight=infoPtr->uItemHeight; INT cx,cy,prevHeight=infoPtr->uItemHeight;
HDC hdc; HDC hdc;
TRACE (treeview,"\n"); TRACE("\n");
if (wParam==-1) { if (wParam==-1) {
hdc=GetDC (hwnd); hdc=GetDC (hwnd);
infoPtr->uItemHeight=-1; infoPtr->uItemHeight=-1;
@ -454,7 +454,7 @@ TREEVIEW_GetItemHeight (HWND hwnd)
{ {
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd); TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd);
TRACE (treeview,"\n"); TRACE("\n");
return infoPtr->uItemHeight; return infoPtr->uItemHeight;
} }
@ -464,7 +464,7 @@ TREEVIEW_SetTextColor (HWND hwnd, WPARAM wParam, LPARAM lParam)
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd); TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd);
COLORREF prevColor=infoPtr->clrText; COLORREF prevColor=infoPtr->clrText;
TRACE (treeview,"\n"); TRACE("\n");
infoPtr->clrText=(COLORREF) lParam; infoPtr->clrText=(COLORREF) lParam;
return (LRESULT) prevColor; return (LRESULT) prevColor;
} }
@ -474,7 +474,7 @@ TREEVIEW_GetBkColor (HWND hwnd)
{ {
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd); TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd);
TRACE (treeview,"\n"); TRACE("\n");
return (LRESULT) infoPtr->clrText; return (LRESULT) infoPtr->clrText;
} }
@ -484,7 +484,7 @@ TREEVIEW_SetBkColor (HWND hwnd, WPARAM wParam, LPARAM lParam)
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd); TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd);
COLORREF prevColor=infoPtr->clrBk; COLORREF prevColor=infoPtr->clrBk;
TRACE (treeview,"\n"); TRACE("\n");
infoPtr->clrBk=(COLORREF) lParam; infoPtr->clrBk=(COLORREF) lParam;
return (LRESULT) prevColor; return (LRESULT) prevColor;
} }
@ -494,7 +494,7 @@ TREEVIEW_GetTextColor (HWND hwnd)
{ {
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd); TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd);
TRACE (treeview,"\n"); TRACE("\n");
return (LRESULT) infoPtr->clrBk; return (LRESULT) infoPtr->clrBk;
} }
@ -530,7 +530,7 @@ TREEVIEW_DrawItem (HWND hwnd, HDC hdc, TREEVIEW_ITEM *wineItem)
cditem=TREEVIEW_SendCustomDrawItemNotify (hwnd, hdc, wineItem, drawmode); cditem=TREEVIEW_SendCustomDrawItemNotify (hwnd, hdc, wineItem, drawmode);
TRACE (treeview,"cditem:%d\n",cditem); TRACE("cditem:%d\n",cditem);
if (cditem & CDRF_SKIPDEFAULT) if (cditem & CDRF_SKIPDEFAULT)
return; return;
@ -733,7 +733,7 @@ TREEVIEW_DrawItem (HWND hwnd, HDC hdc, TREEVIEW_ITEM *wineItem)
} }
if (wineItem->pszText== LPSTR_TEXTCALLBACKA) { if (wineItem->pszText== LPSTR_TEXTCALLBACKA) {
TRACE (treeview,"LPSTR_TEXTCALLBACK\n"); TRACE("LPSTR_TEXTCALLBACK\n");
TREEVIEW_SendDispInfoNotify (hwnd, wineItem, TVN_GETDISPINFO, TVIF_TEXT); TREEVIEW_SendDispInfoNotify (hwnd, wineItem, TVN_GETDISPINFO, TVIF_TEXT);
} }
@ -798,7 +798,7 @@ TREEVIEW_GetItemRect (HWND hwnd, WPARAM wParam, LPARAM lParam)
HTREEITEM *iItem; HTREEITEM *iItem;
LPRECT lpRect = (LPRECT)lParam; LPRECT lpRect = (LPRECT)lParam;
TRACE (treeview,"\n"); TRACE("\n");
/* /*
* validate parameters * validate parameters
*/ */
@ -832,7 +832,7 @@ TREEVIEW_GetItemRect (HWND hwnd, WPARAM wParam, LPARAM lParam)
lpRect->top = wineItem->rect.top; lpRect->top = wineItem->rect.top;
} }
TRACE (treeview,"[L:%d R:%d T:%d B:%d]\n", TRACE("[L:%d R:%d T:%d B:%d]\n",
lpRect->left,lpRect->right, lpRect->left,lpRect->right,
lpRect->top,lpRect->bottom); lpRect->top,lpRect->bottom);
@ -860,7 +860,7 @@ TREEVIEW_SetItemA (HWND hwnd, WPARAM wParam, LPARAM lParam)
tvItem=(LPTVITEMEXA) lParam; tvItem=(LPTVITEMEXA) lParam;
iItem=(INT)tvItem->hItem; iItem=(INT)tvItem->hItem;
TRACE (treeview,"item %d,mask %x\n",iItem,tvItem->mask); TRACE("item %d,mask %x\n",iItem,tvItem->mask);
wineItem = TREEVIEW_ValidItem (infoPtr, (HTREEITEM)iItem); wineItem = TREEVIEW_ValidItem (infoPtr, (HTREEITEM)iItem);
if (!wineItem) return FALSE; if (!wineItem) return FALSE;
@ -875,7 +875,7 @@ TREEVIEW_SetItemA (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (tvItem->mask & TVIF_INTEGRAL) { if (tvItem->mask & TVIF_INTEGRAL) {
wineItem->iIntegral=tvItem->iIntegral; wineItem->iIntegral=tvItem->iIntegral;
FIXME (treeview," TVIF_INTEGRAL not supported yet\n"); FIXME(" TVIF_INTEGRAL not supported yet\n");
} }
if (tvItem->mask & TVIF_PARAM) { if (tvItem->mask & TVIF_PARAM) {
@ -925,7 +925,7 @@ TREEVIEW_Refresh (HWND hwnd)
INT viewtop,viewbottom,viewleft,viewright; INT viewtop,viewbottom,viewleft,viewright;
TREEVIEW_ITEM *wineItem, *prevItem; TREEVIEW_ITEM *wineItem, *prevItem;
TRACE (treeview,"\n"); TRACE("\n");
hdc=GetDC (hwnd); hdc=GetDC (hwnd);
@ -967,7 +967,7 @@ TREEVIEW_Refresh (HWND hwnd)
wineItem=NULL; wineItem=NULL;
indent=0; indent=0;
x=y=0; x=y=0;
TRACE (treeview, "[%d %d %d %d]\n",viewtop,viewbottom,viewleft,viewright); TRACE("[%d %d %d %d]\n",viewtop,viewbottom,viewleft,viewright);
while (iItem) { while (iItem) {
prevItem=wineItem; prevItem=wineItem;
@ -1065,7 +1065,7 @@ TREEVIEW_Refresh (HWND hwnd)
(hwnd, CDDS_POSTPAINT, hdc, rect); (hwnd, CDDS_POSTPAINT, hdc, rect);
ReleaseDC (hwnd, hdc); ReleaseDC (hwnd, hdc);
TRACE (treeview,"done\n"); TRACE("done\n");
} }
@ -1074,7 +1074,7 @@ TREEVIEW_HandleTimer (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd); TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd);
TRACE (treeview, " %d\n",wParam); TRACE(" %d\n",wParam);
if (!infoPtr) return FALSE; if (!infoPtr) return FALSE;
switch (wParam) { switch (wParam) {
@ -1088,7 +1088,7 @@ TREEVIEW_HandleTimer (HWND hwnd, WPARAM wParam, LPARAM lParam)
infoPtr->Timer &= ~TV_EDIT_TIMER_SET; infoPtr->Timer &= ~TV_EDIT_TIMER_SET;
return 0; return 0;
default: default:
ERR (treeview,"got unknown timer\n"); ERR("got unknown timer\n");
} }
return 1; return 1;
@ -1101,7 +1101,7 @@ TREEVIEW_QueueRefresh (HWND hwnd)
{ {
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd); TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd);
TRACE (treeview,"\n"); TRACE("\n");
if (infoPtr->Timer & TV_REFRESH_TIMER_SET) { if (infoPtr->Timer & TV_REFRESH_TIMER_SET) {
KillTimer (hwnd, TV_REFRESH_TIMER); KillTimer (hwnd, TV_REFRESH_TIMER);
} }
@ -1128,7 +1128,7 @@ TREEVIEW_GetItemA (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (tvItem->mask & TVIF_CHILDREN) { if (tvItem->mask & TVIF_CHILDREN) {
if (TVIF_CHILDREN==I_CHILDRENCALLBACK) if (TVIF_CHILDREN==I_CHILDRENCALLBACK)
FIXME (treeview,"I_CHILDRENCALLBACK not supported\n"); FIXME("I_CHILDRENCALLBACK not supported\n");
tvItem->cChildren=wineItem->cChildren; tvItem->cChildren=wineItem->cChildren;
} }
@ -1142,7 +1142,7 @@ TREEVIEW_GetItemA (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (tvItem->mask & TVIF_INTEGRAL) { if (tvItem->mask & TVIF_INTEGRAL) {
tvItem->iIntegral=wineItem->iIntegral; tvItem->iIntegral=wineItem->iIntegral;
FIXME (treeview," TVIF_INTEGRAL not supported yet\n"); FIXME(" TVIF_INTEGRAL not supported yet\n");
} }
if (tvItem->mask & TVIF_PARAM) { if (tvItem->mask & TVIF_PARAM) {
@ -1160,14 +1160,14 @@ TREEVIEW_GetItemA (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (tvItem->mask & TVIF_TEXT) { if (tvItem->mask & TVIF_TEXT) {
if (wineItem->pszText == LPSTR_TEXTCALLBACKA) { if (wineItem->pszText == LPSTR_TEXTCALLBACKA) {
tvItem->pszText = LPSTR_TEXTCALLBACKA; /* FIXME:send notification? */ tvItem->pszText = LPSTR_TEXTCALLBACKA; /* FIXME:send notification? */
ERR (treeview," GetItem called with LPSTR_TEXTCALLBACK\n"); ERR(" GetItem called with LPSTR_TEXTCALLBACK\n");
} }
else if (wineItem->pszText) { else if (wineItem->pszText) {
lstrcpynA (tvItem->pszText, wineItem->pszText, tvItem->cchTextMax); lstrcpynA (tvItem->pszText, wineItem->pszText, tvItem->cchTextMax);
} }
} }
TRACE(treeview,"item %d<%p>, txt %p, img %p, action %x\n", TRACE("item %d<%p>, txt %p, img %p, action %x\n",
iItem, iItem,
tvItem, tvItem,
tvItem->pszText, tvItem->pszText,
@ -1209,7 +1209,7 @@ TREEVIEW_GetNextItem (HWND hwnd, WPARAM wParam, LPARAM lParam)
break; break;
} }
if (retval) { if (retval) {
TRACE (treeview,"flags:%x, returns %u\n", flag, retval); TRACE("flags:%x, returns %u\n", flag, retval);
return retval; return retval;
} }
@ -1238,17 +1238,17 @@ TREEVIEW_GetNextItem (HWND hwnd, WPARAM wParam, LPARAM lParam)
case TVGN_PREVIOUSVISIBLE: case TVGN_PREVIOUSVISIBLE:
returnItem=TREEVIEW_GetPrevListItem (infoPtr, wineItem); returnItem=TREEVIEW_GetPrevListItem (infoPtr, wineItem);
break; break;
default: FIXME (treeview,"Unknown msg %x,item %x\n", flag,iItem); default: FIXME("Unknown msg %x,item %x\n", flag,iItem);
break; break;
} }
if (returnItem) { if (returnItem) {
TRACE (treeview,"flags:%x, item %d;returns %d\n", flag, iItem, TRACE("flags:%x, item %d;returns %d\n", flag, iItem,
(INT)returnItem->hItem); (INT)returnItem->hItem);
return (INT)returnItem->hItem; return (INT)returnItem->hItem;
} }
TRACE (treeview,"flags:%x, item %d;returns %d\n", flag, iItem,retval); TRACE("flags:%x, item %d;returns %d\n", flag, iItem,retval);
return retval; return retval;
} }
@ -1258,7 +1258,7 @@ TREEVIEW_GetCount (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd); TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd);
TRACE (treeview," %d\n",infoPtr->uNumItems); TRACE(" %d\n",infoPtr->uNumItems);
return (LRESULT) infoPtr->uNumItems; return (LRESULT) infoPtr->uNumItems;
} }
@ -1277,10 +1277,10 @@ static void TREEVIEW_InsertBefore(
TREEVIEW_ITEM *upSibling = NULL; TREEVIEW_ITEM *upSibling = NULL;
if (newItem == NULL) if (newItem == NULL)
ERR(treeview, "NULL newItem, impossible condition\n"); ERR("NULL newItem, impossible condition\n");
if (parent == NULL) if (parent == NULL)
ERR(treeview, "NULL parent, impossible condition\n"); ERR("NULL parent, impossible condition\n");
if (sibling != NULL) /* Insert before this sibling for this parent */ if (sibling != NULL) /* Insert before this sibling for this parent */
{ {
@ -1324,10 +1324,10 @@ static void TREEVIEW_InsertAfter(
TREEVIEW_ITEM *sibling = NULL; TREEVIEW_ITEM *sibling = NULL;
if (newItem == NULL) if (newItem == NULL)
ERR(treeview, "NULL newItem, impossible condition\n"); ERR("NULL newItem, impossible condition\n");
if (parent == NULL) if (parent == NULL)
ERR(treeview, "NULL parent, impossible condition\n"); ERR("NULL parent, impossible condition\n");
if (upSibling != NULL) /* Insert after this upsibling for this parent */ if (upSibling != NULL) /* Insert after this upsibling for this parent */
{ {
@ -1531,10 +1531,10 @@ TREEVIEW_InsertItemA (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (TRACE_ON(treeview)) { if (TRACE_ON(treeview)) {
for (i=0; i<infoPtr->uNumPtrsAlloced>>5; i++) for (i=0; i<infoPtr->uNumPtrsAlloced>>5; i++)
TRACE (treeview,"%8x\n",infoPtr->freeList[i]); TRACE("%8x\n",infoPtr->freeList[i]);
} }
if (!iItem) ERR (treeview, "Argh -- can't find free item.\n"); if (!iItem) ERR("Argh -- can't find free item.\n");
/* /*
* Find the parent item of the new item * Find the parent item of the new item
@ -1575,7 +1575,7 @@ TREEVIEW_InsertItemA (HWND hwnd, WPARAM wParam, LPARAM lParam)
*/ */
if (tvItem->pszText!=LPSTR_TEXTCALLBACKA) if (tvItem->pszText!=LPSTR_TEXTCALLBACKA)
{ {
TRACE (treeview,"(%p,%s)\n", &tvItem->pszText, tvItem->pszText); TRACE("(%p,%s)\n", &tvItem->pszText, tvItem->pszText);
len = lstrlenA (tvItem->pszText)+1; len = lstrlenA (tvItem->pszText)+1;
wineItem->pszText= COMCTL32_Alloc (len+1); wineItem->pszText= COMCTL32_Alloc (len+1);
lstrcpyA (wineItem->pszText, tvItem->pszText); lstrcpyA (wineItem->pszText, tvItem->pszText);
@ -1583,7 +1583,7 @@ TREEVIEW_InsertItemA (HWND hwnd, WPARAM wParam, LPARAM lParam)
} }
else else
{ {
TRACE (treeview,"LPSTR_TEXTCALLBACK\n"); TRACE("LPSTR_TEXTCALLBACK\n");
wineItem->pszText = LPSTR_TEXTCALLBACKA; wineItem->pszText = LPSTR_TEXTCALLBACKA;
wineItem->cchTextMax = 0; wineItem->cchTextMax = 0;
} }
@ -1687,7 +1687,7 @@ TREEVIEW_InsertItemA (HWND hwnd, WPARAM wParam, LPARAM lParam)
sibItem=&infoPtr->items [(INT)sibItem->sibling]; sibItem=&infoPtr->items [(INT)sibItem->sibling];
} }
if (sibItem->hItem!=ptdi->hInsertAfter) { if (sibItem->hItem!=ptdi->hInsertAfter) {
ERR (treeview, "tried to insert item after nonexisting handle.\n"); ERR("tried to insert item after nonexisting handle.\n");
break; break;
} }
prevsib=sibItem; prevsib=sibItem;
@ -1705,7 +1705,7 @@ TREEVIEW_InsertItemA (HWND hwnd, WPARAM wParam, LPARAM lParam)
/* Fill in info structure */ /* Fill in info structure */
TRACE (treeview,"new item %d; parent %d, mask %x\n", iItem, TRACE("new item %d; parent %d, mask %x\n", iItem,
(INT)wineItem->parent,tvItem->mask); (INT)wineItem->parent,tvItem->mask);
wineItem->mask=tvItem->mask; wineItem->mask=tvItem->mask;
@ -1714,7 +1714,7 @@ TREEVIEW_InsertItemA (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (tvItem->mask & TVIF_CHILDREN) { if (tvItem->mask & TVIF_CHILDREN) {
wineItem->cChildren=tvItem->cChildren; wineItem->cChildren=tvItem->cChildren;
if (tvItem->cChildren==I_CHILDRENCALLBACK) if (tvItem->cChildren==I_CHILDRENCALLBACK)
FIXME (treeview," I_CHILDRENCALLBACK not supported\n"); FIXME(" I_CHILDRENCALLBACK not supported\n");
} }
wineItem->expandBox.left = 0; /* Initialize the expandBox */ wineItem->expandBox.left = 0; /* Initialize the expandBox */
@ -1735,7 +1735,7 @@ TREEVIEW_InsertItemA (HWND hwnd, WPARAM wParam, LPARAM lParam)
wineItem->iSelectedImage=tvItem->iSelectedImage; wineItem->iSelectedImage=tvItem->iSelectedImage;
if (tvItem->mask & TVIF_STATE) { if (tvItem->mask & TVIF_STATE) {
TRACE(treeview, "Changing item state from %d to %d\n", TRACE("Changing item state from %d to %d\n",
wineItem->state, wineItem->state,
tvItem->state); tvItem->state);
wineItem->state=tvItem->state; wineItem->state=tvItem->state;
@ -1759,7 +1759,7 @@ TREEVIEW_DeleteItem (HWND hwnd, WPARAM wParam, LPARAM lParam)
INT iItem; INT iItem;
TREEVIEW_ITEM *wineItem; TREEVIEW_ITEM *wineItem;
TRACE (treeview,"\n"); TRACE("\n");
if (!infoPtr) return FALSE; if (!infoPtr) return FALSE;
if (lParam == (INT)TVI_ROOT) { if (lParam == (INT)TVI_ROOT) {
@ -1768,7 +1768,7 @@ TREEVIEW_DeleteItem (HWND hwnd, WPARAM wParam, LPARAM lParam)
iItem= (INT) lParam; iItem= (INT) lParam;
wineItem = TREEVIEW_ValidItem (infoPtr, (HTREEITEM)iItem); wineItem = TREEVIEW_ValidItem (infoPtr, (HTREEITEM)iItem);
if (!wineItem) return FALSE; if (!wineItem) return FALSE;
TRACE (treeview,"%s\n",wineItem->pszText); TRACE("%s\n",wineItem->pszText);
TREEVIEW_RemoveItem (hwnd, wineItem); TREEVIEW_RemoveItem (hwnd, wineItem);
} }
@ -1784,7 +1784,7 @@ TREEVIEW_GetIndent (HWND hwnd)
{ {
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd); TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd);
TRACE (treeview,"\n"); TRACE("\n");
return infoPtr->uIndent; return infoPtr->uIndent;
} }
@ -1794,7 +1794,7 @@ TREEVIEW_SetIndent (HWND hwnd, WPARAM wParam)
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd); TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd);
INT newIndent; INT newIndent;
TRACE (treeview,"\n"); TRACE("\n");
newIndent=(INT) wParam; newIndent=(INT) wParam;
if (newIndent < MINIMUM_INDENT) newIndent=MINIMUM_INDENT; if (newIndent < MINIMUM_INDENT) newIndent=MINIMUM_INDENT;
infoPtr->uIndent=newIndent; infoPtr->uIndent=newIndent;
@ -1808,7 +1808,7 @@ TREEVIEW_GetToolTips (HWND hwnd)
{ {
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd); TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd);
TRACE (treeview,"\n"); TRACE("\n");
return infoPtr->hwndToolTip; return infoPtr->hwndToolTip;
} }
@ -1820,7 +1820,7 @@ TREEVIEW_SetToolTips (HWND hwnd, WPARAM wParam)
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd); TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd);
HWND prevToolTip; HWND prevToolTip;
TRACE (treeview,"\n"); TRACE("\n");
prevToolTip=infoPtr->hwndToolTip; prevToolTip=infoPtr->hwndToolTip;
infoPtr->hwndToolTip= (HWND) wParam; infoPtr->hwndToolTip= (HWND) wParam;
@ -1874,7 +1874,7 @@ static LRESULT
TREEVIEW_Command (HWND hwnd, WPARAM wParam, LPARAM lParam) TREEVIEW_Command (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
TRACE (treeview, "%x %ld\n",wParam, lParam); TRACE("%x %ld\n",wParam, lParam);
switch (HIWORD(wParam)) switch (HIWORD(wParam))
{ {
@ -1937,7 +1937,7 @@ TREEVIEW_Size (HWND hwnd, WPARAM wParam, LPARAM lParam)
infoPtr->uTotalWidth = LOWORD (lParam); infoPtr->uTotalWidth = LOWORD (lParam);
infoPtr->uTotalHeight = HIWORD (lParam); infoPtr->uTotalHeight = HIWORD (lParam);
} else { } else {
FIXME (treeview,"WM_SIZE flag %x %lx not handled\n", wParam, lParam); FIXME("WM_SIZE flag %x %lx not handled\n", wParam, lParam);
} }
TREEVIEW_QueueRefresh (hwnd); TREEVIEW_QueueRefresh (hwnd);
@ -1951,7 +1951,7 @@ TREEVIEW_StyleChanged (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
LPSTYLESTRUCT lpss=(LPSTYLESTRUCT) lParam; LPSTYLESTRUCT lpss=(LPSTYLESTRUCT) lParam;
TRACE (treeview,"(%x %lx)\n",wParam,lParam); TRACE("(%x %lx)\n",wParam,lParam);
if (wParam & (GWL_STYLE)) if (wParam & (GWL_STYLE))
SetWindowLongA( hwnd, GWL_STYLE, lpss->styleNew); SetWindowLongA( hwnd, GWL_STYLE, lpss->styleNew);
@ -1969,19 +1969,19 @@ TREEVIEW_Create (HWND hwnd, WPARAM wParam, LPARAM lParam)
TEXTMETRICA tm; TEXTMETRICA tm;
HDC hdc; HDC hdc;
TRACE (treeview,"wnd %x\n",hwnd); TRACE("wnd %x\n",hwnd);
/* allocate memory for info structure */ /* allocate memory for info structure */
infoPtr = (TREEVIEW_INFO *) COMCTL32_Alloc (sizeof(TREEVIEW_INFO)); infoPtr = (TREEVIEW_INFO *) COMCTL32_Alloc (sizeof(TREEVIEW_INFO));
SetWindowLongA( hwnd, 0, (DWORD)infoPtr); SetWindowLongA( hwnd, 0, (DWORD)infoPtr);
if (infoPtr == NULL) { if (infoPtr == NULL) {
ERR (treeview, "could not allocate info memory!\n"); ERR("could not allocate info memory!\n");
return 0; return 0;
} }
if ((TREEVIEW_INFO*) GetWindowLongA( hwnd, 0) != infoPtr) { if ((TREEVIEW_INFO*) GetWindowLongA( hwnd, 0) != infoPtr) {
ERR (treeview, "pointer assignment error!\n"); ERR("pointer assignment error!\n");
return 0; return 0;
} }
@ -2076,7 +2076,7 @@ TREEVIEW_Destroy (HWND hwnd)
{ {
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd); TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd);
TRACE (treeview,"\n"); TRACE("\n");
TREEVIEW_RemoveTree (hwnd); TREEVIEW_RemoveTree (hwnd);
if (infoPtr->Timer & TV_REFRESH_TIMER_SET) if (infoPtr->Timer & TV_REFRESH_TIMER_SET)
KillTimer (hwnd, TV_REFRESH_TIMER); KillTimer (hwnd, TV_REFRESH_TIMER);
@ -2094,12 +2094,12 @@ TREEVIEW_Paint (HWND hwnd, WPARAM wParam, LPARAM lParam)
HDC hdc; HDC hdc;
PAINTSTRUCT ps; PAINTSTRUCT ps;
TRACE (treeview,"\n"); TRACE("\n");
hdc = wParam==0 ? BeginPaint (hwnd, &ps) : (HDC)wParam; hdc = wParam==0 ? BeginPaint (hwnd, &ps) : (HDC)wParam;
TREEVIEW_Refresh (hwnd); TREEVIEW_Refresh (hwnd);
if(!wParam) if(!wParam)
EndPaint (hwnd, &ps); EndPaint (hwnd, &ps);
TRACE (treeview,"done\n"); TRACE("done\n");
return DefWindowProcA (hwnd, WM_PAINT, wParam, lParam); return DefWindowProcA (hwnd, WM_PAINT, wParam, lParam);
} }
@ -2127,7 +2127,7 @@ TREEVIEW_EraseBackground (HWND hwnd, WPARAM wParam, LPARAM lParam)
HBRUSH hBrush = CreateSolidBrush (infoPtr->clrBk); HBRUSH hBrush = CreateSolidBrush (infoPtr->clrBk);
RECT rect; RECT rect;
TRACE (treeview,"\n"); TRACE("\n");
GetClientRect (hwnd, &rect); GetClientRect (hwnd, &rect);
FillRect ((HDC)wParam, &rect, hBrush); FillRect ((HDC)wParam, &rect, hBrush);
DeleteObject (hBrush); DeleteObject (hBrush);
@ -2150,7 +2150,7 @@ TREEVIEW_SendSimpleNotify (HWND hwnd, UINT code)
{ {
NMHDR nmhdr; NMHDR nmhdr;
TRACE (treeview, "%x\n",code); TRACE("%x\n",code);
nmhdr.hwndFrom = hwnd; nmhdr.hwndFrom = hwnd;
nmhdr.idFrom = GetWindowLongA( hwnd, GWL_ID); nmhdr.idFrom = GetWindowLongA( hwnd, GWL_ID);
nmhdr.code = code; nmhdr.code = code;
@ -2170,7 +2170,7 @@ TREEVIEW_SendTreeviewNotify (HWND hwnd, UINT code, UINT action,
NMTREEVIEWA nmhdr; NMTREEVIEWA nmhdr;
TREEVIEW_ITEM *wineItem; TREEVIEW_ITEM *wineItem;
TRACE (treeview,"code:%x action:%x olditem:%x newitem:%x\n", TRACE("code:%x action:%x olditem:%x newitem:%x\n",
code,action,(INT)oldItem,(INT)newItem); code,action,(INT)oldItem,(INT)newItem);
nmhdr.hdr.hwndFrom = hwnd; nmhdr.hdr.hwndFrom = hwnd;
nmhdr.hdr.idFrom = GetWindowLongA( hwnd, GWL_ID); nmhdr.hdr.idFrom = GetWindowLongA( hwnd, GWL_ID);
@ -2222,7 +2222,7 @@ TREEVIEW_SendTreeviewDnDNotify (HWND hwnd, UINT code, HTREEITEM dragItem,
NMTREEVIEWA nmhdr; NMTREEVIEWA nmhdr;
TREEVIEW_ITEM *wineItem; TREEVIEW_ITEM *wineItem;
TRACE (treeview,"code:%x dragitem:%x\n", code,(INT)dragItem); TRACE("code:%x dragitem:%x\n", code,(INT)dragItem);
nmhdr.hdr.hwndFrom = hwnd; nmhdr.hdr.hwndFrom = hwnd;
nmhdr.hdr.idFrom = GetWindowLongA( hwnd, GWL_ID); nmhdr.hdr.idFrom = GetWindowLongA( hwnd, GWL_ID);
@ -2252,7 +2252,7 @@ TREEVIEW_SendDispInfoNotify (HWND hwnd, TREEVIEW_ITEM *wineItem,
BOOL retval; BOOL retval;
char *buf; char *buf;
TRACE (treeview,"item %d, action %x, state %d\n", TRACE("item %d, action %x, state %d\n",
(INT)wineItem->hItem, (INT)wineItem->hItem,
what, what,
(INT)wineItem->state); (INT)wineItem->state);
@ -2278,7 +2278,7 @@ TREEVIEW_SendDispInfoNotify (HWND hwnd, TREEVIEW_ITEM *wineItem,
if (buf==tvdi.item.pszText) { if (buf==tvdi.item.pszText) {
wineItem->cchTextMax = 128; wineItem->cchTextMax = 128;
} else { } else {
TRACE (treeview,"user-supplied buffer\n"); TRACE("user-supplied buffer\n");
COMCTL32_Free (buf); COMCTL32_Free (buf);
wineItem->cchTextMax = 0; wineItem->cchTextMax = 0;
} }
@ -2303,7 +2303,7 @@ TREEVIEW_SendCustomDrawNotify (HWND hwnd, DWORD dwDrawStage, HDC hdc,
NMTVCUSTOMDRAW nmcdhdr; NMTVCUSTOMDRAW nmcdhdr;
LPNMCUSTOMDRAW nmcd; LPNMCUSTOMDRAW nmcd;
TRACE (treeview,"drawstage:%lx hdc:%x\n", dwDrawStage, hdc); TRACE("drawstage:%lx hdc:%x\n", dwDrawStage, hdc);
nmcd= & nmcdhdr.nmcd; nmcd= & nmcdhdr.nmcd;
nmcd->hdr.hwndFrom = hwnd; nmcd->hdr.hwndFrom = hwnd;
@ -2366,7 +2366,7 @@ TREEVIEW_SendCustomDrawItemNotify (HWND hwnd, HDC hdc,
nmcdhdr.clrTextBk= infoPtr->clrBk; nmcdhdr.clrTextBk= infoPtr->clrBk;
nmcdhdr.iLevel = wineItem->iLevel; nmcdhdr.iLevel = wineItem->iLevel;
TRACE (treeview,"drawstage:%lx hdc:%x item:%lx, itemstate:%x\n", TRACE("drawstage:%lx hdc:%x item:%lx, itemstate:%x\n",
dwDrawStage, hdc, dwItemSpec, uItemState); dwDrawStage, hdc, dwItemSpec, uItemState);
return (BOOL)SendMessageA (GetParent (hwnd), WM_NOTIFY, return (BOOL)SendMessageA (GetParent (hwnd), WM_NOTIFY,
@ -2399,14 +2399,14 @@ TREEVIEW_Expand (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (!wineItem->cChildren) if (!wineItem->cChildren)
return 0; return 0;
TRACE (treeview,"For (%s) flags:%x item:%d state:%d\n", TRACE("For (%s) flags:%x item:%d state:%d\n",
wineItem->pszText, wineItem->pszText,
flag, flag,
expand, expand,
wineItem->state); wineItem->state);
if (wineItem->cChildren==I_CHILDRENCALLBACK) { if (wineItem->cChildren==I_CHILDRENCALLBACK) {
FIXME (treeview,"we don't handle I_CHILDRENCALLBACK yet\n"); FIXME("we don't handle I_CHILDRENCALLBACK yet\n");
return 0; return 0;
} }
@ -2421,7 +2421,7 @@ TREEVIEW_Expand (HWND hwnd, WPARAM wParam, LPARAM lParam)
switch (flag) switch (flag)
{ {
case TVE_COLLAPSERESET: case TVE_COLLAPSERESET:
TRACE(treeview, " case TVE_COLLAPSERESET\n"); TRACE(" case TVE_COLLAPSERESET\n");
if (!wineItem->state & TVIS_EXPANDED) if (!wineItem->state & TVIS_EXPANDED)
return 0; return 0;
@ -2430,7 +2430,7 @@ TREEVIEW_Expand (HWND hwnd, WPARAM wParam, LPARAM lParam)
break; break;
case TVE_COLLAPSE: case TVE_COLLAPSE:
TRACE(treeview, " case TVE_COLLAPSE\n"); TRACE(" case TVE_COLLAPSE\n");
if (!wineItem->state & TVIS_EXPANDED) if (!wineItem->state & TVIS_EXPANDED)
return 0; return 0;
@ -2438,15 +2438,15 @@ TREEVIEW_Expand (HWND hwnd, WPARAM wParam, LPARAM lParam)
break; break;
case TVE_EXPAND: case TVE_EXPAND:
TRACE(treeview, " case TVE_EXPAND\n"); TRACE(" case TVE_EXPAND\n");
if (wineItem->state & TVIS_EXPANDED) if (wineItem->state & TVIS_EXPANDED)
return 0; return 0;
TRACE(treeview, " is not expanded...\n"); TRACE(" is not expanded...\n");
if (!(wineItem->state & TVIS_EXPANDEDONCE)) if (!(wineItem->state & TVIS_EXPANDEDONCE))
{ {
TRACE(treeview, " and has never been expanded...\n"); TRACE(" and has never been expanded...\n");
wineItem->state |= TVIS_EXPANDED; wineItem->state |= TVIS_EXPANDED;
/* this item has never been expanded */ /* this item has never been expanded */
@ -2457,7 +2457,7 @@ TREEVIEW_Expand (HWND hwnd, WPARAM wParam, LPARAM lParam)
0, 0,
(HTREEITEM)expand)) (HTREEITEM)expand))
{ {
TRACE(treeview, " TVN_ITEMEXPANDING returned TRUE, exiting...\n"); TRACE(" TVN_ITEMEXPANDING returned TRUE, exiting...\n");
return FALSE; return FALSE;
} }
@ -2472,14 +2472,14 @@ TREEVIEW_Expand (HWND hwnd, WPARAM wParam, LPARAM lParam)
wineItem = TREEVIEW_ValidItem (infoPtr, (HTREEITEM)expand); wineItem = TREEVIEW_ValidItem (infoPtr, (HTREEITEM)expand);
if (! wineItem) if (! wineItem)
{ {
ERR(treeview, ERR(
"Catastropic situation, cannot retreive item #%d\n", "Catastropic situation, cannot retreive item #%d\n",
expand); expand);
return FALSE; return FALSE;
} }
wineItem->state |= TVIS_EXPANDEDONCE; wineItem->state |= TVIS_EXPANDEDONCE;
TRACE(treeview, " TVN_ITEMEXPANDING sent...\n"); TRACE(" TVN_ITEMEXPANDING sent...\n");
TREEVIEW_SendTreeviewNotify ( TREEVIEW_SendTreeviewNotify (
hwnd, hwnd,
@ -2488,7 +2488,7 @@ TREEVIEW_Expand (HWND hwnd, WPARAM wParam, LPARAM lParam)
0, 0,
(HTREEITEM)expand); (HTREEITEM)expand);
TRACE(treeview, " TVN_ITEMEXPANDED sent...\n"); TRACE(" TVN_ITEMEXPANDED sent...\n");
} }
else else
@ -2499,14 +2499,14 @@ TREEVIEW_Expand (HWND hwnd, WPARAM wParam, LPARAM lParam)
break; break;
case TVE_EXPANDPARTIAL: case TVE_EXPANDPARTIAL:
TRACE(treeview, " case TVE_EXPANDPARTIAL\n"); TRACE(" case TVE_EXPANDPARTIAL\n");
FIXME (treeview, "TVE_EXPANDPARTIAL not implemented\n"); FIXME("TVE_EXPANDPARTIAL not implemented\n");
wineItem->state ^=TVIS_EXPANDED; wineItem->state ^=TVIS_EXPANDED;
wineItem->state |=TVIS_EXPANDEDONCE; wineItem->state |=TVIS_EXPANDEDONCE;
break; break;
} }
TRACE(treeview, "Exiting, Item %d state is now %d...\n", TRACE("Exiting, Item %d state is now %d...\n",
expand, expand,
wineItem->state); wineItem->state);
@ -2627,11 +2627,11 @@ TREEVIEW_EndEditLabelNow (HWND hwnd, WPARAM wParam, LPARAM lParam)
if (iLength == 0) if (iLength == 0)
{ {
ERR( treeview, "Problem retreiving new item label."); ERR("Problem retreiving new item label.");
} }
else if (iLength >= 1023) else if (iLength >= 1023)
{ {
ERR( treeview, ERR(
"Insuficient space to retrieve new item label, new label ignored."); "Insuficient space to retrieve new item label, new label ignored.");
} }
else else
@ -2644,7 +2644,7 @@ TREEVIEW_EndEditLabelNow (HWND hwnd, WPARAM wParam, LPARAM lParam)
LPSTR tmpLabel = COMCTL32_Alloc( iLength+1 ); LPSTR tmpLabel = COMCTL32_Alloc( iLength+1 );
if ( tmpLabel == NULL ) if ( tmpLabel == NULL )
ERR( treeview, ERR(
"OutOfMemory, cannot allocate space for label"); "OutOfMemory, cannot allocate space for label");
else else
{ {
@ -2672,14 +2672,14 @@ TREEVIEW_LButtonDoubleClick (HWND hwnd, WPARAM wParam, LPARAM lParam)
TREEVIEW_ITEM *wineItem; TREEVIEW_ITEM *wineItem;
POINT pt; POINT pt;
TRACE (treeview,"\n"); TRACE("\n");
pt.x = (INT)LOWORD(lParam); pt.x = (INT)LOWORD(lParam);
pt.y = (INT)HIWORD(lParam); pt.y = (INT)HIWORD(lParam);
SetFocus (hwnd); SetFocus (hwnd);
wineItem=TREEVIEW_HitTestPoint (hwnd, pt); wineItem=TREEVIEW_HitTestPoint (hwnd, pt);
if (!wineItem) return 0; if (!wineItem) return 0;
TRACE (treeview,"item %d \n",(INT)wineItem->hItem); TRACE("item %d \n",(INT)wineItem->hItem);
if (TREEVIEW_SendSimpleNotify (hwnd, NM_DBLCLK)!=TRUE) { /* FIXME!*/ if (TREEVIEW_SendSimpleNotify (hwnd, NM_DBLCLK)!=TRUE) { /* FIXME!*/
TREEVIEW_Expand (hwnd, (WPARAM) TVE_TOGGLE, (LPARAM) wineItem->hItem); TREEVIEW_Expand (hwnd, (WPARAM) TVE_TOGGLE, (LPARAM) wineItem->hItem);
@ -2700,7 +2700,7 @@ TREEVIEW_LButtonDown (HWND hwnd, WPARAM wParam, LPARAM lParam)
SetFocus (hwnd); SetFocus (hwnd);
iItem=TREEVIEW_HitTest (hwnd, (LPARAM) &ht); iItem=TREEVIEW_HitTest (hwnd, (LPARAM) &ht);
TRACE (treeview,"item %d \n",iItem); TRACE("item %d \n",iItem);
if (ht.flags & TVHT_ONITEMBUTTON) { if (ht.flags & TVHT_ONITEMBUTTON) {
TREEVIEW_Expand (hwnd, (WPARAM) TVE_TOGGLE, (LPARAM) iItem); TREEVIEW_Expand (hwnd, (WPARAM) TVE_TOGGLE, (LPARAM) iItem);
@ -2724,7 +2724,7 @@ TREEVIEW_LButtonUp (HWND hwnd, WPARAM wParam, LPARAM lParam)
ht.pt.x = (INT)LOWORD(lParam); ht.pt.x = (INT)LOWORD(lParam);
ht.pt.y = (INT)HIWORD(lParam); ht.pt.y = (INT)HIWORD(lParam);
TRACE (treeview,"\n"); TRACE("\n");
/* Return true to cancel default behaviour */ /* Return true to cancel default behaviour */
if ( TREEVIEW_SendSimpleNotify (hwnd, NM_CLICK) ) if ( TREEVIEW_SendSimpleNotify (hwnd, NM_CLICK) )
@ -2758,7 +2758,7 @@ TREEVIEW_LButtonUp (HWND hwnd, WPARAM wParam, LPARAM lParam)
return 0; return 0;
} }
TRACE(treeview,"Edit started for %s.\n", editItem->pszText); TRACE("Edit started for %s.\n", editItem->pszText);
infoPtr->editItem = editItem->hItem; infoPtr->editItem = editItem->hItem;
SetWindowPos ( SetWindowPos (
@ -2798,7 +2798,7 @@ TREEVIEW_RButtonDown (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd); TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd);
TRACE (treeview,"\n"); TRACE("\n");
infoPtr->uInternalStatus|=TV_RDRAG; infoPtr->uInternalStatus|=TV_RDRAG;
return 0; return 0;
} }
@ -2808,7 +2808,7 @@ TREEVIEW_RButtonUp (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd); TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd);
TRACE (treeview,"\n"); TRACE("\n");
if (TREEVIEW_SendSimpleNotify (hwnd, NM_RCLICK)) return 0; if (TREEVIEW_SendSimpleNotify (hwnd, NM_RCLICK)) return 0;
infoPtr->uInternalStatus&= ~(TV_RDRAG | TV_RDRAGGING); infoPtr->uInternalStatus&= ~(TV_RDRAG | TV_RDRAGGING);
return 0; return 0;
@ -2864,7 +2864,7 @@ TREEVIEW_CreateDragImage (HWND hwnd, WPARAM wParam, LPARAM lParam)
HFONT hOldFont; HFONT hOldFont;
char *itemtxt; char *itemtxt;
TRACE (treeview,"\n"); TRACE("\n");
if (!(infoPtr->himlNormal)) return 0; if (!(infoPtr->himlNormal)) return 0;
dragItem=TREEVIEW_ValidItem (infoPtr, (HTREEITEM) lParam); dragItem=TREEVIEW_ValidItem (infoPtr, (HTREEITEM) lParam);
@ -2877,7 +2877,7 @@ TREEVIEW_CreateDragImage (HWND hwnd, WPARAM wParam, LPARAM lParam)
hOldFont=SelectObject (hdc, infoPtr->hFont); hOldFont=SelectObject (hdc, infoPtr->hFont);
GetTextExtentPoint32A (hdc, itemtxt, lstrlenA (itemtxt), &size); GetTextExtentPoint32A (hdc, itemtxt, lstrlenA (itemtxt), &size);
TRACE (treeview,"%d %d %s %d\n",size.cx,size.cy,itemtxt,lstrlenA(itemtxt)); TRACE("%d %d %s %d\n",size.cx,size.cy,itemtxt,lstrlenA(itemtxt));
hbmp=CreateCompatibleBitmap (htopdc, size.cx, size.cy); hbmp=CreateCompatibleBitmap (htopdc, size.cx, size.cy);
hOldbmp=SelectObject (hdc, hbmp); hOldbmp=SelectObject (hdc, hbmp);
@ -2920,7 +2920,7 @@ TREEVIEW_DoSelectItem (HWND hwnd, INT action, HTREEITEM newSelect, INT cause)
wineItem = TREEVIEW_ValidItem (infoPtr, (HTREEITEM)newSelect); wineItem = TREEVIEW_ValidItem (infoPtr, (HTREEITEM)newSelect);
TRACE (treeview,"Entering item %d, flag %x, cause %x, state %d\n", TRACE("Entering item %d, flag %x, cause %x, state %d\n",
(INT)newSelect, (INT)newSelect,
action, action,
cause, cause,
@ -2986,13 +2986,13 @@ TREEVIEW_DoSelectItem (HWND hwnd, INT action, HTREEITEM newSelect, INT cause)
break; break;
case TVGN_FIRSTVISIBLE: case TVGN_FIRSTVISIBLE:
FIXME (treeview, "FIRSTVISIBLE not implemented\n"); FIXME("FIRSTVISIBLE not implemented\n");
break; break;
} }
TREEVIEW_QueueRefresh (hwnd); TREEVIEW_QueueRefresh (hwnd);
TRACE (treeview,"Leaving state %d\n", wineItem->state); TRACE("Leaving state %d\n", wineItem->state);
return TRUE; return TRUE;
} }
@ -3013,7 +3013,7 @@ TREEVIEW_GetFont (HWND hwnd, WPARAM wParam, LPARAM lParam)
{ {
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd); TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd);
TRACE (treeview,"%x\n",infoPtr->hFont); TRACE("%x\n",infoPtr->hFont);
return infoPtr->hFont; return infoPtr->hFont;
} }
@ -3028,7 +3028,7 @@ TREEVIEW_SetFont (HWND hwnd, WPARAM wParam, LPARAM lParam)
INT height; INT height;
HDC hdc; HDC hdc;
TRACE (treeview,"%x %lx\n",wParam, lParam); TRACE("%x %lx\n",wParam, lParam);
infoPtr->hFont = (HFONT)wParam; infoPtr->hFont = (HFONT)wParam;
@ -3062,7 +3062,7 @@ TREEVIEW_VScroll (HWND hwnd, WPARAM wParam, LPARAM lParam)
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd); TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd);
int maxHeight; int maxHeight;
TRACE (treeview,"wp %x, lp %lx\n", wParam, lParam); TRACE("wp %x, lp %lx\n", wParam, lParam);
if (!infoPtr->uInternalStatus & TV_VSCROLL) return FALSE; if (!infoPtr->uInternalStatus & TV_VSCROLL) return FALSE;
switch (LOWORD (wParam)) { switch (LOWORD (wParam)) {
@ -3106,7 +3106,7 @@ TREEVIEW_HScroll (HWND hwnd, WPARAM wParam, LPARAM lParam)
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd); TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(hwnd);
int maxWidth; int maxWidth;
TRACE (treeview,"wp %lx, lp %x\n", lParam, wParam); TRACE("wp %lx, lp %x\n", lParam, wParam);
if (!infoPtr->uInternalStatus & TV_HSCROLL) return FALSE; if (!infoPtr->uInternalStatus & TV_HSCROLL) return FALSE;
@ -3162,7 +3162,7 @@ TREEVIEW_KeyDown (HWND hwnd, WPARAM wParam, LPARAM lParam)
TREEVIEW_ITEM *newItem = NULL; TREEVIEW_ITEM *newItem = NULL;
TRACE (treeview,"%x %lx\n",wParam, lParam); TRACE("%x %lx\n",wParam, lParam);
if (prevSelect == 0) if (prevSelect == 0)
return FALSE; return FALSE;
@ -3289,7 +3289,7 @@ TREEVIEW_KeyDown (HWND hwnd, WPARAM wParam, LPARAM lParam)
case VK_RETURN: case VK_RETURN:
default: default:
FIXME (treeview, "%x not implemented\n", wParam); FIXME("%x not implemented\n", wParam);
break; break;
} }
@ -3337,7 +3337,7 @@ TREEVIEW_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
return TREEVIEW_InsertItemA (hwnd, wParam, lParam); return TREEVIEW_InsertItemA (hwnd, wParam, lParam);
case TVM_INSERTITEMW: case TVM_INSERTITEMW:
FIXME (treeview, "Unimplemented msg TVM_INSERTITEM32W\n"); FIXME("Unimplemented msg TVM_INSERTITEM32W\n");
return 0; return 0;
case TVM_DELETEITEM: case TVM_DELETEITEM:
@ -3374,22 +3374,22 @@ TREEVIEW_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
return TREEVIEW_GetItemA (hwnd, wParam, lParam); return TREEVIEW_GetItemA (hwnd, wParam, lParam);
case TVM_GETITEMW: case TVM_GETITEMW:
FIXME (treeview, "Unimplemented msg TVM_GETITEM32W\n"); FIXME("Unimplemented msg TVM_GETITEM32W\n");
return 0; return 0;
case TVM_SETITEMA: case TVM_SETITEMA:
return TREEVIEW_SetItemA (hwnd, wParam, lParam); return TREEVIEW_SetItemA (hwnd, wParam, lParam);
case TVM_SETITEMW: case TVM_SETITEMW:
FIXME (treeview, "Unimplemented msg TVM_SETITEMW\n"); FIXME("Unimplemented msg TVM_SETITEMW\n");
return 0; return 0;
case TVM_EDITLABELA: case TVM_EDITLABELA:
FIXME (treeview, "Unimplemented msg TVM_EDITLABEL32A \n"); FIXME("Unimplemented msg TVM_EDITLABEL32A \n");
return 0; return 0;
case TVM_EDITLABELW: case TVM_EDITLABELW:
FIXME (treeview, "Unimplemented msg TVM_EDITLABEL32W \n"); FIXME("Unimplemented msg TVM_EDITLABEL32W \n");
return 0; return 0;
case TVM_GETEDITCONTROL: case TVM_GETEDITCONTROL:
@ -3405,11 +3405,11 @@ TREEVIEW_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
return TREEVIEW_CreateDragImage (hwnd, wParam, lParam); return TREEVIEW_CreateDragImage (hwnd, wParam, lParam);
case TVM_SORTCHILDREN: case TVM_SORTCHILDREN:
FIXME (treeview, "Unimplemented msg TVM_SORTCHILDREN\n"); FIXME("Unimplemented msg TVM_SORTCHILDREN\n");
return 0; return 0;
case TVM_ENSUREVISIBLE: case TVM_ENSUREVISIBLE:
FIXME (treeview, "Unimplemented msg TVM_ENSUREVISIBLE\n"); FIXME("Unimplemented msg TVM_ENSUREVISIBLE\n");
return 0; return 0;
case TVM_SORTCHILDRENCB: case TVM_SORTCHILDRENCB:
@ -3419,11 +3419,11 @@ TREEVIEW_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
return TREEVIEW_EndEditLabelNow (hwnd, wParam, lParam); return TREEVIEW_EndEditLabelNow (hwnd, wParam, lParam);
case TVM_GETISEARCHSTRINGA: case TVM_GETISEARCHSTRINGA:
FIXME (treeview, "Unimplemented msg TVM_GETISEARCHSTRING32A\n"); FIXME("Unimplemented msg TVM_GETISEARCHSTRING32A\n");
return 0; return 0;
case TVM_GETISEARCHSTRINGW: case TVM_GETISEARCHSTRINGW:
FIXME (treeview, "Unimplemented msg TVM_GETISEARCHSTRING32W\n"); FIXME("Unimplemented msg TVM_GETISEARCHSTRING32W\n");
return 0; return 0;
case TVM_GETTOOLTIPS: case TVM_GETTOOLTIPS:
@ -3433,7 +3433,7 @@ TREEVIEW_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
return TREEVIEW_SetToolTips (hwnd, wParam); return TREEVIEW_SetToolTips (hwnd, wParam);
case TVM_SETINSERTMARK: case TVM_SETINSERTMARK:
FIXME (treeview, "Unimplemented msg TVM_SETINSERTMARK\n"); FIXME("Unimplemented msg TVM_SETINSERTMARK\n");
return 0; return 0;
case TVM_SETITEMHEIGHT: case TVM_SETITEMHEIGHT:
@ -3455,23 +3455,23 @@ TREEVIEW_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
return TREEVIEW_GetTextColor (hwnd); return TREEVIEW_GetTextColor (hwnd);
case TVM_SETSCROLLTIME: case TVM_SETSCROLLTIME:
FIXME (treeview, "Unimplemented msg TVM_SETSCROLLTIME\n"); FIXME("Unimplemented msg TVM_SETSCROLLTIME\n");
return 0; return 0;
case TVM_GETSCROLLTIME: case TVM_GETSCROLLTIME:
FIXME (treeview, "Unimplemented msg TVM_GETSCROLLTIME\n"); FIXME("Unimplemented msg TVM_GETSCROLLTIME\n");
return 0; return 0;
case TVM_SETINSERTMARKCOLOR: case TVM_SETINSERTMARKCOLOR:
FIXME (treeview, "Unimplemented msg TVM_SETINSERTMARKCOLOR\n"); FIXME("Unimplemented msg TVM_SETINSERTMARKCOLOR\n");
return 0; return 0;
case TVM_SETUNICODEFORMAT: case TVM_SETUNICODEFORMAT:
FIXME (treeview, "Unimplemented msg TVM_SETUNICODEFORMAT\n"); FIXME("Unimplemented msg TVM_SETUNICODEFORMAT\n");
return 0; return 0;
case TVM_GETUNICODEFORMAT: case TVM_GETUNICODEFORMAT:
FIXME (treeview, "Unimplemented msg TVM_GETUNICODEFORMAT\n"); FIXME("Unimplemented msg TVM_GETUNICODEFORMAT\n");
return 0; return 0;
case WM_COMMAND: case WM_COMMAND:
@ -3553,7 +3553,7 @@ TREEVIEW_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
default: default:
if (uMsg >= WM_USER) if (uMsg >= WM_USER)
FIXME (treeview, "Unknown msg %04x wp=%08x lp=%08lx\n", FIXME("Unknown msg %04x wp=%08x lp=%08lx\n",
uMsg, wParam, lParam); uMsg, wParam, lParam);
return DefWindowProcA (hwnd, uMsg, wParam, lParam); return DefWindowProcA (hwnd, uMsg, wParam, lParam);
} }
@ -3566,7 +3566,7 @@ TREEVIEW_Register (VOID)
{ {
WNDCLASSA wndClass; WNDCLASSA wndClass;
TRACE (treeview,"\n"); TRACE("\n");
if (GlobalFindAtomA (WC_TREEVIEWA)) return; if (GlobalFindAtomA (WC_TREEVIEWA)) return;

View file

@ -37,7 +37,7 @@
#include "commctrl.h" #include "commctrl.h"
#include "winnls.h" #include "winnls.h"
#include "updown.h" #include "updown.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(updown) DEFAULT_DEBUG_CHANNEL(updown)
@ -64,7 +64,7 @@ DEFAULT_DEBUG_CHANNEL(updown)
static int accelIndex = -1; static int accelIndex = -1;
#define UNKNOWN_PARAM(msg, wParam, lParam) WARN(updown, \ #define UNKNOWN_PARAM(msg, wParam, lParam) WARN(\
"UpDown Ctrl: Unknown parameter(s) for message " #msg \ "UpDown Ctrl: Unknown parameter(s) for message " #msg \
"(%04x): wp=%04x lp=%08lx\n", msg, wParam, lParam); "(%04x): wp=%04x lp=%08lx\n", msg, wParam, lParam);
@ -215,7 +215,7 @@ static BOOL UPDOWN_GetBuddyInt (HWND hwnd)
if(*src || !UPDOWN_InBounds (hwnd, newVal)) if(*src || !UPDOWN_InBounds (hwnd, newVal))
return FALSE; return FALSE;
TRACE(updown, "new value(%d) read from buddy (old=%d)\n", TRACE("new value(%d) read from buddy (old=%d)\n",
newVal, infoPtr->CurVal); newVal, infoPtr->CurVal);
} }
@ -240,7 +240,7 @@ static BOOL UPDOWN_SetBuddyInt (HWND hwnd)
if (!IsWindow(infoPtr->Buddy)) if (!IsWindow(infoPtr->Buddy))
return FALSE; return FALSE;
TRACE(updown, "set new value(%d) to buddy.\n", TRACE("set new value(%d) to buddy.\n",
infoPtr->CurVal); infoPtr->CurVal);
/*if the buddy is a list window, we must set curr index */ /*if the buddy is a list window, we must set curr index */
@ -366,7 +366,7 @@ static BOOL UPDOWN_SetBuddy (HWND hwnd, HWND hwndBud)
GetClassNameA (hwndBud, infoPtr->szBuddyClass, 40); GetClassNameA (hwndBud, infoPtr->szBuddyClass, 40);
if(dwStyle & UDS_ARROWKEYS){ if(dwStyle & UDS_ARROWKEYS){
FIXME(updown, "we need to subclass the buddy to process the arrow keys.\n"); FIXME("we need to subclass the buddy to process the arrow keys.\n");
} }
/* do we need to do any adjustments? */ /* do we need to do any adjustments? */
@ -422,7 +422,7 @@ static void UPDOWN_DoAction (HWND hwnd, int delta, BOOL incr)
int old_val = infoPtr->CurVal; int old_val = infoPtr->CurVal;
NM_UPDOWN ni; NM_UPDOWN ni;
TRACE(updown, "%s by %d\n", incr ? "inc" : "dec", delta); TRACE("%s by %d\n", incr ? "inc" : "dec", delta);
/* check if we can do the modification first */ /* check if we can do the modification first */
delta *= (incr ? 1 : -1) * (infoPtr->MaxVal < infoPtr->MinVal ? -1 : 1); delta *= (incr ? 1 : -1) * (infoPtr->MaxVal < infoPtr->MinVal ? -1 : 1);
@ -592,7 +592,7 @@ static void UPDOWN_HandleMouseEvent (HWND hwnd, UINT msg, POINT pt)
break; break;
default: default:
ERR(updown, "Impossible case!\n"); ERR("Impossible case!\n");
} }
} }
@ -629,7 +629,7 @@ LRESULT WINAPI UpDownWindowProc(HWND hwnd, UINT message, WPARAM wParam,
if (dwStyle & UDS_AUTOBUDDY) if (dwStyle & UDS_AUTOBUDDY)
UPDOWN_SetBuddy (hwnd, GetWindow (hwnd, GW_HWNDPREV)); UPDOWN_SetBuddy (hwnd, GetWindow (hwnd, GW_HWNDPREV));
TRACE(updown, "UpDown Ctrl creation, hwnd=%04x\n", hwnd); TRACE("UpDown Ctrl creation, hwnd=%04x\n", hwnd);
break; break;
case WM_DESTROY: case WM_DESTROY:
@ -638,7 +638,7 @@ LRESULT WINAPI UpDownWindowProc(HWND hwnd, UINT message, WPARAM wParam,
COMCTL32_Free (infoPtr); COMCTL32_Free (infoPtr);
TRACE(updown, "UpDown Ctrl destruction, hwnd=%04x\n", hwnd); TRACE("UpDown Ctrl destruction, hwnd=%04x\n", hwnd);
break; break;
case WM_ENABLE: case WM_ENABLE:
@ -728,7 +728,7 @@ LRESULT WINAPI UpDownWindowProc(HWND hwnd, UINT message, WPARAM wParam,
return temp; return temp;
case UDM_SETACCEL: case UDM_SETACCEL:
TRACE(updown, "UpDown Ctrl new accel info, hwnd=%04x\n", hwnd); TRACE("UpDown Ctrl new accel info, hwnd=%04x\n", hwnd);
if(infoPtr->AccelVect){ if(infoPtr->AccelVect){
COMCTL32_Free (infoPtr->AccelVect); COMCTL32_Free (infoPtr->AccelVect);
infoPtr->AccelCount = 0; infoPtr->AccelCount = 0;
@ -748,7 +748,7 @@ LRESULT WINAPI UpDownWindowProc(HWND hwnd, UINT message, WPARAM wParam,
return infoPtr->Base; return infoPtr->Base;
case UDM_SETBASE: case UDM_SETBASE:
TRACE(updown, "UpDown Ctrl new base(%d), hwnd=%04x\n", TRACE("UpDown Ctrl new base(%d), hwnd=%04x\n",
wParam, hwnd); wParam, hwnd);
if ( !(wParam==10 || wParam==16) || lParam) if ( !(wParam==10 || wParam==16) || lParam)
UNKNOWN_PARAM(UDM_SETBASE, wParam, lParam); UNKNOWN_PARAM(UDM_SETBASE, wParam, lParam);
@ -770,7 +770,7 @@ LRESULT WINAPI UpDownWindowProc(HWND hwnd, UINT message, WPARAM wParam,
temp = infoPtr->Buddy; temp = infoPtr->Buddy;
infoPtr->Buddy = wParam; infoPtr->Buddy = wParam;
UPDOWN_SetBuddy (hwnd, wParam); UPDOWN_SetBuddy (hwnd, wParam);
TRACE(updown, "UpDown Ctrl new buddy(%04x), hwnd=%04x\n", TRACE("UpDown Ctrl new buddy(%04x), hwnd=%04x\n",
infoPtr->Buddy, hwnd); infoPtr->Buddy, hwnd);
return temp; return temp;
@ -784,7 +784,7 @@ LRESULT WINAPI UpDownWindowProc(HWND hwnd, UINT message, WPARAM wParam,
if (wParam || HIWORD(lParam)) if (wParam || HIWORD(lParam))
UNKNOWN_PARAM(UDM_GETPOS, wParam, lParam); UNKNOWN_PARAM(UDM_GETPOS, wParam, lParam);
temp = SLOWORD(lParam); temp = SLOWORD(lParam);
TRACE(updown, "UpDown Ctrl new value(%d), hwnd=%04x\n", TRACE("UpDown Ctrl new value(%d), hwnd=%04x\n",
temp, hwnd); temp, hwnd);
if(!UPDOWN_InBounds(hwnd, temp)){ if(!UPDOWN_InBounds(hwnd, temp)){
if(temp < infoPtr->MinVal) if(temp < infoPtr->MinVal)
@ -809,7 +809,7 @@ LRESULT WINAPI UpDownWindowProc(HWND hwnd, UINT message, WPARAM wParam,
infoPtr->MaxVal = SLOWORD(lParam); /* UD_MINVAL <= Max <= UD_MAXVAL */ infoPtr->MaxVal = SLOWORD(lParam); /* UD_MINVAL <= Max <= UD_MAXVAL */
infoPtr->MinVal = SHIWORD(lParam); /* UD_MINVAL <= Min <= UD_MAXVAL */ infoPtr->MinVal = SHIWORD(lParam); /* UD_MINVAL <= Min <= UD_MAXVAL */
/* |Max-Min| <= UD_MAXVAL */ /* |Max-Min| <= UD_MAXVAL */
TRACE(updown, "UpDown Ctrl new range(%d to %d), hwnd=%04x\n", TRACE("UpDown Ctrl new range(%d to %d), hwnd=%04x\n",
infoPtr->MinVal, infoPtr->MaxVal, hwnd); infoPtr->MinVal, infoPtr->MaxVal, hwnd);
break; break;
@ -825,13 +825,13 @@ LRESULT WINAPI UpDownWindowProc(HWND hwnd, UINT message, WPARAM wParam,
infoPtr->MaxVal = (INT)lParam; infoPtr->MaxVal = (INT)lParam;
if (infoPtr->MaxVal <= infoPtr->MinVal) if (infoPtr->MaxVal <= infoPtr->MinVal)
infoPtr->MaxVal = infoPtr->MinVal + 1; infoPtr->MaxVal = infoPtr->MinVal + 1;
TRACE(updown, "UpDown Ctrl new range(%d to %d), hwnd=%04x\n", TRACE("UpDown Ctrl new range(%d to %d), hwnd=%04x\n",
infoPtr->MinVal, infoPtr->MaxVal, hwnd); infoPtr->MinVal, infoPtr->MaxVal, hwnd);
break; break;
default: default:
if (message >= WM_USER) if (message >= WM_USER)
ERR (updown, "unknown msg %04x wp=%04x lp=%08lx\n", ERR("unknown msg %04x wp=%04x lp=%08lx\n",
message, wParam, lParam); message, wParam, lParam);
return DefWindowProcA (hwnd, message, wParam, lParam); return DefWindowProcA (hwnd, message, wParam, lParam);
} }

View file

@ -8,7 +8,7 @@
#include "winbase.h" #include "winbase.h"
#include "commdlg.h" #include "commdlg.h"
#include "cderr.h" #include "cderr.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(commdlg) DEFAULT_DEBUG_CHANNEL(commdlg)
@ -32,7 +32,7 @@ static int COMDLG32_Attach = 0;
*/ */
BOOL WINAPI COMDLG32_DllEntryPoint(HINSTANCE hInstance, DWORD Reason, LPVOID Reserved) BOOL WINAPI COMDLG32_DllEntryPoint(HINSTANCE hInstance, DWORD Reason, LPVOID Reserved)
{ {
TRACE(commdlg, "(%08x, %08lx, %p)\n", hInstance, Reason, Reserved); TRACE("(%08x, %08lx, %p)\n", hInstance, Reason, Reserved);
switch(Reason) switch(Reason)
{ {
@ -40,7 +40,7 @@ BOOL WINAPI COMDLG32_DllEntryPoint(HINSTANCE hInstance, DWORD Reason, LPVOID Res
COMDLG32_Attach++; COMDLG32_Attach++;
if(COMDLG32_hInstance) if(COMDLG32_hInstance)
{ {
ERR(commdlg, "comdlg32.dll instantiated twice in one address space!\n"); ERR("comdlg32.dll instantiated twice in one address space!\n");
/* /*
* We should return FALSE here, but that will break * We should return FALSE here, but that will break
* most apps that use CreateProcess because we do * most apps that use CreateProcess because we do
@ -56,14 +56,14 @@ BOOL WINAPI COMDLG32_DllEntryPoint(HINSTANCE hInstance, DWORD Reason, LPVOID Res
{ {
if(!(COMDLG32_hInstance16 = LoadLibrary16("commdlg.dll"))) if(!(COMDLG32_hInstance16 = LoadLibrary16("commdlg.dll")))
{ {
ERR(commdlg, "Could not load sibling commdlg.dll\n"); ERR("Could not load sibling commdlg.dll\n");
return FALSE; return FALSE;
} }
} }
if((COMDLG32_TlsIndex = TlsAlloc()) == 0xffffffff) if((COMDLG32_TlsIndex = TlsAlloc()) == 0xffffffff)
{ {
ERR(commdlg, "No space for COMDLG32 TLS\n"); ERR("No space for COMDLG32 TLS\n");
return FALSE; return FALSE;
} }
break; break;
@ -109,7 +109,7 @@ LPVOID COMDLG32_AllocMem(
*/ */
void COMDLG32_SetCommDlgExtendedError(DWORD err) void COMDLG32_SetCommDlgExtendedError(DWORD err)
{ {
TRACE(commdlg, "(%08lx)\n", err); TRACE("(%08lx)\n", err);
TlsSetValue(COMDLG32_TlsIndex, (void *)err); TlsSetValue(COMDLG32_TlsIndex, (void *)err);
} }

View file

@ -18,7 +18,7 @@
#include "dialog.h" #include "dialog.h"
#include "dlgs.h" #include "dlgs.h"
#include "module.h" #include "module.h"
#include "debug.h" #include "debugtools.h"
#include "winproc.h" #include "winproc.h"
#include "cderr.h" #include "cderr.h"
@ -37,7 +37,7 @@ BOOL16 WINAPI ChooseColor16(LPCHOOSECOLOR16 lpChCol)
LPCVOID template; LPCVOID template;
HWND hwndDialog; HWND hwndDialog;
TRACE(commdlg,"ChooseColor\n"); TRACE("ChooseColor\n");
if (!lpChCol) return FALSE; if (!lpChCol) return FALSE;
if (lpChCol->Flags & CC_ENABLETEMPLATEHANDLE) if (lpChCol->Flags & CC_ENABLETEMPLATEHANDLE)
@ -594,7 +594,7 @@ static void CC_PaintColorGraph(HWND16 hDlg)
if (lpp->hdcMem) if (lpp->hdcMem)
BitBlt(hDC,0,0,rect.right,rect.bottom,lpp->hdcMem,0,0,SRCCOPY); BitBlt(hDC,0,0,rect.right,rect.bottom,lpp->hdcMem,0,0,SRCCOPY);
else else
WARN(commdlg,"choose color: hdcMem is not defined\n"); WARN("choose color: hdcMem is not defined\n");
ReleaseDC(hwnd,hDC); ReleaseDC(hwnd,hDC);
} }
} }
@ -815,7 +815,7 @@ static LONG CC_WMInitDialog(HWND16 hDlg, WPARAM16 wParam, LPARAM lParam)
POINT16 point; POINT16 point;
struct CCPRIVATE * lpp; struct CCPRIVATE * lpp;
TRACE(commdlg,"WM_INITDIALOG lParam=%08lX\n", lParam); TRACE("WM_INITDIALOG lParam=%08lX\n", lParam);
lpp=calloc(1,sizeof(struct CCPRIVATE)); lpp=calloc(1,sizeof(struct CCPRIVATE));
lpp->lpcc=(LPCHOOSECOLOR16)lParam; lpp->lpcc=(LPCHOOSECOLOR16)lParam;
@ -910,7 +910,7 @@ static LRESULT CC_WMCommand(HWND16 hDlg, WPARAM16 wParam, LPARAM lParam)
HDC hdc; HDC hdc;
COLORREF *cr; COLORREF *cr;
struct CCPRIVATE * lpp=(struct CCPRIVATE *)GetWindowLongA(hDlg, DWL_USER); struct CCPRIVATE * lpp=(struct CCPRIVATE *)GetWindowLongA(hDlg, DWL_USER);
TRACE(commdlg,"CC_WMCommand wParam=%x lParam=%lx\n",wParam,lParam); TRACE("CC_WMCommand wParam=%x lParam=%lx\n",wParam,lParam);
switch (wParam) switch (wParam)
{ {
case 0x2c2: /* edit notify RGB */ case 0x2c2: /* edit notify RGB */

View file

@ -19,7 +19,7 @@
#include "dlgs.h" #include "dlgs.h"
#include "module.h" #include "module.h"
#include "drive.h" #include "drive.h"
#include "debug.h" #include "debugtools.h"
#include "winproc.h" #include "winproc.h"
#include "cderr.h" #include "cderr.h"
@ -56,13 +56,13 @@ static BOOL FileDlg_Init(void)
if (hFolder == 0 || hFolder2 == 0 || hFloppy == 0 || if (hFolder == 0 || hFolder2 == 0 || hFloppy == 0 ||
hHDisk == 0 || hCDRom == 0 || hNet == 0) hHDisk == 0 || hCDRom == 0 || hNet == 0)
{ {
ERR(commdlg, "Error loading icons !\n"); ERR("Error loading icons !\n");
return FALSE; return FALSE;
} }
fldrInfo = (CURSORICONINFO *) GlobalLock16( hFolder2 ); fldrInfo = (CURSORICONINFO *) GlobalLock16( hFolder2 );
if (!fldrInfo) if (!fldrInfo)
{ {
ERR(commdlg, "Error measuring icons !\n"); ERR("Error measuring icons !\n");
return FALSE; return FALSE;
} }
fldrHeight = fldrInfo -> nHeight; fldrHeight = fldrInfo -> nHeight;
@ -183,7 +183,7 @@ BOOL16 WINAPI GetOpenFileName16(
if (!(lpofn->lpstrFilter)) if (!(lpofn->lpstrFilter))
{ {
str = SEGPTR_ALLOC(sizeof(defaultfilter)); str = SEGPTR_ALLOC(sizeof(defaultfilter));
TRACE(commdlg,"Alloc %p default for Filetype in GetOpenFileName\n",str); TRACE("Alloc %p default for Filetype in GetOpenFileName\n",str);
memcpy(str,defaultfilter,sizeof(defaultfilter)); memcpy(str,defaultfilter,sizeof(defaultfilter));
lpofn->lpstrFilter=SEGPTR_GET(str); lpofn->lpstrFilter=SEGPTR_GET(str);
} }
@ -191,7 +191,7 @@ BOOL16 WINAPI GetOpenFileName16(
if (!(lpofn->lpstrTitle)) if (!(lpofn->lpstrTitle))
{ {
str1 = SEGPTR_ALLOC(strlen(defaultopen)+1); str1 = SEGPTR_ALLOC(strlen(defaultopen)+1);
TRACE(commdlg,"Alloc %p default for Title in GetOpenFileName\n",str1); TRACE("Alloc %p default for Title in GetOpenFileName\n",str1);
strcpy(str1,defaultopen); strcpy(str1,defaultopen);
lpofn->lpstrTitle=SEGPTR_GET(str1); lpofn->lpstrTitle=SEGPTR_GET(str1);
} }
@ -205,14 +205,14 @@ BOOL16 WINAPI GetOpenFileName16(
if (str1) if (str1)
{ {
TRACE(commdlg,"Freeing %p default for Title in GetOpenFileName\n",str1); TRACE("Freeing %p default for Title in GetOpenFileName\n",str1);
SEGPTR_FREE(str1); SEGPTR_FREE(str1);
lpofn->lpstrTitle=0; lpofn->lpstrTitle=0;
} }
if (str) if (str)
{ {
TRACE(commdlg,"Freeing %p default for Filetype in GetOpenFileName\n",str); TRACE("Freeing %p default for Filetype in GetOpenFileName\n",str);
SEGPTR_FREE(str); SEGPTR_FREE(str);
lpofn->lpstrFilter=0; lpofn->lpstrFilter=0;
} }
@ -224,7 +224,7 @@ BOOL16 WINAPI GetOpenFileName16(
FreeResource16( hDlgTmpl ); FreeResource16( hDlgTmpl );
} }
TRACE(commdlg,"return lpstrFile='%s' !\n", TRACE("return lpstrFile='%s' !\n",
(LPSTR)PTR_SEG_TO_LIN(lpofn->lpstrFile)); (LPSTR)PTR_SEG_TO_LIN(lpofn->lpstrFile));
return bRet; return bRet;
} }
@ -346,7 +346,7 @@ BOOL16 WINAPI GetSaveFileName16(
if (!(lpofn->lpstrFilter)) if (!(lpofn->lpstrFilter))
{ {
str = SEGPTR_ALLOC(sizeof(defaultfilter)); str = SEGPTR_ALLOC(sizeof(defaultfilter));
TRACE(commdlg,"Alloc default for Filetype in GetSaveFileName\n"); TRACE("Alloc default for Filetype in GetSaveFileName\n");
memcpy(str,defaultfilter,sizeof(defaultfilter)); memcpy(str,defaultfilter,sizeof(defaultfilter));
lpofn->lpstrFilter=SEGPTR_GET(str); lpofn->lpstrFilter=SEGPTR_GET(str);
} }
@ -354,7 +354,7 @@ BOOL16 WINAPI GetSaveFileName16(
if (!(lpofn->lpstrTitle)) if (!(lpofn->lpstrTitle))
{ {
str1 = SEGPTR_ALLOC(sizeof(defaultsave)+1); str1 = SEGPTR_ALLOC(sizeof(defaultsave)+1);
TRACE(commdlg,"Alloc default for Title in GetSaveFileName\n"); TRACE("Alloc default for Title in GetSaveFileName\n");
strcpy(str1,defaultsave); strcpy(str1,defaultsave);
lpofn->lpstrTitle=SEGPTR_GET(str1); lpofn->lpstrTitle=SEGPTR_GET(str1);
} }
@ -367,14 +367,14 @@ BOOL16 WINAPI GetSaveFileName16(
if (str1) if (str1)
{ {
TRACE(commdlg,"Freeing %p default for Title in GetSaveFileName\n",str1); TRACE("Freeing %p default for Title in GetSaveFileName\n",str1);
SEGPTR_FREE(str1); SEGPTR_FREE(str1);
lpofn->lpstrTitle=0; lpofn->lpstrTitle=0;
} }
if (str) if (str)
{ {
TRACE(commdlg,"Freeing %p default for Filetype in GetSaveFileName\n",str); TRACE("Freeing %p default for Filetype in GetSaveFileName\n",str);
SEGPTR_FREE(str); SEGPTR_FREE(str);
lpofn->lpstrFilter=0; lpofn->lpstrFilter=0;
} }
@ -386,7 +386,7 @@ BOOL16 WINAPI GetSaveFileName16(
FreeResource16( hDlgTmpl ); FreeResource16( hDlgTmpl );
} }
TRACE(commdlg, "return lpstrFile='%s' !\n", TRACE("return lpstrFile='%s' !\n",
(LPSTR)PTR_SEG_TO_LIN(lpofn->lpstrFile)); (LPSTR)PTR_SEG_TO_LIN(lpofn->lpstrFile));
return bRet; return bRet;
} }
@ -441,12 +441,12 @@ static BOOL FILEDLG_ScanDir(HWND16 hWnd, LPSTR newPath)
char* scptr; /* ptr on semi-colon */ char* scptr; /* ptr on semi-colon */
char* filter = buffer; char* filter = buffer;
TRACE(commdlg, "Using filter %s\n", filter); TRACE("Using filter %s\n", filter);
SendMessageA(hlb, LB_RESETCONTENT, 0, 0); SendMessageA(hlb, LB_RESETCONTENT, 0, 0);
while (filter) { while (filter) {
scptr = strchr(filter, ';'); scptr = strchr(filter, ';');
if (scptr) *scptr = 0; if (scptr) *scptr = 0;
TRACE(commdlg, "Using file spec %s\n", filter); TRACE("Using file spec %s\n", filter);
if (SendMessageA(hlb, LB_DIR, 0, (LPARAM)filter) == LB_ERR) if (SendMessageA(hlb, LB_DIR, 0, (LPARAM)filter) == LB_ERR)
return FALSE; return FALSE;
if (scptr) *scptr = ';'; if (scptr) *scptr = ';';
@ -700,7 +700,7 @@ static LONG FILEDLG_WMInitDialog(HWND16 hWnd, WPARAM16 wParam, LPARAM lParam)
{ {
pstr = (LPSTR)PTR_SEG_TO_LIN(lpofn->lpstrCustomFilter); pstr = (LPSTR)PTR_SEG_TO_LIN(lpofn->lpstrCustomFilter);
n = 0; n = 0;
TRACE(commdlg,"lpstrCustomFilter = %p\n", pstr); TRACE("lpstrCustomFilter = %p\n", pstr);
while(*pstr) while(*pstr)
{ {
old_pstr = pstr; old_pstr = pstr;
@ -708,7 +708,7 @@ static LONG FILEDLG_WMInitDialog(HWND16 hWnd, WPARAM16 wParam, LPARAM lParam)
(LPARAM)lpofn->lpstrCustomFilter + n ); (LPARAM)lpofn->lpstrCustomFilter + n );
n += strlen(pstr) + 1; n += strlen(pstr) + 1;
pstr += strlen(pstr) + 1; pstr += strlen(pstr) + 1;
TRACE(commdlg,"add str='%s' " TRACE("add str='%s' "
"associated to '%s'\n", old_pstr, pstr); "associated to '%s'\n", old_pstr, pstr);
SendDlgItemMessage16(hWnd, cmb1, CB_SETITEMDATA16, i, (LPARAM)pstr); SendDlgItemMessage16(hWnd, cmb1, CB_SETITEMDATA16, i, (LPARAM)pstr);
n += strlen(pstr) + 1; n += strlen(pstr) + 1;
@ -725,7 +725,7 @@ static LONG FILEDLG_WMInitDialog(HWND16 hWnd, WPARAM16 wParam, LPARAM lParam)
(LPARAM)lpofn->lpstrFilter + n ); (LPARAM)lpofn->lpstrFilter + n );
n += strlen(pstr) + 1; n += strlen(pstr) + 1;
pstr += strlen(pstr) + 1; pstr += strlen(pstr) + 1;
TRACE(commdlg,"add str='%s' " TRACE("add str='%s' "
"associated to '%s'\n", old_pstr, pstr); "associated to '%s'\n", old_pstr, pstr);
SendDlgItemMessage16(hWnd, cmb1, CB_SETITEMDATA16, i, (LPARAM)pstr); SendDlgItemMessage16(hWnd, cmb1, CB_SETITEMDATA16, i, (LPARAM)pstr);
n += strlen(pstr) + 1; n += strlen(pstr) + 1;
@ -739,7 +739,7 @@ static LONG FILEDLG_WMInitDialog(HWND16 hWnd, WPARAM16 wParam, LPARAM lParam)
strncpy(tmpstr, FILEDLG_GetFileType(PTR_SEG_TO_LIN(lpofn->lpstrCustomFilter), strncpy(tmpstr, FILEDLG_GetFileType(PTR_SEG_TO_LIN(lpofn->lpstrCustomFilter),
PTR_SEG_TO_LIN(lpofn->lpstrFilter), lpofn->nFilterIndex - 1),511); PTR_SEG_TO_LIN(lpofn->lpstrFilter), lpofn->nFilterIndex - 1),511);
tmpstr[511]=0; tmpstr[511]=0;
TRACE(commdlg,"nFilterIndex = %ld, SetText of edt1 to '%s'\n", TRACE("nFilterIndex = %ld, SetText of edt1 to '%s'\n",
lpofn->nFilterIndex, tmpstr); lpofn->nFilterIndex, tmpstr);
SetDlgItemTextA( hWnd, edt1, tmpstr ); SetDlgItemTextA( hWnd, edt1, tmpstr );
/* get drive list */ /* get drive list */
@ -759,7 +759,7 @@ static LONG FILEDLG_WMInitDialog(HWND16 hWnd, WPARAM16 wParam, LPARAM lParam)
if (!FILEDLG_ScanDir(hWnd, tmpstr)) { if (!FILEDLG_ScanDir(hWnd, tmpstr)) {
*tmpstr = 0; *tmpstr = 0;
if (!FILEDLG_ScanDir(hWnd, tmpstr)) if (!FILEDLG_ScanDir(hWnd, tmpstr))
WARN(commdlg, "Couldn't read initial directory %s!\n",tmpstr); WARN("Couldn't read initial directory %s!\n",tmpstr);
} }
/* select current drive in combo 2, omit missing drives */ /* select current drive in combo 2, omit missing drives */
for(i=0, n=-1; i<=DRIVE_GetCurrentDrive(); i++) for(i=0, n=-1; i<=DRIVE_GetCurrentDrive(); i++)
@ -860,7 +860,7 @@ static LRESULT FILEDLG_WMCommand(HWND16 hWnd, WPARAM16 wParam, LPARAM lParam)
if (lRet == LB_ERR) if (lRet == LB_ERR)
return TRUE; return TRUE;
pstr = (LPSTR)SendDlgItemMessage16(hWnd, cmb1, CB_GETITEMDATA16, lRet, 0); pstr = (LPSTR)SendDlgItemMessage16(hWnd, cmb1, CB_GETITEMDATA16, lRet, 0);
TRACE(commdlg,"Selected filter : %s\n", pstr); TRACE("Selected filter : %s\n", pstr);
SetDlgItemTextA( hWnd, edt1, pstr ); SetDlgItemTextA( hWnd, edt1, pstr );
FILEDLG_ScanDir(hWnd, tmpstr); FILEDLG_ScanDir(hWnd, tmpstr);
in_update=TRUE; in_update=TRUE;
@ -884,7 +884,7 @@ static LRESULT FILEDLG_WMCommand(HWND16 hWnd, WPARAM16 wParam, LPARAM lParam)
strcpy(tmpstr2, tmpstr); strcpy(tmpstr2, tmpstr);
*tmpstr=0; *tmpstr=0;
} }
TRACE(commdlg,"tmpstr=%s, tmpstr2=%s\n", tmpstr, tmpstr2); TRACE("tmpstr=%s, tmpstr2=%s\n", tmpstr, tmpstr2);
SetDlgItemTextA( hWnd, edt1, tmpstr2 ); SetDlgItemTextA( hWnd, edt1, tmpstr2 );
FILEDLG_ScanDir(hWnd, tmpstr); FILEDLG_ScanDir(hWnd, tmpstr);
return TRUE; return TRUE;
@ -897,7 +897,7 @@ static LRESULT FILEDLG_WMCommand(HWND16 hWnd, WPARAM16 wParam, LPARAM lParam)
lRet = SendDlgItemMessage16(hWnd, cmb1, CB_GETCURSEL16, 0, 0); lRet = SendDlgItemMessage16(hWnd, cmb1, CB_GETCURSEL16, 0, 0);
if (lRet == LB_ERR) return TRUE; if (lRet == LB_ERR) return TRUE;
lpofn->nFilterIndex = lRet + 1; lpofn->nFilterIndex = lRet + 1;
TRACE(commdlg,"lpofn->nFilterIndex=%ld\n", lpofn->nFilterIndex); TRACE("lpofn->nFilterIndex=%ld\n", lpofn->nFilterIndex);
lstrcpynA(tmpstr2, lstrcpynA(tmpstr2,
FILEDLG_GetFileType(PTR_SEG_TO_LIN(lpofn->lpstrCustomFilter), FILEDLG_GetFileType(PTR_SEG_TO_LIN(lpofn->lpstrCustomFilter),
PTR_SEG_TO_LIN(lpofn->lpstrFilter), PTR_SEG_TO_LIN(lpofn->lpstrFilter),

View file

@ -10,7 +10,7 @@
#include "wine/winestring.h" #include "wine/winestring.h"
#include "winbase.h" #include "winbase.h"
#include "commdlg.h" #include "commdlg.h"
#include "debug.h" #include "debugtools.h"
#include "heap.h" /* Has to go */ #include "heap.h" /* Has to go */
@ -26,7 +26,7 @@ short WINAPI GetFileTitleA(LPCSTR lpFile, LPSTR lpTitle, UINT cbBuf)
{ {
int i, len; int i, len;
TRACE(commdlg,"(%p %p %d); \n", lpFile, lpTitle, cbBuf); TRACE("(%p %p %d); \n", lpFile, lpTitle, cbBuf);
if(lpFile == NULL || lpTitle == NULL) if(lpFile == NULL || lpTitle == NULL)
return -1; return -1;
@ -56,7 +56,7 @@ short WINAPI GetFileTitleA(LPCSTR lpFile, LPSTR lpTitle, UINT cbBuf)
if(i == -1) if(i == -1)
i++; i++;
TRACE(commdlg,"---> '%s' \n", &lpFile[i]); TRACE("---> '%s' \n", &lpFile[i]);
len = strlen(lpFile+i)+1; len = strlen(lpFile+i)+1;
if(cbBuf < len) if(cbBuf < len)

View file

@ -16,7 +16,7 @@
#include "dialog.h" #include "dialog.h"
#include "dlgs.h" #include "dlgs.h"
#include "module.h" #include "module.h"
#include "debug.h" #include "debugtools.h"
#include "winproc.h" #include "winproc.h"
#include "cderr.h" #include "cderr.h"
@ -39,7 +39,7 @@ HWND16 WINAPI FindText16( SEGPTR find )
* For now, only the standard dialog works. * For now, only the standard dialog works.
*/ */
if (lpFind->Flags & (FR_ENABLETEMPLATE | FR_ENABLETEMPLATEHANDLE | if (lpFind->Flags & (FR_ENABLETEMPLATE | FR_ENABLETEMPLATEHANDLE |
FR_ENABLEHOOK)) FIXME(commdlg, ": unimplemented flag (ignored)\n"); FR_ENABLEHOOK)) FIXME(": unimplemented flag (ignored)\n");
if (!(hResInfo = FindResourceA(COMMDLG_hInstance32, MAKEINTRESOURCEA(FINDDLGORD), RT_DIALOGA))) if (!(hResInfo = FindResourceA(COMMDLG_hInstance32, MAKEINTRESOURCEA(FINDDLGORD), RT_DIALOGA)))
{ {
COMDLG32_SetCommDlgExtendedError(CDERR_FINDRESFAILURE); COMDLG32_SetCommDlgExtendedError(CDERR_FINDRESFAILURE);
@ -73,7 +73,7 @@ HWND16 WINAPI ReplaceText16( SEGPTR find )
* and make CommDlgExtendedError() return the error condition. * and make CommDlgExtendedError() return the error condition.
*/ */
if (lpFind->Flags & (FR_ENABLETEMPLATE | FR_ENABLETEMPLATEHANDLE | if (lpFind->Flags & (FR_ENABLETEMPLATE | FR_ENABLETEMPLATEHANDLE |
FR_ENABLEHOOK)) FIXME(commdlg, ": unimplemented flag (ignored)\n"); FR_ENABLEHOOK)) FIXME(": unimplemented flag (ignored)\n");
if (!(hResInfo = FindResourceA(COMMDLG_hInstance32, MAKEINTRESOURCEA(REPLACEDLGORD), RT_DIALOGA))) if (!(hResInfo = FindResourceA(COMMDLG_hInstance32, MAKEINTRESOURCEA(REPLACEDLGORD), RT_DIALOGA)))
{ {
COMDLG32_SetCommDlgExtendedError(CDERR_FINDRESFAILURE); COMDLG32_SetCommDlgExtendedError(CDERR_FINDRESFAILURE);

View file

@ -10,7 +10,7 @@
#include "commdlg.h" #include "commdlg.h"
#include "cderr.h" #include "cderr.h"
#include "dlgs.h" #include "dlgs.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(commdlg) DEFAULT_DEBUG_CHANNEL(commdlg)
@ -158,7 +158,7 @@ BOOL CALLBACK COMDLG32_FindReplaceDlgProc(HWND hDlgWnd, UINT iMsg, WPARAM wParam
pdata = (COMDLG32_FR_Data *)lParam; pdata = (COMDLG32_FR_Data *)lParam;
if(!SetPropA(hDlgWnd, (LPSTR)COMDLG32_Atom, (HANDLE)pdata)) if(!SetPropA(hDlgWnd, (LPSTR)COMDLG32_Atom, (HANDLE)pdata))
{ {
ERR(commdlg, "Could not Set prop; invent a gracefull exit?...\n"); ERR("Could not Set prop; invent a gracefull exit?...\n");
DestroyWindow(hDlgWnd); DestroyWindow(hDlgWnd);
return FALSE; return FALSE;
} }
@ -237,12 +237,12 @@ BOOL CALLBACK COMDLG32_FindReplaceDlgProc(HWND hDlgWnd, UINT iMsg, WPARAM wParam
case WM_HELP: case WM_HELP:
/* Heeeeelp! */ /* Heeeeelp! */
FIXME(commdlg, "Got WM_HELP. Who is gonna supply it?\n"); FIXME("Got WM_HELP. Who is gonna supply it?\n");
break; break;
case WM_CONTEXTMENU: case WM_CONTEXTMENU:
/* Heeeeelp! */ /* Heeeeelp! */
FIXME(commdlg, "Got WM_CONTEXTMENU. Who is gonna supply it?\n"); FIXME("Got WM_CONTEXTMENU. Who is gonna supply it?\n");
break; break;
/* FIXME: Handle F1 help */ /* FIXME: Handle F1 help */
@ -348,7 +348,7 @@ HWND COMDLG32_FR_DoFindReplace(
DWORD error; DWORD error;
LPDLGTEMPLATEW rcs; LPDLGTEMPLATEW rcs;
TRACE(commdlg, "hInst=%08x, Flags=%08lx\n", pdata->fr.hInstance, pdata->fr.Flags); TRACE("hInst=%08x, Flags=%08lx\n", pdata->fr.hInstance, pdata->fr.Flags);
if(!(pdata->fr.Flags & FR_ENABLETEMPLATEHANDLE)) if(!(pdata->fr.Flags & FR_ENABLETEMPLATEHANDLE))
{ {
@ -423,7 +423,7 @@ HWND WINAPI FindTextA(
) { ) {
COMDLG32_FR_Data *pdata; COMDLG32_FR_Data *pdata;
TRACE(commdlg, "LPFINDREPLACE=%p\n", pfr); TRACE("LPFINDREPLACE=%p\n", pfr);
if(!COMDLG32_FR_CheckPartial(pfr, FALSE)) if(!COMDLG32_FR_CheckPartial(pfr, FALSE))
return 0; return 0;
@ -447,7 +447,7 @@ HWND WINAPI ReplaceTextA(
) { ) {
COMDLG32_FR_Data *pdata; COMDLG32_FR_Data *pdata;
TRACE(commdlg, "LPFINDREPLACE=%p\n", pfr); TRACE("LPFINDREPLACE=%p\n", pfr);
if(!COMDLG32_FR_CheckPartial(pfr, TRUE)) if(!COMDLG32_FR_CheckPartial(pfr, TRUE))
return 0; return 0;
@ -472,7 +472,7 @@ HWND WINAPI FindTextW(
) { ) {
COMDLG32_FR_Data *pdata; COMDLG32_FR_Data *pdata;
TRACE(commdlg, "LPFINDREPLACE=%p\n", pfr); TRACE("LPFINDREPLACE=%p\n", pfr);
if(!COMDLG32_FR_CheckPartial((LPFINDREPLACEA)pfr, FALSE)) if(!COMDLG32_FR_CheckPartial((LPFINDREPLACEA)pfr, FALSE))
return 0; return 0;
@ -500,7 +500,7 @@ HWND WINAPI ReplaceTextW(
) { ) {
COMDLG32_FR_Data *pdata; COMDLG32_FR_Data *pdata;
TRACE(commdlg, "LPFINDREPLACE=%p\n", pfr); TRACE("LPFINDREPLACE=%p\n", pfr);
if(!COMDLG32_FR_CheckPartial((LPFINDREPLACEA)pfr, FALSE)) if(!COMDLG32_FR_CheckPartial((LPFINDREPLACEA)pfr, FALSE))
return 0; return 0;

View file

@ -18,7 +18,7 @@
#include "dialog.h" #include "dialog.h"
#include "dlgs.h" #include "dlgs.h"
#include "module.h" #include "module.h"
#include "debug.h" #include "debugtools.h"
#include "font.h" #include "font.h"
#include "winproc.h" #include "winproc.h"
#include "cderr.h" #include "cderr.h"
@ -69,7 +69,7 @@ BOOL16 WINAPI ChooseFont16(LPCHOOSEFONT16 lpChFont)
cf32a.lpLogFont=&lf32a; cf32a.lpLogFont=&lf32a;
CFn_CHOOSEFONT16to32A(lpChFont, &cf32a); CFn_CHOOSEFONT16to32A(lpChFont, &cf32a);
TRACE(commdlg,"ChooseFont\n"); TRACE("ChooseFont\n");
if (!lpChFont) return FALSE; if (!lpChFont) return FALSE;
if (lpChFont->Flags & CF_ENABLETEMPLATEHANDLE) if (lpChFont->Flags & CF_ENABLETEMPLATEHANDLE)
@ -157,7 +157,7 @@ BOOL WINAPI ChooseFontA(LPCHOOSEFONTA lpChFont)
} }
if (lpChFont->Flags & (CF_SELECTSCRIPT | CF_NOVERTFONTS | CF_ENABLETEMPLATE | if (lpChFont->Flags & (CF_SELECTSCRIPT | CF_NOVERTFONTS | CF_ENABLETEMPLATE |
CF_ENABLETEMPLATEHANDLE)) FIXME(commdlg, ": unimplemented flag (ignored)\n"); CF_ENABLETEMPLATEHANDLE)) FIXME(": unimplemented flag (ignored)\n");
hwndDialog = DIALOG_CreateIndirect(hInst, template, TRUE, lpChFont->hwndOwner, hwndDialog = DIALOG_CreateIndirect(hInst, template, TRUE, lpChFont->hwndOwner,
(DLGPROC16)FormatCharDlgProcA, (LPARAM)lpChFont, WIN_PROC_32A ); (DLGPROC16)FormatCharDlgProcA, (LPARAM)lpChFont, WIN_PROC_32A );
if (hwndDialog) bRet = DIALOG_DoDialogBox(hwndDialog, lpChFont->hwndOwner); if (hwndDialog) bRet = DIALOG_DoDialogBox(hwndDialog, lpChFont->hwndOwner);
@ -190,7 +190,7 @@ BOOL WINAPI ChooseFontW(LPCHOOSEFONTW lpChFont)
} }
if (lpChFont->Flags & (CF_SELECTSCRIPT | CF_NOVERTFONTS | CF_ENABLETEMPLATE | if (lpChFont->Flags & (CF_SELECTSCRIPT | CF_NOVERTFONTS | CF_ENABLETEMPLATE |
CF_ENABLETEMPLATEHANDLE)) FIXME(commdlg, ": unimplemented flag (ignored)\n"); CF_ENABLETEMPLATEHANDLE)) FIXME(": unimplemented flag (ignored)\n");
memcpy(&cf32a, lpChFont, sizeof(cf32a)); memcpy(&cf32a, lpChFont, sizeof(cf32a));
memcpy(&lf32a, lpChFont->lpLogFont, sizeof(LOGFONTA)); memcpy(&lf32a, lpChFont->lpLogFont, sizeof(LOGFONTA));
lstrcpynWtoA(lf32a.lfFaceName, lpChFont->lpLogFont->lfFaceName, LF_FACESIZE); lstrcpynWtoA(lf32a.lfFaceName, lpChFont->lpLogFont->lfFaceName, LF_FACESIZE);
@ -253,7 +253,7 @@ static INT AddFontFamily(LPLOGFONTA lplf, UINT nFontType,
int i; int i;
WORD w; WORD w;
TRACE(commdlg,"font=%s (nFontType=%d)\n", lplf->lfFaceName,nFontType); TRACE("font=%s (nFontType=%d)\n", lplf->lfFaceName,nFontType);
if (lpcf->Flags & CF_FIXEDPITCHONLY) if (lpcf->Flags & CF_FIXEDPITCHONLY)
if (!(lplf->lfPitchAndFamily & FIXED_PITCH)) if (!(lplf->lfPitchAndFamily & FIXED_PITCH))
@ -398,8 +398,8 @@ INT AddFontStyle(LPLOGFONTA lplf, UINT nFontType,
{ {
int i; int i;
TRACE(commdlg,"(nFontType=%d)\n",nFontType); TRACE("(nFontType=%d)\n",nFontType);
TRACE(commdlg," %s h=%ld w=%ld e=%ld o=%ld wg=%ld i=%d u=%d s=%d" TRACE(" %s h=%ld w=%ld e=%ld o=%ld wg=%ld i=%d u=%d s=%d"
" ch=%d op=%d cp=%d q=%d pf=%xh\n", " ch=%d op=%d cp=%d q=%d pf=%xh\n",
lplf->lfFaceName,lplf->lfHeight,lplf->lfWidth, lplf->lfFaceName,lplf->lfHeight,lplf->lfWidth,
lplf->lfEscapement,lplf->lfOrientation, lplf->lfEscapement,lplf->lfOrientation,
@ -469,11 +469,11 @@ LRESULT CFn_WMInitDialog(HWND hDlg, WPARAM wParam, LPARAM lParam,
SetWindowLongA(hDlg, DWL_USER, lParam); SetWindowLongA(hDlg, DWL_USER, lParam);
lpxx=lpcf->lpLogFont; lpxx=lpcf->lpLogFont;
TRACE(commdlg,"WM_INITDIALOG lParam=%08lX\n", lParam); TRACE("WM_INITDIALOG lParam=%08lX\n", lParam);
if (lpcf->lStructSize != sizeof(CHOOSEFONTA)) if (lpcf->lStructSize != sizeof(CHOOSEFONTA))
{ {
ERR(commdlg,"structure size failure !!!\n"); ERR("structure size failure !!!\n");
EndDialog (hDlg, 0); EndDialog (hDlg, 0);
return FALSE; return FALSE;
} }
@ -517,7 +517,7 @@ LRESULT CFn_WMInitDialog(HWND hDlg, WPARAM wParam, LPARAM lParam,
s.hWnd1=GetDlgItem(hDlg,cmb1); s.hWnd1=GetDlgItem(hDlg,cmb1);
s.lpcf32a=lpcf; s.lpcf32a=lpcf;
if (!EnumFontFamiliesA(hdc, NULL, FontFamilyEnumProc, (LPARAM)&s)) if (!EnumFontFamiliesA(hdc, NULL, FontFamilyEnumProc, (LPARAM)&s))
TRACE(commdlg,"EnumFontFamilies returns 0\n"); TRACE("EnumFontFamilies returns 0\n");
if (lpcf->Flags & CF_INITTOLOGFONTSTRUCT) if (lpcf->Flags & CF_INITTOLOGFONTSTRUCT)
{ {
/* look for fitting font name in combobox1 */ /* look for fitting font name in combobox1 */
@ -564,7 +564,7 @@ LRESULT CFn_WMInitDialog(HWND hDlg, WPARAM wParam, LPARAM lParam,
} }
else else
{ {
WARN(commdlg,"HDC failure !!!\n"); WARN("HDC failure !!!\n");
EndDialog (hDlg, 0); EndDialog (hDlg, 0);
return FALSE; return FALSE;
} }
@ -721,7 +721,7 @@ LRESULT CFn_WMCommand(HWND hDlg, WPARAM wParam, LPARAM lParam,
HDC hdc; HDC hdc;
LPLOGFONTA lpxx=lpcf->lpLogFont; LPLOGFONTA lpxx=lpcf->lpLogFont;
TRACE(commdlg,"WM_COMMAND wParam=%08lX lParam=%08lX\n", (LONG)wParam, lParam); TRACE("WM_COMMAND wParam=%08lX lParam=%08lX\n", (LONG)wParam, lParam);
switch (LOWORD(wParam)) switch (LOWORD(wParam))
{ {
case cmb1:if (HIWORD(wParam)==CBN_SELCHANGE) case cmb1:if (HIWORD(wParam)==CBN_SELCHANGE)
@ -739,7 +739,7 @@ LRESULT CFn_WMCommand(HWND hDlg, WPARAM wParam, LPARAM lParam,
char str[256]; char str[256];
SendDlgItemMessageA(hDlg, cmb1, CB_GETLBTEXT, i, SendDlgItemMessageA(hDlg, cmb1, CB_GETLBTEXT, i,
(LPARAM)str); (LPARAM)str);
TRACE(commdlg,"WM_COMMAND/cmb1 =>%s\n",str); TRACE("WM_COMMAND/cmb1 =>%s\n",str);
s.hWnd1=GetDlgItem(hDlg, cmb2); s.hWnd1=GetDlgItem(hDlg, cmb2);
s.hWnd2=GetDlgItem(hDlg, cmb3); s.hWnd2=GetDlgItem(hDlg, cmb3);
s.lpcf32a=lpcf; s.lpcf32a=lpcf;
@ -751,7 +751,7 @@ LRESULT CFn_WMCommand(HWND hDlg, WPARAM wParam, LPARAM lParam,
} }
else else
{ {
WARN(commdlg,"HDC failure !!!\n"); WARN("HDC failure !!!\n");
EndDialog (hDlg, 0); EndDialog (hDlg, 0);
return TRUE; return TRUE;
} }
@ -762,7 +762,7 @@ LRESULT CFn_WMCommand(HWND hDlg, WPARAM wParam, LPARAM lParam,
case cmb3:if (HIWORD(wParam)==CBN_SELCHANGE || HIWORD(wParam)== BN_CLICKED ) case cmb3:if (HIWORD(wParam)==CBN_SELCHANGE || HIWORD(wParam)== BN_CLICKED )
{ {
char str[256]; char str[256];
TRACE(commdlg,"WM_COMMAND/cmb2,3 =%08lX\n", lParam); TRACE("WM_COMMAND/cmb2,3 =%08lX\n", lParam);
i=SendDlgItemMessageA(hDlg,cmb1,CB_GETCURSEL,0,0); i=SendDlgItemMessageA(hDlg,cmb1,CB_GETCURSEL,0,0);
if (i==CB_ERR) if (i==CB_ERR)
i=GetDlgItemTextA( hDlg, cmb1, str, 256 ); i=GetDlgItemTextA( hDlg, cmb1, str, 256 );
@ -884,7 +884,7 @@ LRESULT WINAPI FormatCharDlgProc16(HWND16 hDlg, UINT16 message, WPARAM16 wParam,
lpcf32a=(LPCHOOSEFONTA)lpcf->lpTemplateName; lpcf32a=(LPCHOOSEFONTA)lpcf->lpTemplateName;
if (!CFn_WMInitDialog(hDlg, wParam, lParam, lpcf32a)) if (!CFn_WMInitDialog(hDlg, wParam, lParam, lpcf32a))
{ {
TRACE(commdlg, "CFn_WMInitDialog returned FALSE\n"); TRACE("CFn_WMInitDialog returned FALSE\n");
return FALSE; return FALSE;
} }
if (CFn_HookCallChk(lpcf)) if (CFn_HookCallChk(lpcf))
@ -910,9 +910,9 @@ LRESULT WINAPI FormatCharDlgProc16(HWND16 hDlg, UINT16 message, WPARAM16 wParam,
res=CFn_WMDestroy(hDlg, wParam32, lParam); res=CFn_WMDestroy(hDlg, wParam32, lParam);
break; break;
case WM_CHOOSEFONT_GETLOGFONT: case WM_CHOOSEFONT_GETLOGFONT:
TRACE(commdlg,"WM_CHOOSEFONT_GETLOGFONT lParam=%08lX\n", TRACE("WM_CHOOSEFONT_GETLOGFONT lParam=%08lX\n",
lParam); lParam);
FIXME(commdlg, "current logfont back to caller\n"); FIXME("current logfont back to caller\n");
break; break;
} }
WINPROC_UnmapMsg16To32A(hDlg,uMsg32, wParam32, lParam, res); WINPROC_UnmapMsg16To32A(hDlg,uMsg32, wParam32, lParam, res);
@ -942,7 +942,7 @@ LRESULT WINAPI FormatCharDlgProcA(HWND hDlg, UINT uMsg, WPARAM wParam,
lpcf=(LPCHOOSEFONTA)lParam; lpcf=(LPCHOOSEFONTA)lParam;
if (!CFn_WMInitDialog(hDlg, wParam, lParam, lpcf)) if (!CFn_WMInitDialog(hDlg, wParam, lParam, lpcf))
{ {
TRACE(commdlg, "CFn_WMInitDialog returned FALSE\n"); TRACE("CFn_WMInitDialog returned FALSE\n");
return FALSE; return FALSE;
} }
if (CFn_HookCallChk32(lpcf)) if (CFn_HookCallChk32(lpcf))
@ -961,9 +961,9 @@ LRESULT WINAPI FormatCharDlgProcA(HWND hDlg, UINT uMsg, WPARAM wParam,
case WM_DESTROY: case WM_DESTROY:
return CFn_WMDestroy(hDlg, wParam, lParam); return CFn_WMDestroy(hDlg, wParam, lParam);
case WM_CHOOSEFONT_GETLOGFONT: case WM_CHOOSEFONT_GETLOGFONT:
TRACE(commdlg,"WM_CHOOSEFONT_GETLOGFONT lParam=%08lX\n", TRACE("WM_CHOOSEFONT_GETLOGFONT lParam=%08lX\n",
lParam); lParam);
FIXME(commdlg, "current logfont back to caller\n"); FIXME("current logfont back to caller\n");
break; break;
} }
return res; return res;
@ -994,7 +994,7 @@ LRESULT WINAPI FormatCharDlgProcW(HWND hDlg, UINT uMsg, WPARAM wParam,
lpcf32a=(LPCHOOSEFONTA)lpcf32w->lpTemplateName; lpcf32a=(LPCHOOSEFONTA)lpcf32w->lpTemplateName;
if (!CFn_WMInitDialog(hDlg, wParam, lParam, lpcf32a)) if (!CFn_WMInitDialog(hDlg, wParam, lParam, lpcf32a))
{ {
TRACE(commdlg, "CFn_WMInitDialog returned FALSE\n"); TRACE("CFn_WMInitDialog returned FALSE\n");
return FALSE; return FALSE;
} }
if (CFn_HookCallChk32((LPCHOOSEFONTA)lpcf32w)) if (CFn_HookCallChk32((LPCHOOSEFONTA)lpcf32w))
@ -1014,9 +1014,9 @@ LRESULT WINAPI FormatCharDlgProcW(HWND hDlg, UINT uMsg, WPARAM wParam,
case WM_DESTROY: case WM_DESTROY:
return CFn_WMDestroy(hDlg, wParam, lParam); return CFn_WMDestroy(hDlg, wParam, lParam);
case WM_CHOOSEFONT_GETLOGFONT: case WM_CHOOSEFONT_GETLOGFONT:
TRACE(commdlg,"WM_CHOOSEFONT_GETLOGFONT lParam=%08lX\n", TRACE("WM_CHOOSEFONT_GETLOGFONT lParam=%08lX\n",
lParam); lParam);
FIXME(commdlg, "current logfont back to caller\n"); FIXME("current logfont back to caller\n");
break; break;
} }
return res; return res;

View file

@ -9,7 +9,7 @@
#include "winbase.h" #include "winbase.h"
#include "commdlg.h" #include "commdlg.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(commdlg) DEFAULT_DEBUG_CHANNEL(commdlg)
@ -28,14 +28,14 @@ static int COMMDLG_Attach = 0;
*/ */
BOOL WINAPI COMMDLG_DllEntryPoint(DWORD Reason, HINSTANCE16 hInst, WORD ds, WORD HeapSize, DWORD res1, WORD res2) BOOL WINAPI COMMDLG_DllEntryPoint(DWORD Reason, HINSTANCE16 hInst, WORD ds, WORD HeapSize, DWORD res1, WORD res2)
{ {
TRACE(commdlg, "(%08lx, %04x, %04x, %04x, %08lx, %04x)\n", Reason, hInst, ds, HeapSize, res1, res2); TRACE("(%08lx, %04x, %04x, %04x, %08lx, %04x)\n", Reason, hInst, ds, HeapSize, res1, res2);
switch(Reason) switch(Reason)
{ {
case DLL_PROCESS_ATTACH: case DLL_PROCESS_ATTACH:
COMMDLG_Attach++; COMMDLG_Attach++;
if(COMMDLG_hInstance) if(COMMDLG_hInstance)
{ {
ERR(commdlg, "commdlg.dll instantiated twice!\n"); ERR("commdlg.dll instantiated twice!\n");
/* /*
* We should return FALSE here, but that will break * We should return FALSE here, but that will break
* most apps that use CreateProcess because we do * most apps that use CreateProcess because we do
@ -49,7 +49,7 @@ BOOL WINAPI COMMDLG_DllEntryPoint(DWORD Reason, HINSTANCE16 hInst, WORD ds, WORD
{ {
if(!(COMMDLG_hInstance32 = LoadLibraryA("comdlg32.dll"))) if(!(COMMDLG_hInstance32 = LoadLibraryA("comdlg32.dll")))
{ {
ERR(commdlg, "Could not load sibling comdlg32.dll\n"); ERR("Could not load sibling comdlg32.dll\n");
return FALSE; return FALSE;
} }
} }

View file

@ -18,7 +18,7 @@
#include "dialog.h" #include "dialog.h"
#include "dlgs.h" #include "dlgs.h"
#include "module.h" #include "module.h"
#include "debug.h" #include "debugtools.h"
#include "winproc.h" #include "winproc.h"
#include "cderr.h" #include "cderr.h"
#include "winspool.h" #include "winspool.h"
@ -40,7 +40,7 @@ BOOL16 WINAPI PrintDlg16( SEGPTR printdlg )
LPSTR rscname; LPSTR rscname;
LPPRINTDLG16 lpPrint = (LPPRINTDLG16)PTR_SEG_TO_LIN(printdlg); LPPRINTDLG16 lpPrint = (LPPRINTDLG16)PTR_SEG_TO_LIN(printdlg);
TRACE(commdlg,"(%p) -- Flags=%08lX\n", lpPrint, lpPrint->Flags ); TRACE("(%p) -- Flags=%08lX\n", lpPrint, lpPrint->Flags );
if (lpPrint->Flags & PD_RETURNDEFAULT) if (lpPrint->Flags & PD_RETURNDEFAULT)
/* FIXME: should fill lpPrint->hDevMode and lpPrint->hDevNames here */ /* FIXME: should fill lpPrint->hDevMode and lpPrint->hDevNames here */
@ -130,7 +130,7 @@ BOOL WINAPI PrintDlgA(
DWORD CopyOfEnumBytesNeeded; DWORD CopyOfEnumBytesNeeded;
PRINT_PTRA PrintStructures; PRINT_PTRA PrintStructures;
FIXME(commdlg, "KVG (%p): stub\n", lppd); FIXME("KVG (%p): stub\n", lppd);
PrintStructures.lpPrintDlg = lppd; PrintStructures.lpPrintDlg = lppd;
if (!(hResInfo = FindResourceA(COMDLG32_hInstance, "PRINT32", RT_DIALOGA))) if (!(hResInfo = FindResourceA(COMDLG32_hInstance, "PRINT32", RT_DIALOGA)))
@ -171,7 +171,7 @@ BOOL WINAPI PrintDlgA(
*/ */
if (lppd->Flags & PD_RETURNDEFAULT) if (lppd->Flags & PD_RETURNDEFAULT)
{ {
WARN(commdlg, ": PrintDlg was requested to return printer info only." WARN(": PrintDlg was requested to return printer info only."
"\n The return value currently does NOT provide these.\n"); "\n The return value currently does NOT provide these.\n");
COMDLG32_SetCommDlgExtendedError(PDERR_NODEVICES); COMDLG32_SetCommDlgExtendedError(PDERR_NODEVICES);
/* return TRUE, thus never checked! */ /* return TRUE, thus never checked! */
@ -180,7 +180,7 @@ BOOL WINAPI PrintDlgA(
if (lppd->Flags & PD_PRINTSETUP) if (lppd->Flags & PD_PRINTSETUP)
{ {
FIXME(commdlg, ": PrintDlg was requested to display PrintSetup box.\n"); FIXME(": PrintDlg was requested to display PrintSetup box.\n");
COMDLG32_SetCommDlgExtendedError(PDERR_INITFAILURE); COMDLG32_SetCommDlgExtendedError(PDERR_INITFAILURE);
return(FALSE); return(FALSE);
} }
@ -204,7 +204,7 @@ BOOL WINAPI PrintDlgA(
/* FIXME: Currently Unimplemented */ /* FIXME: Currently Unimplemented */
if (lppd->Flags & PD_NOWARNING) if (lppd->Flags & PD_NOWARNING)
{ {
WARN(commdlg, ": PD_NOWARNING Flag is not yet implemented.\n"); WARN(": PD_NOWARNING Flag is not yet implemented.\n");
} }
/* /*
@ -214,7 +214,7 @@ BOOL WINAPI PrintDlgA(
if (lppd->Flags & (PD_ENABLEPRINTHOOK | PD_ENABLEPRINTTEMPLATE | if (lppd->Flags & (PD_ENABLEPRINTHOOK | PD_ENABLEPRINTTEMPLATE |
PD_ENABLEPRINTTEMPLATEHANDLE | PD_ENABLESETUPHOOK | PD_ENABLEPRINTTEMPLATEHANDLE | PD_ENABLESETUPHOOK |
PD_ENABLESETUPTEMPLATE|PD_ENABLESETUPTEMPLATEHANDLE)) PD_ENABLESETUPTEMPLATE|PD_ENABLESETUPTEMPLATEHANDLE))
FIXME(commdlg, ": unimplemented flag (ignored)\n"); FIXME(": unimplemented flag (ignored)\n");
hwndDialog= DIALOG_CreateIndirect(hInst, ptr, TRUE, lppd->hwndOwner, hwndDialog= DIALOG_CreateIndirect(hInst, ptr, TRUE, lppd->hwndOwner,
@ -234,7 +234,7 @@ BOOL WINAPI PrintDlgA(
*/ */
BOOL WINAPI PrintDlgW( LPPRINTDLGW printdlg ) BOOL WINAPI PrintDlgW( LPPRINTDLGW printdlg )
{ {
FIXME(commdlg, "A really empty stub\n" ); FIXME("A really empty stub\n" );
return FALSE; return FALSE;
} }
@ -280,11 +280,11 @@ LRESULT PRINTDLG_WMInitDialog(HWND hDlg, WPARAM wParam, LPARAM lParam,
LPPRINTER_INFO_2A lppi = PrintStructures->lpPrinterInfo; LPPRINTER_INFO_2A lppi = PrintStructures->lpPrinterInfo;
SetWindowLongA(hDlg, DWL_USER, lParam); SetWindowLongA(hDlg, DWL_USER, lParam);
TRACE(commdlg,"WM_INITDIALOG lParam=%08lX\n", lParam); TRACE("WM_INITDIALOG lParam=%08lX\n", lParam);
if (lppd->lStructSize != sizeof(PRINTDLGA)) if (lppd->lStructSize != sizeof(PRINTDLGA))
{ {
FIXME(commdlg,"structure size failure !!!\n"); FIXME("structure size failure !!!\n");
/* EndDialog (hDlg, 0); /* EndDialog (hDlg, 0);
return FALSE; return FALSE;
*/ } */ }
@ -346,7 +346,7 @@ LRESULT PRINTDLG_WMInitDialog(HWND hDlg, WPARAM wParam, LPARAM lParam,
/* Collate pages */ /* Collate pages */
if (lppd->Flags & PD_COLLATE) if (lppd->Flags & PD_COLLATE)
FIXME(commdlg, "PD_COLLATE not implemented yet\n"); FIXME("PD_COLLATE not implemented yet\n");
/* print to file */ /* print to file */
CheckDlgButton(hDlg, chx1, (lppd->Flags & PD_PRINTTOFILE) ? 1 : 0); CheckDlgButton(hDlg, chx1, (lppd->Flags & PD_PRINTTOFILE) ? 1 : 0);
@ -363,7 +363,7 @@ LRESULT PRINTDLG_WMInitDialog(HWND hDlg, WPARAM wParam, LPARAM lParam,
ShowWindow(GetDlgItem(hDlg, pshHelp), SW_HIDE); ShowWindow(GetDlgItem(hDlg, pshHelp), SW_HIDE);
} }
TRACE(commdlg, "succesful!\n"); TRACE("succesful!\n");
return TRUE; return TRUE;
} }
@ -395,7 +395,7 @@ BOOL PRINTDLG_ValidateAndDuplicateSettings(HWND hDlg,
nToPage < lppd->nMinPage || nToPage > lppd->nMaxPage) nToPage < lppd->nMinPage || nToPage > lppd->nMaxPage)
{ {
char TempBuffer[256]; char TempBuffer[256];
FIXME(commdlg, "This MessageBox is not internationalised."); FIXME("This MessageBox is not internationalised.");
sprintf(TempBuffer, "This value lies not within Page range\n" sprintf(TempBuffer, "This value lies not within Page range\n"
"Please enter a value between %d and %d", "Please enter a value between %d and %d",
lppd->nMinPage, lppd->nMaxPage); lppd->nMinPage, lppd->nMaxPage);
@ -427,17 +427,17 @@ static LRESULT PRINTDLG_WMCommand(HWND hDlg, WPARAM wParam,
switch (LOWORD(wParam)) switch (LOWORD(wParam))
{ {
case IDOK: case IDOK:
TRACE(commdlg, " OK button was hit\n"); TRACE(" OK button was hit\n");
if (PRINTDLG_ValidateAndDuplicateSettings(hDlg, PrintStructures) != TRUE) if (PRINTDLG_ValidateAndDuplicateSettings(hDlg, PrintStructures) != TRUE)
return(FALSE); return(FALSE);
DestroyWindow(hDlg); DestroyWindow(hDlg);
return(TRUE); return(TRUE);
case IDCANCEL: case IDCANCEL:
TRACE(commdlg, " CANCEL button was hit\n"); TRACE(" CANCEL button was hit\n");
EndDialog(hDlg, FALSE); EndDialog(hDlg, FALSE);
return(FALSE); return(FALSE);
case pshHelp: case pshHelp:
TRACE(commdlg, " HELP button was hit\n"); TRACE(" HELP button was hit\n");
SendMessageA(lppd->hwndOwner, PrintStructures->HelpMessageID, SendMessageA(lppd->hwndOwner, PrintStructures->HelpMessageID,
(WPARAM) hDlg, (LPARAM) lppd); (WPARAM) hDlg, (LPARAM) lppd);
break; break;
@ -464,7 +464,7 @@ static LRESULT PRINTDLG_WMCommand(HWND hDlg, WPARAM wParam,
ClosePrinter(hPrinter); ClosePrinter(hPrinter);
} }
else else
WARN(commdlg, " Call to OpenPrinter did not succeed!\n"); WARN(" Call to OpenPrinter did not succeed!\n");
break; break;
} }
case cmb4: /* Printer combobox */ case cmb4: /* Printer combobox */
@ -499,7 +499,7 @@ LRESULT WINAPI PrintDlgProcA(HWND hDlg, UINT uMsg, WPARAM wParam,
PrintStructures=(PRINT_PTRA*) lParam; PrintStructures=(PRINT_PTRA*) lParam;
if (!PRINTDLG_WMInitDialog(hDlg, wParam, lParam, PrintStructures)) if (!PRINTDLG_WMInitDialog(hDlg, wParam, lParam, PrintStructures))
{ {
TRACE(commdlg, "PRINTDLG_WMInitDialog returned FALSE\n"); TRACE("PRINTDLG_WMInitDialog returned FALSE\n");
return FALSE; return FALSE;
} }
MessageBoxA(hDlg,"Warning: this dialog has no functionality yet!", MessageBoxA(hDlg,"Warning: this dialog has no functionality yet!",
@ -528,7 +528,7 @@ LRESULT WINAPI PrintDlgProc16(HWND16 hWnd, UINT16 wMsg, WPARAM16 wParam,
switch (wMsg) switch (wMsg)
{ {
case WM_INITDIALOG: case WM_INITDIALOG:
TRACE(commdlg,"WM_INITDIALOG lParam=%08lX\n", lParam); TRACE("WM_INITDIALOG lParam=%08lX\n", lParam);
ShowWindow16(hWnd, SW_SHOWNORMAL); ShowWindow16(hWnd, SW_SHOWNORMAL);
return (TRUE); return (TRUE);
case WM_COMMAND: case WM_COMMAND:
@ -556,7 +556,7 @@ LRESULT WINAPI PrintSetupDlgProc16(HWND16 hWnd, UINT16 wMsg, WPARAM16 wParam,
switch (wMsg) switch (wMsg)
{ {
case WM_INITDIALOG: case WM_INITDIALOG:
TRACE(commdlg,"WM_INITDIALOG lParam=%08lX\n", lParam); TRACE("WM_INITDIALOG lParam=%08lX\n", lParam);
ShowWindow16(hWnd, SW_SHOWNORMAL); ShowWindow16(hWnd, SW_SHOWNORMAL);
return (TRUE); return (TRUE);
case WM_COMMAND: case WM_COMMAND:
@ -580,6 +580,6 @@ LRESULT WINAPI PrintSetupDlgProc16(HWND16 hWnd, UINT16 wMsg, WPARAM16 wParam,
* PageSetupDlgA (COMDLG32.15) * PageSetupDlgA (COMDLG32.15)
*/ */
BOOL WINAPI PageSetupDlgA(LPPAGESETUPDLGA setupdlg) { BOOL WINAPI PageSetupDlgA(LPPAGESETUPDLGA setupdlg) {
FIXME(commdlg,"(%p), stub!\n",setupdlg); FIXME("(%p), stub!\n",setupdlg);
return FALSE; return FALSE;
} }

View file

@ -7,7 +7,7 @@
#include "dlgs.h" #include "dlgs.h"
#include "win.h" #include "win.h"
#include "sysmetrics.h" #include "sysmetrics.h"
#include "debug.h" #include "debugtools.h"
#include "winreg.h" #include "winreg.h"
#include "authors.h" #include "authors.h"
#include "winnls.h" #include "winnls.h"
@ -41,7 +41,7 @@ static void InitializeTreeView(HWND hwndParent)
hwndTreeView = GetDlgItem (hwndParent, IDD_TREEVIEW); hwndTreeView = GetDlgItem (hwndParent, IDD_TREEVIEW);
Shell_GetImageList(NULL, &hImageList); Shell_GetImageList(NULL, &hImageList);
TRACE(shell,"dlg=%x tree=%x\n", hwndParent, hwndTreeView ); TRACE("dlg=%x tree=%x\n", hwndParent, hwndTreeView );
if (hImageList && hwndTreeView) if (hImageList && hwndTreeView)
{ TreeView_SetImageList(hwndTreeView, hImageList, 0); { TreeView_SetImageList(hwndTreeView, hImageList, 0);
@ -66,7 +66,7 @@ static int GetIcon(LPITEMIDLIST lpi, UINT uFlags)
} }
static void GetNormalAndSelectedIcons(LPITEMIDLIST lpifq,LPTVITEMA lpTV_ITEM) static void GetNormalAndSelectedIcons(LPITEMIDLIST lpifq,LPTVITEMA lpTV_ITEM)
{ TRACE (shell,"%p %p\n",lpifq, lpTV_ITEM); { TRACE("%p %p\n",lpifq, lpTV_ITEM);
lpTV_ITEM->iImage = GetIcon(lpifq, SHGFI_PIDL | SHGFI_SYSICONINDEX | SHGFI_SMALLICON); lpTV_ITEM->iImage = GetIcon(lpifq, SHGFI_PIDL | SHGFI_SYSICONINDEX | SHGFI_SMALLICON);
lpTV_ITEM->iSelectedImage = GetIcon(lpifq, SHGFI_PIDL | SHGFI_SYSICONINDEX | SHGFI_SMALLICON | SHGFI_OPENICON); lpTV_ITEM->iSelectedImage = GetIcon(lpifq, SHGFI_PIDL | SHGFI_SYSICONINDEX | SHGFI_SMALLICON | SHGFI_OPENICON);
@ -86,14 +86,14 @@ static BOOL GetName(LPSHELLFOLDER lpsf, LPITEMIDLIST lpi, DWORD dwFlags, LPSTR l
BOOL bSuccess=TRUE; BOOL bSuccess=TRUE;
STRRET str; STRRET str;
TRACE(shell,"%p %p %lx %p\n", lpsf, lpi, dwFlags, lpFriendlyName); TRACE("%p %p %lx %p\n", lpsf, lpi, dwFlags, lpFriendlyName);
if (SUCCEEDED(IShellFolder_GetDisplayNameOf(lpsf, lpi, dwFlags, &str))) if (SUCCEEDED(IShellFolder_GetDisplayNameOf(lpsf, lpi, dwFlags, &str)))
{ bSuccess = StrRetToStrN (lpFriendlyName, MAX_PATH, &str, lpi); { bSuccess = StrRetToStrN (lpFriendlyName, MAX_PATH, &str, lpi);
} }
else else
bSuccess = FALSE; bSuccess = FALSE;
TRACE(shell,"-- %s\n",lpFriendlyName); TRACE("-- %s\n",lpFriendlyName);
return bSuccess; return bSuccess;
} }
@ -110,7 +110,7 @@ static void FillTreeView(IShellFolder * lpsf, LPITEMIDLIST pidl, HTREEITEM hPar
char szBuff[256]; char szBuff[256];
HWND hwnd=GetParent(hwndTreeView); HWND hwnd=GetParent(hwndTreeView);
TRACE(shell, "%p %p %x\n",lpsf, pidl, (INT)hParent); TRACE("%p %p %x\n",lpsf, pidl, (INT)hParent);
SetCapture(GetParent(hwndTreeView)); SetCapture(GetParent(hwndTreeView));
SetCursor(LoadCursorA(0, IDC_WAITA)); SetCursor(LoadCursorA(0, IDC_WAITA));
@ -176,13 +176,13 @@ static LRESULT MsgNotify(HWND hWnd, UINT CtlID, LPNMHDR lpnmh)
IShellFolder * lpsf2=0; IShellFolder * lpsf2=0;
TRACE(shell,"%x %x %p msg=%x\n", hWnd, CtlID, lpnmh, pnmtv->hdr.code); TRACE("%x %x %p msg=%x\n", hWnd, CtlID, lpnmh, pnmtv->hdr.code);
switch (pnmtv->hdr.idFrom) switch (pnmtv->hdr.idFrom)
{ case IDD_TREEVIEW: { case IDD_TREEVIEW:
switch (pnmtv->hdr.code) switch (pnmtv->hdr.code)
{ case TVN_DELETEITEM: { case TVN_DELETEITEM:
{ FIXME(shell,"TVN_DELETEITEM\n"); { FIXME("TVN_DELETEITEM\n");
lptvid=(LPTV_ITEMDATA)pnmtv->itemOld.lParam; lptvid=(LPTV_ITEMDATA)pnmtv->itemOld.lParam;
IShellFolder_Release(lptvid->lpsfParent); IShellFolder_Release(lptvid->lpsfParent);
SHFree(lptvid->lpi); SHFree(lptvid->lpi);
@ -192,7 +192,7 @@ static LRESULT MsgNotify(HWND hWnd, UINT CtlID, LPNMHDR lpnmh)
break; break;
case TVN_ITEMEXPANDING: case TVN_ITEMEXPANDING:
{ FIXME(shell,"TVN_ITEMEXPANDING\n"); { FIXME("TVN_ITEMEXPANDING\n");
if ((pnmtv->itemNew.state & TVIS_EXPANDEDONCE)) if ((pnmtv->itemNew.state & TVIS_EXPANDEDONCE))
break; break;
@ -209,7 +209,7 @@ static LRESULT MsgNotify(HWND hWnd, UINT CtlID, LPNMHDR lpnmh)
break; break;
default: default:
FIXME(shell,"unhandled\n"); FIXME("unhandled\n");
break; break;
} }
break; break;
@ -227,20 +227,20 @@ static LRESULT MsgNotify(HWND hWnd, UINT CtlID, LPNMHDR lpnmh)
*/ */
BOOL WINAPI BrsFolderDlgProc( HWND hWnd, UINT msg, WPARAM wParam, BOOL WINAPI BrsFolderDlgProc( HWND hWnd, UINT msg, WPARAM wParam,
LPARAM lParam ) LPARAM lParam )
{ TRACE(shell,"hwnd=%i msg=%i 0x%08x 0x%08lx\n", hWnd, msg, wParam, lParam ); { TRACE("hwnd=%i msg=%i 0x%08x 0x%08lx\n", hWnd, msg, wParam, lParam );
switch(msg) switch(msg)
{ case WM_INITDIALOG: { case WM_INITDIALOG:
pidlRet = NULL; pidlRet = NULL;
lpBrowseInfo = (LPBROWSEINFOA) lParam; lpBrowseInfo = (LPBROWSEINFOA) lParam;
if (lpBrowseInfo->lpfn) if (lpBrowseInfo->lpfn)
FIXME(shell,"Callbacks not implemented\n"); FIXME("Callbacks not implemented\n");
if (lpBrowseInfo->ulFlags) if (lpBrowseInfo->ulFlags)
FIXME(shell,"flag %x not implemented\n", lpBrowseInfo->ulFlags); FIXME("flag %x not implemented\n", lpBrowseInfo->ulFlags);
if (lpBrowseInfo->lpszTitle) if (lpBrowseInfo->lpszTitle)
FIXME(shell,"title %s not displayed\n", lpBrowseInfo->lpszTitle); FIXME("title %s not displayed\n", lpBrowseInfo->lpszTitle);
if ( lpBrowseInfo->pidlRoot ) if ( lpBrowseInfo->pidlRoot )
FIXME(shell,"root is desktop\n"); FIXME("root is desktop\n");
InitializeTreeView ( hWnd); InitializeTreeView ( hWnd);
return 1; return 1;
@ -272,7 +272,7 @@ BOOL WINAPI BrsFolderDlgProc( HWND hWnd, UINT msg, WPARAM wParam,
*/ */
LPITEMIDLIST WINAPI SHBrowseForFolderA (LPBROWSEINFOA lpbi) LPITEMIDLIST WINAPI SHBrowseForFolderA (LPBROWSEINFOA lpbi)
{ {
TRACE(shell, "(%lx,%s) empty stub!\n", (DWORD)lpbi, lpbi->lpszTitle); TRACE("(%lx,%s) empty stub!\n", (DWORD)lpbi, lpbi->lpszTitle);
return (LPITEMIDLIST) DialogBoxParamA( shell32_hInstance, return (LPITEMIDLIST) DialogBoxParamA( shell32_hInstance,
"SHBRSFORFOLDER_MSGBOX", 0, "SHBRSFORFOLDER_MSGBOX", 0,

View file

@ -6,7 +6,7 @@
*/ */
#include <stdlib.h> #include <stdlib.h>
#include <string.h> #include <string.h>
#include "debug.h" #include "debugtools.h"
#include "winerror.h" #include "winerror.h"
#include "winreg.h" #include "winreg.h"
@ -18,7 +18,7 @@ DEFAULT_DEBUG_CHANNEL(shell)
BOOL HCR_MapTypeToValue ( LPCSTR szExtension, LPSTR szFileType, DWORD len) BOOL HCR_MapTypeToValue ( LPCSTR szExtension, LPSTR szFileType, DWORD len)
{ HKEY hkey; { HKEY hkey;
TRACE(shell, "%s %p\n",szExtension, szFileType ); TRACE("%s %p\n",szExtension, szFileType );
if (RegOpenKeyExA(HKEY_CLASSES_ROOT,szExtension,0,0x02000000,&hkey)) if (RegOpenKeyExA(HKEY_CLASSES_ROOT,szExtension,0,0x02000000,&hkey))
{ return FALSE; { return FALSE;
@ -31,7 +31,7 @@ BOOL HCR_MapTypeToValue ( LPCSTR szExtension, LPSTR szFileType, DWORD len)
RegCloseKey(hkey); RegCloseKey(hkey);
TRACE(shell, "-- %s\n", szFileType ); TRACE("-- %s\n", szFileType );
return TRUE; return TRUE;
} }
@ -39,7 +39,7 @@ BOOL HCR_GetExecuteCommand ( LPCSTR szClass, LPCSTR szVerb, LPSTR szDest, DWORD
{ HKEY hkey; { HKEY hkey;
char sTemp[256]; char sTemp[256];
TRACE(shell, "%s %s\n",szClass, szVerb ); TRACE("%s %s\n",szClass, szVerb );
sprintf(sTemp, "%s\\shell\\%s\\command",szClass, szVerb); sprintf(sTemp, "%s\\shell\\%s\\command",szClass, szVerb);
@ -53,7 +53,7 @@ BOOL HCR_GetExecuteCommand ( LPCSTR szClass, LPCSTR szVerb, LPSTR szDest, DWORD
} }
RegCloseKey(hkey); RegCloseKey(hkey);
TRACE(shell, "-- %s\n", szDest ); TRACE("-- %s\n", szDest );
return TRUE; return TRUE;
@ -68,7 +68,7 @@ BOOL HCR_GetDefaultIcon (LPCSTR szClass, LPSTR szDest, DWORD len, LPDWORD dwNr)
char sTemp[256]; char sTemp[256];
char sNum[5]; char sNum[5];
TRACE(shell, "%s\n",szClass ); TRACE("%s\n",szClass );
sprintf(sTemp, "%s\\DefaultIcon",szClass); sprintf(sTemp, "%s\\DefaultIcon",szClass);
@ -89,7 +89,7 @@ BOOL HCR_GetDefaultIcon (LPCSTR szClass, LPSTR szDest, DWORD len, LPDWORD dwNr)
ParseFieldA (szDest, 1, szDest, len); ParseFieldA (szDest, 1, szDest, len);
TRACE(shell, "-- %s %li\n", szDest, *dwNr ); TRACE("-- %s %li\n", szDest, *dwNr );
return TRUE; return TRUE;

View file

@ -6,7 +6,7 @@
#include <string.h> #include <string.h>
#include "winerror.h" #include "winerror.h"
#include "debug.h" #include "debugtools.h"
#include "pidl.h" #include "pidl.h"
#include "wine/obj_base.h" #include "wine/obj_base.h"
@ -37,7 +37,7 @@ static struct ICOM_VTABLE(IContextMenu) cmvt;
*/ */
BOOL IContextMenu_AllocPidlTable(IContextMenuImpl *This, DWORD dwEntries) BOOL IContextMenu_AllocPidlTable(IContextMenuImpl *This, DWORD dwEntries)
{ {
TRACE(shell,"(%p)->(entrys=%lu)\n",This, dwEntries); TRACE("(%p)->(entrys=%lu)\n",This, dwEntries);
/*add one for NULL terminator */ /*add one for NULL terminator */
dwEntries++; dwEntries++;
@ -57,7 +57,7 @@ void IContextMenu_FreePidlTable(IContextMenuImpl *This)
{ {
int i; int i;
TRACE(shell,"(%p)->()\n",This); TRACE("(%p)->()\n",This);
if(This->aPidls) if(This->aPidls)
{ for(i = 0; This->aPidls[i]; i++) { for(i = 0; This->aPidls[i]; i++)
@ -76,7 +76,7 @@ BOOL IContextMenu_FillPidlTable(IContextMenuImpl *This, LPCITEMIDLIST *aPidls, U
{ {
UINT i; UINT i;
TRACE(shell,"(%p)->(apidl=%p count=%u)\n",This, aPidls, uItemCount); TRACE("(%p)->(apidl=%p count=%u)\n",This, aPidls, uItemCount);
if(This->aPidls) if(This->aPidls)
{ for(i = 0; i < uItemCount; i++) { for(i = 0; i < uItemCount; i++)
@ -94,7 +94,7 @@ BOOL IContextMenu_CanRenameItems(IContextMenuImpl *This)
{ UINT i; { UINT i;
DWORD dwAttributes; DWORD dwAttributes;
TRACE(shell,"(%p)->()\n",This); TRACE("(%p)->()\n",This);
if(This->aPidls) if(This->aPidls)
{ {
@ -138,7 +138,7 @@ IContextMenu *IContextMenu_Constructor(LPSHELLFOLDER pSFParent, LPCITEMIDLIST *a
for(u = 0; u < uItemCount; u++) for(u = 0; u < uItemCount; u++)
{ cm->bAllValues &= (_ILIsValue(aPidls[u]) ? 1 : 0); { cm->bAllValues &= (_ILIsValue(aPidls[u]) ? 1 : 0);
} }
TRACE(shell,"(%p)->()\n",cm); TRACE("(%p)->()\n",cm);
shell32_ObjCount++; shell32_ObjCount++;
return (IContextMenu*)cm; return (IContextMenu*)cm;
} }
@ -153,7 +153,7 @@ static HRESULT WINAPI IContextMenu_fnQueryInterface(IContextMenu *iface, REFIID
char xriid[50]; char xriid[50];
WINE_StringFromCLSID((LPCLSID)riid,xriid); WINE_StringFromCLSID((LPCLSID)riid,xriid);
TRACE(shell,"(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj); TRACE("(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj);
*ppvObj = NULL; *ppvObj = NULL;
@ -164,16 +164,16 @@ static HRESULT WINAPI IContextMenu_fnQueryInterface(IContextMenu *iface, REFIID
{ *ppvObj = This; { *ppvObj = This;
} }
else if(IsEqualIID(riid, &IID_IShellExtInit)) /*IShellExtInit*/ else if(IsEqualIID(riid, &IID_IShellExtInit)) /*IShellExtInit*/
{ FIXME (shell,"-- LPSHELLEXTINIT pointer requested\n"); { FIXME("-- LPSHELLEXTINIT pointer requested\n");
} }
if(*ppvObj) if(*ppvObj)
{ {
IContextMenu_AddRef((IContextMenu*)*ppvObj); IContextMenu_AddRef((IContextMenu*)*ppvObj);
TRACE(shell,"-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj); TRACE("-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj);
return S_OK; return S_OK;
} }
TRACE(shell,"-- Interface: E_NOINTERFACE\n"); TRACE("-- Interface: E_NOINTERFACE\n");
return E_NOINTERFACE; return E_NOINTERFACE;
} }
@ -184,7 +184,7 @@ static ULONG WINAPI IContextMenu_fnAddRef(IContextMenu *iface)
{ {
ICOM_THIS(IContextMenuImpl, iface); ICOM_THIS(IContextMenuImpl, iface);
TRACE(shell,"(%p)->(count=%lu)\n",This, This->ref); TRACE("(%p)->(count=%lu)\n",This, This->ref);
shell32_ObjCount++; shell32_ObjCount++;
return ++(This->ref); return ++(This->ref);
@ -197,12 +197,12 @@ static ULONG WINAPI IContextMenu_fnRelease(IContextMenu *iface)
{ {
ICOM_THIS(IContextMenuImpl, iface); ICOM_THIS(IContextMenuImpl, iface);
TRACE(shell,"(%p)->()\n",This); TRACE("(%p)->()\n",This);
shell32_ObjCount--; shell32_ObjCount--;
if (!--(This->ref)) if (!--(This->ref))
{ TRACE(shell," destroying IContextMenu(%p)\n",This); { TRACE(" destroying IContextMenu(%p)\n",This);
if(This->pSFParent) if(This->pSFParent)
IShellFolder_Release(This->pSFParent); IShellFolder_Release(This->pSFParent);
@ -262,7 +262,7 @@ static HRESULT WINAPI IContextMenu_fnQueryContextMenu(
BOOL fExplore ; BOOL fExplore ;
TRACE(shell,"(%p)->(hmenu=%x indexmenu=%x cmdfirst=%x cmdlast=%x flags=%x )\n",This, hmenu, indexMenu, idCmdFirst, idCmdLast, uFlags); TRACE("(%p)->(hmenu=%x indexmenu=%x cmdfirst=%x cmdlast=%x flags=%x )\n",This, hmenu, indexMenu, idCmdFirst, idCmdLast, uFlags);
if(!(CMF_DEFAULTONLY & uFlags)) if(!(CMF_DEFAULTONLY & uFlags))
{ if(!This->bAllValues) { if(!This->bAllValues)
@ -310,7 +310,7 @@ static HRESULT WINAPI IContextMenu_fnInvokeCommand(
SHELLEXECUTEINFOA sei; SHELLEXECUTEINFOA sei;
int i; int i;
TRACE(shell,"(%p)->(invcom=%p verb=%p wnd=%x)\n",This,lpcmi,lpcmi->lpVerb, lpcmi->hwnd); TRACE("(%p)->(invcom=%p verb=%p wnd=%x)\n",This,lpcmi,lpcmi->lpVerb, lpcmi->hwnd);
if(HIWORD(lpcmi->lpVerb)) if(HIWORD(lpcmi->lpVerb))
{ /* get the active IShellView */ { /* get the active IShellView */
@ -319,9 +319,9 @@ static HRESULT WINAPI IContextMenu_fnInvokeCommand(
IShellView_GetWindow(lpSV, &hWndSV); IShellView_GetWindow(lpSV, &hWndSV);
/* these verbs are used by the filedialogs*/ /* these verbs are used by the filedialogs*/
TRACE(shell,"%s\n",lpcmi->lpVerb); TRACE("%s\n",lpcmi->lpVerb);
if (! strcmp(lpcmi->lpVerb,CMDSTR_NEWFOLDER)) if (! strcmp(lpcmi->lpVerb,CMDSTR_NEWFOLDER))
{ FIXME(shell,"%s not implemented\n",lpcmi->lpVerb); { FIXME("%s not implemented\n",lpcmi->lpVerb);
} }
else if (! strcmp(lpcmi->lpVerb,CMDSTR_VIEWLIST)) else if (! strcmp(lpcmi->lpVerb,CMDSTR_VIEWLIST))
{ SendMessageA(hWndSV, WM_COMMAND, MAKEWPARAM(FCIDM_SHVIEW_LISTVIEW,0),0 ); { SendMessageA(hWndSV, WM_COMMAND, MAKEWPARAM(FCIDM_SHVIEW_LISTVIEW,0),0 );
@ -330,7 +330,7 @@ static HRESULT WINAPI IContextMenu_fnInvokeCommand(
{ SendMessageA(hWndSV, WM_COMMAND, MAKEWPARAM(FCIDM_SHVIEW_REPORTVIEW,0),0 ); { SendMessageA(hWndSV, WM_COMMAND, MAKEWPARAM(FCIDM_SHVIEW_REPORTVIEW,0),0 );
} }
else else
{ FIXME(shell,"please report: unknown verb %s\n",lpcmi->lpVerb); { FIXME("please report: unknown verb %s\n",lpcmi->lpVerb);
} }
IShellView_Release(lpSV); IShellView_Release(lpSV);
return NOERROR; return NOERROR;
@ -395,7 +395,7 @@ static HRESULT WINAPI IContextMenu_fnGetCommandString(
HRESULT hr = E_INVALIDARG; HRESULT hr = E_INVALIDARG;
TRACE(shell,"(%p)->(idcom=%x flags=%x %p name=%p len=%x)\n",This, idCommand, uFlags, lpReserved, lpszName, uMaxNameLen); TRACE("(%p)->(idcom=%x flags=%x %p name=%p len=%x)\n",This, idCommand, uFlags, lpReserved, lpszName, uMaxNameLen);
switch(uFlags) switch(uFlags)
{ case GCS_HELPTEXT: { case GCS_HELPTEXT:
@ -426,7 +426,7 @@ static HRESULT WINAPI IContextMenu_fnGetCommandString(
hr = NOERROR; hr = NOERROR;
break; break;
} }
TRACE(shell,"-- (%p)->(name=%s)\n",This, lpszName); TRACE("-- (%p)->(name=%s)\n",This, lpszName);
return hr; return hr;
} }
@ -444,7 +444,7 @@ static HRESULT WINAPI IContextMenu_fnHandleMenuMsg(
{ {
ICOM_THIS(IContextMenuImpl, iface); ICOM_THIS(IContextMenuImpl, iface);
TRACE(shell,"(%p)->(msg=%x wp=%x lp=%lx)\n",This, uMsg, wParam, lParam); TRACE("(%p)->(msg=%x wp=%x lp=%lx)\n",This, uMsg, wParam, lParam);
return E_NOTIMPL; return E_NOTIMPL;
} }

View file

@ -11,7 +11,7 @@
#include "pidl.h" #include "pidl.h"
#include "winerror.h" #include "winerror.h"
#include "shell32_main.h" #include "shell32_main.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(shell) DEFAULT_DEBUG_CHANNEL(shell)
@ -70,7 +70,7 @@ LPENUMFORMATETC IEnumFORMATETC_Constructor(UINT cfmt, const FORMATETC afmt[])
{ memcpy(ef->pFmt, afmt, size); { memcpy(ef->pFmt, afmt, size);
} }
TRACE(shell,"(%p)->()\n",ef); TRACE("(%p)->()\n",ef);
shell32_ObjCount++; shell32_ObjCount++;
return (LPENUMFORMATETC)ef; return (LPENUMFORMATETC)ef;
} }
@ -79,7 +79,7 @@ static HRESULT WINAPI IEnumFORMATETC_fnQueryInterface(LPENUMFORMATETC iface, REF
ICOM_THIS(IEnumFORMATETCImpl,iface); ICOM_THIS(IEnumFORMATETCImpl,iface);
char xriid[50]; char xriid[50];
WINE_StringFromCLSID((LPCLSID)riid,xriid); WINE_StringFromCLSID((LPCLSID)riid,xriid);
TRACE(shell,"(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj); TRACE("(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj);
*ppvObj = NULL; *ppvObj = NULL;
@ -92,29 +92,29 @@ static HRESULT WINAPI IEnumFORMATETC_fnQueryInterface(LPENUMFORMATETC iface, REF
if(*ppvObj) if(*ppvObj)
{ IEnumFORMATETC_AddRef((IEnumFORMATETC*)*ppvObj); { IEnumFORMATETC_AddRef((IEnumFORMATETC*)*ppvObj);
TRACE(shell,"-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj); TRACE("-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj);
return S_OK; return S_OK;
} }
TRACE(shell,"-- Interface: E_NOINTERFACE\n"); TRACE("-- Interface: E_NOINTERFACE\n");
return E_NOINTERFACE; return E_NOINTERFACE;
} }
static ULONG WINAPI IEnumFORMATETC_fnAddRef(LPENUMFORMATETC iface) static ULONG WINAPI IEnumFORMATETC_fnAddRef(LPENUMFORMATETC iface)
{ {
ICOM_THIS(IEnumFORMATETCImpl,iface); ICOM_THIS(IEnumFORMATETCImpl,iface);
TRACE(shell,"(%p)->(count=%lu)\n",This, This->ref); TRACE("(%p)->(count=%lu)\n",This, This->ref);
shell32_ObjCount++; shell32_ObjCount++;
return ++(This->ref); return ++(This->ref);
} }
static ULONG WINAPI IEnumFORMATETC_fnRelease(LPENUMFORMATETC iface) static ULONG WINAPI IEnumFORMATETC_fnRelease(LPENUMFORMATETC iface)
{ {
ICOM_THIS(IEnumFORMATETCImpl,iface); ICOM_THIS(IEnumFORMATETCImpl,iface);
TRACE(shell,"(%p)->()\n",This); TRACE("(%p)->()\n",This);
shell32_ObjCount--; shell32_ObjCount--;
if (!--(This->ref)) if (!--(This->ref))
{ TRACE(shell," destroying IEnumFORMATETC(%p)\n",This); { TRACE(" destroying IEnumFORMATETC(%p)\n",This);
if (This->pFmt) if (This->pFmt)
{ SHFree (This->pFmt); { SHFree (This->pFmt);
} }
@ -129,7 +129,7 @@ static HRESULT WINAPI IEnumFORMATETC_fnNext(LPENUMFORMATETC iface, ULONG celt, F
UINT cfetch; UINT cfetch;
HRESULT hres = S_FALSE; HRESULT hres = S_FALSE;
TRACE (shell, "(%p)->()\n", This); TRACE("(%p)->()\n", This);
if (This->posFmt < This->countFmt) if (This->posFmt < This->countFmt)
{ cfetch = This->countFmt - This->posFmt; { cfetch = This->countFmt - This->posFmt;
@ -153,7 +153,7 @@ static HRESULT WINAPI IEnumFORMATETC_fnNext(LPENUMFORMATETC iface, ULONG celt, F
static HRESULT WINAPI IEnumFORMATETC_fnSkip(LPENUMFORMATETC iface, ULONG celt) static HRESULT WINAPI IEnumFORMATETC_fnSkip(LPENUMFORMATETC iface, ULONG celt)
{ {
ICOM_THIS(IEnumFORMATETCImpl,iface); ICOM_THIS(IEnumFORMATETCImpl,iface);
FIXME (shell, "(%p)->(num=%lu)\n", This, celt); FIXME("(%p)->(num=%lu)\n", This, celt);
This->posFmt += celt; This->posFmt += celt;
if (This->posFmt > This->countFmt) if (This->posFmt > This->countFmt)
@ -165,7 +165,7 @@ static HRESULT WINAPI IEnumFORMATETC_fnSkip(LPENUMFORMATETC iface, ULONG celt)
static HRESULT WINAPI IEnumFORMATETC_fnReset(LPENUMFORMATETC iface) static HRESULT WINAPI IEnumFORMATETC_fnReset(LPENUMFORMATETC iface)
{ {
ICOM_THIS(IEnumFORMATETCImpl,iface); ICOM_THIS(IEnumFORMATETCImpl,iface);
FIXME (shell, "(%p)->()\n", This); FIXME("(%p)->()\n", This);
This->posFmt = 0; This->posFmt = 0;
return S_OK; return S_OK;
@ -173,7 +173,7 @@ static HRESULT WINAPI IEnumFORMATETC_fnReset(LPENUMFORMATETC iface)
static HRESULT WINAPI IEnumFORMATETC_fnClone(LPENUMFORMATETC iface, LPENUMFORMATETC* ppenum) static HRESULT WINAPI IEnumFORMATETC_fnClone(LPENUMFORMATETC iface, LPENUMFORMATETC* ppenum)
{ {
ICOM_THIS(IEnumFORMATETCImpl,iface); ICOM_THIS(IEnumFORMATETCImpl,iface);
FIXME (shell, "(%p)->(ppenum=%p)\n", This, ppenum); FIXME("(%p)->(ppenum=%p)\n", This, ppenum);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -249,16 +249,16 @@ LPIDLLIST IDLList_Constructor (UINT uStep)
lpidll->uStep=uStep; lpidll->uStep=uStep;
lpidll->dpa=NULL; lpidll->dpa=NULL;
TRACE (shell,"(%p)\n",lpidll); TRACE("(%p)\n",lpidll);
return lpidll; return lpidll;
} }
void IDLList_Destructor(LPIDLLIST this) void IDLList_Destructor(LPIDLLIST this)
{ TRACE (shell,"(%p)\n",this); { TRACE("(%p)\n",this);
IDLList_CleanList(this); IDLList_CleanList(this);
} }
static UINT WINAPI IDLList_GetState(LPIDLLIST this) static UINT WINAPI IDLList_GetState(LPIDLLIST this)
{ TRACE (shell,"(%p)->(uStep=%u dpa=%p)\n",this, this->uStep, this->dpa); { TRACE("(%p)->(uStep=%u dpa=%p)\n",this, this->uStep, this->dpa);
if (this->uStep == 0) if (this->uStep == 0)
{ if (this->dpa) { if (this->dpa)
@ -268,15 +268,15 @@ static UINT WINAPI IDLList_GetState(LPIDLLIST this)
return(State_UnInit); return(State_UnInit);
} }
static LPITEMIDLIST WINAPI IDLList_GetElement(LPIDLLIST this, UINT nIndex) static LPITEMIDLIST WINAPI IDLList_GetElement(LPIDLLIST this, UINT nIndex)
{ TRACE (shell,"(%p)->(index=%u)\n",this, nIndex); { TRACE("(%p)->(index=%u)\n",this, nIndex);
return((LPITEMIDLIST)pDPA_GetPtr(this->dpa, nIndex)); return((LPITEMIDLIST)pDPA_GetPtr(this->dpa, nIndex));
} }
static UINT WINAPI IDLList_GetCount(LPIDLLIST this) static UINT WINAPI IDLList_GetCount(LPIDLLIST this)
{ TRACE (shell,"(%p)\n",this); { TRACE("(%p)\n",this);
return(IDLList_GetState(this)==State_Init ? DPA_GetPtrCount(this->dpa) : 0); return(IDLList_GetState(this)==State_Init ? DPA_GetPtrCount(this->dpa) : 0);
} }
static BOOL WINAPI IDLList_StoreItem(LPIDLLIST this, LPITEMIDLIST pidl) static BOOL WINAPI IDLList_StoreItem(LPIDLLIST this, LPITEMIDLIST pidl)
{ TRACE (shell,"(%p)->(pidl=%p)\n",this, pidl); { TRACE("(%p)->(pidl=%p)\n",this, pidl);
if (pidl) if (pidl)
{ if (IDLList_InitList(this) && pDPA_InsertPtr(this->dpa, 0x7fff, (LPSTR)pidl)>=0) { if (IDLList_InitList(this) && pDPA_InsertPtr(this->dpa, 0x7fff, (LPSTR)pidl)>=0)
return(TRUE); return(TRUE);
@ -287,7 +287,7 @@ static BOOL WINAPI IDLList_StoreItem(LPIDLLIST this, LPITEMIDLIST pidl)
} }
static BOOL WINAPI IDLList_AddItems(LPIDLLIST this, LPITEMIDLIST *apidl, UINT cidl) static BOOL WINAPI IDLList_AddItems(LPIDLLIST this, LPITEMIDLIST *apidl, UINT cidl)
{ INT i; { INT i;
TRACE (shell,"(%p)->(apidl=%p cidl=%u)\n",this, apidl, cidl); TRACE("(%p)->(apidl=%p cidl=%u)\n",this, apidl, cidl);
for (i=0; i<cidl; ++i) for (i=0; i<cidl; ++i)
{ if (!IDLList_StoreItem(this, ILClone((LPCITEMIDLIST)apidl[i]))) { if (!IDLList_StoreItem(this, ILClone((LPCITEMIDLIST)apidl[i])))
@ -296,7 +296,7 @@ static BOOL WINAPI IDLList_AddItems(LPIDLLIST this, LPITEMIDLIST *apidl, UINT ci
return(TRUE); return(TRUE);
} }
static BOOL WINAPI IDLList_InitList(LPIDLLIST this) static BOOL WINAPI IDLList_InitList(LPIDLLIST this)
{ TRACE (shell,"(%p)\n",this); { TRACE("(%p)\n",this);
switch (IDLList_GetState(this)) switch (IDLList_GetState(this))
{ case State_Init: { case State_Init:
return(TRUE); return(TRUE);
@ -313,7 +313,7 @@ static BOOL WINAPI IDLList_InitList(LPIDLLIST this)
} }
static void WINAPI IDLList_CleanList(LPIDLLIST this) static void WINAPI IDLList_CleanList(LPIDLLIST this)
{ INT i; { INT i;
TRACE (shell,"(%p)\n",this); TRACE("(%p)\n",this);
if (this->uStep != 0) if (this->uStep != 0)
{ this->dpa = NULL; { this->dpa = NULL;
@ -400,7 +400,7 @@ LPDATAOBJECT IDataObject_Constructor(HWND hwndOwner, LPSHELLFOLDER psf, LPITEMID
dto->lpill->lpvtbl->fnAddItems(dto->lpill, apidl, cidl); dto->lpill->lpvtbl->fnAddItems(dto->lpill, apidl, cidl);
TRACE(shell,"(%p)->(sf=%p apidl=%p cidl=%u)\n",dto, psf, apidl, cidl); TRACE("(%p)->(sf=%p apidl=%p cidl=%u)\n",dto, psf, apidl, cidl);
shell32_ObjCount++; shell32_ObjCount++;
return (LPDATAOBJECT)dto; return (LPDATAOBJECT)dto;
} }
@ -412,7 +412,7 @@ static HRESULT WINAPI IDataObject_fnQueryInterface(LPDATAOBJECT iface, REFIID ri
ICOM_THIS(IDataObjectImpl,iface); ICOM_THIS(IDataObjectImpl,iface);
char xriid[50]; char xriid[50];
WINE_StringFromCLSID((LPCLSID)riid,xriid); WINE_StringFromCLSID((LPCLSID)riid,xriid);
TRACE(shell,"(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj); TRACE("(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj);
*ppvObj = NULL; *ppvObj = NULL;
@ -425,10 +425,10 @@ static HRESULT WINAPI IDataObject_fnQueryInterface(LPDATAOBJECT iface, REFIID ri
if(*ppvObj) if(*ppvObj)
{ IDataObject_AddRef((IDataObject*)*ppvObj); { IDataObject_AddRef((IDataObject*)*ppvObj);
TRACE(shell,"-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj); TRACE("-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj);
return S_OK; return S_OK;
} }
TRACE(shell,"-- Interface: E_NOINTERFACE\n"); TRACE("-- Interface: E_NOINTERFACE\n");
return E_NOINTERFACE; return E_NOINTERFACE;
} }
/************************************************************************** /**************************************************************************
@ -438,7 +438,7 @@ static ULONG WINAPI IDataObject_fnAddRef(LPDATAOBJECT iface)
{ {
ICOM_THIS(IDataObjectImpl,iface); ICOM_THIS(IDataObjectImpl,iface);
TRACE(shell,"(%p)->(count=%lu)\n",This, This->ref); TRACE("(%p)->(count=%lu)\n",This, This->ref);
shell32_ObjCount++; shell32_ObjCount++;
return ++(This->ref); return ++(This->ref);
@ -449,12 +449,12 @@ static ULONG WINAPI IDataObject_fnAddRef(LPDATAOBJECT iface)
static ULONG WINAPI IDataObject_fnRelease(LPDATAOBJECT iface) static ULONG WINAPI IDataObject_fnRelease(LPDATAOBJECT iface)
{ {
ICOM_THIS(IDataObjectImpl,iface); ICOM_THIS(IDataObjectImpl,iface);
TRACE(shell,"(%p)->()\n",This); TRACE("(%p)->()\n",This);
shell32_ObjCount--; shell32_ObjCount--;
if (!--(This->ref)) if (!--(This->ref))
{ TRACE(shell," destroying IDataObject(%p)\n",This); { TRACE(" destroying IDataObject(%p)\n",This);
IDLList_Destructor(This->lpill); IDLList_Destructor(This->lpill);
HeapFree(GetProcessHeap(),0,This); HeapFree(GetProcessHeap(),0,This);
return 0; return 0;
@ -523,7 +523,7 @@ static HRESULT WINAPI IDataObject_fnGetData(LPDATAOBJECT iface, LPFORMATETC pfor
HGLOBAL hmem; HGLOBAL hmem;
GetClipboardFormatNameA (pformatetcIn->cfFormat, temp, 256); GetClipboardFormatNameA (pformatetcIn->cfFormat, temp, 256);
WARN (shell, "(%p)->(%p %p format=%s)semi-stub\n", This, pformatetcIn, pmedium, temp); WARN("(%p)->(%p %p format=%s)semi-stub\n", This, pformatetcIn, pmedium, temp);
if (!DATAOBJECT_InitShellIDList()) /* is the clipformat registred? */ if (!DATAOBJECT_InitShellIDList()) /* is the clipformat registred? */
{ return(E_UNEXPECTED); { return(E_UNEXPECTED);
@ -558,71 +558,71 @@ static HRESULT WINAPI IDataObject_fnGetData(LPDATAOBJECT iface, LPFORMATETC pfor
pcida->aoffset[0] = size; pcida->aoffset[0] = size;
pcida->aoffset[1] = size+size1; pcida->aoffset[1] = size+size1;
TRACE(shell,"-- %lu %lu %lu\n",size, size1, size2 ); TRACE("-- %lu %lu %lu\n",size, size1, size2 );
TRACE(shell,"-- %p %p\n",This->pidl, pidl); TRACE("-- %p %p\n",This->pidl, pidl);
TRACE(shell,"-- %p %p %p\n",pcida, (LPBYTE)pcida+size,(LPBYTE)pcida+size+size1); TRACE("-- %p %p %p\n",pcida, (LPBYTE)pcida+size,(LPBYTE)pcida+size+size1);
memcpy ((LPBYTE)pcida+size, This->pidl, size1); memcpy ((LPBYTE)pcida+size, This->pidl, size1);
memcpy ((LPBYTE)pcida+size+size1, pidl, size2); memcpy ((LPBYTE)pcida+size+size1, pidl, size2);
TRACE(shell,"-- after copy\n"); TRACE("-- after copy\n");
GlobalUnlock(hmem); GlobalUnlock(hmem);
pmedium->tymed = TYMED_HGLOBAL; pmedium->tymed = TYMED_HGLOBAL;
pmedium->u.hGlobal = (HGLOBAL)pcida; pmedium->u.hGlobal = (HGLOBAL)pcida;
pmedium->pUnkForRelease = NULL; pmedium->pUnkForRelease = NULL;
TRACE(shell,"-- ready\n"); TRACE("-- ready\n");
return(NOERROR); return(NOERROR);
} }
} }
FIXME (shell, "-- clipformat not implemented\n"); FIXME("-- clipformat not implemented\n");
return (E_INVALIDARG); return (E_INVALIDARG);
} }
static HRESULT WINAPI IDataObject_fnGetDataHere(LPDATAOBJECT iface, LPFORMATETC pformatetc, STGMEDIUM *pmedium) static HRESULT WINAPI IDataObject_fnGetDataHere(LPDATAOBJECT iface, LPFORMATETC pformatetc, STGMEDIUM *pmedium)
{ {
ICOM_THIS(IDataObjectImpl,iface); ICOM_THIS(IDataObjectImpl,iface);
FIXME (shell, "(%p)->()\n", This); FIXME("(%p)->()\n", This);
return E_NOTIMPL; return E_NOTIMPL;
} }
static HRESULT WINAPI IDataObject_fnQueryGetData(LPDATAOBJECT iface, LPFORMATETC pformatetc) static HRESULT WINAPI IDataObject_fnQueryGetData(LPDATAOBJECT iface, LPFORMATETC pformatetc)
{ {
ICOM_THIS(IDataObjectImpl,iface); ICOM_THIS(IDataObjectImpl,iface);
FIXME (shell, "(%p)->()\n", This); FIXME("(%p)->()\n", This);
return E_NOTIMPL; return E_NOTIMPL;
} }
static HRESULT WINAPI IDataObject_fnGetCanonicalFormatEtc(LPDATAOBJECT iface, LPFORMATETC pformatectIn, LPFORMATETC pformatetcOut) static HRESULT WINAPI IDataObject_fnGetCanonicalFormatEtc(LPDATAOBJECT iface, LPFORMATETC pformatectIn, LPFORMATETC pformatetcOut)
{ {
ICOM_THIS(IDataObjectImpl,iface); ICOM_THIS(IDataObjectImpl,iface);
FIXME (shell, "(%p)->()\n", This); FIXME("(%p)->()\n", This);
return E_NOTIMPL; return E_NOTIMPL;
} }
static HRESULT WINAPI IDataObject_fnSetData(LPDATAOBJECT iface, LPFORMATETC pformatetc, STGMEDIUM *pmedium, BOOL fRelease) static HRESULT WINAPI IDataObject_fnSetData(LPDATAOBJECT iface, LPFORMATETC pformatetc, STGMEDIUM *pmedium, BOOL fRelease)
{ {
ICOM_THIS(IDataObjectImpl,iface); ICOM_THIS(IDataObjectImpl,iface);
FIXME (shell, "(%p)->()\n", This); FIXME("(%p)->()\n", This);
return E_NOTIMPL; return E_NOTIMPL;
} }
static HRESULT WINAPI IDataObject_fnEnumFormatEtc(LPDATAOBJECT iface, DWORD dwDirection, IEnumFORMATETC **ppenumFormatEtc) static HRESULT WINAPI IDataObject_fnEnumFormatEtc(LPDATAOBJECT iface, DWORD dwDirection, IEnumFORMATETC **ppenumFormatEtc)
{ {
ICOM_THIS(IDataObjectImpl,iface); ICOM_THIS(IDataObjectImpl,iface);
FIXME (shell, "(%p)->()\n", This); FIXME("(%p)->()\n", This);
return E_NOTIMPL; return E_NOTIMPL;
} }
static HRESULT WINAPI IDataObject_fnDAdvise(LPDATAOBJECT iface, FORMATETC *pformatetc, DWORD advf, IAdviseSink *pAdvSink, DWORD *pdwConnection) static HRESULT WINAPI IDataObject_fnDAdvise(LPDATAOBJECT iface, FORMATETC *pformatetc, DWORD advf, IAdviseSink *pAdvSink, DWORD *pdwConnection)
{ {
ICOM_THIS(IDataObjectImpl,iface); ICOM_THIS(IDataObjectImpl,iface);
FIXME (shell, "(%p)->()\n", This); FIXME("(%p)->()\n", This);
return E_NOTIMPL; return E_NOTIMPL;
} }
static HRESULT WINAPI IDataObject_fnDUnadvise(LPDATAOBJECT iface, DWORD dwConnection) static HRESULT WINAPI IDataObject_fnDUnadvise(LPDATAOBJECT iface, DWORD dwConnection)
{ {
ICOM_THIS(IDataObjectImpl,iface); ICOM_THIS(IDataObjectImpl,iface);
FIXME (shell, "(%p)->()\n", This); FIXME("(%p)->()\n", This);
return E_NOTIMPL; return E_NOTIMPL;
} }
static HRESULT WINAPI IDataObject_fnEnumDAdvise(LPDATAOBJECT iface, IEnumSTATDATA **ppenumAdvise) static HRESULT WINAPI IDataObject_fnEnumDAdvise(LPDATAOBJECT iface, IEnumSTATDATA **ppenumAdvise)
{ {
ICOM_THIS(IDataObjectImpl,iface); ICOM_THIS(IDataObjectImpl,iface);
FIXME (shell, "(%p)->()\n", This); FIXME("(%p)->()\n", This);
return E_NOTIMPL; return E_NOTIMPL;
} }

View file

@ -6,7 +6,7 @@
#include <stdlib.h> #include <stdlib.h>
#include <string.h> #include <string.h>
#include "debug.h" #include "debugtools.h"
#include "wine/obj_base.h" #include "wine/obj_base.h"
#include "wine/obj_enumidlist.h" #include "wine/obj_enumidlist.h"
#include "winerror.h" #include "winerror.h"
@ -55,7 +55,7 @@ IEnumIDList * IEnumIDList_Constructor(
lpeidl->mpLast=NULL; lpeidl->mpLast=NULL;
lpeidl->mpCurrent=NULL; lpeidl->mpCurrent=NULL;
TRACE(shell,"(%p)->(%s flags=0x%08lx)\n",lpeidl,debugstr_a(lpszPath),dwFlags); TRACE("(%p)->(%s flags=0x%08lx)\n",lpeidl,debugstr_a(lpszPath),dwFlags);
if(!IEnumIDList_CreateEnumList((IEnumIDList*)lpeidl, lpszPath, dwFlags)) if(!IEnumIDList_CreateEnumList((IEnumIDList*)lpeidl, lpszPath, dwFlags))
{ if (lpeidl) { if (lpeidl)
@ -64,7 +64,7 @@ IEnumIDList * IEnumIDList_Constructor(
return NULL; return NULL;
} }
TRACE(shell,"-- (%p)->()\n",lpeidl); TRACE("-- (%p)->()\n",lpeidl);
shell32_ObjCount++; shell32_ObjCount++;
return (IEnumIDList*)lpeidl; return (IEnumIDList*)lpeidl;
} }
@ -81,7 +81,7 @@ static HRESULT WINAPI IEnumIDList_fnQueryInterface(
char xriid[50]; char xriid[50];
WINE_StringFromCLSID((LPCLSID)riid,xriid); WINE_StringFromCLSID((LPCLSID)riid,xriid);
TRACE(shell,"(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj); TRACE("(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj);
*ppvObj = NULL; *ppvObj = NULL;
@ -94,11 +94,11 @@ static HRESULT WINAPI IEnumIDList_fnQueryInterface(
if(*ppvObj) if(*ppvObj)
{ IEnumIDList_AddRef((IEnumIDList*)*ppvObj); { IEnumIDList_AddRef((IEnumIDList*)*ppvObj);
TRACE(shell,"-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj); TRACE("-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj);
return S_OK; return S_OK;
} }
TRACE(shell,"-- Interface: E_NOINTERFACE\n"); TRACE("-- Interface: E_NOINTERFACE\n");
return E_NOINTERFACE; return E_NOINTERFACE;
} }
@ -110,7 +110,7 @@ static ULONG WINAPI IEnumIDList_fnAddRef(
{ {
ICOM_THIS(IEnumIDListImpl,iface); ICOM_THIS(IEnumIDListImpl,iface);
TRACE(shell,"(%p)->(%lu)\n",This,This->ref); TRACE("(%p)->(%lu)\n",This,This->ref);
shell32_ObjCount++; shell32_ObjCount++;
return ++(This->ref); return ++(This->ref);
@ -123,12 +123,12 @@ static ULONG WINAPI IEnumIDList_fnRelease(
{ {
ICOM_THIS(IEnumIDListImpl,iface); ICOM_THIS(IEnumIDListImpl,iface);
TRACE(shell,"(%p)->(%lu)\n",This,This->ref); TRACE("(%p)->(%lu)\n",This,This->ref);
shell32_ObjCount--; shell32_ObjCount--;
if (!--(This->ref)) if (!--(This->ref))
{ TRACE(shell," destroying IEnumIDList(%p)\n",This); { TRACE(" destroying IEnumIDList(%p)\n",This);
IEnumIDList_DeleteList((IEnumIDList*)This); IEnumIDList_DeleteList((IEnumIDList*)This);
HeapFree(GetProcessHeap(),0,This); HeapFree(GetProcessHeap(),0,This);
return 0; return 0;
@ -152,7 +152,7 @@ static HRESULT WINAPI IEnumIDList_fnNext(
HRESULT hr = S_OK; HRESULT hr = S_OK;
LPITEMIDLIST temp; LPITEMIDLIST temp;
TRACE(shell,"(%p)->(%ld,%p, %p)\n",This,celt,rgelt,pceltFetched); TRACE("(%p)->(%ld,%p, %p)\n",This,celt,rgelt,pceltFetched);
/* It is valid to leave pceltFetched NULL when celt is 1. Some of explorer's /* It is valid to leave pceltFetched NULL when celt is 1. Some of explorer's
* subsystems actually use it (and so may a third party browser) * subsystems actually use it (and so may a third party browser)
@ -193,7 +193,7 @@ static HRESULT WINAPI IEnumIDList_fnSkip(
DWORD dwIndex; DWORD dwIndex;
HRESULT hr = S_OK; HRESULT hr = S_OK;
TRACE(shell,"(%p)->(%lu)\n",This,celt); TRACE("(%p)->(%lu)\n",This,celt);
for(dwIndex = 0; dwIndex < celt; dwIndex++) for(dwIndex = 0; dwIndex < celt; dwIndex++)
{ if(!This->mpCurrent) { if(!This->mpCurrent)
@ -212,7 +212,7 @@ static HRESULT WINAPI IEnumIDList_fnReset(
{ {
ICOM_THIS(IEnumIDListImpl,iface); ICOM_THIS(IEnumIDListImpl,iface);
TRACE(shell,"(%p)\n",This); TRACE("(%p)\n",This);
This->mpCurrent = This->mpFirst; This->mpCurrent = This->mpFirst;
return S_OK; return S_OK;
} }
@ -224,7 +224,7 @@ static HRESULT WINAPI IEnumIDList_fnClone(
{ {
ICOM_THIS(IEnumIDListImpl,iface); ICOM_THIS(IEnumIDListImpl,iface);
TRACE(shell,"(%p)->() to (%p)->() E_NOTIMPL\n",This,ppenum); TRACE("(%p)->() to (%p)->() E_NOTIMPL\n",This,ppenum);
return E_NOTIMPL; return E_NOTIMPL;
} }
/************************************************************************** /**************************************************************************
@ -247,7 +247,7 @@ static BOOL WINAPI IEnumIDList_fnCreateEnumList(
CHAR szDriveName[4]; CHAR szDriveName[4];
CHAR szPath[MAX_PATH]; CHAR szPath[MAX_PATH];
TRACE(shell,"(%p)->(path=%s flags=0x%08lx) \n",This,debugstr_a(lpszPath),dwFlags); TRACE("(%p)->(path=%s flags=0x%08lx) \n",This,debugstr_a(lpszPath),dwFlags);
if (lpszPath && lpszPath[0]!='\0') if (lpszPath && lpszPath[0]!='\0')
{ strcpy(szPath, lpszPath); { strcpy(szPath, lpszPath);
@ -260,7 +260,7 @@ static BOOL WINAPI IEnumIDList_fnCreateEnumList(
{ /* special case - we can't enumerate the Desktop level Objects (MyComputer,Nethood... { /* special case - we can't enumerate the Desktop level Objects (MyComputer,Nethood...
so we need to fake an enumeration of those.*/ so we need to fake an enumeration of those.*/
if(!lpszPath) if(!lpszPath)
{ TRACE (shell,"-- (%p)-> enumerate SHCONTF_FOLDERS (special) items\n",This); { TRACE("-- (%p)-> enumerate SHCONTF_FOLDERS (special) items\n",This);
/*create the pidl for This item */ /*create the pidl for This item */
pidl = _ILCreateMyComputer(); pidl = _ILCreateMyComputer();
if(pidl) if(pidl)
@ -269,7 +269,7 @@ static BOOL WINAPI IEnumIDList_fnCreateEnumList(
} }
} }
else if (lpszPath[0]=='\0') /* enumerate the drives*/ else if (lpszPath[0]=='\0') /* enumerate the drives*/
{ TRACE (shell,"-- (%p)-> enumerate SHCONTF_FOLDERS (drives)\n",This); { TRACE("-- (%p)-> enumerate SHCONTF_FOLDERS (drives)\n",This);
dwDrivemap = GetLogicalDrives(); dwDrivemap = GetLogicalDrives();
strcpy (szDriveName,"A:\\"); strcpy (szDriveName,"A:\\");
while (szDriveName[0]<='Z') while (szDriveName[0]<='Z')
@ -285,7 +285,7 @@ static BOOL WINAPI IEnumIDList_fnCreateEnumList(
} }
} }
else else
{ TRACE (shell,"-- (%p)-> enumerate SHCONTF_FOLDERS of %s\n",This,debugstr_a(szPath)); { TRACE("-- (%p)-> enumerate SHCONTF_FOLDERS of %s\n",This,debugstr_a(szPath));
hFile = FindFirstFileA(szPath,&stffile); hFile = FindFirstFileA(szPath,&stffile);
if ( hFile != INVALID_HANDLE_VALUE ) if ( hFile != INVALID_HANDLE_VALUE )
{ do { do
@ -312,7 +312,7 @@ static BOOL WINAPI IEnumIDList_fnCreateEnumList(
/*enumerate the non-folder items (values) */ /*enumerate the non-folder items (values) */
if(dwFlags & SHCONTF_NONFOLDERS) if(dwFlags & SHCONTF_NONFOLDERS)
{ if(lpszPath) { if(lpszPath)
{ TRACE (shell,"-- (%p)-> enumerate SHCONTF_NONFOLDERS of %s\n",This,debugstr_a(szPath)); { TRACE("-- (%p)-> enumerate SHCONTF_NONFOLDERS of %s\n",This,debugstr_a(szPath));
hFile = FindFirstFileA(szPath,&stffile); hFile = FindFirstFileA(szPath,&stffile);
if ( hFile != INVALID_HANDLE_VALUE ) if ( hFile != INVALID_HANDLE_VALUE )
{ do { do
@ -350,7 +350,7 @@ static BOOL WINAPI IEnumIDList_fnAddToEnumList(
LPENUMLIST pNew; LPENUMLIST pNew;
TRACE(shell,"(%p)->(pidl=%p)\n",This,pidl); TRACE("(%p)->(pidl=%p)\n",This,pidl);
pNew = (LPENUMLIST)SHAlloc(sizeof(ENUMLIST)); pNew = (LPENUMLIST)SHAlloc(sizeof(ENUMLIST));
if(pNew) if(pNew)
{ /*set the next pointer */ { /*set the next pointer */
@ -370,7 +370,7 @@ static BOOL WINAPI IEnumIDList_fnAddToEnumList(
/*update the last item pointer */ /*update the last item pointer */
This->mpLast = pNew; This->mpLast = pNew;
TRACE(shell,"-- (%p)->(first=%p, last=%p)\n",This,This->mpFirst,This->mpLast); TRACE("-- (%p)->(first=%p, last=%p)\n",This,This->mpFirst,This->mpLast);
return TRUE; return TRUE;
} }
return FALSE; return FALSE;
@ -385,7 +385,7 @@ static BOOL WINAPI IEnumIDList_fnDeleteList(
LPENUMLIST pDelete; LPENUMLIST pDelete;
TRACE(shell,"(%p)->()\n",This); TRACE("(%p)->()\n",This);
while(This->mpFirst) while(This->mpFirst)
{ pDelete = This->mpFirst; { pDelete = This->mpFirst;

View file

@ -10,7 +10,7 @@
#include "wine/obj_base.h" #include "wine/obj_base.h"
#include "wine/obj_extracticon.h" #include "wine/obj_extracticon.h"
#include "debug.h" #include "debugtools.h"
#include "winerror.h" #include "winerror.h"
#include "pidl.h" #include "pidl.h"
@ -51,7 +51,7 @@ IExtractIconA* IExtractIconA_Constructor(LPCITEMIDLIST pidl)
pdump(pidl); pdump(pidl);
TRACE(shell,"(%p)\n",ei); TRACE("(%p)\n",ei);
shell32_ObjCount++; shell32_ObjCount++;
return (IExtractIconA *)ei; return (IExtractIconA *)ei;
} }
@ -64,7 +64,7 @@ static HRESULT WINAPI IExtractIconA_fnQueryInterface( IExtractIconA * iface, REF
char xriid[50]; char xriid[50];
WINE_StringFromCLSID((LPCLSID)riid,xriid); WINE_StringFromCLSID((LPCLSID)riid,xriid);
TRACE(shell,"(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj); TRACE("(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj);
*ppvObj = NULL; *ppvObj = NULL;
@ -80,10 +80,10 @@ static HRESULT WINAPI IExtractIconA_fnQueryInterface( IExtractIconA * iface, REF
if(*ppvObj) if(*ppvObj)
{ IExtractIconA_AddRef((IExtractIconA*) *ppvObj); { IExtractIconA_AddRef((IExtractIconA*) *ppvObj);
TRACE(shell,"-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj); TRACE("-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj);
return S_OK; return S_OK;
} }
TRACE(shell,"-- Interface: E_NOINTERFACE\n"); TRACE("-- Interface: E_NOINTERFACE\n");
return E_NOINTERFACE; return E_NOINTERFACE;
} }
@ -94,7 +94,7 @@ static ULONG WINAPI IExtractIconA_fnAddRef(IExtractIconA * iface)
{ {
ICOM_THIS(IExtractIconAImpl,iface); ICOM_THIS(IExtractIconAImpl,iface);
TRACE(shell,"(%p)->(count=%lu)\n",This, This->ref ); TRACE("(%p)->(count=%lu)\n",This, This->ref );
shell32_ObjCount++; shell32_ObjCount++;
@ -107,12 +107,12 @@ static ULONG WINAPI IExtractIconA_fnRelease(IExtractIconA * iface)
{ {
ICOM_THIS(IExtractIconAImpl,iface); ICOM_THIS(IExtractIconAImpl,iface);
TRACE(shell,"(%p)->()\n",This); TRACE("(%p)->()\n",This);
shell32_ObjCount--; shell32_ObjCount--;
if (!--(This->ref)) if (!--(This->ref))
{ TRACE(shell," destroying IExtractIcon(%p)\n",This); { TRACE(" destroying IExtractIcon(%p)\n",This);
SHFree(This->pidl); SHFree(This->pidl);
HeapFree(GetProcessHeap(),0,This); HeapFree(GetProcessHeap(),0,This);
return 0; return 0;
@ -136,7 +136,7 @@ static HRESULT WINAPI IExtractIconA_fnGetIconLocation(
DWORD ret = S_FALSE, dwNr; DWORD ret = S_FALSE, dwNr;
LPITEMIDLIST pSimplePidl = ILFindLastID(This->pidl); LPITEMIDLIST pSimplePidl = ILFindLastID(This->pidl);
TRACE (shell,"(%p) (flags=%u %p %u %p %p)\n", This, uFlags, szIconFile, cchMax, piIndex, pwFlags); TRACE("(%p) (flags=%u %p %u %p %p)\n", This, uFlags, szIconFile, cchMax, piIndex, pwFlags);
if (pwFlags) if (pwFlags)
*pwFlags = 0; *pwFlags = 0;
@ -195,7 +195,7 @@ static HRESULT WINAPI IExtractIconA_fnGetIconLocation(
} }
} }
TRACE (shell,"-- %s %x\n", (ret==NOERROR)?debugstr_a(szIconFile):"[error]", *piIndex); TRACE("-- %s %x\n", (ret==NOERROR)?debugstr_a(szIconFile):"[error]", *piIndex);
return ret; return ret;
} }
/************************************************************************** /**************************************************************************
@ -205,7 +205,7 @@ static HRESULT WINAPI IExtractIconA_fnExtract(IExtractIconA * iface, LPCSTR pszF
{ {
ICOM_THIS(IExtractIconAImpl,iface); ICOM_THIS(IExtractIconAImpl,iface);
FIXME (shell,"(%p) (file=%p index=%u %p %p size=%u) semi-stub\n", This, pszFile, nIconIndex, phiconLarge, phiconSmall, nIconSize); FIXME("(%p) (file=%p index=%u %p %p size=%u) semi-stub\n", This, pszFile, nIconIndex, phiconLarge, phiconSmall, nIconSize);
if (phiconLarge) if (phiconLarge)
*phiconLarge = pImageList_GetIcon(ShellBigIconList, nIconIndex, ILD_TRANSPARENT); *phiconLarge = pImageList_GetIcon(ShellBigIconList, nIconIndex, ILD_TRANSPARENT);
@ -284,7 +284,7 @@ static HRESULT WINAPI IEIPersistFile_fnGetClassID(
static HRESULT WINAPI IEIPersistFile_fnLoad(IPersistFile* iface, LPCOLESTR pszFileName, DWORD dwMode) static HRESULT WINAPI IEIPersistFile_fnLoad(IPersistFile* iface, LPCOLESTR pszFileName, DWORD dwMode)
{ {
_ICOM_THIS_From_IPersistFile(IExtractIconA, iface); _ICOM_THIS_From_IPersistFile(IExtractIconA, iface);
FIXME(shell,"%p\n", This); FIXME("%p\n", This);
return E_NOTIMPL; return E_NOTIMPL;
} }

View file

@ -12,7 +12,7 @@
#include "cursoricon.h" #include "cursoricon.h"
#include "module.h" #include "module.h"
#include "heap.h" #include "heap.h"
#include "debug.h" #include "debugtools.h"
#include "winversion.h" #include "winversion.h"
#include "shellapi.h" #include "shellapi.h"
@ -48,14 +48,14 @@ typedef struct
#if 0 #if 0
static void dumpIcoDirEnty ( LPicoICONDIRENTRY entry ) static void dumpIcoDirEnty ( LPicoICONDIRENTRY entry )
{ {
TRACE (shell, "width = 0x%08x height = 0x%08x\n", entry->bWidth, entry->bHeight); TRACE("width = 0x%08x height = 0x%08x\n", entry->bWidth, entry->bHeight);
TRACE (shell, "colors = 0x%08x planes = 0x%08x\n", entry->bColorCount, entry->wPlanes); TRACE("colors = 0x%08x planes = 0x%08x\n", entry->bColorCount, entry->wPlanes);
TRACE (shell, "bitcount = 0x%08x bytesinres = 0x%08lx offset = 0x%08lx\n", TRACE("bitcount = 0x%08x bytesinres = 0x%08lx offset = 0x%08lx\n",
entry->wBitCount, entry->dwBytesInRes, entry->dwImageOffset); entry->wBitCount, entry->dwBytesInRes, entry->dwImageOffset);
} }
static void dumpIcoDir ( LPicoICONDIR entry ) static void dumpIcoDir ( LPicoICONDIR entry )
{ {
TRACE (shell, "type = 0x%08x count = 0x%08x\n", entry->idType, entry->idCount); TRACE("type = 0x%08x count = 0x%08x\n", entry->idType, entry->idCount);
} }
#endif #endif
/************************************************************************* /*************************************************************************
@ -66,7 +66,7 @@ static DWORD SHELL_GetResourceTable(HFILE hFile, LPBYTE *retptr)
char magic[4]; char magic[4];
int size; int size;
TRACE(shell,"0x%08x %p\n", hFile, retptr); TRACE("0x%08x %p\n", hFile, retptr);
*retptr = NULL; *retptr = NULL;
_llseek( hFile, 0, SEEK_SET ); _llseek( hFile, 0, SEEK_SET );
@ -121,7 +121,7 @@ static DWORD SHELL_GetResourceTable(HFILE hFile, LPBYTE *retptr)
static BYTE * SHELL_LoadResource( HFILE hFile, NE_NAMEINFO* pNInfo, WORD sizeShift, ULONG *uSize) static BYTE * SHELL_LoadResource( HFILE hFile, NE_NAMEINFO* pNInfo, WORD sizeShift, ULONG *uSize)
{ BYTE* ptr; { BYTE* ptr;
TRACE(shell,"0x%08x %p 0x%08x\n", hFile, pNInfo, sizeShift); TRACE("0x%08x %p 0x%08x\n", hFile, pNInfo, sizeShift);
*uSize = (DWORD)pNInfo->length << sizeShift; *uSize = (DWORD)pNInfo->length << sizeShift;
if( (ptr = (BYTE*)HeapAlloc(GetProcessHeap(),0, *uSize) )) if( (ptr = (BYTE*)HeapAlloc(GetProcessHeap(),0, *uSize) ))
@ -138,7 +138,7 @@ static BYTE * SHELL_LoadResource( HFILE hFile, NE_NAMEINFO* pNInfo, WORD sizeShi
static BYTE * ICO_LoadIcon( HFILE hFile, LPicoICONDIRENTRY lpiIDE, ULONG *uSize) static BYTE * ICO_LoadIcon( HFILE hFile, LPicoICONDIRENTRY lpiIDE, ULONG *uSize)
{ BYTE* ptr; { BYTE* ptr;
TRACE(shell,"0x%08x %p\n", hFile, lpiIDE); TRACE("0x%08x %p\n", hFile, lpiIDE);
*uSize = lpiIDE->dwBytesInRes; *uSize = lpiIDE->dwBytesInRes;
if( (ptr = (BYTE*)HeapAlloc(GetProcessHeap(),0, *uSize)) ) if( (ptr = (BYTE*)HeapAlloc(GetProcessHeap(),0, *uSize)) )
@ -164,7 +164,7 @@ static BYTE * ICO_GetIconDirectory( HFILE hFile, LPicoICONDIR* lplpiID, ULONG *u
LPicoICONDIR lpiID; /* icon resource in file format */ LPicoICONDIR lpiID; /* icon resource in file format */
int i; int i;
TRACE(shell,"0x%08x %p\n", hFile, lplpiID); TRACE("0x%08x %p\n", hFile, lplpiID);
_llseek( hFile, 0, SEEK_SET ); _llseek( hFile, 0, SEEK_SET );
if( _lread(hFile,(char*)&lpcid, HEADER_SIZE_FILE) != HEADER_SIZE_FILE ) if( _lread(hFile,(char*)&lpcid, HEADER_SIZE_FILE) != HEADER_SIZE_FILE )
@ -224,7 +224,7 @@ HGLOBAL WINAPI ICO_ExtractIconEx(LPCSTR lpszExeFileName, HICON * RetPtr, UINT nI
HANDLE fmapping; HANDLE fmapping;
ULONG uSize; ULONG uSize;
TRACE(shell,"(file %s,start %d,extract %d\n", lpszExeFileName, nIconIndex, n); TRACE("(file %s,start %d,extract %d\n", lpszExeFileName, nIconIndex, n);
if( hFile == HFILE_ERROR || !n ) if( hFile == HFILE_ERROR || !n )
return ICO_INVALID_FILE; return ICO_INVALID_FILE;
@ -239,25 +239,25 @@ HGLOBAL WINAPI ICO_ExtractIconEx(LPCSTR lpszExeFileName, HICON * RetPtr, UINT nI
NE_NAMEINFO *pIconDir = NULL; NE_NAMEINFO *pIconDir = NULL;
LPicoICONDIR lpiID = NULL; LPicoICONDIR lpiID = NULL;
TRACE(shell,"-- OS2/icon Signature (0x%08lx)\n", sig); TRACE("-- OS2/icon Signature (0x%08lx)\n", sig);
if( pData == (BYTE*)-1 ) if( pData == (BYTE*)-1 )
{ pCIDir = ICO_GetIconDirectory(hFile, &lpiID, &uSize); /* check for .ICO file */ { pCIDir = ICO_GetIconDirectory(hFile, &lpiID, &uSize); /* check for .ICO file */
if( pCIDir ) if( pCIDir )
{ iconDirCount = 1; iconCount = lpiID->idCount; { iconDirCount = 1; iconCount = lpiID->idCount;
TRACE(shell,"-- icon found %p 0x%08lx 0x%08x 0x%08x\n", pCIDir, uSize, iconDirCount, iconCount); TRACE("-- icon found %p 0x%08lx 0x%08x 0x%08x\n", pCIDir, uSize, iconDirCount, iconCount);
} }
} }
else while( pTInfo->type_id && !(pIconStorage && pIconDir) ) else while( pTInfo->type_id && !(pIconStorage && pIconDir) )
{ if( pTInfo->type_id == NE_RSCTYPE_GROUP_ICON ) /* find icon directory and icon repository */ { if( pTInfo->type_id == NE_RSCTYPE_GROUP_ICON ) /* find icon directory and icon repository */
{ iconDirCount = pTInfo->count; { iconDirCount = pTInfo->count;
pIconDir = ((NE_NAMEINFO*)(pTInfo + 1)); pIconDir = ((NE_NAMEINFO*)(pTInfo + 1));
TRACE(shell,"\tfound directory - %i icon families\n", iconDirCount); TRACE("\tfound directory - %i icon families\n", iconDirCount);
} }
if( pTInfo->type_id == NE_RSCTYPE_ICON ) if( pTInfo->type_id == NE_RSCTYPE_ICON )
{ iconCount = pTInfo->count; { iconCount = pTInfo->count;
pIconStorage = ((NE_NAMEINFO*)(pTInfo + 1)); pIconStorage = ((NE_NAMEINFO*)(pTInfo + 1));
TRACE(shell,"\ttotal icons - %i\n", iconCount); TRACE("\ttotal icons - %i\n", iconCount);
} }
pTInfo = (NE_TYPEINFO *)((char*)(pTInfo+1)+pTInfo->count*sizeof(NE_NAMEINFO)); pTInfo = (NE_TYPEINFO *)((char*)(pTInfo+1)+pTInfo->count*sizeof(NE_NAMEINFO));
} }
@ -320,13 +320,13 @@ HGLOBAL WINAPI ICO_ExtractIconEx(LPCSTR lpszExeFileName, HICON * RetPtr, UINT nI
int i,j; int i,j;
if ( !(fmapping = CreateFileMappingA(hFile,NULL,PAGE_READONLY|SEC_COMMIT,0,0,NULL))) if ( !(fmapping = CreateFileMappingA(hFile,NULL,PAGE_READONLY|SEC_COMMIT,0,0,NULL)))
{ WARN(shell,"failed to create filemap.\n"); /* FIXME, INVALID_HANDLE_VALUE? */ { WARN("failed to create filemap.\n"); /* FIXME, INVALID_HANDLE_VALUE? */
hRet = ICO_INVALID_FILE; hRet = ICO_INVALID_FILE;
goto end_2; /* failure */ goto end_2; /* failure */
} }
if ( !(peimage = MapViewOfFile(fmapping,FILE_MAP_READ,0,0,0))) if ( !(peimage = MapViewOfFile(fmapping,FILE_MAP_READ,0,0,0)))
{ WARN(shell,"failed to mmap filemap.\n"); { WARN("failed to mmap filemap.\n");
hRet = ICO_INVALID_FILE; hRet = ICO_INVALID_FILE;
goto end_2; /* failure */ goto end_2; /* failure */
} }
@ -347,12 +347,12 @@ HGLOBAL WINAPI ICO_ExtractIconEx(LPCSTR lpszExeFileName, HICON * RetPtr, UINT nI
} }
if (!rootresdir) if (!rootresdir)
{ WARN(shell,"haven't found section for resource directory.\n"); { WARN("haven't found section for resource directory.\n");
goto end_4; /* failure */ goto end_4; /* failure */
} }
/* search the group icon dir*/ /* search the group icon dir*/
if (!(icongroupresdir = GetResDirEntryW(rootresdir,RT_GROUP_ICONW, (DWORD)rootresdir,FALSE))) if (!(icongroupresdir = GetResDirEntryW(rootresdir,RT_GROUP_ICONW, (DWORD)rootresdir,FALSE)))
{ WARN(shell,"No Icongroupresourcedirectory!\n"); { WARN("No Icongroupresourcedirectory!\n");
goto end_4; /* failure */ goto end_4; /* failure */
} }
iconDirCount = icongroupresdir->NumberOfNamedEntries+icongroupresdir->NumberOfIdEntries; iconDirCount = icongroupresdir->NumberOfNamedEntries+icongroupresdir->NumberOfIdEntries;
@ -364,7 +364,7 @@ HGLOBAL WINAPI ICO_ExtractIconEx(LPCSTR lpszExeFileName, HICON * RetPtr, UINT nI
} }
if (nIconIndex >= iconDirCount) if (nIconIndex >= iconDirCount)
{ WARN(shell,"nIconIndex %d is larger than iconDirCount %d\n",nIconIndex,iconDirCount); { WARN("nIconIndex %d is larger than iconDirCount %d\n",nIconIndex,iconDirCount);
goto end_4; /* failure */ goto end_4; /* failure */
} }
@ -398,14 +398,14 @@ HGLOBAL WINAPI ICO_ExtractIconEx(LPCSTR lpszExeFileName, HICON * RetPtr, UINT nI
} }
if (!igdata) if (!igdata)
{ WARN(shell,"no matching real address for icongroup!\n"); { WARN("no matching real address for icongroup!\n");
goto end_4; /* failure */ goto end_4; /* failure */
} }
RetPtr[i] = (HICON)pLookupIconIdFromDirectoryEx(igdata, TRUE, cxDesired, cyDesired, LR_DEFAULTCOLOR); RetPtr[i] = (HICON)pLookupIconIdFromDirectoryEx(igdata, TRUE, cxDesired, cyDesired, LR_DEFAULTCOLOR);
} }
if (!(iconresdir=GetResDirEntryW(rootresdir,RT_ICONW,(DWORD)rootresdir,FALSE))) if (!(iconresdir=GetResDirEntryW(rootresdir,RT_ICONW,(DWORD)rootresdir,FALSE)))
{ WARN(shell,"No Iconresourcedirectory!\n"); { WARN("No Iconresourcedirectory!\n");
goto end_4; /* failure */ goto end_4; /* failure */
} }
@ -425,7 +425,7 @@ HGLOBAL WINAPI ICO_ExtractIconEx(LPCSTR lpszExeFileName, HICON * RetPtr, UINT nI
idata = peimage+(idataent->OffsetToData-pe_sections[j].VirtualAddress+pe_sections[j].PointerToRawData); idata = peimage+(idataent->OffsetToData-pe_sections[j].VirtualAddress+pe_sections[j].PointerToRawData);
} }
if (!idata) if (!idata)
{ WARN(shell,"no matching real address found for icondata!\n"); { WARN("no matching real address found for icondata!\n");
RetPtr[i]=0; RetPtr[i]=0;
continue; continue;
} }
@ -467,7 +467,7 @@ typedef struct
* Callback for DPA_Search * Callback for DPA_Search
*/ */
INT CALLBACK SIC_CompareEntrys( LPVOID p1, LPVOID p2, LPARAM lparam) INT CALLBACK SIC_CompareEntrys( LPVOID p1, LPVOID p2, LPARAM lparam)
{ TRACE(shell,"%p %p\n", p1, p2); { TRACE("%p %p\n", p1, p2);
if (((LPSIC_ENTRY)p1)->dwSourceIndex != ((LPSIC_ENTRY)p2)->dwSourceIndex) /* first the faster one*/ if (((LPSIC_ENTRY)p1)->dwSourceIndex != ((LPSIC_ENTRY)p2)->dwSourceIndex) /* first the faster one*/
return 1; return 1;
@ -487,7 +487,7 @@ static INT SIC_IconAppend (LPCSTR sSourceFile, INT dwSourceIndex, HICON hSmallIc
{ LPSIC_ENTRY lpsice; { LPSIC_ENTRY lpsice;
INT index, index1; INT index, index1;
TRACE(shell,"%s %i %x %x\n", sSourceFile, dwSourceIndex, hSmallIcon ,hBigIcon); TRACE("%s %i %x %x\n", sSourceFile, dwSourceIndex, hSmallIcon ,hBigIcon);
lpsice = (LPSIC_ENTRY) SHAlloc (sizeof (SIC_ENTRY)); lpsice = (LPSIC_ENTRY) SHAlloc (sizeof (SIC_ENTRY));
@ -504,7 +504,7 @@ static INT SIC_IconAppend (LPCSTR sSourceFile, INT dwSourceIndex, HICON hSmallIc
index1= pImageList_AddIcon (ShellBigIconList, hBigIcon); index1= pImageList_AddIcon (ShellBigIconList, hBigIcon);
if (index!=index1) if (index!=index1)
{ FIXME(shell,"iconlists out of sync 0x%x 0x%x\n", index, index1); { FIXME("iconlists out of sync 0x%x 0x%x\n", index, index1);
} }
lpsice->dwListIndex = index; lpsice->dwListIndex = index;
@ -526,7 +526,7 @@ static INT SIC_LoadIcon (LPCSTR sSourceFile, INT dwSourceIndex)
if ( !hiconLarge || !hiconSmall) if ( !hiconLarge || !hiconSmall)
{ WARN(shell, "failure loading icon %i from %s (%x %x)\n", dwSourceIndex, sSourceFile, hiconLarge, hiconSmall); { WARN("failure loading icon %i from %s (%x %x)\n", dwSourceIndex, sSourceFile, hiconLarge, hiconSmall);
return -1; return -1;
} }
return SIC_IconAppend (sSourceFile, dwSourceIndex, hiconSmall, hiconLarge); return SIC_IconAppend (sSourceFile, dwSourceIndex, hiconSmall, hiconLarge);
@ -546,7 +546,7 @@ INT SIC_GetIconIndex (LPCSTR sSourceFile, INT dwSourceIndex )
{ SIC_ENTRY sice; { SIC_ENTRY sice;
INT index = INVALID_INDEX; INT index = INVALID_INDEX;
TRACE(shell,"%s %i\n", sSourceFile, dwSourceIndex); TRACE("%s %i\n", sSourceFile, dwSourceIndex);
sice.sSourceFile = PathFindFilenameA(sSourceFile); sice.sSourceFile = PathFindFilenameA(sSourceFile);
sice.dwSourceIndex = dwSourceIndex; sice.dwSourceIndex = dwSourceIndex;
@ -559,7 +559,7 @@ INT SIC_GetIconIndex (LPCSTR sSourceFile, INT dwSourceIndex )
{ return SIC_LoadIcon (sSourceFile, dwSourceIndex); { return SIC_LoadIcon (sSourceFile, dwSourceIndex);
} }
TRACE(shell, "-- found\n"); TRACE("-- found\n");
return ((LPSIC_ENTRY)pDPA_GetPtr(hdpa, index))->dwListIndex; return ((LPSIC_ENTRY)pDPA_GetPtr(hdpa, index))->dwListIndex;
} }
/**************************************************************************** /****************************************************************************
@ -571,7 +571,7 @@ INT SIC_GetIconIndex (LPCSTR sSourceFile, INT dwSourceIndex )
static HICON WINE_UNUSED SIC_GetIcon (LPCSTR sSourceFile, INT dwSourceIndex, BOOL bSmallIcon ) static HICON WINE_UNUSED SIC_GetIcon (LPCSTR sSourceFile, INT dwSourceIndex, BOOL bSmallIcon )
{ INT index; { INT index;
TRACE(shell,"%s %i\n", sSourceFile, dwSourceIndex); TRACE("%s %i\n", sSourceFile, dwSourceIndex);
index = SIC_GetIconIndex(sSourceFile, dwSourceIndex); index = SIC_GetIconIndex(sSourceFile, dwSourceIndex);
if (INVALID_INDEX == index) if (INVALID_INDEX == index)
@ -596,7 +596,7 @@ BOOL SIC_Initialize(void)
HICON *pSmRet, *pLgRet; HICON *pSmRet, *pLgRet;
UINT index; UINT index;
TRACE(shell,"\n"); TRACE("\n");
if (hdpa) /* already initialized?*/ if (hdpa) /* already initialized?*/
return TRUE; return TRUE;
@ -624,9 +624,9 @@ BOOL SIC_Initialize(void)
for (index=0; index<40; index++) for (index=0; index<40; index++)
{ if (! pSmRet[index] ) { if (! pSmRet[index] )
{ MSG("*** failure loading resources from %s\n", szShellPath ); { MESSAGE("*** failure loading resources from %s\n", szShellPath );
MSG("*** this is a hack for loading the internal and external dll at the same time\n"); MESSAGE("*** this is a hack for loading the internal and external dll at the same time\n");
MSG("*** you can ignore it but you will miss some icons in win95 dialogs\n\n"); MESSAGE("*** you can ignore it but you will miss some icons in win95 dialogs\n\n");
break; break;
} }
SIC_IconAppend (szShellPath, index, pSmRet[index], pLgRet[index]); SIC_IconAppend (szShellPath, index, pSmRet[index], pLgRet[index]);
@ -638,7 +638,7 @@ BOOL SIC_Initialize(void)
GlobalUnlock(hSmRet); GlobalUnlock(hSmRet);
GlobalFree(hSmRet); GlobalFree(hSmRet);
TRACE(shell,"hIconSmall=%p hIconBig=%p\n",ShellSmallIconList, ShellBigIconList); TRACE("hIconSmall=%p hIconBig=%p\n",ShellSmallIconList, ShellBigIconList);
return TRUE; return TRUE;
} }
@ -668,7 +668,7 @@ void SIC_Destroy(void)
* *
*/ */
BOOL WINAPI Shell_GetImageList(HIMAGELIST * lpBigList, HIMAGELIST * lpSmallList) BOOL WINAPI Shell_GetImageList(HIMAGELIST * lpBigList, HIMAGELIST * lpSmallList)
{ TRACE(shell,"(%p,%p)\n",lpBigList,lpSmallList); { TRACE("(%p,%p)\n",lpBigList,lpSmallList);
if (lpBigList) if (lpBigList)
{ *lpBigList = ShellBigIconList; { *lpBigList = ShellBigIconList;
} }
@ -696,7 +696,7 @@ BOOL PidlToSicIndex (IShellFolder * sh, LPITEMIDLIST pidl, BOOL bBigIcon, UINT *
BOOL ret = FALSE; BOOL ret = FALSE;
UINT dwFlags = 0; UINT dwFlags = 0;
TRACE(shell,"sf=%p pidl=%p\n", sh, pidl); TRACE("sf=%p pidl=%p\n", sh, pidl);
if (SUCCEEDED (IShellFolder_GetUIObjectOf(sh, 0, 1, &pidl, &IID_IExtractIconA, 0, (void **)&ei))) if (SUCCEEDED (IShellFolder_GetUIObjectOf(sh, 0, 1, &pidl, &IID_IExtractIconA, 0, (void **)&ei)))
{ {
@ -727,7 +727,7 @@ UINT WINAPI SHMapPIDLToSystemImageListIndex(LPSHELLFOLDER sh, LPITEMIDLIST pidl,
{ {
UINT Index; UINT Index;
WARN(shell,"(SF=%p,pidl=%p,%p)\n",sh,pidl,pIndex); WARN("(SF=%p,pidl=%p,%p)\n",sh,pidl,pIndex);
pdump(pidl); pdump(pidl);
if (pIndex) if (pIndex)
@ -742,7 +742,7 @@ UINT WINAPI SHMapPIDLToSystemImageListIndex(LPSHELLFOLDER sh, LPITEMIDLIST pidl,
*/ */
INT WINAPI Shell_GetCachedImageIndexA(LPCSTR szPath, INT nIndex, BOOL bSimulateDoc) INT WINAPI Shell_GetCachedImageIndexA(LPCSTR szPath, INT nIndex, BOOL bSimulateDoc)
{ {
WARN(shell,"(%s,%08x,%08x) semi-stub.\n",debugstr_a(szPath), nIndex, bSimulateDoc); WARN("(%s,%08x,%08x) semi-stub.\n",debugstr_a(szPath), nIndex, bSimulateDoc);
return SIC_GetIconIndex(szPath, nIndex); return SIC_GetIconIndex(szPath, nIndex);
} }
@ -750,7 +750,7 @@ INT WINAPI Shell_GetCachedImageIndexW(LPCWSTR szPath, INT nIndex, BOOL bSimulate
{ INT ret; { INT ret;
LPSTR sTemp = HEAP_strdupWtoA (GetProcessHeap(),0,szPath); LPSTR sTemp = HEAP_strdupWtoA (GetProcessHeap(),0,szPath);
WARN(shell,"(%s,%08x,%08x) semi-stub.\n",debugstr_w(szPath), nIndex, bSimulateDoc); WARN("(%s,%08x,%08x) semi-stub.\n",debugstr_w(szPath), nIndex, bSimulateDoc);
ret = SIC_GetIconIndex(sTemp, nIndex); ret = SIC_GetIconIndex(sTemp, nIndex);
HeapFree(GetProcessHeap(),0,sTemp); HeapFree(GetProcessHeap(),0,sTemp);
@ -781,7 +781,7 @@ HICON WINAPI ExtractIconExAW ( LPCVOID lpszFile, INT nIconIndex, HICON * phiconL
HICON WINAPI ExtractIconExA ( LPCSTR lpszFile, INT nIconIndex, HICON * phiconLarge, HICON * phiconSmall, UINT nIcons ) HICON WINAPI ExtractIconExA ( LPCSTR lpszFile, INT nIconIndex, HICON * phiconLarge, HICON * phiconSmall, UINT nIcons )
{ HICON ret=0; { HICON ret=0;
TRACE(shell,"file=%s idx=%i %p %p num=%i\n", lpszFile, nIconIndex, phiconLarge, phiconSmall, nIcons ); TRACE("file=%s idx=%i %p %p num=%i\n", lpszFile, nIconIndex, phiconLarge, phiconSmall, nIcons );
if (nIconIndex==-1) /* Number of icons requested */ if (nIconIndex==-1) /* Number of icons requested */
return ICO_ExtractIconEx(lpszFile, NULL, -1, 0, 0, 0 ); return ICO_ExtractIconEx(lpszFile, NULL, -1, 0, 0, 0 );
@ -814,7 +814,7 @@ HICON WINAPI ExtractIconExW ( LPCWSTR lpszFile, INT nIconIndex, HICON * phiconLa
{ LPSTR sFile; { LPSTR sFile;
DWORD ret; DWORD ret;
TRACE(shell,"file=%s idx=%i %p %p num=%i\n", debugstr_w(lpszFile), nIconIndex, phiconLarge, phiconSmall, nIcons ); TRACE("file=%s idx=%i %p %p num=%i\n", debugstr_w(lpszFile), nIconIndex, phiconLarge, phiconSmall, nIcons );
sFile = HEAP_strdupWtoA (GetProcessHeap(),0,lpszFile); sFile = HEAP_strdupWtoA (GetProcessHeap(),0,lpszFile);
ret = ExtractIconExA ( sFile, nIconIndex, phiconLarge, phiconSmall, nIcons); ret = ExtractIconExA ( sFile, nIconIndex, phiconLarge, phiconSmall, nIcons);

View file

@ -5,7 +5,7 @@
#include "wine/obj_storage.h" #include "wine/obj_storage.h"
#include "debug.h" #include "debugtools.h"
#include "heap.h" #include "heap.h"
#include "winerror.h" #include "winerror.h"
#include "winreg.h" #include "winreg.h"
@ -48,7 +48,7 @@ IStream *IStream_Constructor(HKEY hKey, LPCSTR pszSubKey, LPCSTR pszValue, DWORD
{ if (dwType == REG_BINARY ) { if (dwType == REG_BINARY )
{ rstr->pszSubKey = HEAP_strdupA (GetProcessHeap(),0, pszSubKey); { rstr->pszSubKey = HEAP_strdupA (GetProcessHeap(),0, pszSubKey);
rstr->pszValue = HEAP_strdupA (GetProcessHeap(),0, pszValue); rstr->pszValue = HEAP_strdupA (GetProcessHeap(),0, pszValue);
TRACE(shell,"(%p)->0x%08x,%s,%s,0x%08lx\n", rstr, hKey, pszSubKey, pszValue, grfMode); TRACE("(%p)->0x%08x,%s,%s,0x%08lx\n", rstr, hKey, pszSubKey, pszValue, grfMode);
shell32_ObjCount++; shell32_ObjCount++;
return (IStream*)rstr; return (IStream*)rstr;
} }
@ -73,7 +73,7 @@ static HRESULT WINAPI IStream_fnQueryInterface(IStream *iface, REFIID riid, LPVO
char xriid[50]; char xriid[50];
WINE_StringFromCLSID((LPCLSID)riid,xriid); WINE_StringFromCLSID((LPCLSID)riid,xriid);
TRACE(shell,"(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj); TRACE("(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj);
*ppvObj = NULL; *ppvObj = NULL;
@ -87,10 +87,10 @@ static HRESULT WINAPI IStream_fnQueryInterface(IStream *iface, REFIID riid, LPVO
if(*ppvObj) if(*ppvObj)
{ {
IStream_AddRef((IStream*)*ppvObj); IStream_AddRef((IStream*)*ppvObj);
TRACE(shell,"-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj); TRACE("-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj);
return S_OK; return S_OK;
} }
TRACE(shell,"-- Interface: E_NOINTERFACE\n"); TRACE("-- Interface: E_NOINTERFACE\n");
return E_NOINTERFACE; return E_NOINTERFACE;
} }
@ -101,7 +101,7 @@ static ULONG WINAPI IStream_fnAddRef(IStream *iface)
{ {
ICOM_THIS(ISHRegStream, iface); ICOM_THIS(ISHRegStream, iface);
TRACE(shell,"(%p)->(count=%lu)\n",This, This->ref); TRACE("(%p)->(count=%lu)\n",This, This->ref);
shell32_ObjCount++; shell32_ObjCount++;
return ++(This->ref); return ++(This->ref);
@ -114,12 +114,12 @@ static ULONG WINAPI IStream_fnRelease(IStream *iface)
{ {
ICOM_THIS(ISHRegStream, iface); ICOM_THIS(ISHRegStream, iface);
TRACE(shell,"(%p)->()\n",This); TRACE("(%p)->()\n",This);
shell32_ObjCount--; shell32_ObjCount--;
if (!--(This->ref)) if (!--(This->ref))
{ TRACE(shell," destroying SHReg IStream (%p)\n",This); { TRACE(" destroying SHReg IStream (%p)\n",This);
if (This->pszSubKey) if (This->pszSubKey)
HeapFree(GetProcessHeap(),0,This->pszSubKey); HeapFree(GetProcessHeap(),0,This->pszSubKey);
@ -145,7 +145,7 @@ HRESULT WINAPI IStream_fnRead (IStream * iface, void* pv, ULONG cb, ULONG* pcbRe
DWORD dwBytesToRead, dwBytesLeft; DWORD dwBytesToRead, dwBytesLeft;
TRACE(shell,"(%p)->(%p,0x%08lx,%p)\n",This, pv, cb, pcbRead); TRACE("(%p)->(%p,0x%08lx,%p)\n",This, pv, cb, pcbRead);
if ( !pv ) if ( !pv )
return STG_E_INVALIDPOINTER; return STG_E_INVALIDPOINTER;
@ -170,7 +170,7 @@ HRESULT WINAPI IStream_fnWrite (IStream * iface, const void* pv, ULONG cb, ULONG
{ {
ICOM_THIS(ISHRegStream, iface); ICOM_THIS(ISHRegStream, iface);
TRACE(shell,"(%p)\n",This); TRACE("(%p)\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -178,7 +178,7 @@ HRESULT WINAPI IStream_fnSeek (IStream * iface, LARGE_INTEGER dlibMove, DWORD dw
{ {
ICOM_THIS(ISHRegStream, iface); ICOM_THIS(ISHRegStream, iface);
TRACE(shell,"(%p)\n",This); TRACE("(%p)\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -186,7 +186,7 @@ HRESULT WINAPI IStream_fnSetSize (IStream * iface, ULARGE_INTEGER libNewSize)
{ {
ICOM_THIS(ISHRegStream, iface); ICOM_THIS(ISHRegStream, iface);
TRACE(shell,"(%p)\n",This); TRACE("(%p)\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -194,7 +194,7 @@ HRESULT WINAPI IStream_fnCopyTo (IStream * iface, IStream* pstm, ULARGE_INTEGER
{ {
ICOM_THIS(ISHRegStream, iface); ICOM_THIS(ISHRegStream, iface);
TRACE(shell,"(%p)\n",This); TRACE("(%p)\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -202,7 +202,7 @@ HRESULT WINAPI IStream_fnCommit (IStream * iface, DWORD grfCommitFlags)
{ {
ICOM_THIS(ISHRegStream, iface); ICOM_THIS(ISHRegStream, iface);
TRACE(shell,"(%p)\n",This); TRACE("(%p)\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -210,7 +210,7 @@ HRESULT WINAPI IStream_fnRevert (IStream * iface)
{ {
ICOM_THIS(ISHRegStream, iface); ICOM_THIS(ISHRegStream, iface);
TRACE(shell,"(%p)\n",This); TRACE("(%p)\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -218,7 +218,7 @@ HRESULT WINAPI IStream_fnLockRegion (IStream * iface, ULARGE_INTEGER libOffset,
{ {
ICOM_THIS(ISHRegStream, iface); ICOM_THIS(ISHRegStream, iface);
TRACE(shell,"(%p)\n",This); TRACE("(%p)\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -226,7 +226,7 @@ HRESULT WINAPI IStream_fnUnlockRegion (IStream * iface, ULARGE_INTEGER libOffset
{ {
ICOM_THIS(ISHRegStream, iface); ICOM_THIS(ISHRegStream, iface);
TRACE(shell,"(%p)\n",This); TRACE("(%p)\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -234,7 +234,7 @@ HRESULT WINAPI IStream_fnStat (IStream * iface, STATSTG* pstatstg, DWORD grfSt
{ {
ICOM_THIS(ISHRegStream, iface); ICOM_THIS(ISHRegStream, iface);
TRACE(shell,"(%p)\n",This); TRACE("(%p)\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -242,7 +242,7 @@ HRESULT WINAPI IStream_fnClone (IStream * iface, IStream** ppstm)
{ {
ICOM_THIS(ISHRegStream, iface); ICOM_THIS(ISHRegStream, iface);
TRACE(shell,"(%p)\n",This); TRACE("(%p)\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -275,6 +275,6 @@ static struct ICOM_VTABLE(IStream) rstvt =
*/ */
IStream * WINAPI OpenRegStream(HKEY hkey, LPCSTR pszSubkey, LPCSTR pszValue, DWORD grfMode) IStream * WINAPI OpenRegStream(HKEY hkey, LPCSTR pszSubkey, LPCSTR pszValue, DWORD grfMode)
{ {
TRACE(shell,"(0x%08x,%s,%s,0x%08lx)\n",hkey, pszSubkey, pszValue, grfMode); TRACE("(0x%08x,%s,%s,0x%08lx)\n",hkey, pszSubkey, pszValue, grfMode);
return IStream_Constructor(hkey, pszSubkey, pszValue, grfMode); return IStream_Constructor(hkey, pszSubkey, pszValue, grfMode);
} }

View file

@ -6,7 +6,7 @@
*/ */
#include <string.h> #include <string.h>
#include "debug.h" #include "debugtools.h"
#include "winerror.h" #include "winerror.h"
#include "wine/obj_base.h" #include "wine/obj_base.h"
@ -81,7 +81,7 @@ IPersistFileImpl * IPersistFile_Constructor(void)
sl->sPath = NULL; sl->sPath = NULL;
sl->pPidl = NULL; sl->pPidl = NULL;
TRACE(shell,"(%p)->()\n",sl); TRACE("(%p)->()\n",sl);
shell32_ObjCount++; shell32_ObjCount++;
return sl; return sl;
} }
@ -96,7 +96,7 @@ static HRESULT WINAPI IPersistFile_fnQueryInterface(
char xriid[50]; char xriid[50];
WINE_StringFromCLSID((LPCLSID)riid,xriid); WINE_StringFromCLSID((LPCLSID)riid,xriid);
TRACE(shell,"(%p)->(\n\tIID:\t%s)\n",This,xriid); TRACE("(%p)->(\n\tIID:\t%s)\n",This,xriid);
*ppvObj = NULL; *ppvObj = NULL;
@ -109,10 +109,10 @@ static HRESULT WINAPI IPersistFile_fnQueryInterface(
if(*ppvObj) if(*ppvObj)
{ IPersistFile_AddRef((IPersistFile*)*ppvObj); { IPersistFile_AddRef((IPersistFile*)*ppvObj);
TRACE(shell,"-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj); TRACE("-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj);
return S_OK; return S_OK;
} }
TRACE(shell,"-- Interface: E_NOINTERFACE\n"); TRACE("-- Interface: E_NOINTERFACE\n");
return E_NOINTERFACE; return E_NOINTERFACE;
} }
/****************************************************************************** /******************************************************************************
@ -122,7 +122,7 @@ static ULONG WINAPI IPersistFile_fnAddRef(IPersistFile* iface)
{ {
ICOM_THIS(IPersistFileImpl,iface); ICOM_THIS(IPersistFileImpl,iface);
TRACE(shell,"(%p)->(count=%lu)\n",This,This->ref); TRACE("(%p)->(count=%lu)\n",This,This->ref);
shell32_ObjCount++; shell32_ObjCount++;
return ++(This->ref); return ++(This->ref);
@ -134,12 +134,12 @@ static ULONG WINAPI IPersistFile_fnRelease(IPersistFile* iface)
{ {
ICOM_THIS(IPersistFileImpl,iface); ICOM_THIS(IPersistFileImpl,iface);
TRACE(shell,"(%p)->(count=%lu)\n",This,This->ref); TRACE("(%p)->(count=%lu)\n",This,This->ref);
shell32_ObjCount--; shell32_ObjCount--;
if (!--(This->ref)) if (!--(This->ref))
{ TRACE(shell,"-- destroying IPersistFile(%p)\n",This); { TRACE("-- destroying IPersistFile(%p)\n",This);
if (This->sPath) if (This->sPath)
HeapFree(GetProcessHeap(),0,This->sPath); HeapFree(GetProcessHeap(),0,This->sPath);
if (This->pPidl) if (This->pPidl)
@ -153,13 +153,13 @@ static ULONG WINAPI IPersistFile_fnRelease(IPersistFile* iface)
static HRESULT WINAPI IPersistFile_fnGetClassID(const IPersistFile* iface, CLSID *pClassID) static HRESULT WINAPI IPersistFile_fnGetClassID(const IPersistFile* iface, CLSID *pClassID)
{ {
ICOM_CTHIS(IPersistFile,iface); ICOM_CTHIS(IPersistFile,iface);
FIXME(shell,"(%p)\n",This); FIXME("(%p)\n",This);
return NOERROR; return NOERROR;
} }
static HRESULT WINAPI IPersistFile_fnIsDirty(const IPersistFile* iface) static HRESULT WINAPI IPersistFile_fnIsDirty(const IPersistFile* iface)
{ {
ICOM_CTHIS(IPersistFile,iface); ICOM_CTHIS(IPersistFile,iface);
FIXME(shell,"(%p)\n",This); FIXME("(%p)\n",This);
return NOERROR; return NOERROR;
} }
static HRESULT WINAPI IPersistFile_fnLoad(IPersistFile* iface, LPCOLESTR pszFileName, DWORD dwMode) static HRESULT WINAPI IPersistFile_fnLoad(IPersistFile* iface, LPCOLESTR pszFileName, DWORD dwMode)
@ -174,22 +174,22 @@ static HRESULT WINAPI IPersistFile_fnLoad(IPersistFile* iface, LPCOLESTR pszFile
HRESULT hRet = E_FAIL; HRESULT hRet = E_FAIL;
CHAR sTemp[512]; CHAR sTemp[512];
TRACE(shell,"(%p)->(%s)\n",This,sFile); TRACE("(%p)->(%s)\n",This,sFile);
HeapFree(GetProcessHeap(),0,sFile); HeapFree(GetProcessHeap(),0,sFile);
if ( !(hMapping = CreateFileMappingA(hFile,NULL,PAGE_READONLY|SEC_COMMIT,0,0,NULL))) if ( !(hMapping = CreateFileMappingA(hFile,NULL,PAGE_READONLY|SEC_COMMIT,0,0,NULL)))
{ WARN(shell,"failed to create filemap.\n"); { WARN("failed to create filemap.\n");
goto end_1; goto end_1;
} }
if ( !(pImage = (PLINK_HEADER) MapViewOfFile(hMapping,FILE_MAP_READ,0,0,0))) if ( !(pImage = (PLINK_HEADER) MapViewOfFile(hMapping,FILE_MAP_READ,0,0,0)))
{ WARN(shell,"failed to mmap filemap.\n"); { WARN("failed to mmap filemap.\n");
goto end_2; goto end_2;
} }
if (!( (pImage->MagicStr == 0x0000004CL) && IsEqualIID(&pImage->MagicGuid, &CLSID_ShellLink))) if (!( (pImage->MagicStr == 0x0000004CL) && IsEqualIID(&pImage->MagicGuid, &CLSID_ShellLink)))
{ TRACE(shell,"file isn't a lnk\n"); { TRACE("file isn't a lnk\n");
goto end_3; goto end_3;
} }
@ -197,15 +197,15 @@ static HRESULT WINAPI IPersistFile_fnLoad(IPersistFile* iface, LPCOLESTR pszFile
SYSTEMTIME time; SYSTEMTIME time;
FileTimeToSystemTime (&pImage->Time1, &time); FileTimeToSystemTime (&pImage->Time1, &time);
GetDateFormatA(LOCALE_USER_DEFAULT,DATE_SHORTDATE,&time, NULL, sTemp, 256); GetDateFormatA(LOCALE_USER_DEFAULT,DATE_SHORTDATE,&time, NULL, sTemp, 256);
TRACE(shell, "-- time1: %s\n", sTemp); TRACE("-- time1: %s\n", sTemp);
FileTimeToSystemTime (&pImage->Time2, &time); FileTimeToSystemTime (&pImage->Time2, &time);
GetDateFormatA(LOCALE_USER_DEFAULT,DATE_SHORTDATE,&time, NULL, sTemp, 256); GetDateFormatA(LOCALE_USER_DEFAULT,DATE_SHORTDATE,&time, NULL, sTemp, 256);
TRACE(shell, "-- time2: %s\n", sTemp); TRACE("-- time2: %s\n", sTemp);
FileTimeToSystemTime (&pImage->Time3, &time); FileTimeToSystemTime (&pImage->Time3, &time);
GetDateFormatA(LOCALE_USER_DEFAULT,DATE_SHORTDATE,&time, NULL, sTemp, 256); GetDateFormatA(LOCALE_USER_DEFAULT,DATE_SHORTDATE,&time, NULL, sTemp, 256);
TRACE(shell, "-- time3: %s\n", sTemp); TRACE("-- time3: %s\n", sTemp);
pdump (&pImage->Pidl); pdump (&pImage->Pidl);
} }
@ -228,19 +228,19 @@ end_1: _lclose( hFile);
static HRESULT WINAPI IPersistFile_fnSave(IPersistFile* iface, LPCOLESTR pszFileName, BOOL fRemember) static HRESULT WINAPI IPersistFile_fnSave(IPersistFile* iface, LPCOLESTR pszFileName, BOOL fRemember)
{ {
ICOM_THIS(IPersistFileImpl,iface); ICOM_THIS(IPersistFileImpl,iface);
FIXME(shell,"(%p)->(%s)\n",This,debugstr_w(pszFileName)); FIXME("(%p)->(%s)\n",This,debugstr_w(pszFileName));
return NOERROR; return NOERROR;
} }
static HRESULT WINAPI IPersistFile_fnSaveCompleted(IPersistFile* iface, LPCOLESTR pszFileName) static HRESULT WINAPI IPersistFile_fnSaveCompleted(IPersistFile* iface, LPCOLESTR pszFileName)
{ {
ICOM_THIS(IPersistFileImpl,iface); ICOM_THIS(IPersistFileImpl,iface);
FIXME(shell,"(%p)->(%s)\n",This,debugstr_w(pszFileName)); FIXME("(%p)->(%s)\n",This,debugstr_w(pszFileName));
return NOERROR; return NOERROR;
} }
static HRESULT WINAPI IPersistFile_fnGetCurFile(const IPersistFile* iface, LPOLESTR *ppszFileName) static HRESULT WINAPI IPersistFile_fnGetCurFile(const IPersistFile* iface, LPOLESTR *ppszFileName)
{ {
ICOM_CTHIS(IPersistFileImpl,iface); ICOM_CTHIS(IPersistFileImpl,iface);
FIXME(shell,"(%p)\n",This); FIXME("(%p)\n",This);
return NOERROR; return NOERROR;
} }
@ -282,7 +282,7 @@ LPCLASSFACTORY IShellLink_CF_Constructor(void)
lpclf= (IClassFactoryImpl*)HeapAlloc(GetProcessHeap(),0,sizeof(IClassFactoryImpl)); lpclf= (IClassFactoryImpl*)HeapAlloc(GetProcessHeap(),0,sizeof(IClassFactoryImpl));
lpclf->ref = 1; lpclf->ref = 1;
lpclf->lpvtbl = &slcfvt; lpclf->lpvtbl = &slcfvt;
TRACE(shell,"(%p)->()\n",lpclf); TRACE("(%p)->()\n",lpclf);
shell32_ObjCount++; shell32_ObjCount++;
return (LPCLASSFACTORY)lpclf; return (LPCLASSFACTORY)lpclf;
} }
@ -295,7 +295,7 @@ static HRESULT WINAPI IShellLink_CF_QueryInterface(
ICOM_THIS(IClassFactoryImpl,iface); ICOM_THIS(IClassFactoryImpl,iface);
char xriid[50]; char xriid[50];
WINE_StringFromCLSID((LPCLSID)riid,xriid); WINE_StringFromCLSID((LPCLSID)riid,xriid);
TRACE(shell,"(%p)->(\n\tIID:\t%s)\n",This,xriid); TRACE("(%p)->(\n\tIID:\t%s)\n",This,xriid);
*ppvObj = NULL; *ppvObj = NULL;
@ -308,10 +308,10 @@ static HRESULT WINAPI IShellLink_CF_QueryInterface(
if(*ppvObj) if(*ppvObj)
{ IUnknown_AddRef((IUnknown*)*ppvObj); { IUnknown_AddRef((IUnknown*)*ppvObj);
TRACE(shell,"-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj); TRACE("-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj);
return S_OK; return S_OK;
} }
TRACE(shell,"-- Interface: E_NOINTERFACE\n"); TRACE("-- Interface: E_NOINTERFACE\n");
return E_NOINTERFACE; return E_NOINTERFACE;
} }
/****************************************************************************** /******************************************************************************
@ -320,7 +320,7 @@ static HRESULT WINAPI IShellLink_CF_QueryInterface(
static ULONG WINAPI IShellLink_CF_AddRef(IClassFactory* iface) static ULONG WINAPI IShellLink_CF_AddRef(IClassFactory* iface)
{ {
ICOM_THIS(IClassFactoryImpl,iface); ICOM_THIS(IClassFactoryImpl,iface);
TRACE(shell,"(%p)->(count=%lu)\n",This,This->ref); TRACE("(%p)->(count=%lu)\n",This,This->ref);
shell32_ObjCount++; shell32_ObjCount++;
return ++(This->ref); return ++(This->ref);
@ -331,11 +331,11 @@ static ULONG WINAPI IShellLink_CF_AddRef(IClassFactory* iface)
static ULONG WINAPI IShellLink_CF_Release(IClassFactory* iface) static ULONG WINAPI IShellLink_CF_Release(IClassFactory* iface)
{ {
ICOM_THIS(IClassFactoryImpl,iface); ICOM_THIS(IClassFactoryImpl,iface);
TRACE(shell,"(%p)->(count=%lu)\n",This,This->ref); TRACE("(%p)->(count=%lu)\n",This,This->ref);
shell32_ObjCount--; shell32_ObjCount--;
if (!--(This->ref)) if (!--(This->ref))
{ TRACE(shell,"-- destroying IClassFactory(%p)\n",This); { TRACE("-- destroying IClassFactory(%p)\n",This);
HeapFree(GetProcessHeap(),0,This); HeapFree(GetProcessHeap(),0,This);
return 0; return 0;
} }
@ -353,7 +353,7 @@ static HRESULT WINAPI IShellLink_CF_CreateInstance(
char xriid[50]; char xriid[50];
WINE_StringFromCLSID((LPCLSID)riid,xriid); WINE_StringFromCLSID((LPCLSID)riid,xriid);
TRACE(shell,"%p->(%p,\n\tIID:\t%s,%p)\n",This,pUnknown,xriid,ppObject); TRACE("%p->(%p,\n\tIID:\t%s,%p)\n",This,pUnknown,xriid,ppObject);
*ppObject = NULL; *ppObject = NULL;
@ -365,7 +365,7 @@ static HRESULT WINAPI IShellLink_CF_CreateInstance(
{ pObj = (IUnknown *)IShellLink_Constructor(); { pObj = (IUnknown *)IShellLink_Constructor();
} }
else else
{ ERR(shell,"unknown IID requested\n\tIID:\t%s\n",xriid); { ERR("unknown IID requested\n\tIID:\t%s\n",xriid);
return(E_NOINTERFACE); return(E_NOINTERFACE);
} }
@ -375,7 +375,7 @@ static HRESULT WINAPI IShellLink_CF_CreateInstance(
hres = IUnknown_QueryInterface(pObj,riid, ppObject); hres = IUnknown_QueryInterface(pObj,riid, ppObject);
IUnknown_Release(pObj); IUnknown_Release(pObj);
TRACE(shell,"-- Object created: (%p)->%p\n",This,*ppObject); TRACE("-- Object created: (%p)->%p\n",This,*ppObject);
return hres; return hres;
} }
@ -385,7 +385,7 @@ static HRESULT WINAPI IShellLink_CF_CreateInstance(
static HRESULT WINAPI IShellLink_CF_LockServer(IClassFactory* iface, BOOL fLock) static HRESULT WINAPI IShellLink_CF_LockServer(IClassFactory* iface, BOOL fLock)
{ {
ICOM_THIS(IClassFactoryImpl,iface); ICOM_THIS(IClassFactoryImpl,iface);
TRACE(shell,"%p->(0x%x), not implemented\n",This, fLock); TRACE("%p->(0x%x), not implemented\n",This, fLock);
return E_NOTIMPL; return E_NOTIMPL;
} }
static ICOM_VTABLE(IClassFactory) slcfvt = static ICOM_VTABLE(IClassFactory) slcfvt =
@ -424,7 +424,7 @@ IShellLink * IShellLink_Constructor(void)
sl->lppf = IPersistFile_Constructor(); sl->lppf = IPersistFile_Constructor();
TRACE(shell,"(%p)->()\n",sl); TRACE("(%p)->()\n",sl);
shell32_ObjCount++; shell32_ObjCount++;
return (IShellLink *)sl; return (IShellLink *)sl;
} }
@ -438,7 +438,7 @@ static HRESULT WINAPI IShellLink_fnQueryInterface( IShellLink * iface, REFIID ri
char xriid[50]; char xriid[50];
WINE_StringFromCLSID((LPCLSID)riid,xriid); WINE_StringFromCLSID((LPCLSID)riid,xriid);
TRACE(shell,"(%p)->(\n\tIID:\t%s)\n",This,xriid); TRACE("(%p)->(\n\tIID:\t%s)\n",This,xriid);
*ppvObj = NULL; *ppvObj = NULL;
@ -454,10 +454,10 @@ static HRESULT WINAPI IShellLink_fnQueryInterface( IShellLink * iface, REFIID ri
if(*ppvObj) if(*ppvObj)
{ IShellLink_AddRef((IShellLink*)*ppvObj); { IShellLink_AddRef((IShellLink*)*ppvObj);
TRACE(shell,"-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj); TRACE("-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj);
return S_OK; return S_OK;
} }
TRACE(shell,"-- Interface: E_NOINTERFACE\n"); TRACE("-- Interface: E_NOINTERFACE\n");
return E_NOINTERFACE; return E_NOINTERFACE;
} }
/****************************************************************************** /******************************************************************************
@ -467,7 +467,7 @@ static ULONG WINAPI IShellLink_fnAddRef(IShellLink * iface)
{ {
ICOM_THIS(IShellLinkImpl, iface); ICOM_THIS(IShellLinkImpl, iface);
TRACE(shell,"(%p)->(count=%lu)\n",This,This->ref); TRACE("(%p)->(count=%lu)\n",This,This->ref);
shell32_ObjCount++; shell32_ObjCount++;
return ++(This->ref); return ++(This->ref);
@ -479,11 +479,11 @@ static ULONG WINAPI IShellLink_fnRelease(IShellLink * iface)
{ {
ICOM_THIS(IShellLinkImpl, iface); ICOM_THIS(IShellLinkImpl, iface);
TRACE(shell,"(%p)->(count=%lu)\n",This,This->ref); TRACE("(%p)->(count=%lu)\n",This,This->ref);
shell32_ObjCount--; shell32_ObjCount--;
if (!--(This->ref)) if (!--(This->ref))
{ TRACE(shell,"-- destroying IShellLink(%p)\n",This); { TRACE("-- destroying IShellLink(%p)\n",This);
IPersistFile_Release((IPersistFile*) This->lppf); /* IPersistFile*/ IPersistFile_Release((IPersistFile*) This->lppf); /* IPersistFile*/
HeapFree(GetProcessHeap(),0,This); HeapFree(GetProcessHeap(),0,This);
return 0; return 0;
@ -495,7 +495,7 @@ static HRESULT WINAPI IShellLink_fnGetPath(IShellLink * iface, LPSTR pszFile,INT
{ {
ICOM_THIS(IShellLinkImpl, iface); ICOM_THIS(IShellLinkImpl, iface);
TRACE(shell,"(%p)->(pfile=%p len=%u find_data=%p flags=%lu)\n",This, pszFile, cchMaxPath, pfd, fFlags); TRACE("(%p)->(pfile=%p len=%u find_data=%p flags=%lu)\n",This, pszFile, cchMaxPath, pfd, fFlags);
strncpy(pszFile,This->lppf->sPath, cchMaxPath); strncpy(pszFile,This->lppf->sPath, cchMaxPath);
return NOERROR; return NOERROR;
@ -504,7 +504,7 @@ static HRESULT WINAPI IShellLink_fnGetIDList(IShellLink * iface, LPITEMIDLIST *
{ {
ICOM_THIS(IShellLinkImpl, iface); ICOM_THIS(IShellLinkImpl, iface);
TRACE(shell,"(%p)->(ppidl=%p)\n",This, ppidl); TRACE("(%p)->(ppidl=%p)\n",This, ppidl);
*ppidl = ILClone(This->lppf->pPidl); *ppidl = ILClone(This->lppf->pPidl);
return NOERROR; return NOERROR;
@ -513,7 +513,7 @@ static HRESULT WINAPI IShellLink_fnSetIDList(IShellLink * iface, LPCITEMIDLIST p
{ {
ICOM_THIS(IShellLinkImpl, iface); ICOM_THIS(IShellLinkImpl, iface);
TRACE (shell,"(%p)->(pidl=%p)\n",This, pidl); TRACE("(%p)->(pidl=%p)\n",This, pidl);
if (This->lppf->pPidl) if (This->lppf->pPidl)
SHFree(This->lppf->pPidl); SHFree(This->lppf->pPidl);
@ -524,7 +524,7 @@ static HRESULT WINAPI IShellLink_fnGetDescription(IShellLink * iface, LPSTR pszN
{ {
ICOM_THIS(IShellLinkImpl, iface); ICOM_THIS(IShellLinkImpl, iface);
FIXME(shell,"(%p)->(%p len=%u)\n",This, pszName, cchMaxName); FIXME("(%p)->(%p len=%u)\n",This, pszName, cchMaxName);
strncpy(pszName,"Description, FIXME",cchMaxName); strncpy(pszName,"Description, FIXME",cchMaxName);
return NOERROR; return NOERROR;
} }
@ -532,14 +532,14 @@ static HRESULT WINAPI IShellLink_fnSetDescription(IShellLink * iface, LPCSTR psz
{ {
ICOM_THIS(IShellLinkImpl, iface); ICOM_THIS(IShellLinkImpl, iface);
FIXME(shell,"(%p)->(desc=%s)\n",This, pszName); FIXME("(%p)->(desc=%s)\n",This, pszName);
return NOERROR; return NOERROR;
} }
static HRESULT WINAPI IShellLink_fnGetWorkingDirectory(IShellLink * iface, LPSTR pszDir,INT cchMaxPath) static HRESULT WINAPI IShellLink_fnGetWorkingDirectory(IShellLink * iface, LPSTR pszDir,INT cchMaxPath)
{ {
ICOM_THIS(IShellLinkImpl, iface); ICOM_THIS(IShellLinkImpl, iface);
FIXME(shell,"(%p)->()\n",This); FIXME("(%p)->()\n",This);
strncpy(pszDir,"c:\\", cchMaxPath); strncpy(pszDir,"c:\\", cchMaxPath);
return NOERROR; return NOERROR;
} }
@ -547,14 +547,14 @@ static HRESULT WINAPI IShellLink_fnSetWorkingDirectory(IShellLink * iface, LPCST
{ {
ICOM_THIS(IShellLinkImpl, iface); ICOM_THIS(IShellLinkImpl, iface);
FIXME(shell,"(%p)->(dir=%s)\n",This, pszDir); FIXME("(%p)->(dir=%s)\n",This, pszDir);
return NOERROR; return NOERROR;
} }
static HRESULT WINAPI IShellLink_fnGetArguments(IShellLink * iface, LPSTR pszArgs,INT cchMaxPath) static HRESULT WINAPI IShellLink_fnGetArguments(IShellLink * iface, LPSTR pszArgs,INT cchMaxPath)
{ {
ICOM_THIS(IShellLinkImpl, iface); ICOM_THIS(IShellLinkImpl, iface);
FIXME(shell,"(%p)->(%p len=%u)\n",This, pszArgs, cchMaxPath); FIXME("(%p)->(%p len=%u)\n",This, pszArgs, cchMaxPath);
strncpy(pszArgs, "", cchMaxPath); strncpy(pszArgs, "", cchMaxPath);
return NOERROR; return NOERROR;
} }
@ -562,14 +562,14 @@ static HRESULT WINAPI IShellLink_fnSetArguments(IShellLink * iface, LPCSTR pszAr
{ {
ICOM_THIS(IShellLinkImpl, iface); ICOM_THIS(IShellLinkImpl, iface);
FIXME(shell,"(%p)->(args=%s)\n",This, pszArgs); FIXME("(%p)->(args=%s)\n",This, pszArgs);
return NOERROR; return NOERROR;
} }
static HRESULT WINAPI IShellLink_fnGetHotkey(IShellLink * iface, WORD *pwHotkey) static HRESULT WINAPI IShellLink_fnGetHotkey(IShellLink * iface, WORD *pwHotkey)
{ {
ICOM_THIS(IShellLinkImpl, iface); ICOM_THIS(IShellLinkImpl, iface);
FIXME(shell,"(%p)->(%p) returning 0\n",This, pwHotkey); FIXME("(%p)->(%p) returning 0\n",This, pwHotkey);
*pwHotkey=0x0; *pwHotkey=0x0;
return NOERROR; return NOERROR;
} }
@ -577,14 +577,14 @@ static HRESULT WINAPI IShellLink_fnSetHotkey(IShellLink * iface, WORD wHotkey)
{ {
ICOM_THIS(IShellLinkImpl, iface); ICOM_THIS(IShellLinkImpl, iface);
FIXME(shell,"(%p)->(hotkey=%x)\n",This, wHotkey); FIXME("(%p)->(hotkey=%x)\n",This, wHotkey);
return NOERROR; return NOERROR;
} }
static HRESULT WINAPI IShellLink_fnGetShowCmd(IShellLink * iface, INT *piShowCmd) static HRESULT WINAPI IShellLink_fnGetShowCmd(IShellLink * iface, INT *piShowCmd)
{ {
ICOM_THIS(IShellLinkImpl, iface); ICOM_THIS(IShellLinkImpl, iface);
FIXME(shell,"(%p)->(%p)\n",This, piShowCmd); FIXME("(%p)->(%p)\n",This, piShowCmd);
*piShowCmd=0; *piShowCmd=0;
return NOERROR; return NOERROR;
} }
@ -592,14 +592,14 @@ static HRESULT WINAPI IShellLink_fnSetShowCmd(IShellLink * iface, INT iShowCmd)
{ {
ICOM_THIS(IShellLinkImpl, iface); ICOM_THIS(IShellLinkImpl, iface);
FIXME(shell,"(%p)->(showcmd=%x)\n",This, iShowCmd); FIXME("(%p)->(showcmd=%x)\n",This, iShowCmd);
return NOERROR; return NOERROR;
} }
static HRESULT WINAPI IShellLink_fnGetIconLocation(IShellLink * iface, LPSTR pszIconPath,INT cchIconPath,INT *piIcon) static HRESULT WINAPI IShellLink_fnGetIconLocation(IShellLink * iface, LPSTR pszIconPath,INT cchIconPath,INT *piIcon)
{ {
ICOM_THIS(IShellLinkImpl, iface); ICOM_THIS(IShellLinkImpl, iface);
FIXME(shell,"(%p)->(%p len=%u iicon=%p)\n",This, pszIconPath, cchIconPath, piIcon); FIXME("(%p)->(%p len=%u iicon=%p)\n",This, pszIconPath, cchIconPath, piIcon);
strncpy(pszIconPath,"shell32.dll",cchIconPath); strncpy(pszIconPath,"shell32.dll",cchIconPath);
*piIcon=1; *piIcon=1;
return NOERROR; return NOERROR;
@ -608,28 +608,28 @@ static HRESULT WINAPI IShellLink_fnSetIconLocation(IShellLink * iface, LPCSTR ps
{ {
ICOM_THIS(IShellLinkImpl, iface); ICOM_THIS(IShellLinkImpl, iface);
FIXME(shell,"(%p)->(path=%s iicon=%u)\n",This, pszIconPath, iIcon); FIXME("(%p)->(path=%s iicon=%u)\n",This, pszIconPath, iIcon);
return NOERROR; return NOERROR;
} }
static HRESULT WINAPI IShellLink_fnSetRelativePath(IShellLink * iface, LPCSTR pszPathRel, DWORD dwReserved) static HRESULT WINAPI IShellLink_fnSetRelativePath(IShellLink * iface, LPCSTR pszPathRel, DWORD dwReserved)
{ {
ICOM_THIS(IShellLinkImpl, iface); ICOM_THIS(IShellLinkImpl, iface);
FIXME(shell,"(%p)->(path=%s %lx)\n",This, pszPathRel, dwReserved); FIXME("(%p)->(path=%s %lx)\n",This, pszPathRel, dwReserved);
return NOERROR; return NOERROR;
} }
static HRESULT WINAPI IShellLink_fnResolve(IShellLink * iface, HWND hwnd, DWORD fFlags) static HRESULT WINAPI IShellLink_fnResolve(IShellLink * iface, HWND hwnd, DWORD fFlags)
{ {
ICOM_THIS(IShellLinkImpl, iface); ICOM_THIS(IShellLinkImpl, iface);
FIXME(shell,"(%p)->(hwnd=%x flags=%lx)\n",This, hwnd, fFlags); FIXME("(%p)->(hwnd=%x flags=%lx)\n",This, hwnd, fFlags);
return NOERROR; return NOERROR;
} }
static HRESULT WINAPI IShellLink_fnSetPath(IShellLink * iface, LPCSTR pszFile) static HRESULT WINAPI IShellLink_fnSetPath(IShellLink * iface, LPCSTR pszFile)
{ {
ICOM_THIS(IShellLinkImpl, iface); ICOM_THIS(IShellLinkImpl, iface);
FIXME(shell,"(%p)->(path=%s)\n",This, pszFile); FIXME("(%p)->(path=%s)\n",This, pszFile);
return NOERROR; return NOERROR;
} }
@ -680,7 +680,7 @@ LPCLASSFACTORY IShellLinkW_CF_Constructor(void)
lpclf= (IClassFactoryImpl*)HeapAlloc(GetProcessHeap(),0,sizeof(IClassFactoryImpl)); lpclf= (IClassFactoryImpl*)HeapAlloc(GetProcessHeap(),0,sizeof(IClassFactoryImpl));
lpclf->ref = 1; lpclf->ref = 1;
lpclf->lpvtbl = &slwcfvt; lpclf->lpvtbl = &slwcfvt;
TRACE(shell,"(%p)->()\n",lpclf); TRACE("(%p)->()\n",lpclf);
shell32_ObjCount++; shell32_ObjCount++;
return (LPCLASSFACTORY)lpclf; return (LPCLASSFACTORY)lpclf;
} }
@ -693,7 +693,7 @@ static HRESULT WINAPI IShellLinkW_CF_QueryInterface(
ICOM_THIS(IClassFactoryImpl,iface); ICOM_THIS(IClassFactoryImpl,iface);
char xriid[50]; char xriid[50];
WINE_StringFromCLSID((LPCLSID)riid,xriid); WINE_StringFromCLSID((LPCLSID)riid,xriid);
TRACE(shell,"(%p)->(\n\tIID:\t%s)\n",This,xriid); TRACE("(%p)->(\n\tIID:\t%s)\n",This,xriid);
*ppvObj = NULL; *ppvObj = NULL;
@ -706,10 +706,10 @@ static HRESULT WINAPI IShellLinkW_CF_QueryInterface(
if(*ppvObj) { if(*ppvObj) {
IUnknown_AddRef((IUnknown*)*ppvObj); IUnknown_AddRef((IUnknown*)*ppvObj);
TRACE(shell,"-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj); TRACE("-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj);
return S_OK; return S_OK;
} }
TRACE(shell,"-- Interface: E_NOINTERFACE\n"); TRACE("-- Interface: E_NOINTERFACE\n");
return E_NOINTERFACE; return E_NOINTERFACE;
} }
/****************************************************************************** /******************************************************************************
@ -718,7 +718,7 @@ static HRESULT WINAPI IShellLinkW_CF_QueryInterface(
static ULONG WINAPI IShellLinkW_CF_AddRef(LPCLASSFACTORY iface) static ULONG WINAPI IShellLinkW_CF_AddRef(LPCLASSFACTORY iface)
{ {
ICOM_THIS(IClassFactoryImpl,iface); ICOM_THIS(IClassFactoryImpl,iface);
TRACE(shell,"(%p)->(count=%lu)\n",This,This->ref); TRACE("(%p)->(count=%lu)\n",This,This->ref);
shell32_ObjCount++; shell32_ObjCount++;
return ++(This->ref); return ++(This->ref);
@ -729,11 +729,11 @@ static ULONG WINAPI IShellLinkW_CF_AddRef(LPCLASSFACTORY iface)
static ULONG WINAPI IShellLinkW_CF_Release(LPCLASSFACTORY iface) static ULONG WINAPI IShellLinkW_CF_Release(LPCLASSFACTORY iface)
{ {
ICOM_THIS(IClassFactoryImpl,iface); ICOM_THIS(IClassFactoryImpl,iface);
TRACE(shell,"(%p)->(count=%lu)\n",This,This->ref); TRACE("(%p)->(count=%lu)\n",This,This->ref);
shell32_ObjCount--; shell32_ObjCount--;
if (!--(This->ref)) if (!--(This->ref))
{ TRACE(shell,"-- destroying IClassFactory(%p)\n",This); { TRACE("-- destroying IClassFactory(%p)\n",This);
HeapFree(GetProcessHeap(),0,This); HeapFree(GetProcessHeap(),0,This);
return 0; return 0;
} }
@ -751,7 +751,7 @@ static HRESULT WINAPI IShellLinkW_CF_CreateInstance(
char xriid[50]; char xriid[50];
WINE_StringFromCLSID((LPCLSID)riid,xriid); WINE_StringFromCLSID((LPCLSID)riid,xriid);
TRACE(shell,"%p->(%p,\n\tIID:\t%s,%p)\n",This,pUnknown,xriid,ppObject); TRACE("%p->(%p,\n\tIID:\t%s,%p)\n",This,pUnknown,xriid,ppObject);
*ppObject = NULL; *ppObject = NULL;
@ -763,7 +763,7 @@ static HRESULT WINAPI IShellLinkW_CF_CreateInstance(
{ pObj = (IUnknown *)IShellLinkW_Constructor(); { pObj = (IUnknown *)IShellLinkW_Constructor();
} }
else else
{ ERR(shell,"unknown IID requested\n\tIID:\t%s\n",xriid); { ERR("unknown IID requested\n\tIID:\t%s\n",xriid);
return(E_NOINTERFACE); return(E_NOINTERFACE);
} }
@ -773,7 +773,7 @@ static HRESULT WINAPI IShellLinkW_CF_CreateInstance(
hres = pObj->lpvtbl->fnQueryInterface(pObj,riid, ppObject); hres = pObj->lpvtbl->fnQueryInterface(pObj,riid, ppObject);
pObj->lpvtbl->fnRelease(pObj); pObj->lpvtbl->fnRelease(pObj);
TRACE(shell,"-- Object created: (%p)->%p\n",This,*ppObject); TRACE("-- Object created: (%p)->%p\n",This,*ppObject);
return hres; return hres;
} }
@ -784,7 +784,7 @@ static HRESULT WINAPI IShellLinkW_CF_CreateInstance(
static HRESULT WINAPI IShellLinkW_CF_LockServer(LPCLASSFACTORY iface, BOOL fLock) static HRESULT WINAPI IShellLinkW_CF_LockServer(LPCLASSFACTORY iface, BOOL fLock)
{ {
ICOM_THIS(IClassFactoryImpl,iface); ICOM_THIS(IClassFactoryImpl,iface);
TRACE(shell,"%p->(0x%x), not implemented\n",This, fLock); TRACE("%p->(0x%x), not implemented\n",This, fLock);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -825,7 +825,7 @@ IShellLinkW * IShellLinkW_Constructor(void)
sl->lppf = IPersistFile_Constructor(); sl->lppf = IPersistFile_Constructor();
TRACE(shell,"(%p)->()\n",sl); TRACE("(%p)->()\n",sl);
shell32_ObjCount++; shell32_ObjCount++;
return (IShellLinkW*)sl; return (IShellLinkW*)sl;
} }
@ -840,7 +840,7 @@ static HRESULT WINAPI IShellLinkW_fnQueryInterface(
char xriid[50]; char xriid[50];
WINE_StringFromCLSID((LPCLSID)riid,xriid); WINE_StringFromCLSID((LPCLSID)riid,xriid);
TRACE(shell,"(%p)->(\n\tIID:\t%s)\n",This,xriid); TRACE("(%p)->(\n\tIID:\t%s)\n",This,xriid);
*ppvObj = NULL; *ppvObj = NULL;
@ -856,11 +856,11 @@ static HRESULT WINAPI IShellLinkW_fnQueryInterface(
if(*ppvObj) if(*ppvObj)
{ IShellLink_AddRef((IShellLinkW*)*ppvObj); { IShellLink_AddRef((IShellLinkW*)*ppvObj);
TRACE(shell,"-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj); TRACE("-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj);
return S_OK; return S_OK;
} }
TRACE(shell,"-- Interface: E_NOINTERFACE\n"); TRACE("-- Interface: E_NOINTERFACE\n");
return E_NOINTERFACE; return E_NOINTERFACE;
} }
@ -871,7 +871,7 @@ static ULONG WINAPI IShellLinkW_fnAddRef(IShellLinkW * iface)
{ {
ICOM_THIS(IShellLinkWImpl, iface); ICOM_THIS(IShellLinkWImpl, iface);
TRACE(shell,"(%p)->(count=%lu)\n",This,This->ref); TRACE("(%p)->(count=%lu)\n",This,This->ref);
shell32_ObjCount++; shell32_ObjCount++;
return ++(This->ref); return ++(This->ref);
@ -884,11 +884,11 @@ static ULONG WINAPI IShellLinkW_fnRelease(IShellLinkW * iface)
{ {
ICOM_THIS(IShellLinkWImpl, iface); ICOM_THIS(IShellLinkWImpl, iface);
TRACE(shell,"(%p)->(count=%lu)\n",This,This->ref); TRACE("(%p)->(count=%lu)\n",This,This->ref);
shell32_ObjCount--; shell32_ObjCount--;
if (!--(This->ref)) if (!--(This->ref))
{ TRACE(shell,"-- destroying IShellLinkW(%p)\n",This); { TRACE("-- destroying IShellLinkW(%p)\n",This);
IPersistFile_Release((IPersistFile*)This->lppf); /* IPersistFile*/ IPersistFile_Release((IPersistFile*)This->lppf); /* IPersistFile*/
HeapFree(GetProcessHeap(),0,This); HeapFree(GetProcessHeap(),0,This);
return 0; return 0;
@ -900,7 +900,7 @@ static HRESULT WINAPI IShellLinkW_fnGetPath(IShellLinkW * iface, LPWSTR pszFile,
{ {
ICOM_THIS(IShellLinkWImpl, iface); ICOM_THIS(IShellLinkWImpl, iface);
FIXME(shell,"(%p)->(pfile=%p len=%u find_data=%p flags=%lu)\n",This, pszFile, cchMaxPath, pfd, fFlags); FIXME("(%p)->(pfile=%p len=%u find_data=%p flags=%lu)\n",This, pszFile, cchMaxPath, pfd, fFlags);
lstrcpynAtoW(pszFile,"c:\\foo.bar", cchMaxPath); lstrcpynAtoW(pszFile,"c:\\foo.bar", cchMaxPath);
return NOERROR; return NOERROR;
} }
@ -909,7 +909,7 @@ static HRESULT WINAPI IShellLinkW_fnGetIDList(IShellLinkW * iface, LPITEMIDLIST
{ {
ICOM_THIS(IShellLinkWImpl, iface); ICOM_THIS(IShellLinkWImpl, iface);
FIXME(shell,"(%p)->(ppidl=%p)\n",This, ppidl); FIXME("(%p)->(ppidl=%p)\n",This, ppidl);
*ppidl = _ILCreateDesktop(); *ppidl = _ILCreateDesktop();
return NOERROR; return NOERROR;
} }
@ -918,7 +918,7 @@ static HRESULT WINAPI IShellLinkW_fnSetIDList(IShellLinkW * iface, LPCITEMIDLIST
{ {
ICOM_THIS(IShellLinkWImpl, iface); ICOM_THIS(IShellLinkWImpl, iface);
FIXME(shell,"(%p)->(pidl=%p)\n",This, pidl); FIXME("(%p)->(pidl=%p)\n",This, pidl);
return NOERROR; return NOERROR;
} }
@ -926,7 +926,7 @@ static HRESULT WINAPI IShellLinkW_fnGetDescription(IShellLinkW * iface, LPWSTR p
{ {
ICOM_THIS(IShellLinkWImpl, iface); ICOM_THIS(IShellLinkWImpl, iface);
FIXME(shell,"(%p)->(%p len=%u)\n",This, pszName, cchMaxName); FIXME("(%p)->(%p len=%u)\n",This, pszName, cchMaxName);
lstrcpynAtoW(pszName,"Description, FIXME",cchMaxName); lstrcpynAtoW(pszName,"Description, FIXME",cchMaxName);
return NOERROR; return NOERROR;
} }
@ -935,7 +935,7 @@ static HRESULT WINAPI IShellLinkW_fnSetDescription(IShellLinkW * iface, LPCWSTR
{ {
ICOM_THIS(IShellLinkWImpl, iface); ICOM_THIS(IShellLinkWImpl, iface);
FIXME(shell,"(%p)->(desc=%s)\n",This, debugstr_w(pszName)); FIXME("(%p)->(desc=%s)\n",This, debugstr_w(pszName));
return NOERROR; return NOERROR;
} }
@ -943,7 +943,7 @@ static HRESULT WINAPI IShellLinkW_fnGetWorkingDirectory(IShellLinkW * iface, LPW
{ {
ICOM_THIS(IShellLinkWImpl, iface); ICOM_THIS(IShellLinkWImpl, iface);
FIXME(shell,"(%p)->()\n",This); FIXME("(%p)->()\n",This);
lstrcpynAtoW(pszDir,"c:\\", cchMaxPath); lstrcpynAtoW(pszDir,"c:\\", cchMaxPath);
return NOERROR; return NOERROR;
} }
@ -952,7 +952,7 @@ static HRESULT WINAPI IShellLinkW_fnSetWorkingDirectory(IShellLinkW * iface, LPC
{ {
ICOM_THIS(IShellLinkWImpl, iface); ICOM_THIS(IShellLinkWImpl, iface);
FIXME(shell,"(%p)->(dir=%s)\n",This, debugstr_w(pszDir)); FIXME("(%p)->(dir=%s)\n",This, debugstr_w(pszDir));
return NOERROR; return NOERROR;
} }
@ -960,7 +960,7 @@ static HRESULT WINAPI IShellLinkW_fnGetArguments(IShellLinkW * iface, LPWSTR psz
{ {
ICOM_THIS(IShellLinkWImpl, iface); ICOM_THIS(IShellLinkWImpl, iface);
FIXME(shell,"(%p)->(%p len=%u)\n",This, pszArgs, cchMaxPath); FIXME("(%p)->(%p len=%u)\n",This, pszArgs, cchMaxPath);
lstrcpynAtoW(pszArgs, "", cchMaxPath); lstrcpynAtoW(pszArgs, "", cchMaxPath);
return NOERROR; return NOERROR;
} }
@ -969,7 +969,7 @@ static HRESULT WINAPI IShellLinkW_fnSetArguments(IShellLinkW * iface, LPCWSTR ps
{ {
ICOM_THIS(IShellLinkWImpl, iface); ICOM_THIS(IShellLinkWImpl, iface);
FIXME(shell,"(%p)->(args=%s)\n",This, debugstr_w(pszArgs)); FIXME("(%p)->(args=%s)\n",This, debugstr_w(pszArgs));
return NOERROR; return NOERROR;
} }
@ -977,7 +977,7 @@ static HRESULT WINAPI IShellLinkW_fnGetHotkey(IShellLinkW * iface, WORD *pwHotke
{ {
ICOM_THIS(IShellLinkWImpl, iface); ICOM_THIS(IShellLinkWImpl, iface);
FIXME(shell,"(%p)->(%p)\n",This, pwHotkey); FIXME("(%p)->(%p)\n",This, pwHotkey);
*pwHotkey=0x0; *pwHotkey=0x0;
return NOERROR; return NOERROR;
} }
@ -986,7 +986,7 @@ static HRESULT WINAPI IShellLinkW_fnSetHotkey(IShellLinkW * iface, WORD wHotkey)
{ {
ICOM_THIS(IShellLinkWImpl, iface); ICOM_THIS(IShellLinkWImpl, iface);
FIXME(shell,"(%p)->(hotkey=%x)\n",This, wHotkey); FIXME("(%p)->(hotkey=%x)\n",This, wHotkey);
return NOERROR; return NOERROR;
} }
@ -994,7 +994,7 @@ static HRESULT WINAPI IShellLinkW_fnGetShowCmd(IShellLinkW * iface, INT *piShowC
{ {
ICOM_THIS(IShellLinkWImpl, iface); ICOM_THIS(IShellLinkWImpl, iface);
FIXME(shell,"(%p)->(%p)\n",This, piShowCmd); FIXME("(%p)->(%p)\n",This, piShowCmd);
*piShowCmd=0; *piShowCmd=0;
return NOERROR; return NOERROR;
} }
@ -1003,7 +1003,7 @@ static HRESULT WINAPI IShellLinkW_fnSetShowCmd(IShellLinkW * iface, INT iShowCmd
{ {
ICOM_THIS(IShellLinkWImpl, iface); ICOM_THIS(IShellLinkWImpl, iface);
FIXME(shell,"(%p)->(showcmd=%x)\n",This, iShowCmd); FIXME("(%p)->(showcmd=%x)\n",This, iShowCmd);
return NOERROR; return NOERROR;
} }
@ -1011,7 +1011,7 @@ static HRESULT WINAPI IShellLinkW_fnGetIconLocation(IShellLinkW * iface, LPWSTR
{ {
ICOM_THIS(IShellLinkWImpl, iface); ICOM_THIS(IShellLinkWImpl, iface);
FIXME(shell,"(%p)->(%p len=%u iicon=%p)\n",This, pszIconPath, cchIconPath, piIcon); FIXME("(%p)->(%p len=%u iicon=%p)\n",This, pszIconPath, cchIconPath, piIcon);
lstrcpynAtoW(pszIconPath,"shell32.dll",cchIconPath); lstrcpynAtoW(pszIconPath,"shell32.dll",cchIconPath);
*piIcon=1; *piIcon=1;
return NOERROR; return NOERROR;
@ -1021,7 +1021,7 @@ static HRESULT WINAPI IShellLinkW_fnSetIconLocation(IShellLinkW * iface, LPCWSTR
{ {
ICOM_THIS(IShellLinkWImpl, iface); ICOM_THIS(IShellLinkWImpl, iface);
FIXME(shell,"(%p)->(path=%s iicon=%u)\n",This, debugstr_w(pszIconPath), iIcon); FIXME("(%p)->(path=%s iicon=%u)\n",This, debugstr_w(pszIconPath), iIcon);
return NOERROR; return NOERROR;
} }
@ -1029,7 +1029,7 @@ static HRESULT WINAPI IShellLinkW_fnSetRelativePath(IShellLinkW * iface, LPCWSTR
{ {
ICOM_THIS(IShellLinkWImpl, iface); ICOM_THIS(IShellLinkWImpl, iface);
FIXME(shell,"(%p)->(path=%s %lx)\n",This, debugstr_w(pszPathRel), dwReserved); FIXME("(%p)->(path=%s %lx)\n",This, debugstr_w(pszPathRel), dwReserved);
return NOERROR; return NOERROR;
} }
@ -1037,7 +1037,7 @@ static HRESULT WINAPI IShellLinkW_fnResolve(IShellLinkW * iface, HWND hwnd, DWOR
{ {
ICOM_THIS(IShellLinkWImpl, iface); ICOM_THIS(IShellLinkWImpl, iface);
FIXME(shell,"(%p)->(hwnd=%x flags=%lx)\n",This, hwnd, fFlags); FIXME("(%p)->(hwnd=%x flags=%lx)\n",This, hwnd, fFlags);
return NOERROR; return NOERROR;
} }
@ -1045,7 +1045,7 @@ static HRESULT WINAPI IShellLinkW_fnSetPath(IShellLinkW * iface, LPCWSTR pszFile
{ {
ICOM_THIS(IShellLinkWImpl, iface); ICOM_THIS(IShellLinkWImpl, iface);
FIXME(shell,"(%p)->(path=%s)\n",This, debugstr_w(pszFile)); FIXME("(%p)->(path=%s)\n",This, debugstr_w(pszFile));
return NOERROR; return NOERROR;
} }

View file

@ -21,7 +21,7 @@
#include "winversion.h" #include "winversion.h"
#include "winreg.h" #include "winreg.h"
#include "winerror.h" #include "winerror.h"
#include "debug.h" #include "debugtools.h"
#include "shell32_main.h" #include "shell32_main.h"
@ -36,7 +36,7 @@ static GetClassPtr SH_find_moduleproc(LPSTR dllname,HMODULE *xhmod,LPSTR name)
{ HMODULE hmod; { HMODULE hmod;
FARPROC dllunload,nameproc; FARPROC dllunload,nameproc;
TRACE(shell,"dll=%s, hmodule=%p, name=%s\n",dllname, xhmod, name); TRACE("dll=%s, hmodule=%p, name=%s\n",dllname, xhmod, name);
if (xhmod) if (xhmod)
{ *xhmod = 0; { *xhmod = 0;
} }
@ -73,7 +73,7 @@ static DWORD SH_get_instance(REFCLSID clsid,LPSTR dllname,LPVOID unknownouter,RE
char xclsid[50],xrefiid[50]; char xclsid[50],xrefiid[50];
WINE_StringFromCLSID((LPCLSID)clsid,xclsid); WINE_StringFromCLSID((LPCLSID)clsid,xclsid);
WINE_StringFromCLSID((LPCLSID)refiid,xrefiid); WINE_StringFromCLSID((LPCLSID)refiid,xrefiid);
TRACE(shell,"\n\tCLSID:%s,%s,%p,\n\tIID:%s,%p\n",xclsid, dllname,unknownouter,xrefiid,inst); TRACE("\n\tCLSID:%s,%s,%p,\n\tIID:%s,%p\n",xclsid, dllname,unknownouter,xrefiid,inst);
dllgetclassob = SH_find_moduleproc(dllname,NULL,"DllGetClassObject"); dllgetclassob = SH_find_moduleproc(dllname,NULL,"DllGetClassObject");
if (!dllgetclassob) if (!dllgetclassob)
@ -84,7 +84,7 @@ static DWORD SH_get_instance(REFCLSID clsid,LPSTR dllname,LPVOID unknownouter,RE
if ((hres<0) || (hres>=0x80000000)) if ((hres<0) || (hres>=0x80000000))
return hres; return hres;
if (!classfac) if (!classfac)
{ FIXME(shell,"no classfactory, but hres is 0x%ld!\n",hres); { FIXME("no classfactory, but hres is 0x%ld!\n",hres);
return E_FAIL; return E_FAIL;
} }
IClassFactory_CreateInstance(classfac,unknownouter,refiid,inst); IClassFactory_CreateInstance(classfac,unknownouter,refiid,inst);
@ -115,7 +115,7 @@ LRESULT WINAPI SHCoCreateInstance(LPSTR aclsid,CLSID *clsid,LPUNKNOWN unknownout
} }
strcpy(xclsid,aclsid); strcpy(xclsid,aclsid);
} }
TRACE(shell,"(%p,\n\tSID:\t%s,%p,\n\tIID:\t%s,%p)\n",aclsid,xclsid,unknownouter,xiid,inst); TRACE("(%p,\n\tSID:\t%s,%p,\n\tIID:\t%s,%p)\n",aclsid,xclsid,unknownouter,xiid,inst);
sprintf(buffer,"CLSID\\%s\\InProcServer32",xclsid); sprintf(buffer,"CLSID\\%s\\InProcServer32",xclsid);
@ -129,7 +129,7 @@ LRESULT WINAPI SHCoCreateInstance(LPSTR aclsid,CLSID *clsid,LPUNKNOWN unknownout
return SH_get_instance(clsid,"shell32.dll",unknownouter,refiid,inst); return SH_get_instance(clsid,"shell32.dll",unknownouter,refiid,inst);
} }
TRACE(shell, "Server dll is %s\n",path); TRACE("Server dll is %s\n",path);
tmodellen=sizeof(tmodel); tmodellen=sizeof(tmodel);
type=REG_SZ; type=REG_SZ;
if (RegQueryValueExA(inprockey,"ThreadingModel",NULL,&type,tmodel,&tmodellen)) if (RegQueryValueExA(inprockey,"ThreadingModel",NULL,&type,tmodel,&tmodellen))
@ -137,7 +137,7 @@ LRESULT WINAPI SHCoCreateInstance(LPSTR aclsid,CLSID *clsid,LPUNKNOWN unknownout
return SH_get_instance(clsid,"shell32.dll",unknownouter,refiid,inst); return SH_get_instance(clsid,"shell32.dll",unknownouter,refiid,inst);
} }
TRACE(shell, "Threading model is %s\n",tmodel); TRACE("Threading model is %s\n",tmodel);
hres=SH_get_instance(clsid,path,unknownouter,refiid,inst); hres=SH_get_instance(clsid,path,unknownouter,refiid,inst);
if (hres<0 || (hres>0x80000000)) if (hres<0 || (hres>0x80000000))
@ -166,13 +166,13 @@ HRESULT WINAPI SHELL32_DllGetClassObject(REFCLSID rclsid,REFIID iid,LPVOID *ppv)
char xclsid[50],xiid[50]; char xclsid[50],xiid[50];
WINE_StringFromCLSID((LPCLSID)rclsid,xclsid); WINE_StringFromCLSID((LPCLSID)rclsid,xclsid);
WINE_StringFromCLSID((LPCLSID)iid,xiid); WINE_StringFromCLSID((LPCLSID)iid,xiid);
TRACE(shell,"\n\tCLSID:\t%s,\n\tIID:\t%s\n",xclsid,xiid); TRACE("\n\tCLSID:\t%s,\n\tIID:\t%s\n",xclsid,xiid);
*ppv = NULL; *ppv = NULL;
if(IsEqualCLSID(rclsid, &CLSID_ShellDesktop)|| if(IsEqualCLSID(rclsid, &CLSID_ShellDesktop)||
IsEqualCLSID(rclsid, &CLSID_ShellLink)) IsEqualCLSID(rclsid, &CLSID_ShellLink))
{ if(IsEqualCLSID(rclsid, &CLSID_ShellDesktop)) /*debug*/ { if(IsEqualCLSID(rclsid, &CLSID_ShellDesktop)) /*debug*/
{ TRACE(shell,"-- requested CLSID_ShellDesktop\n"); { TRACE("-- requested CLSID_ShellDesktop\n");
} }
if (IsEqualCLSID(rclsid, &CLSID_ShellLink)) if (IsEqualCLSID(rclsid, &CLSID_ShellLink))
@ -191,10 +191,10 @@ HRESULT WINAPI SHELL32_DllGetClassObject(REFCLSID rclsid,REFIID iid,LPVOID *ppv)
} }
} }
else else
{ WARN(shell, "-- CLSID not found\n"); { WARN("-- CLSID not found\n");
hres = CLASS_E_CLASSNOTAVAILABLE; hres = CLASS_E_CLASSNOTAVAILABLE;
} }
TRACE(shell,"-- pointer to class factory: %p\n",*ppv); TRACE("-- pointer to class factory: %p\n",*ppv);
return hres; return hres;
} }
@ -206,7 +206,7 @@ HRESULT WINAPI SHELL32_DllGetClassObject(REFCLSID rclsid,REFIID iid,LPVOID *ppv)
*/ */
DWORD WINAPI SHCLSIDFromString (LPSTR clsid, CLSID *id) DWORD WINAPI SHCLSIDFromString (LPSTR clsid, CLSID *id)
{ {
TRACE (shell,"(%p(%s) %p)\n", clsid, clsid, id); TRACE("(%p(%s) %p)\n", clsid, clsid, id);
return CLSIDFromString16(clsid, id); return CLSIDFromString16(clsid, id);
} }
@ -221,7 +221,7 @@ DWORD WINAPI SHCLSIDFromString (LPSTR clsid, CLSID *id)
* heap (ProcessHeap). * heap (ProcessHeap).
*/ */
DWORD WINAPI SHGetMalloc(LPMALLOC *lpmal) DWORD WINAPI SHGetMalloc(LPMALLOC *lpmal)
{ TRACE(shell,"(%p)\n", lpmal); { TRACE("(%p)\n", lpmal);
return CoGetMalloc(0,lpmal); return CoGetMalloc(0,lpmal);
} }
@ -250,7 +250,7 @@ LPCLASSFACTORY IClassFactory_Constructor(void)
lpclf->ref = 1; lpclf->ref = 1;
lpclf->lpvtbl = &clfvt; lpclf->lpvtbl = &clfvt;
TRACE(shell,"(%p)->()\n",lpclf); TRACE("(%p)->()\n",lpclf);
shell32_ObjCount++; shell32_ObjCount++;
return (LPCLASSFACTORY)lpclf; return (LPCLASSFACTORY)lpclf;
} }
@ -263,7 +263,7 @@ static HRESULT WINAPI IClassFactory_fnQueryInterface(
ICOM_THIS(IClassFactoryImpl,iface); ICOM_THIS(IClassFactoryImpl,iface);
char xriid[50]; char xriid[50];
WINE_StringFromCLSID((LPCLSID)riid,xriid); WINE_StringFromCLSID((LPCLSID)riid,xriid);
TRACE(shell,"(%p)->(\n\tIID:\t%s)\n",This,xriid); TRACE("(%p)->(\n\tIID:\t%s)\n",This,xriid);
*ppvObj = NULL; *ppvObj = NULL;
@ -276,10 +276,10 @@ static HRESULT WINAPI IClassFactory_fnQueryInterface(
if(*ppvObj) if(*ppvObj)
{ IUnknown_AddRef((LPUNKNOWN)*ppvObj); { IUnknown_AddRef((LPUNKNOWN)*ppvObj);
TRACE(shell,"-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj); TRACE("-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj);
return S_OK; return S_OK;
} }
TRACE(shell,"-- Interface: E_NOINTERFACE\n"); TRACE("-- Interface: E_NOINTERFACE\n");
return E_NOINTERFACE; return E_NOINTERFACE;
} }
/****************************************************************************** /******************************************************************************
@ -288,7 +288,7 @@ static HRESULT WINAPI IClassFactory_fnQueryInterface(
static ULONG WINAPI IClassFactory_fnAddRef(LPCLASSFACTORY iface) static ULONG WINAPI IClassFactory_fnAddRef(LPCLASSFACTORY iface)
{ {
ICOM_THIS(IClassFactoryImpl,iface); ICOM_THIS(IClassFactoryImpl,iface);
TRACE(shell,"(%p)->(count=%lu)\n",This,This->ref); TRACE("(%p)->(count=%lu)\n",This,This->ref);
shell32_ObjCount++; shell32_ObjCount++;
return ++(This->ref); return ++(This->ref);
@ -299,11 +299,11 @@ static ULONG WINAPI IClassFactory_fnAddRef(LPCLASSFACTORY iface)
static ULONG WINAPI IClassFactory_fnRelease(LPCLASSFACTORY iface) static ULONG WINAPI IClassFactory_fnRelease(LPCLASSFACTORY iface)
{ {
ICOM_THIS(IClassFactoryImpl,iface); ICOM_THIS(IClassFactoryImpl,iface);
TRACE(shell,"(%p)->(count=%lu)\n",This,This->ref); TRACE("(%p)->(count=%lu)\n",This,This->ref);
shell32_ObjCount--; shell32_ObjCount--;
if (!--(This->ref)) if (!--(This->ref))
{ TRACE(shell,"-- destroying IClassFactory(%p)\n",This); { TRACE("-- destroying IClassFactory(%p)\n",This);
HeapFree(GetProcessHeap(),0,This); HeapFree(GetProcessHeap(),0,This);
return 0; return 0;
} }
@ -321,7 +321,7 @@ static HRESULT WINAPI IClassFactory_fnCreateInstance(
char xriid[50]; char xriid[50];
WINE_StringFromCLSID((LPCLSID)riid,xriid); WINE_StringFromCLSID((LPCLSID)riid,xriid);
TRACE(shell,"%p->(%p,\n\tIID:\t%s,%p)\n",This,pUnknown,xriid,ppObject); TRACE("%p->(%p,\n\tIID:\t%s,%p)\n",This,pUnknown,xriid,ppObject);
*ppObject = NULL; *ppObject = NULL;
@ -345,7 +345,7 @@ static HRESULT WINAPI IClassFactory_fnCreateInstance(
{ pObj = (IUnknown *)IDataObject_Constructor(0,NULL,NULL,0); { pObj = (IUnknown *)IDataObject_Constructor(0,NULL,NULL,0);
} }
else else
{ ERR(shell,"unknown IID requested\n\tIID:\t%s\n",xriid); { ERR("unknown IID requested\n\tIID:\t%s\n",xriid);
return(E_NOINTERFACE); return(E_NOINTERFACE);
} }
@ -355,7 +355,7 @@ static HRESULT WINAPI IClassFactory_fnCreateInstance(
hres = pObj->lpvtbl->fnQueryInterface(pObj,riid, ppObject); hres = pObj->lpvtbl->fnQueryInterface(pObj,riid, ppObject);
pObj->lpvtbl->fnRelease(pObj); pObj->lpvtbl->fnRelease(pObj);
TRACE(shell,"-- Object created: (%p)->%p\n",This,*ppObject); TRACE("-- Object created: (%p)->%p\n",This,*ppObject);
return hres; return hres;
} }
@ -365,7 +365,7 @@ static HRESULT WINAPI IClassFactory_fnCreateInstance(
static HRESULT WINAPI IClassFactory_fnLockServer(LPCLASSFACTORY iface, BOOL fLock) static HRESULT WINAPI IClassFactory_fnLockServer(LPCLASSFACTORY iface, BOOL fLock)
{ {
ICOM_THIS(IClassFactoryImpl,iface); ICOM_THIS(IClassFactoryImpl,iface);
TRACE(shell,"%p->(0x%x), not implemented\n",This, fLock); TRACE("%p->(0x%x), not implemented\n",This, fLock);
return E_NOTIMPL; return E_NOTIMPL;
} }

View file

@ -8,7 +8,7 @@
#include <string.h> #include <string.h>
#include "winerror.h" #include "winerror.h"
#include "winreg.h" #include "winreg.h"
#include "debug.h" #include "debugtools.h"
#include "winnls.h" #include "winnls.h"
#include "winversion.h" #include "winversion.h"
#include "heap.h" #include "heap.h"
@ -34,7 +34,7 @@ SHChangeNotifyRegister(
DWORD msg, DWORD msg,
int count, int count,
IDSTRUCT *idlist) IDSTRUCT *idlist)
{ FIXME(shell,"(0x%04x,0x%08lx,0x%08lx,0x%08lx,0x%08x,%p):stub.\n", { FIXME("(0x%04x,0x%08lx,0x%08lx,0x%08lx,0x%08x,%p):stub.\n",
hwnd,events1,events2,msg,count,idlist); hwnd,events1,events2,msg,count,idlist);
return 0; return 0;
} }
@ -43,7 +43,7 @@ SHChangeNotifyRegister(
*/ */
DWORD WINAPI DWORD WINAPI
SHChangeNotifyDeregister(LONG x1) SHChangeNotifyDeregister(LONG x1)
{ FIXME(shell,"(0x%08lx):stub.\n",x1); { FIXME("(0x%08lx):stub.\n",x1);
return 0; return 0;
} }
/************************************************************************* /*************************************************************************
@ -59,7 +59,7 @@ DWORD WINAPI NTSHChangeNotifyRegister(
DWORD msg, DWORD msg,
int count, int count,
IDSTRUCT *idlist) IDSTRUCT *idlist)
{ FIXME(shell,"(0x%04x,0x%08lx,0x%08lx,0x%08lx,0x%08x,%p):stub.\n", { FIXME("(0x%04x,0x%08lx,0x%08lx,0x%08lx,0x%08x,%p):stub.\n",
hwnd,events1,events2,msg,count,idlist); hwnd,events1,events2,msg,count,idlist);
return 0; return 0;
} }
@ -67,7 +67,7 @@ DWORD WINAPI NTSHChangeNotifyRegister(
* NTSHChangeNotifyDeregister [SHELL32.641] * NTSHChangeNotifyDeregister [SHELL32.641]
*/ */
DWORD WINAPI NTSHChangeNotifyDeregister(LONG x1) DWORD WINAPI NTSHChangeNotifyDeregister(LONG x1)
{ FIXME(shell,"(0x%08lx):stub.\n",x1); { FIXME("(0x%08lx):stub.\n",x1);
return 0; return 0;
} }
@ -76,7 +76,7 @@ DWORD WINAPI NTSHChangeNotifyDeregister(LONG x1)
* *
*/ */
DWORD WINAPI ParseFieldA(LPCSTR src, DWORD field, LPSTR dst, DWORD len) DWORD WINAPI ParseFieldA(LPCSTR src, DWORD field, LPSTR dst, DWORD len)
{ WARN(shell,"('%s',0x%08lx,%p,%ld) semi-stub.\n",src,field,dst,len); { WARN("('%s',0x%08lx,%p,%ld) semi-stub.\n",src,field,dst,len);
if (!src || !src[0] || !dst || !len) if (!src || !src[0] || !dst || !len)
return 0; return 0;
@ -103,7 +103,7 @@ DWORD WINAPI ParseFieldA(LPCSTR src, DWORD field, LPSTR dst, DWORD len)
* *
*/ */
DWORD WINAPI PickIconDlg(DWORD x,DWORD y,DWORD z,DWORD a) DWORD WINAPI PickIconDlg(DWORD x,DWORD y,DWORD z,DWORD a)
{ FIXME(shell,"(%08lx,%08lx,%08lx,%08lx):stub.\n",x,y,z,a); { FIXME("(%08lx,%08lx,%08lx,%08lx):stub.\n",x,y,z,a);
return 0xffffffff; return 0xffffffff;
} }
@ -112,7 +112,7 @@ DWORD WINAPI PickIconDlg(DWORD x,DWORD y,DWORD z,DWORD a)
* *
*/ */
DWORD WINAPI GetFileNameFromBrowse(HWND howner, LPSTR targetbuf, DWORD len, DWORD x, LPCSTR suffix, LPCSTR y, LPCSTR cmd) DWORD WINAPI GetFileNameFromBrowse(HWND howner, LPSTR targetbuf, DWORD len, DWORD x, LPCSTR suffix, LPCSTR y, LPCSTR cmd)
{ FIXME(shell,"(%04x,%p,%ld,%08lx,%s,%s,%s):stub.\n", { FIXME("(%04x,%p,%ld,%08lx,%s,%s,%s):stub.\n",
howner,targetbuf,len,x,suffix,y,cmd); howner,targetbuf,len,x,suffix,y,cmd);
/* puts up a Open Dialog and requests input into targetbuf */ /* puts up a Open Dialog and requests input into targetbuf */
/* OFN_HIDEREADONLY|OFN_NOCHANGEDIR|OFN_FILEMUSTEXIST|OFN_unknown */ /* OFN_HIDEREADONLY|OFN_NOCHANGEDIR|OFN_FILEMUSTEXIST|OFN_unknown */
@ -133,7 +133,7 @@ void WINAPI SHGetSettings(LPSHELLFLAGSTATE lpsfs, DWORD dwMask, DWORD dwx)
DWORD dwData; DWORD dwData;
DWORD dwDataSize = sizeof (DWORD); DWORD dwDataSize = sizeof (DWORD);
TRACE(shell,"(%p 0x%08lx 0x%08lx)\n",lpsfs,dwMask, dwx); TRACE("(%p 0x%08lx 0x%08lx)\n",lpsfs,dwMask, dwx);
if (RegCreateKeyExA(HKEY_CURRENT_USER, "Software\\Microsoft\\Windows\\CurrentVersion\\Explorer\\Advanced", if (RegCreateKeyExA(HKEY_CURRENT_USER, "Software\\Microsoft\\Windows\\CurrentVersion\\Explorer\\Advanced",
0, 0, 0, KEY_ALL_ACCESS, 0, &hKey, 0)) 0, 0, 0, KEY_ALL_ACCESS, 0, &hKey, 0))
@ -173,7 +173,7 @@ void WINAPI SHGetSettings(LPSHELLFLAGSTATE lpsfs, DWORD dwMask, DWORD dwx)
} }
RegCloseKey (hKey); RegCloseKey (hKey);
TRACE(shell,"-- 0x%04x\n", *(WORD*)lpsfs); TRACE("-- 0x%04x\n", *(WORD*)lpsfs);
} }
/************************************************************************* /*************************************************************************
@ -192,7 +192,7 @@ void WINAPI SHGetSettings(LPSHELLFLAGSTATE lpsfs, DWORD dwMask, DWORD dwx)
* that was clicked. * that was clicked.
*/ */
int WINAPI SHShellFolderView_Message(HWND hwndCabinet,UINT uMsg,LPARAM lParam) int WINAPI SHShellFolderView_Message(HWND hwndCabinet,UINT uMsg,LPARAM lParam)
{ FIXME(shell,"%04x %08ux %08lx stub\n",hwndCabinet,uMsg,lParam); { FIXME("%04x %08ux %08lx stub\n",hwndCabinet,uMsg,lParam);
return 0; return 0;
} }
@ -201,7 +201,7 @@ int WINAPI SHShellFolderView_Message(HWND hwndCabinet,UINT uMsg,LPARAM lParam)
*/ */
BOOL WINAPI OleStrToStrN (LPSTR lpMulti, INT nMulti, LPCWSTR lpWide, INT nWide) BOOL WINAPI OleStrToStrN (LPSTR lpMulti, INT nMulti, LPCWSTR lpWide, INT nWide)
{ {
TRACE(shell,"%s %x %s %x\n", lpMulti, nMulti, debugstr_w(lpWide), nWide); TRACE("%s %x %s %x\n", lpMulti, nMulti, debugstr_w(lpWide), nWide);
return WideCharToMultiByte (0, 0, lpWide, nWide, lpMulti, nMulti, NULL, NULL); return WideCharToMultiByte (0, 0, lpWide, nWide, lpMulti, nMulti, NULL, NULL);
} }
@ -210,7 +210,7 @@ BOOL WINAPI OleStrToStrN (LPSTR lpMulti, INT nMulti, LPCWSTR lpWide, INT nWide)
*/ */
BOOL WINAPI StrToOleStrN (LPWSTR lpWide, INT nWide, LPCSTR lpMulti, INT nMulti) BOOL WINAPI StrToOleStrN (LPWSTR lpWide, INT nWide, LPCSTR lpMulti, INT nMulti)
{ {
TRACE(shell,"%s %x %s %x\n", debugstr_w(lpWide), nWide, lpMulti, nMulti); TRACE("%s %x %s %x\n", debugstr_w(lpWide), nWide, lpMulti, nMulti);
return MultiByteToWideChar (0, 0, lpMulti, nMulti, lpWide, nWide); return MultiByteToWideChar (0, 0, lpMulti, nMulti, lpWide, nWide);
} }
@ -225,7 +225,7 @@ BOOL WINAPI StrToOleStrN (LPWSTR lpWide, INT nWide, LPCSTR lpMulti, INT nMulti)
* exported by ordinal * exported by ordinal
*/ */
void WINAPI RegisterShellHook(HWND hwnd, DWORD y) { void WINAPI RegisterShellHook(HWND hwnd, DWORD y) {
FIXME(shell,"(0x%08x,0x%08lx):stub.\n",hwnd,y); FIXME("(0x%08x,0x%08lx):stub.\n",hwnd,y);
} }
/************************************************************************* /*************************************************************************
* ShellMessageBoxW [SHELL32.182] * ShellMessageBoxW [SHELL32.182]
@ -244,7 +244,7 @@ ShellMessageBoxW(HMODULE hmod,HWND hwnd,DWORD idText,DWORD idTitle,DWORD uType,L
LPWSTR pszText = &szText[0], pszTitle = &szTitle[0]; LPWSTR pszText = &szText[0], pszTitle = &szTitle[0];
LPVOID args = &arglist; LPVOID args = &arglist;
TRACE(shell,"(%08lx,%08lx,%08lx,%08lx,%08lx,%p)\n",(DWORD)hmod,(DWORD)hwnd,idText,idTitle,uType,arglist); TRACE("(%08lx,%08lx,%08lx,%08lx,%08lx,%p)\n",(DWORD)hmod,(DWORD)hwnd,idText,idTitle,uType,arglist);
if (!HIWORD (idTitle)) if (!HIWORD (idTitle))
LoadStringW(hmod,idTitle,pszTitle,100); LoadStringW(hmod,idTitle,pszTitle,100);
@ -269,7 +269,7 @@ ShellMessageBoxA(HMODULE hmod,HWND hwnd,DWORD idText,DWORD idTitle,DWORD uType,L
LPSTR pszText = &szText[0], pszTitle = &szTitle[0]; LPSTR pszText = &szText[0], pszTitle = &szTitle[0];
LPVOID args = &arglist; LPVOID args = &arglist;
TRACE(shell,"(%08lx,%08lx,%08lx,%08lx,%08lx,%p)\n", (DWORD)hmod,(DWORD)hwnd,idText,idTitle,uType,arglist); TRACE("(%08lx,%08lx,%08lx,%08lx,%08lx,%p)\n", (DWORD)hmod,(DWORD)hwnd,idText,idTitle,uType,arglist);
if (!HIWORD (idTitle)) if (!HIWORD (idTitle))
LoadStringA(hmod,idTitle,pszTitle,100); LoadStringA(hmod,idTitle,pszTitle,100);
@ -317,7 +317,7 @@ ShellMessageBoxA(HMODULE hmod,HWND hwnd,DWORD idText,DWORD idTitle,DWORD uType,L
DWORD WINAPI SHRestricted (DWORD pol) { DWORD WINAPI SHRestricted (DWORD pol) {
HKEY xhkey; HKEY xhkey;
FIXME(shell,"(%08lx):stub.\n",pol); FIXME("(%08lx):stub.\n",pol);
if (RegOpenKeyA(HKEY_CURRENT_USER,"Software\\Microsoft\\Windows\\CurrentVersion\\Policies",&xhkey)) if (RegOpenKeyA(HKEY_CURRENT_USER,"Software\\Microsoft\\Windows\\CurrentVersion\\Policies",&xhkey))
return 0; return 0;
/* FIXME: do nothing for now, just return 0 (== "allowed") */ /* FIXME: do nothing for now, just return 0 (== "allowed") */
@ -333,7 +333,7 @@ DWORD WINAPI SHRestricted (DWORD pol) {
* not sure about LPSECURITY_ATTRIBUTES * not sure about LPSECURITY_ATTRIBUTES
*/ */
DWORD WINAPI SHCreateDirectory(LPSECURITY_ATTRIBUTES sec,LPCSTR path) { DWORD WINAPI SHCreateDirectory(LPSECURITY_ATTRIBUTES sec,LPCSTR path) {
TRACE(shell,"(%p,%s):stub.\n",sec,path); TRACE("(%p,%s):stub.\n",sec,path);
if (CreateDirectoryA(path,sec)) if (CreateDirectoryA(path,sec))
return TRUE; return TRUE;
/* SHChangeNotify(8,1,path,0); */ /* SHChangeNotify(8,1,path,0); */
@ -341,7 +341,7 @@ DWORD WINAPI SHCreateDirectory(LPSECURITY_ATTRIBUTES sec,LPCSTR path) {
#if 0 #if 0
if (SHELL32_79(path,(LPVOID)x)) if (SHELL32_79(path,(LPVOID)x))
return 0; return 0;
FIXME(shell,"(%08lx,%s):stub.\n",x,path); FIXME("(%08lx,%s):stub.\n",x,path);
return 0; return 0;
#endif #endif
} }
@ -354,7 +354,7 @@ DWORD WINAPI SHCreateDirectory(LPSECURITY_ATTRIBUTES sec,LPCSTR path) {
* exported by ordinal * exported by ordinal
*/ */
DWORD WINAPI SHFree(LPVOID x) { DWORD WINAPI SHFree(LPVOID x) {
TRACE(shell,"%p\n",x); TRACE("%p\n",x);
if (!HIWORD(x)) if (!HIWORD(x))
{ *(LPDWORD)0xdeaf0000 = 0; { *(LPDWORD)0xdeaf0000 = 0;
} }
@ -371,7 +371,7 @@ DWORD WINAPI SHFree(LPVOID x) {
LPVOID WINAPI SHAlloc(DWORD len) { LPVOID WINAPI SHAlloc(DWORD len) {
/* void * ret = (LPVOID)LocalAlloc32(len,LMEM_ZEROINIT);*/ /* chrashes */ /* void * ret = (LPVOID)LocalAlloc32(len,LMEM_ZEROINIT);*/ /* chrashes */
void * ret = (LPVOID) HeapAlloc(GetProcessHeap(),0,len); void * ret = (LPVOID) HeapAlloc(GetProcessHeap(),0,len);
TRACE(shell,"%lu bytes at %p\n",len, ret); TRACE("%lu bytes at %p\n",len, ret);
return ret; return ret;
} }
@ -383,7 +383,7 @@ LPVOID WINAPI SHAlloc(DWORD len) {
*/ */
DWORD WINAPI SHRegisterDragDrop(HWND hWnd,IDropTarget * pDropTarget) DWORD WINAPI SHRegisterDragDrop(HWND hWnd,IDropTarget * pDropTarget)
{ {
FIXME (shell, "(0x%08x,%p):stub.\n", hWnd, pDropTarget); FIXME("(0x%08x,%p):stub.\n", hWnd, pDropTarget);
return RegisterDragDrop(hWnd, pDropTarget); return RegisterDragDrop(hWnd, pDropTarget);
} }
@ -394,7 +394,7 @@ DWORD WINAPI SHRegisterDragDrop(HWND hWnd,IDropTarget * pDropTarget)
* exported by ordinal * exported by ordinal
*/ */
DWORD WINAPI SHRevokeDragDrop(DWORD x) { DWORD WINAPI SHRevokeDragDrop(DWORD x) {
FIXME(shell,"(0x%08lx):stub.\n",x); FIXME("(0x%08lx):stub.\n",x);
return 0; return 0;
} }
@ -408,7 +408,7 @@ DWORD WINAPI
RunFileDlg (HWND hwndOwner, DWORD dwParam1, DWORD dwParam2, RunFileDlg (HWND hwndOwner, DWORD dwParam1, DWORD dwParam2,
LPSTR lpszTitle, LPSTR lpszPrompt, UINT uFlags) LPSTR lpszTitle, LPSTR lpszPrompt, UINT uFlags)
{ {
FIXME (shell,"(0x%08x 0x%lx 0x%lx \"%s\" \"%s\" 0x%x):stub.\n", FIXME("(0x%08x 0x%lx 0x%lx \"%s\" \"%s\" 0x%x):stub.\n",
hwndOwner, dwParam1, dwParam2, lpszTitle, lpszPrompt, uFlags); hwndOwner, dwParam1, dwParam2, lpszTitle, lpszPrompt, uFlags);
return 0; return 0;
} }
@ -421,7 +421,7 @@ RunFileDlg (HWND hwndOwner, DWORD dwParam1, DWORD dwParam2,
*/ */
void WINAPI ExitWindowsDialog (HWND hWndOwner) void WINAPI ExitWindowsDialog (HWND hWndOwner)
{ {
TRACE (shell,"(0x%08x)\n", hWndOwner); TRACE("(0x%08x)\n", hWndOwner);
if (MessageBoxA( hWndOwner, "Do you want to exit WINE?", "Shutdown", MB_YESNO|MB_ICONQUESTION) == IDOK) if (MessageBoxA( hWndOwner, "Do you want to exit WINE?", "Shutdown", MB_YESNO|MB_ICONQUESTION) == IDOK)
{ SendMessageA ( hWndOwner, WM_QUIT, 0, 0); { SendMessageA ( hWndOwner, WM_QUIT, 0, 0);
} }
@ -435,7 +435,7 @@ DWORD WINAPI
ArrangeWindows (DWORD dwParam1, DWORD dwParam2, DWORD dwParam3, ArrangeWindows (DWORD dwParam1, DWORD dwParam2, DWORD dwParam3,
DWORD dwParam4, DWORD dwParam5) DWORD dwParam4, DWORD dwParam5)
{ {
FIXME (shell,"(0x%lx 0x%lx 0x%lx 0x%lx 0x%lx):stub.\n", FIXME("(0x%lx 0x%lx 0x%lx 0x%lx 0x%lx):stub.\n",
dwParam1, dwParam2, dwParam3, dwParam4, dwParam5); dwParam1, dwParam2, dwParam3, dwParam4, dwParam5);
return 0; return 0;
} }
@ -449,7 +449,7 @@ ArrangeWindows (DWORD dwParam1, DWORD dwParam2, DWORD dwParam3,
DWORD WINAPI DWORD WINAPI
SignalFileOpen (DWORD dwParam1) SignalFileOpen (DWORD dwParam1)
{ {
FIXME (shell,"(0x%08lx):stub.\n", dwParam1); FIXME("(0x%08lx):stub.\n", dwParam1);
return 0; return 0;
} }
@ -466,10 +466,10 @@ SignalFileOpen (DWORD dwParam1)
*/ */
DWORD WINAPI SHAddToRecentDocs (UINT uFlags,LPCVOID pv) DWORD WINAPI SHAddToRecentDocs (UINT uFlags,LPCVOID pv)
{ if (SHARD_PIDL==uFlags) { if (SHARD_PIDL==uFlags)
{ FIXME (shell,"(0x%08x,pidl=%p):stub.\n", uFlags,pv); { FIXME("(0x%08x,pidl=%p):stub.\n", uFlags,pv);
} }
else else
{ FIXME (shell,"(0x%08x,%s):stub.\n", uFlags,(char*)pv); { FIXME("(0x%08x,%s):stub.\n", uFlags,(char*)pv);
} }
return 0; return 0;
} }
@ -478,7 +478,7 @@ DWORD WINAPI SHAddToRecentDocs (UINT uFlags,LPCVOID pv)
* *
*/ */
DWORD WINAPI SHFileOperationAW(DWORD x) DWORD WINAPI SHFileOperationAW(DWORD x)
{ FIXME(shell,"0x%08lx stub\n",x); { FIXME("0x%08lx stub\n",x);
return 0; return 0;
} }
@ -490,7 +490,7 @@ DWORD WINAPI SHFileOperationAW(DWORD x)
* exported by name * exported by name
*/ */
DWORD WINAPI SHFileOperationA (LPSHFILEOPSTRUCTA lpFileOp) DWORD WINAPI SHFileOperationA (LPSHFILEOPSTRUCTA lpFileOp)
{ FIXME (shell,"(%p):stub.\n", lpFileOp); { FIXME("(%p):stub.\n", lpFileOp);
return 1; return 1;
} }
/************************************************************************* /*************************************************************************
@ -500,7 +500,7 @@ DWORD WINAPI SHFileOperationA (LPSHFILEOPSTRUCTA lpFileOp)
* exported by name * exported by name
*/ */
DWORD WINAPI SHFileOperationW (LPSHFILEOPSTRUCTW lpFileOp) DWORD WINAPI SHFileOperationW (LPSHFILEOPSTRUCTW lpFileOp)
{ FIXME (shell,"(%p):stub.\n", lpFileOp); { FIXME("(%p):stub.\n", lpFileOp);
return 1; return 1;
} }
@ -515,7 +515,7 @@ DWORD WINAPI SHChangeNotify (
UINT uFlags, /* [IN] the meaning of dwItem[1|2]*/ UINT uFlags, /* [IN] the meaning of dwItem[1|2]*/
LPCVOID dwItem1, LPCVOID dwItem1,
LPCVOID dwItem2) LPCVOID dwItem2)
{ FIXME (shell,"(0x%08x,0x%08ux,%p,%p):stub.\n", wEventId,uFlags,dwItem1,dwItem2); { FIXME("(0x%08x,0x%08ux,%p,%p):stub.\n", wEventId,uFlags,dwItem1,dwItem2);
return 0; return 0;
} }
/************************************************************************* /*************************************************************************
@ -527,7 +527,7 @@ DWORD WINAPI SHChangeNotify (
HRESULT WINAPI SHCreateShellFolderViewEx( HRESULT WINAPI SHCreateShellFolderViewEx(
LPSHELLVIEWDATA psvcbi, /*[in ] shelltemplate struct*/ LPSHELLVIEWDATA psvcbi, /*[in ] shelltemplate struct*/
LPVOID* ppv) /*[out] IShellView pointer*/ LPVOID* ppv) /*[out] IShellView pointer*/
{ FIXME (shell,"(%p,%p):stub.\n", psvcbi,ppv); { FIXME("(%p,%p):stub.\n", psvcbi,ppv);
return 0; return 0;
} }
/************************************************************************* /*************************************************************************
@ -535,7 +535,7 @@ HRESULT WINAPI SHCreateShellFolderViewEx(
* *
*/ */
HRESULT WINAPI SHWinHelp (DWORD v, DWORD w, DWORD x, DWORD z) HRESULT WINAPI SHWinHelp (DWORD v, DWORD w, DWORD x, DWORD z)
{ FIXME(shell,"0x%08lx 0x%08lx 0x%08lx 0x%08lx stub\n",v,w,x,z); { FIXME("0x%08lx 0x%08lx 0x%08lx 0x%08lx stub\n",v,w,x,z);
return 0; return 0;
} }
/************************************************************************* /*************************************************************************
@ -543,7 +543,7 @@ HRESULT WINAPI SHWinHelp (DWORD v, DWORD w, DWORD x, DWORD z)
* *
*/ */
HRESULT WINAPI SHRunControlPanel (DWORD x, DWORD z) HRESULT WINAPI SHRunControlPanel (DWORD x, DWORD z)
{ FIXME(shell,"0x%08lx 0x%08lx stub\n",x,z); { FIXME("0x%08lx 0x%08lx stub\n",x,z);
return 0; return 0;
} }
/************************************************************************* /*************************************************************************
@ -566,7 +566,7 @@ BOOL WINAPI ShellExecuteExA (LPSHELLEXECUTEINFOA sei)
STARTUPINFOA startupinfo; STARTUPINFOA startupinfo;
PROCESS_INFORMATION processinformation; PROCESS_INFORMATION processinformation;
WARN(shell,"mask=0x%08lx hwnd=0x%04x verb=%s file=%s parm=%s dir=%s show=0x%08x class=%s incomplete\n", WARN("mask=0x%08lx hwnd=0x%04x verb=%s file=%s parm=%s dir=%s show=0x%08x class=%s incomplete\n",
sei->fMask, sei->hwnd, sei->lpVerb, sei->lpFile, sei->fMask, sei->hwnd, sei->lpVerb, sei->lpFile,
sei->lpParameters, sei->lpDirectory, sei->nShow, sei->lpClass); sei->lpParameters, sei->lpDirectory, sei->nShow, sei->lpClass);
@ -582,7 +582,7 @@ BOOL WINAPI ShellExecuteExA (LPSHELLEXECUTEINFOA sei)
SEE_MASK_NOCLOSEPROCESS | SEE_MASK_CONNECTNETDRV | SEE_MASK_FLAG_DDEWAIT | SEE_MASK_NOCLOSEPROCESS | SEE_MASK_CONNECTNETDRV | SEE_MASK_FLAG_DDEWAIT |
SEE_MASK_DOENVSUBST | SEE_MASK_FLAG_NO_UI | SEE_MASK_UNICODE | SEE_MASK_DOENVSUBST | SEE_MASK_FLAG_NO_UI | SEE_MASK_UNICODE |
SEE_MASK_NO_CONSOLE | SEE_MASK_ASYNCOK | SEE_MASK_HMONITOR )) SEE_MASK_NO_CONSOLE | SEE_MASK_ASYNCOK | SEE_MASK_HMONITOR ))
{ FIXME (shell,"flags ignored: 0x%08lx\n", sei->fMask); { FIXME("flags ignored: 0x%08lx\n", sei->fMask);
} }
if (sei->fMask & SEE_MASK_CLASSNAME) if (sei->fMask & SEE_MASK_CLASSNAME)
@ -592,7 +592,7 @@ BOOL WINAPI ShellExecuteExA (LPSHELLEXECUTEINFOA sei)
/* process the IDList */ /* process the IDList */
if ( (sei->fMask & SEE_MASK_INVOKEIDLIST) == SEE_MASK_INVOKEIDLIST) /*0x0c*/ if ( (sei->fMask & SEE_MASK_INVOKEIDLIST) == SEE_MASK_INVOKEIDLIST) /*0x0c*/
{ SHGetPathFromIDListA (sei->lpIDList,szApplicationName); { SHGetPathFromIDListA (sei->lpIDList,szApplicationName);
TRACE(shell,"-- idlist=%p (%s)\n", sei->lpIDList, szApplicationName); TRACE("-- idlist=%p (%s)\n", sei->lpIDList, szApplicationName);
} }
else else
{ if (sei->fMask & SEE_MASK_IDLIST ) { if (sei->fMask & SEE_MASK_IDLIST )
@ -619,7 +619,7 @@ BOOL WINAPI ShellExecuteExA (LPSHELLEXECUTEINFOA sei)
memmove(pos,pos+3,len); memmove(pos,pos+3,len);
} }
TRACE(shell,"execute: %s %s\n",szApplicationName, szCommandline); TRACE("execute: %s %s\n",szApplicationName, szCommandline);
ZeroMemory(&startupinfo,sizeof(STARTUPINFOA)); ZeroMemory(&startupinfo,sizeof(STARTUPINFOA));
startupinfo.cb = sizeof(STARTUPINFOA); startupinfo.cb = sizeof(STARTUPINFOA);
@ -639,7 +639,7 @@ BOOL WINAPI ShellExecuteExW (LPSHELLEXECUTEINFOW sei)
{ SHELLEXECUTEINFOA seiA; { SHELLEXECUTEINFOA seiA;
DWORD ret; DWORD ret;
TRACE (shell,"%p\n", sei); TRACE("%p\n", sei);
memcpy(&seiA, sei, sizeof(SHELLEXECUTEINFOA)); memcpy(&seiA, sei, sizeof(SHELLEXECUTEINFOA));
@ -679,7 +679,7 @@ static LPUNKNOWN SHELL32_IExplorerInterface=0;
* Sets the interface * Sets the interface
*/ */
HRESULT WINAPI SHSetInstanceExplorer (LPUNKNOWN lpUnknown) HRESULT WINAPI SHSetInstanceExplorer (LPUNKNOWN lpUnknown)
{ TRACE (shell,"%p\n", lpUnknown); { TRACE("%p\n", lpUnknown);
SHELL32_IExplorerInterface = lpUnknown; SHELL32_IExplorerInterface = lpUnknown;
return (HRESULT) lpUnknown; return (HRESULT) lpUnknown;
} }
@ -690,7 +690,7 @@ HRESULT WINAPI SHSetInstanceExplorer (LPUNKNOWN lpUnknown)
* gets the interface pointer of the explorer and a reference * gets the interface pointer of the explorer and a reference
*/ */
HRESULT WINAPI SHGetInstanceExplorer (LPUNKNOWN * lpUnknown) HRESULT WINAPI SHGetInstanceExplorer (LPUNKNOWN * lpUnknown)
{ TRACE(shell,"%p\n", lpUnknown); { TRACE("%p\n", lpUnknown);
*lpUnknown = SHELL32_IExplorerInterface; *lpUnknown = SHELL32_IExplorerInterface;
@ -707,7 +707,7 @@ HRESULT WINAPI SHGetInstanceExplorer (LPUNKNOWN * lpUnknown)
* exported by name * exported by name
*/ */
HRESULT WINAPI SHFreeUnusedLibraries (void) HRESULT WINAPI SHFreeUnusedLibraries (void)
{ FIXME(shell,"stub\n"); { FIXME("stub\n");
return TRUE; return TRUE;
} }
/************************************************************************* /*************************************************************************
@ -717,7 +717,7 @@ HRESULT WINAPI SHFreeUnusedLibraries (void)
* exported by name * exported by name
*/ */
HRESULT WINAPI DAD_ShowDragImage (DWORD u) HRESULT WINAPI DAD_ShowDragImage (DWORD u)
{ FIXME(shell,"0x%08lx stub\n",u); { FIXME("0x%08lx stub\n",u);
return 0; return 0;
} }
/************************************************************************* /*************************************************************************
@ -725,7 +725,7 @@ HRESULT WINAPI DAD_ShowDragImage (DWORD u)
* *
*/ */
HRESULT WINAPI SHRegCloseKey (HKEY hkey) HRESULT WINAPI SHRegCloseKey (HKEY hkey)
{ TRACE(shell,"0x%04x\n",hkey); { TRACE("0x%04x\n",hkey);
return RegCloseKey( hkey ); return RegCloseKey( hkey );
} }
/************************************************************************* /*************************************************************************
@ -733,7 +733,7 @@ HRESULT WINAPI SHRegCloseKey (HKEY hkey)
* *
*/ */
HRESULT WINAPI SHRegOpenKeyA(HKEY hKey, LPSTR lpSubKey, LPHKEY phkResult) HRESULT WINAPI SHRegOpenKeyA(HKEY hKey, LPSTR lpSubKey, LPHKEY phkResult)
{ FIXME(shell,"(0x%08x, %s, %p)\n", hKey, debugstr_a(lpSubKey), { FIXME("(0x%08x, %s, %p)\n", hKey, debugstr_a(lpSubKey),
phkResult); phkResult);
return RegOpenKeyA(hKey, lpSubKey, phkResult); return RegOpenKeyA(hKey, lpSubKey, phkResult);
} }
@ -743,7 +743,7 @@ HRESULT WINAPI SHRegOpenKeyA(HKEY hKey, LPSTR lpSubKey, LPHKEY phkResult)
* *
*/ */
HRESULT WINAPI SHRegOpenKeyW (HKEY hkey, LPCWSTR lpszSubKey, LPHKEY retkey) HRESULT WINAPI SHRegOpenKeyW (HKEY hkey, LPCWSTR lpszSubKey, LPHKEY retkey)
{ WARN(shell,"0x%04x %s %p\n",hkey,debugstr_w(lpszSubKey),retkey); { WARN("0x%04x %s %p\n",hkey,debugstr_w(lpszSubKey),retkey);
return RegOpenKeyW( hkey, lpszSubKey, retkey ); return RegOpenKeyW( hkey, lpszSubKey, retkey );
} }
/************************************************************************* /*************************************************************************
@ -752,7 +752,7 @@ HRESULT WINAPI SHRegOpenKeyW (HKEY hkey, LPCWSTR lpszSubKey, LPHKEY retkey)
*/ */
HRESULT WINAPI SHRegQueryValueExA(DWORD u, LPSTR v, DWORD w, DWORD x, HRESULT WINAPI SHRegQueryValueExA(DWORD u, LPSTR v, DWORD w, DWORD x,
DWORD y, DWORD z) DWORD y, DWORD z)
{ FIXME(shell,"0x%04lx %s 0x%04lx 0x%04lx 0x%04lx 0x%04lx stub\n", { FIXME("0x%04lx %s 0x%04lx 0x%04lx 0x%04lx 0x%04lx stub\n",
u,debugstr_a(v),w,x,y,z); u,debugstr_a(v),w,x,y,z);
return 0; return 0;
} }
@ -762,7 +762,7 @@ HRESULT WINAPI SHRegQueryValueExA(DWORD u, LPSTR v, DWORD w, DWORD x,
*/ */
HRESULT WINAPI SHRegQueryValueW (HKEY hkey, LPWSTR lpszSubKey, HRESULT WINAPI SHRegQueryValueW (HKEY hkey, LPWSTR lpszSubKey,
LPWSTR lpszData, LPDWORD lpcbData ) LPWSTR lpszData, LPDWORD lpcbData )
{ WARN(shell,"0x%04x %s %p %p semi-stub\n", { WARN("0x%04x %s %p %p semi-stub\n",
hkey, debugstr_w(lpszSubKey), lpszData, lpcbData); hkey, debugstr_w(lpszSubKey), lpszData, lpcbData);
return RegQueryValueW( hkey, lpszSubKey, lpszData, lpcbData ); return RegQueryValueW( hkey, lpszSubKey, lpszData, lpcbData );
} }
@ -777,7 +777,7 @@ HRESULT WINAPI SHRegQueryValueW (HKEY hkey, LPWSTR lpszSubKey,
HRESULT WINAPI SHRegQueryValueExW (HKEY hkey, LPWSTR pszValue, LPDWORD pdwReserved, HRESULT WINAPI SHRegQueryValueExW (HKEY hkey, LPWSTR pszValue, LPDWORD pdwReserved,
LPDWORD pdwType, LPVOID pvData, LPDWORD pcbData) LPDWORD pdwType, LPVOID pvData, LPDWORD pcbData)
{ DWORD ret; { DWORD ret;
WARN(shell,"0x%04x %s %p %p %p %p semi-stub\n", WARN("0x%04x %s %p %p %p %p semi-stub\n",
hkey, debugstr_w(pszValue), pdwReserved, pdwType, pvData, pcbData); hkey, debugstr_w(pszValue), pdwReserved, pdwType, pvData, pcbData);
ret = RegQueryValueExW ( hkey, pszValue, pdwReserved, pdwType, pvData, pcbData); ret = RegQueryValueExW ( hkey, pszValue, pdwReserved, pdwType, pvData, pcbData);
return ret; return ret;
@ -788,7 +788,7 @@ HRESULT WINAPI SHRegQueryValueExW (HKEY hkey, LPWSTR pszValue, LPDWORD pdwReserv
* *
*/ */
HRESULT WINAPI ReadCabinetState(DWORD u, DWORD v) HRESULT WINAPI ReadCabinetState(DWORD u, DWORD v)
{ FIXME(shell,"0x%04lx 0x%04lx stub\n",u,v); { FIXME("0x%04lx 0x%04lx stub\n",u,v);
return 0; return 0;
} }
/************************************************************************* /*************************************************************************
@ -796,7 +796,7 @@ HRESULT WINAPI ReadCabinetState(DWORD u, DWORD v)
* *
*/ */
HRESULT WINAPI WriteCabinetState(DWORD u) HRESULT WINAPI WriteCabinetState(DWORD u)
{ FIXME(shell,"0x%04lx stub\n",u); { FIXME("0x%04lx stub\n",u);
return 0; return 0;
} }
/************************************************************************* /*************************************************************************
@ -804,7 +804,7 @@ HRESULT WINAPI WriteCabinetState(DWORD u)
* *
*/ */
BOOL WINAPI FileIconInit(BOOL bFullInit) BOOL WINAPI FileIconInit(BOOL bFullInit)
{ FIXME(shell,"(%s)\n", bFullInit ? "true" : "false"); { FIXME("(%s)\n", bFullInit ? "true" : "false");
return 0; return 0;
} }
/************************************************************************* /*************************************************************************
@ -812,7 +812,7 @@ BOOL WINAPI FileIconInit(BOOL bFullInit)
* *
*/ */
HRESULT WINAPI IsUserAdmin(void) HRESULT WINAPI IsUserAdmin(void)
{ FIXME(shell,"stub\n"); { FIXME("stub\n");
return TRUE; return TRUE;
} }
/************************************************************************* /*************************************************************************
@ -824,7 +824,7 @@ HRESULT WINAPI IsUserAdmin(void)
* the pidl is for STRRET OFFSET * the pidl is for STRRET OFFSET
*/ */
HRESULT WINAPI StrRetToStrN (LPVOID dest, DWORD len, LPSTRRET src, LPITEMIDLIST pidl) HRESULT WINAPI StrRetToStrN (LPVOID dest, DWORD len, LPSTRRET src, LPITEMIDLIST pidl)
{ TRACE(shell,"dest=0x%p len=0x%lx strret=0x%p pidl=%p stub\n",dest,len,src,pidl); { TRACE("dest=0x%p len=0x%lx strret=0x%p pidl=%p stub\n",dest,len,src,pidl);
switch (src->uType) switch (src->uType)
{ case STRRET_WSTR: { case STRRET_WSTR:
@ -849,7 +849,7 @@ HRESULT WINAPI StrRetToStrN (LPVOID dest, DWORD len, LPSTRRET src, LPITEMIDLIST
} }
default: default:
FIXME(shell,"unknown type!\n"); FIXME("unknown type!\n");
if (len) if (len)
{ *(LPSTR)dest = '\0'; { *(LPSTR)dest = '\0';
} }
@ -865,7 +865,7 @@ HRESULT WINAPI StrRetToStrN (LPVOID dest, DWORD len, LPSTRRET src, LPITEMIDLIST
LPWSTR WINAPI StrChrW (LPWSTR str, WCHAR x ) LPWSTR WINAPI StrChrW (LPWSTR str, WCHAR x )
{ LPWSTR ptr=str; { LPWSTR ptr=str;
TRACE(shell,"%s 0x%04x\n",debugstr_w(str),x); TRACE("%s 0x%04x\n",debugstr_w(str),x);
do do
{ if (*ptr==x) { if (*ptr==x)
{ return ptr; { return ptr;
@ -880,7 +880,7 @@ LPWSTR WINAPI StrChrW (LPWSTR str, WCHAR x )
* *
*/ */
INT WINAPI StrCmpNIW ( LPWSTR wstr1, LPWSTR wstr2, INT len) INT WINAPI StrCmpNIW ( LPWSTR wstr1, LPWSTR wstr2, INT len)
{ FIXME( shell,"%s %s %i stub\n", debugstr_w(wstr1),debugstr_w(wstr2),len); { FIXME("%s %s %i stub\n", debugstr_w(wstr1),debugstr_w(wstr2),len);
return 0; return 0;
} }
@ -900,7 +900,7 @@ HGLOBAL WINAPI SHAllocShared(LPVOID psrc, DWORD size, DWORD procID)
{ HGLOBAL hmem; { HGLOBAL hmem;
LPVOID pmem; LPVOID pmem;
TRACE(shell,"ptr=%p size=0x%04lx procID=0x%04lx\n",psrc,size,procID); TRACE("ptr=%p size=0x%04lx procID=0x%04lx\n",psrc,size,procID);
hmem = GlobalAlloc(GMEM_FIXED, size); hmem = GlobalAlloc(GMEM_FIXED, size);
if (!hmem) if (!hmem)
return 0; return 0;
@ -924,7 +924,7 @@ HGLOBAL WINAPI SHAllocShared(LPVOID psrc, DWORD size, DWORD procID)
* the returnvalue seems to be a memoryadress * the returnvalue seems to be a memoryadress
*/ */
LPVOID WINAPI SHLockShared(HANDLE hmem, DWORD procID) LPVOID WINAPI SHLockShared(HANDLE hmem, DWORD procID)
{ TRACE(shell,"handle=0x%04x procID=0x%04lx\n",hmem,procID); { TRACE("handle=0x%04x procID=0x%04lx\n",hmem,procID);
return GlobalLock(hmem); return GlobalLock(hmem);
} }
/************************************************************************* /*************************************************************************
@ -934,7 +934,7 @@ LPVOID WINAPI SHLockShared(HANDLE hmem, DWORD procID)
* parameter1 is return value from SHLockShared * parameter1 is return value from SHLockShared
*/ */
BOOL WINAPI SHUnlockShared(HANDLE pmem) BOOL WINAPI SHUnlockShared(HANDLE pmem)
{ TRACE(shell,"handle=0x%04x\n",pmem); { TRACE("handle=0x%04x\n",pmem);
return GlobalUnlock(pmem); return GlobalUnlock(pmem);
} }
/************************************************************************* /*************************************************************************
@ -945,7 +945,7 @@ BOOL WINAPI SHUnlockShared(HANDLE pmem)
* parameter2 is return value from GetCurrentProcessId * parameter2 is return value from GetCurrentProcessId
*/ */
HANDLE WINAPI SHFreeShared(HANDLE hmem, DWORD procID) HANDLE WINAPI SHFreeShared(HANDLE hmem, DWORD procID)
{ TRACE(shell,"handle=0x%04x 0x%04lx\n",hmem,procID); { TRACE("handle=0x%04x 0x%04lx\n",hmem,procID);
return GlobalFree(hmem); return GlobalFree(hmem);
} }
@ -954,7 +954,7 @@ HANDLE WINAPI SHFreeShared(HANDLE hmem, DWORD procID)
* *
*/ */
HRESULT WINAPI SetAppStartingCursor(HWND u, DWORD v) HRESULT WINAPI SetAppStartingCursor(HWND u, DWORD v)
{ FIXME(shell,"hwnd=0x%04x 0x%04lx stub\n",u,v ); { FIXME("hwnd=0x%04x 0x%04lx stub\n",u,v );
return 0; return 0;
} }
/************************************************************************* /*************************************************************************
@ -962,7 +962,7 @@ HRESULT WINAPI SetAppStartingCursor(HWND u, DWORD v)
* *
*/ */
HRESULT WINAPI SHLoadOLE(DWORD u) HRESULT WINAPI SHLoadOLE(DWORD u)
{ FIXME(shell,"0x%04lx stub\n",u); { FIXME("0x%04lx stub\n",u);
return S_OK; return S_OK;
} }
/************************************************************************* /*************************************************************************
@ -970,7 +970,7 @@ HRESULT WINAPI SHLoadOLE(DWORD u)
* *
*/ */
HRESULT WINAPI DriveType(DWORD u) HRESULT WINAPI DriveType(DWORD u)
{ FIXME(shell,"0x%04lx stub\n",u); { FIXME("0x%04lx stub\n",u);
return 0; return 0;
} }
/************************************************************************* /*************************************************************************
@ -978,7 +978,7 @@ HRESULT WINAPI DriveType(DWORD u)
* *
*/ */
HRESULT WINAPI SHAbortInvokeCommand(void) HRESULT WINAPI SHAbortInvokeCommand(void)
{ FIXME(shell,"stub\n"); { FIXME("stub\n");
return 1; return 1;
} }
/************************************************************************* /*************************************************************************
@ -986,7 +986,7 @@ HRESULT WINAPI SHAbortInvokeCommand(void)
* *
*/ */
HRESULT WINAPI SHOutOfMemoryMessageBox(DWORD u, DWORD v, DWORD w) HRESULT WINAPI SHOutOfMemoryMessageBox(DWORD u, DWORD v, DWORD w)
{ FIXME(shell,"0x%04lx 0x%04lx 0x%04lx stub\n",u,v,w); { FIXME("0x%04lx 0x%04lx 0x%04lx stub\n",u,v,w);
return 0; return 0;
} }
/************************************************************************* /*************************************************************************
@ -994,7 +994,7 @@ HRESULT WINAPI SHOutOfMemoryMessageBox(DWORD u, DWORD v, DWORD w)
* *
*/ */
HRESULT WINAPI SHFlushClipboard(void) HRESULT WINAPI SHFlushClipboard(void)
{ FIXME(shell,"stub\n"); { FIXME("stub\n");
return 1; return 1;
} }
/************************************************************************* /*************************************************************************
@ -1003,7 +1003,7 @@ HRESULT WINAPI SHFlushClipboard(void)
*/ */
LPWSTR WINAPI StrRChrW(LPWSTR lpStart, LPWSTR lpEnd, DWORD wMatch) LPWSTR WINAPI StrRChrW(LPWSTR lpStart, LPWSTR lpEnd, DWORD wMatch)
{ LPWSTR wptr=NULL; { LPWSTR wptr=NULL;
TRACE(shell,"%s %s 0x%04x\n",debugstr_w(lpStart),debugstr_w(lpEnd), (WCHAR)wMatch ); TRACE("%s %s 0x%04x\n",debugstr_w(lpStart),debugstr_w(lpEnd), (WCHAR)wMatch );
/* if the end not given, search*/ /* if the end not given, search*/
if (!lpEnd) if (!lpEnd)
@ -1024,7 +1024,7 @@ LPWSTR WINAPI StrRChrW(LPWSTR lpStart, LPWSTR lpEnd, DWORD wMatch)
*/ */
LPSTR WINAPI StrFormatByteSizeA ( DWORD dw, LPSTR pszBuf, UINT cchBuf ) LPSTR WINAPI StrFormatByteSizeA ( DWORD dw, LPSTR pszBuf, UINT cchBuf )
{ char buf[64]; { char buf[64];
TRACE(shell,"%lx %p %i\n", dw, pszBuf, cchBuf); TRACE("%lx %p %i\n", dw, pszBuf, cchBuf);
if ( dw<1024L ) if ( dw<1024L )
{ sprintf (buf,"%3.1f bytes", (FLOAT)dw); { sprintf (buf,"%3.1f bytes", (FLOAT)dw);
} }
@ -1042,7 +1042,7 @@ LPSTR WINAPI StrFormatByteSizeA ( DWORD dw, LPSTR pszBuf, UINT cchBuf )
} }
LPWSTR WINAPI StrFormatByteSizeW ( DWORD dw, LPWSTR pszBuf, UINT cchBuf ) LPWSTR WINAPI StrFormatByteSizeW ( DWORD dw, LPWSTR pszBuf, UINT cchBuf )
{ char buf[64]; { char buf[64];
TRACE(shell,"%lx %p %i\n", dw, pszBuf, cchBuf); TRACE("%lx %p %i\n", dw, pszBuf, cchBuf);
if ( dw<1024L ) if ( dw<1024L )
{ sprintf (buf,"%3.1f bytes", (FLOAT)dw); { sprintf (buf,"%3.1f bytes", (FLOAT)dw);
} }
@ -1063,7 +1063,7 @@ LPWSTR WINAPI StrFormatByteSizeW ( DWORD dw, LPWSTR pszBuf, UINT cchBuf )
* *
*/ */
HRESULT WINAPI SHWaitForFileToOpen(DWORD u, DWORD v, DWORD w) HRESULT WINAPI SHWaitForFileToOpen(DWORD u, DWORD v, DWORD w)
{ FIXME(shell,"0x%04lx 0x%04lx 0x%04lx stub\n",u,v,w); { FIXME("0x%04lx 0x%04lx 0x%04lx stub\n",u,v,w);
return 0; return 0;
} }
/************************************************************************* /*************************************************************************
@ -1071,7 +1071,7 @@ HRESULT WINAPI SHWaitForFileToOpen(DWORD u, DWORD v, DWORD w)
* *
*/ */
HRESULT WINAPI Control_FillCache_RunDLL(HWND hWnd, HANDLE hModule, DWORD w, DWORD x) HRESULT WINAPI Control_FillCache_RunDLL(HWND hWnd, HANDLE hModule, DWORD w, DWORD x)
{ FIXME(shell,"0x%04x 0x%04x 0x%04lx 0x%04lx stub\n",hWnd, hModule,w,x); { FIXME("0x%04x 0x%04x 0x%04lx 0x%04lx stub\n",hWnd, hModule,w,x);
return 0; return 0;
} }
/************************************************************************* /*************************************************************************
@ -1079,7 +1079,7 @@ HRESULT WINAPI Control_FillCache_RunDLL(HWND hWnd, HANDLE hModule, DWORD w, DWOR
* the name is propably wrong * the name is propably wrong
*/ */
HRESULT WINAPI RunDLL_CallEntry16(DWORD v, DWORD w, DWORD x, DWORD y, DWORD z) HRESULT WINAPI RunDLL_CallEntry16(DWORD v, DWORD w, DWORD x, DWORD y, DWORD z)
{ FIXME(shell,"0x%04lx 0x%04lx 0x%04lx 0x%04lx 0x%04lx stub\n",v,w,x,y,z); { FIXME("0x%04lx 0x%04lx 0x%04lx 0x%04lx 0x%04lx stub\n",v,w,x,y,z);
return 0; return 0;
} }
@ -1088,7 +1088,7 @@ HRESULT WINAPI RunDLL_CallEntry16(DWORD v, DWORD w, DWORD x, DWORD y, DWORD z)
* *
*/ */
HRESULT WINAPI shell32_654 (DWORD x, DWORD y) HRESULT WINAPI shell32_654 (DWORD x, DWORD y)
{ FIXME(shell,"0x%08lx 0x%08lx stub\n",x,y); { FIXME("0x%08lx 0x%08lx stub\n",x,y);
return 0; return 0;
} }
@ -1099,7 +1099,7 @@ HRESULT WINAPI shell32_654 (DWORD x, DWORD y)
* builds a DPA * builds a DPA
*/ */
DWORD WINAPI RLBuildListOfPaths () DWORD WINAPI RLBuildListOfPaths ()
{ FIXME (shell,"stub\n"); { FIXME("stub\n");
return 0; return 0;
} }
/************************************************************************ /************************************************************************
@ -1108,7 +1108,7 @@ DWORD WINAPI RLBuildListOfPaths ()
*/ */
int WINAPI StrToOleStr (LPWSTR lpWideCharStr, LPCSTR lpMultiByteString) int WINAPI StrToOleStr (LPWSTR lpWideCharStr, LPCSTR lpMultiByteString)
{ {
TRACE(shell,"%p %p(%s)\n", TRACE("%p %p(%s)\n",
lpWideCharStr, lpMultiByteString, lpMultiByteString); lpWideCharStr, lpMultiByteString, lpMultiByteString);
return MultiByteToWideChar(0, 0, lpMultiByteString, -1, lpWideCharStr, MAX_PATH); return MultiByteToWideChar(0, 0, lpMultiByteString, -1, lpWideCharStr, MAX_PATH);
@ -1119,6 +1119,6 @@ int WINAPI StrToOleStr (LPWSTR lpWideCharStr, LPCSTR lpMultiByteString)
* *
*/ */
HRESULT WINAPI SHValidateUNC (DWORD x, DWORD y, DWORD z) HRESULT WINAPI SHValidateUNC (DWORD x, DWORD y, DWORD z)
{ FIXME(shell,"0x%08lx 0x%08lx 0x%08lx stub\n",x,y,z); { FIXME("0x%08lx 0x%08lx 0x%08lx stub\n",x,y,z);
return 0; return 0;
} }

View file

@ -6,7 +6,7 @@
*/ */
#include <string.h> #include <string.h>
#include <ctype.h> #include <ctype.h>
#include "debug.h" #include "debugtools.h"
#include "winnls.h" #include "winnls.h"
#include "winversion.h" #include "winversion.h"
@ -19,7 +19,7 @@ DEFAULT_DEBUG_CHANNEL(shell)
* PathIsRoot [SHELL32.29] * PathIsRoot [SHELL32.29]
*/ */
BOOL WINAPI PathIsRootA(LPCSTR x) BOOL WINAPI PathIsRootA(LPCSTR x)
{ TRACE(shell,"%s\n",x); { TRACE("%s\n",x);
if (*(x+1)==':' && *(x+2)=='\\') /* "X:\" */ if (*(x+1)==':' && *(x+2)=='\\') /* "X:\" */
return 1; return 1;
if (*x=='\\') /* "\" */ if (*x=='\\') /* "\" */
@ -37,7 +37,7 @@ BOOL WINAPI PathIsRootA(LPCSTR x)
return 0; return 0;
} }
BOOL WINAPI PathIsRootW(LPCWSTR x) BOOL WINAPI PathIsRootW(LPCWSTR x)
{ TRACE(shell,"%s\n",debugstr_w(x)); { TRACE("%s\n",debugstr_w(x));
if (*(x+1)==':' && *(x+2)=='\\') /* "X:\" */ if (*(x+1)==':' && *(x+2)=='\\') /* "X:\" */
return 1; return 1;
if (*x == (WCHAR) '\\') /* "\" */ if (*x == (WCHAR) '\\') /* "\" */
@ -64,7 +64,7 @@ BOOL WINAPI PathIsRootAW(LPCVOID x)
* PathBuildRoot [SHELL32.30] * PathBuildRoot [SHELL32.30]
*/ */
LPSTR WINAPI PathBuildRootA(LPSTR root,BYTE drive) { LPSTR WINAPI PathBuildRootA(LPSTR root,BYTE drive) {
TRACE(shell,"%p %i\n",root, drive); TRACE("%p %i\n",root, drive);
strcpy(root,"A:\\"); strcpy(root,"A:\\");
root[0]+=drive; root[0]+=drive;
return root; return root;
@ -78,7 +78,7 @@ LPSTR WINAPI PathBuildRootA(LPSTR root,BYTE drive) {
*/ */
LPCSTR WINAPI PathFindExtensionA(LPCSTR path) LPCSTR WINAPI PathFindExtensionA(LPCSTR path)
{ LPCSTR lastpoint = NULL; { LPCSTR lastpoint = NULL;
TRACE(shell,"%p %s\n",path,path); TRACE("%p %s\n",path,path);
while (*path) while (*path)
{ if (*path=='\\'||*path==' ') { if (*path=='\\'||*path==' ')
lastpoint=NULL; lastpoint=NULL;
@ -90,7 +90,7 @@ LPCSTR WINAPI PathFindExtensionA(LPCSTR path)
} }
LPCWSTR WINAPI PathFindExtensionW(LPCWSTR path) LPCWSTR WINAPI PathFindExtensionW(LPCWSTR path)
{ LPCWSTR lastpoint = NULL; { LPCWSTR lastpoint = NULL;
TRACE(shell,"%p L%s\n",path,debugstr_w(path)); TRACE("%p L%s\n",path,debugstr_w(path));
while (*path) while (*path)
{ if (*path==(WCHAR)'\\'||*path==(WCHAR)' ') { if (*path==(WCHAR)'\\'||*path==(WCHAR)' ')
lastpoint=NULL; lastpoint=NULL;
@ -115,7 +115,7 @@ LPCVOID WINAPI PathFindExtensionAW(LPCVOID path)
*/ */
LPSTR WINAPI PathAddBackslashA(LPSTR path) LPSTR WINAPI PathAddBackslashA(LPSTR path)
{ int len; { int len;
TRACE(shell,"%p->%s\n",path,path); TRACE("%p->%s\n",path,path);
len = strlen(path); len = strlen(path);
if (len && path[len-1]!='\\') if (len && path[len-1]!='\\')
@ -127,7 +127,7 @@ LPSTR WINAPI PathAddBackslashA(LPSTR path)
} }
LPWSTR WINAPI PathAddBackslashW(LPWSTR path) LPWSTR WINAPI PathAddBackslashW(LPWSTR path)
{ int len; { int len;
TRACE(shell,"%p->%s\n",path,debugstr_w(path)); TRACE("%p->%s\n",path,debugstr_w(path));
len = lstrlenW(path); len = lstrlenW(path);
if (len && path[len-1]!=(WCHAR)'\\') if (len && path[len-1]!=(WCHAR)'\\')
@ -151,7 +151,7 @@ LPVOID WINAPI PathAddBackslashAW(LPVOID path)
*/ */
LPSTR WINAPI PathRemoveBlanksA(LPSTR str) LPSTR WINAPI PathRemoveBlanksA(LPSTR str)
{ LPSTR x = str; { LPSTR x = str;
TRACE(shell,"%s\n",str); TRACE("%s\n",str);
while (*x==' ') x++; while (*x==' ') x++;
if (x!=str) if (x!=str)
strcpy(str,x); strcpy(str,x);
@ -166,7 +166,7 @@ LPSTR WINAPI PathRemoveBlanksA(LPSTR str)
} }
LPWSTR WINAPI PathRemoveBlanksW(LPWSTR str) LPWSTR WINAPI PathRemoveBlanksW(LPWSTR str)
{ LPWSTR x = str; { LPWSTR x = str;
TRACE(shell,"%s\n",debugstr_w(str)); TRACE("%s\n",debugstr_w(str));
while (*x==' ') x++; while (*x==' ') x++;
if (x!=str) if (x!=str)
lstrcpyW(str,x); lstrcpyW(str,x);
@ -197,7 +197,7 @@ LPCSTR WINAPI PathFindFilenameA(LPCSTR aptr)
{ LPCSTR aslash; { LPCSTR aslash;
aslash = aptr; aslash = aptr;
TRACE(shell,"%s\n",aslash); TRACE("%s\n",aslash);
while (aptr[0]) while (aptr[0])
{ if (((aptr[0]=='\\') || (aptr[0]==':')) && aptr[1] && aptr[1]!='\\') { if (((aptr[0]=='\\') || (aptr[0]==':')) && aptr[1] && aptr[1]!='\\')
aslash = aptr+1; aslash = aptr+1;
@ -210,7 +210,7 @@ LPCWSTR WINAPI PathFindFilenameW(LPCWSTR wptr)
{ LPCWSTR wslash; { LPCWSTR wslash;
wslash = wptr; wslash = wptr;
TRACE(shell,"L%s\n",debugstr_w(wslash)); TRACE("L%s\n",debugstr_w(wslash));
while (wptr[0]) while (wptr[0])
{ if (((wptr[0]=='\\') || (wptr[0]==':')) && wptr[1] && wptr[1]!='\\') { if (((wptr[0]=='\\') || (wptr[0]==':')) && wptr[1] && wptr[1]!='\\')
wslash = wptr+1; wslash = wptr+1;
@ -237,7 +237,7 @@ LPCVOID WINAPI PathFindFilenameAW(LPCVOID fn)
*/ */
DWORD WINAPI PathRemoveFileSpecA(LPSTR fn) { DWORD WINAPI PathRemoveFileSpecA(LPSTR fn) {
LPSTR x,cutplace; LPSTR x,cutplace;
TRACE(shell,"%s\n",fn); TRACE("%s\n",fn);
if (!fn[0]) if (!fn[0])
return 0; return 0;
x=fn; x=fn;
@ -277,7 +277,7 @@ DWORD WINAPI PathRemoveFileSpecA(LPSTR fn) {
* concats "target\\add" and writes them to target * concats "target\\add" and writes them to target
*/ */
LPSTR WINAPI PathAppendA(LPSTR x1,LPSTR x2) { LPSTR WINAPI PathAppendA(LPSTR x1,LPSTR x2) {
TRACE(shell,"%s %s\n",x1,x2); TRACE("%s %s\n",x1,x2);
while (x2[0]=='\\') x2++; while (x2[0]=='\\') x2++;
return PathCombineA(x1,x1,x2); return PathCombineA(x1,x1,x2);
} }
@ -291,7 +291,7 @@ LPSTR WINAPI PathAppendA(LPSTR x1,LPSTR x2) {
*/ */
LPSTR WINAPI PathCombineA(LPSTR szDest, LPCSTR lpszDir, LPCSTR lpszFile) LPSTR WINAPI PathCombineA(LPSTR szDest, LPCSTR lpszDir, LPCSTR lpszFile)
{ char sTemp[MAX_PATH]; { char sTemp[MAX_PATH];
TRACE(shell,"%p %p->%s %p->%s\n",szDest, lpszDir, lpszDir, lpszFile, lpszFile); TRACE("%p %p->%s %p->%s\n",szDest, lpszDir, lpszDir, lpszFile, lpszFile);
if (!lpszFile || !lpszFile[0] || (lpszFile[0]=='.' && !lpszFile[1]) ) if (!lpszFile || !lpszFile[0] || (lpszFile[0]=='.' && !lpszFile[1]) )
@ -313,7 +313,7 @@ LPSTR WINAPI PathCombineA(LPSTR szDest, LPCSTR lpszDir, LPCSTR lpszFile)
} }
LPWSTR WINAPI PathCombineW(LPWSTR szDest, LPCWSTR lpszDir, LPCWSTR lpszFile) LPWSTR WINAPI PathCombineW(LPWSTR szDest, LPCWSTR lpszDir, LPCWSTR lpszFile)
{ WCHAR sTemp[MAX_PATH]; { WCHAR sTemp[MAX_PATH];
TRACE(shell,"%p %p->%s %p->%s\n",szDest, lpszDir, debugstr_w(lpszDir), TRACE("%p %p->%s %p->%s\n",szDest, lpszDir, debugstr_w(lpszDir),
lpszFile, debugstr_w(lpszFile)); lpszFile, debugstr_w(lpszFile));
@ -347,14 +347,14 @@ LPVOID WINAPI PathCombineAW(LPVOID szDest, LPCVOID lpszDir, LPCVOID lpszFile)
* PathIsUNC(char*path); * PathIsUNC(char*path);
*/ */
BOOL WINAPI PathIsUNCA(LPCSTR path) BOOL WINAPI PathIsUNCA(LPCSTR path)
{ TRACE(shell,"%s\n",path); { TRACE("%s\n",path);
if ((path[0]=='\\') && (path[1]=='\\')) if ((path[0]=='\\') && (path[1]=='\\'))
return TRUE; return TRUE;
return FALSE; return FALSE;
} }
BOOL WINAPI PathIsUNCW(LPCWSTR path) BOOL WINAPI PathIsUNCW(LPCWSTR path)
{ TRACE(shell,"%s\n",debugstr_w(path)); { TRACE("%s\n",debugstr_w(path));
if ((path[0]=='\\') && (path[1]=='\\')) if ((path[0]=='\\') && (path[1]=='\\'))
return TRUE; return TRUE;
@ -370,14 +370,14 @@ BOOL WINAPI PathIsUNCAW (LPCVOID path)
* *
*/ */
BOOL WINAPI PathIsRelativeA (LPCSTR path) BOOL WINAPI PathIsRelativeA (LPCSTR path)
{ TRACE(shell,"path=%s\n",path); { TRACE("path=%s\n",path);
if (path && (path[0]!='\\' && path[1]==':')) if (path && (path[0]!='\\' && path[1]==':'))
return TRUE; return TRUE;
return FALSE; return FALSE;
} }
BOOL WINAPI PathIsRelativeW (LPCWSTR path) BOOL WINAPI PathIsRelativeW (LPCWSTR path)
{ TRACE(shell,"path=%s\n",debugstr_w(path)); { TRACE("path=%s\n",debugstr_w(path));
if (path && (path[0]!='\\' && path[1]==':')) if (path && (path[0]!='\\' && path[1]==':'))
return TRUE; return TRUE;
@ -393,11 +393,11 @@ BOOL WINAPI PathIsRelativeAW (LPCVOID path)
* *
*/ */
BOOL WINAPI PathIsExeA (LPCSTR path) BOOL WINAPI PathIsExeA (LPCSTR path)
{ FIXME(shell,"path=%s\n",path); { FIXME("path=%s\n",path);
return FALSE; return FALSE;
} }
BOOL WINAPI PathIsExeW (LPCWSTR path) BOOL WINAPI PathIsExeW (LPCWSTR path)
{ FIXME(shell,"path=%s\n",debugstr_w(path)); { FIXME("path=%s\n",debugstr_w(path));
return FALSE; return FALSE;
} }
BOOL WINAPI PathIsExeAW (LPCVOID path) BOOL WINAPI PathIsExeAW (LPCVOID path)
@ -413,7 +413,7 @@ BOOL WINAPI PathIsExeAW (LPCVOID path)
* file_exists(char *fn); * file_exists(char *fn);
*/ */
BOOL WINAPI PathFileExistsA(LPSTR fn) { BOOL WINAPI PathFileExistsA(LPSTR fn) {
TRACE(shell,"%s\n",fn); TRACE("%s\n",fn);
if (GetFileAttributesA(fn)==-1) if (GetFileAttributesA(fn)==-1)
return FALSE; return FALSE;
else else
@ -429,7 +429,7 @@ BOOL WINAPI PathFileExistsA(LPSTR fn) {
BOOL WINAPI PathMatchSpecA(LPCSTR name, LPCSTR mask) BOOL WINAPI PathMatchSpecA(LPCSTR name, LPCSTR mask)
{ LPCSTR _name; { LPCSTR _name;
TRACE(shell,"%s %s stub\n",name,mask); TRACE("%s %s stub\n",name,mask);
_name = name; _name = name;
while (*_name && *mask) while (*_name && *mask)
@ -461,7 +461,7 @@ BOOL WINAPI PathMatchSpecW(LPCWSTR name, LPCWSTR mask)
{ WCHAR stemp[4]; { WCHAR stemp[4];
LPCWSTR _name; LPCWSTR _name;
TRACE(shell,"%s %s stub\n",debugstr_w(name),debugstr_w(mask)); TRACE("%s %s stub\n",debugstr_w(name),debugstr_w(mask));
lstrcpyAtoW(stemp,"*.*"); lstrcpyAtoW(stemp,"*.*");
if (!lstrcmpW( mask, stemp )) return 1; if (!lstrcmpW( mask, stemp )) return 1;
@ -504,11 +504,11 @@ BOOL WINAPI PathMatchSpecAW(LPVOID name, LPVOID mask)
*/ */
BOOL WINAPI PathSetDlgItemPathA(HWND hDlg, int id, LPCSTR pszPath) BOOL WINAPI PathSetDlgItemPathA(HWND hDlg, int id, LPCSTR pszPath)
{ TRACE(shell,"%x %x %s\n",hDlg, id, pszPath); { TRACE("%x %x %s\n",hDlg, id, pszPath);
return SetDlgItemTextA(hDlg, id, pszPath); return SetDlgItemTextA(hDlg, id, pszPath);
} }
BOOL WINAPI PathSetDlgItemPathW(HWND hDlg, int id, LPCWSTR pszPath) BOOL WINAPI PathSetDlgItemPathW(HWND hDlg, int id, LPCWSTR pszPath)
{ TRACE(shell,"%x %x %s\n",hDlg, id, debugstr_w(pszPath)); { TRACE("%x %x %s\n",hDlg, id, debugstr_w(pszPath));
return SetDlgItemTextW(hDlg, id, pszPath); return SetDlgItemTextW(hDlg, id, pszPath);
} }
BOOL WINAPI PathSetDlgItemPathAW(HWND hDlg, int id, LPCVOID pszPath) BOOL WINAPI PathSetDlgItemPathAW(HWND hDlg, int id, LPCVOID pszPath)
@ -522,11 +522,11 @@ BOOL WINAPI PathSetDlgItemPathAW(HWND hDlg, int id, LPCVOID pszPath)
*/ */
BOOL WINAPI PathQualifyA(LPCSTR pszPath) BOOL WINAPI PathQualifyA(LPCSTR pszPath)
{ TRACE(shell,"%s\n",pszPath); { TRACE("%s\n",pszPath);
return 0; return 0;
} }
BOOL WINAPI PathQualifyW(LPCWSTR pszPath) BOOL WINAPI PathQualifyW(LPCWSTR pszPath)
{ TRACE(shell,"%s\n",debugstr_w(pszPath)); { TRACE("%s\n",debugstr_w(pszPath));
return 0; return 0;
} }
BOOL WINAPI PathQualifyAW(LPCVOID pszPath) BOOL WINAPI PathQualifyAW(LPCVOID pszPath)
@ -539,7 +539,7 @@ BOOL WINAPI PathQualifyAW(LPCVOID pszPath)
* PathResolve [SHELL32.51] * PathResolve [SHELL32.51]
*/ */
DWORD WINAPI PathResolve(LPCSTR s,DWORD x2,DWORD x3) { DWORD WINAPI PathResolve(LPCSTR s,DWORD x2,DWORD x3) {
FIXME(shell,"(%s,0x%08lx,0x%08lx),stub!\n",s,x2,x3); FIXME("(%s,0x%08lx,0x%08lx),stub!\n",s,x2,x3);
return 0; return 0;
} }
@ -553,7 +553,7 @@ DWORD WINAPI PathResolve(LPCSTR s,DWORD x2,DWORD x3) {
LPCSTR WINAPI PathGetArgsA(LPCSTR cmdline) LPCSTR WINAPI PathGetArgsA(LPCSTR cmdline)
{ BOOL qflag = FALSE; { BOOL qflag = FALSE;
TRACE(shell,"%s\n",cmdline); TRACE("%s\n",cmdline);
while (*cmdline) while (*cmdline)
{ if ((*cmdline==' ') && !qflag) { if ((*cmdline==' ') && !qflag)
@ -568,7 +568,7 @@ LPCSTR WINAPI PathGetArgsA(LPCSTR cmdline)
LPCWSTR WINAPI PathGetArgsW(LPCWSTR cmdline) LPCWSTR WINAPI PathGetArgsW(LPCWSTR cmdline)
{ BOOL qflag = FALSE; { BOOL qflag = FALSE;
TRACE(shell,"%sL\n",debugstr_w(cmdline)); TRACE("%sL\n",debugstr_w(cmdline));
while (*cmdline) while (*cmdline)
{ if ((*cmdline==' ') && !qflag) { if ((*cmdline==' ') && !qflag)
@ -591,12 +591,12 @@ LPCVOID WINAPI PathGetArgsAW(LPVOID cmdline)
* basename(char *fn); * basename(char *fn);
*/ */
LPSTR WINAPI PathQuoteSpacesA(LPCSTR aptr) LPSTR WINAPI PathQuoteSpacesA(LPCSTR aptr)
{ FIXME(shell,"%s\n",aptr); { FIXME("%s\n",aptr);
return 0; return 0;
} }
LPWSTR WINAPI PathQuoteSpacesW(LPCWSTR wptr) LPWSTR WINAPI PathQuoteSpacesW(LPCWSTR wptr)
{ FIXME(shell,"L%s\n",debugstr_w(wptr)); { FIXME("L%s\n",debugstr_w(wptr));
return 0; return 0;
} }
LPVOID WINAPI PathQuoteSpacesAW (LPCVOID fn) LPVOID WINAPI PathQuoteSpacesAW (LPCVOID fn)
@ -614,7 +614,7 @@ LPVOID WINAPI PathQuoteSpacesAW (LPCVOID fn)
*/ */
VOID WINAPI PathUnquoteSpacesA(LPSTR str) VOID WINAPI PathUnquoteSpacesA(LPSTR str)
{ DWORD len = lstrlenA(str); { DWORD len = lstrlenA(str);
TRACE(shell,"%s\n",str); TRACE("%s\n",str);
if (*str!='"') if (*str!='"')
return; return;
if (str[len-1]!='"') if (str[len-1]!='"')
@ -626,7 +626,7 @@ VOID WINAPI PathUnquoteSpacesA(LPSTR str)
VOID WINAPI PathUnquoteSpacesW(LPWSTR str) VOID WINAPI PathUnquoteSpacesW(LPWSTR str)
{ DWORD len = lstrlenW(str); { DWORD len = lstrlenW(str);
TRACE(shell,"%s\n",debugstr_w(str)); TRACE("%s\n",debugstr_w(str));
if (*str!='"') if (*str!='"')
return; return;
@ -648,7 +648,7 @@ VOID WINAPI PathUnquoteSpacesAW(LPVOID str)
* *
*/ */
HRESULT WINAPI PathGetDriveNumber(LPSTR u) HRESULT WINAPI PathGetDriveNumber(LPSTR u)
{ FIXME(shell,"%s stub\n",debugstr_a(u)); { FIXME("%s stub\n",debugstr_a(u));
return 0; return 0;
} }
@ -659,7 +659,7 @@ HRESULT WINAPI PathGetDriveNumber(LPSTR u)
* exported by ordinal * exported by ordinal
*/ */
BOOL WINAPI PathYetAnotherMakeUniqueNameA(LPDWORD x,LPDWORD y) { BOOL WINAPI PathYetAnotherMakeUniqueNameA(LPDWORD x,LPDWORD y) {
FIXME(shell,"(%p,%p):stub.\n",x,y); FIXME("(%p,%p):stub.\n",x,y);
return TRUE; return TRUE;
} }
@ -680,11 +680,11 @@ BOOL WINAPI IsLFNDriveA(LPCSTR path) {
* PathFindOnPath [SHELL32.145] * PathFindOnPath [SHELL32.145]
*/ */
BOOL WINAPI PathFindOnPathA(LPSTR sFile, LPCSTR sOtherDirs) BOOL WINAPI PathFindOnPathA(LPSTR sFile, LPCSTR sOtherDirs)
{ FIXME(shell,"%s %s\n",sFile, sOtherDirs); { FIXME("%s %s\n",sFile, sOtherDirs);
return FALSE; return FALSE;
} }
BOOL WINAPI PathFindOnPathW(LPWSTR sFile, LPCWSTR sOtherDirs) BOOL WINAPI PathFindOnPathW(LPWSTR sFile, LPCWSTR sOtherDirs)
{ FIXME(shell,"%s %s\n",debugstr_w(sFile), debugstr_w(sOtherDirs)); { FIXME("%s %s\n",debugstr_w(sFile), debugstr_w(sOtherDirs));
return FALSE; return FALSE;
} }
BOOL WINAPI PathFindOnPathAW(LPVOID sFile, LPCVOID sOtherDirs) BOOL WINAPI PathFindOnPathAW(LPVOID sFile, LPCVOID sOtherDirs)
@ -700,12 +700,12 @@ BOOL WINAPI PathFindOnPathAW(LPVOID sFile, LPCVOID sOtherDirs)
* exported by ordinal * exported by ordinal
*/ */
LPCSTR WINAPI PathGetExtensionA(LPCSTR path,DWORD y,DWORD z) LPCSTR WINAPI PathGetExtensionA(LPCSTR path,DWORD y,DWORD z)
{ TRACE(shell,"(%s,%08lx,%08lx)\n",path,y,z); { TRACE("(%s,%08lx,%08lx)\n",path,y,z);
path = PathFindExtensionA(path); path = PathFindExtensionA(path);
return *path?(path+1):path; return *path?(path+1):path;
} }
LPCWSTR WINAPI PathGetExtensionW(LPCWSTR path,DWORD y,DWORD z) LPCWSTR WINAPI PathGetExtensionW(LPCWSTR path,DWORD y,DWORD z)
{ TRACE(shell,"(L%s,%08lx,%08lx)\n",debugstr_w(path),y,z); { TRACE("(L%s,%08lx,%08lx)\n",debugstr_w(path),y,z);
path = PathFindExtensionW(path); path = PathFindExtensionW(path);
return *path?(path+1):path; return *path?(path+1):path;
} }
@ -720,7 +720,7 @@ LPCVOID WINAPI PathGetExtensionAW(LPCVOID path,DWORD y,DWORD z)
* *
*/ */
HRESULT WINAPI SheGetDirW(LPWSTR u, LPWSTR v) HRESULT WINAPI SheGetDirW(LPWSTR u, LPWSTR v)
{ FIXME(shell,"%p %p stub\n",u,v); { FIXME("%p %p stub\n",u,v);
return 0; return 0;
} }
@ -729,7 +729,7 @@ HRESULT WINAPI SheGetDirW(LPWSTR u, LPWSTR v)
* *
*/ */
HRESULT WINAPI SheChangeDirW(LPWSTR u) HRESULT WINAPI SheChangeDirW(LPWSTR u)
{ FIXME(shell,"(%s),stub\n",debugstr_w(u)); { FIXME("(%s),stub\n",debugstr_w(u));
return 0; return 0;
} }
@ -737,7 +737,7 @@ HRESULT WINAPI SheChangeDirW(LPWSTR u)
* PathProcessCommand [SHELL32.653] * PathProcessCommand [SHELL32.653]
*/ */
HRESULT WINAPI PathProcessCommand (DWORD u, DWORD v, DWORD w, DWORD x) HRESULT WINAPI PathProcessCommand (DWORD u, DWORD v, DWORD w, DWORD x)
{ FIXME(shell,"0x%04lx 0x%04lx 0x%04lx 0x%04lx stub\n",u,v,w,x); { FIXME("0x%04lx 0x%04lx 0x%04lx 0x%04lx stub\n",u,v,w,x);
return 0; return 0;
} }
@ -750,7 +750,7 @@ HRESULT WINAPI PathProcessCommand (DWORD u, DWORD v, DWORD w, DWORD x)
BOOL WINAPI SHGetSpecialFolderPathA (DWORD x1,LPSTR szPath,DWORD csidl,DWORD x4) BOOL WINAPI SHGetSpecialFolderPathA (DWORD x1,LPSTR szPath,DWORD csidl,DWORD x4)
{ LPITEMIDLIST pidl; { LPITEMIDLIST pidl;
WARN(shell,"(0x%04lx,%p,csidl=%lu,0x%04lx) semi-stub\n", x1,szPath,csidl,x4); WARN("(0x%04lx,%p,csidl=%lu,0x%04lx) semi-stub\n", x1,szPath,csidl,x4);
SHGetSpecialFolderLocation(0, csidl, &pidl); SHGetSpecialFolderLocation(0, csidl, &pidl);
SHGetPathFromIDListA (pidl, szPath); SHGetPathFromIDListA (pidl, szPath);
@ -760,7 +760,7 @@ BOOL WINAPI SHGetSpecialFolderPathA (DWORD x1,LPSTR szPath,DWORD csidl,DWORD x4)
BOOL WINAPI SHGetSpecialFolderPathW (DWORD x1,LPWSTR szPath, DWORD csidl,DWORD x4) BOOL WINAPI SHGetSpecialFolderPathW (DWORD x1,LPWSTR szPath, DWORD csidl,DWORD x4)
{ LPITEMIDLIST pidl; { LPITEMIDLIST pidl;
WARN(shell,"(0x%04lx,%p,csidl=%lu,0x%04lx) semi-stub\n", x1,szPath,csidl,x4); WARN("(0x%04lx,%p,csidl=%lu,0x%04lx) semi-stub\n", x1,szPath,csidl,x4);
SHGetSpecialFolderLocation(0, csidl, &pidl); SHGetSpecialFolderLocation(0, csidl, &pidl);
SHGetPathFromIDListW (pidl, szPath); SHGetPathFromIDListW (pidl, szPath);

View file

@ -9,7 +9,7 @@
#include <stdlib.h> #include <stdlib.h>
#include <string.h> #include <string.h>
#include "debug.h" #include "debugtools.h"
#include "winerror.h" #include "winerror.h"
#include "oleidl.h" #include "oleidl.h"
@ -63,7 +63,7 @@ static HRESULT WINAPI ISFDropTarget_QueryInterface(
char xriid[50]; char xriid[50];
WINE_StringFromCLSID((LPCLSID)riid,xriid); WINE_StringFromCLSID((LPCLSID)riid,xriid);
TRACE(shell,"(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj); TRACE("(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj);
if ( !This || !ppvObj) if ( !This || !ppvObj)
return E_INVALIDARG; return E_INVALIDARG;
@ -79,11 +79,11 @@ static HRESULT WINAPI ISFDropTarget_QueryInterface(
if(*ppvObj) if(*ppvObj)
{ IDropTarget_AddRef((IDropTarget*)*ppvObj); { IDropTarget_AddRef((IDropTarget*)*ppvObj);
TRACE(shell,"-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj); TRACE("-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj);
return S_OK; return S_OK;
} }
TRACE(shell,"-- Interface: E_NOINTERFACE\n"); TRACE("-- Interface: E_NOINTERFACE\n");
return E_NOINTERFACE; return E_NOINTERFACE;
} }
@ -92,7 +92,7 @@ static ULONG WINAPI ISFDropTarget_AddRef( IDropTarget *iface)
{ {
ICOM_THIS(ISFDropTarget,iface); ICOM_THIS(ISFDropTarget,iface);
TRACE(shell,"(%p)->(count=%lu)\n",This,This->ref); TRACE("(%p)->(count=%lu)\n",This,This->ref);
shell32_ObjCount++; shell32_ObjCount++;
@ -106,7 +106,7 @@ static ULONG WINAPI ISFDropTarget_Release( IDropTarget *iface)
shell32_ObjCount--; shell32_ObjCount--;
if (!--(This->ref)) if (!--(This->ref))
{ TRACE(shell,"-- destroying ISFDropTarget (%p)\n",This); { TRACE("-- destroying ISFDropTarget (%p)\n",This);
HeapFree(GetProcessHeap(),0,This); HeapFree(GetProcessHeap(),0,This);
return 0; return 0;
} }
@ -123,7 +123,7 @@ static HRESULT WINAPI ISFDropTarget_DragEnter(
ICOM_THIS(ISFDropTarget,iface); ICOM_THIS(ISFDropTarget,iface);
FIXME(shell, "Stub: This=%p, DataObject=%p\n",This,pDataObject); FIXME("Stub: This=%p, DataObject=%p\n",This,pDataObject);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -136,7 +136,7 @@ static HRESULT WINAPI ISFDropTarget_DragOver(
{ {
ICOM_THIS(ISFDropTarget,iface); ICOM_THIS(ISFDropTarget,iface);
FIXME(shell, "Stub: This=%p\n",This); FIXME("Stub: This=%p\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -146,7 +146,7 @@ static HRESULT WINAPI ISFDropTarget_DragLeave(
{ {
ICOM_THIS(ISFDropTarget,iface); ICOM_THIS(ISFDropTarget,iface);
FIXME(shell, "Stub: This=%p\n",This); FIXME("Stub: This=%p\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -160,7 +160,7 @@ static HRESULT WINAPI ISFDropTarget_Drop(
{ {
ICOM_THIS(ISFDropTarget,iface); ICOM_THIS(ISFDropTarget,iface);
FIXME(shell, "Stub: This=%p\n",This); FIXME("Stub: This=%p\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -193,7 +193,7 @@ static struct ICOM_VTABLE(IDropTarget) dtvt =
LPSTR GetNextElement(LPSTR pszNext,LPSTR pszOut,DWORD dwOut) LPSTR GetNextElement(LPSTR pszNext,LPSTR pszOut,DWORD dwOut)
{ LPSTR pszTail = pszNext; { LPSTR pszTail = pszNext;
DWORD dwCopy; DWORD dwCopy;
TRACE(shell,"(%s %p 0x%08lx)\n",debugstr_a(pszNext),pszOut,dwOut); TRACE("(%s %p 0x%08lx)\n",debugstr_a(pszNext),pszOut,dwOut);
if(!pszNext || !*pszNext) if(!pszNext || !*pszNext)
return NULL; return NULL;
@ -208,7 +208,7 @@ LPSTR GetNextElement(LPSTR pszNext,LPSTR pszOut,DWORD dwOut)
{ pszTail++; { pszTail++;
} }
TRACE(shell,"--(%s %s 0x%08lx)\n",debugstr_a(pszNext),debugstr_a(pszOut),dwOut); TRACE("--(%s %s 0x%08lx)\n",debugstr_a(pszNext),debugstr_a(pszOut),dwOut);
return pszTail; return pszTail;
} }
@ -240,7 +240,7 @@ IShellFolder * IShellFolder_Constructor(
sf->sMyPath=NULL; /* path of the folder */ sf->sMyPath=NULL; /* path of the folder */
sf->pMyPidl=NULL; /* my qualified pidl */ sf->pMyPidl=NULL; /* my qualified pidl */
TRACE(shell,"(%p)->(parent=%p, pidl=%p)\n",sf,pParent, pidl); TRACE("(%p)->(parent=%p, pidl=%p)\n",sf,pParent, pidl);
pdump(pidl); pdump(pidl);
/* keep a copy of the pidl in the instance*/ /* keep a copy of the pidl in the instance*/
@ -250,7 +250,7 @@ IShellFolder * IShellFolder_Constructor(
{ dwSize = 0; { dwSize = 0;
if(pParent->sMyPath) /* get the size of the parents path */ if(pParent->sMyPath) /* get the size of the parents path */
{ dwSize += strlen(pParent->sMyPath) ; { dwSize += strlen(pParent->sMyPath) ;
TRACE(shell,"-- (%p)->(parent's path=%s)\n",sf, debugstr_a(pParent->sMyPath)); TRACE("-- (%p)->(parent's path=%s)\n",sf, debugstr_a(pParent->sMyPath));
} }
dwSize += _ILGetFolderText(sf->mpidl,NULL,0); /* add the size of the foldername*/ dwSize += _ILGetFolderText(sf->mpidl,NULL,0); /* add the size of the foldername*/
sf->sMyPath = SHAlloc(dwSize+2); /* '\0' and backslash */ sf->sMyPath = SHAlloc(dwSize+2); /* '\0' and backslash */
@ -264,7 +264,7 @@ IShellFolder * IShellFolder_Constructor(
sf->pMyPidl = ILCombine(pParent->pMyPidl, pidl); sf->pMyPidl = ILCombine(pParent->pMyPidl, pidl);
len = strlen(sf->sMyPath); len = strlen(sf->sMyPath);
_ILGetFolderText(sf->mpidl, sf->sMyPath+len, dwSize-len); _ILGetFolderText(sf->mpidl, sf->sMyPath+len, dwSize-len);
TRACE(shell,"-- (%p)->(my pidl=%p, my path=%s)\n",sf, sf->pMyPidl,debugstr_a(sf->sMyPath)); TRACE("-- (%p)->(my pidl=%p, my path=%s)\n",sf, sf->pMyPidl,debugstr_a(sf->sMyPath));
pdump (sf->pMyPidl); pdump (sf->pMyPidl);
} }
} }
@ -287,7 +287,7 @@ static HRESULT WINAPI IShellFolder_fnQueryInterface(
char xriid[50]; char xriid[50];
WINE_StringFromCLSID((LPCLSID)riid,xriid); WINE_StringFromCLSID((LPCLSID)riid,xriid);
TRACE(shell,"(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj); TRACE("(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj);
*ppvObj = NULL; *ppvObj = NULL;
@ -303,10 +303,10 @@ static HRESULT WINAPI IShellFolder_fnQueryInterface(
if(*ppvObj) if(*ppvObj)
{ IShellFolder_AddRef((IShellFolder*)*ppvObj); { IShellFolder_AddRef((IShellFolder*)*ppvObj);
TRACE(shell,"-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj); TRACE("-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj);
return S_OK; return S_OK;
} }
TRACE(shell,"-- Interface: E_NOINTERFACE\n"); TRACE("-- Interface: E_NOINTERFACE\n");
return E_NOINTERFACE; return E_NOINTERFACE;
} }
@ -318,7 +318,7 @@ static ULONG WINAPI IShellFolder_fnAddRef(IShellFolder * iface)
{ {
ICOM_THIS(IGenericSFImpl, iface); ICOM_THIS(IGenericSFImpl, iface);
TRACE(shell,"(%p)->(count=%lu)\n",This,This->ref); TRACE("(%p)->(count=%lu)\n",This,This->ref);
shell32_ObjCount++; shell32_ObjCount++;
return ++(This->ref); return ++(This->ref);
@ -331,15 +331,15 @@ static ULONG WINAPI IShellFolder_fnRelease(IShellFolder * iface)
{ {
ICOM_THIS(IGenericSFImpl, iface); ICOM_THIS(IGenericSFImpl, iface);
TRACE(shell,"(%p)->(count=%lu)\n",This,This->ref); TRACE("(%p)->(count=%lu)\n",This,This->ref);
shell32_ObjCount--; shell32_ObjCount--;
if (!--(This->ref)) if (!--(This->ref))
{ TRACE(shell,"-- destroying IShellFolder(%p)\n",This); { TRACE("-- destroying IShellFolder(%p)\n",This);
if (pdesktopfolder == iface) if (pdesktopfolder == iface)
{ pdesktopfolder=NULL; { pdesktopfolder=NULL;
TRACE(shell,"-- destroyed IShellFolder(%p) was Desktopfolder\n",This); TRACE("-- destroyed IShellFolder(%p) was Desktopfolder\n",This);
} }
if(This->pMyPidl) if(This->pMyPidl)
{ SHFree(This->pMyPidl); { SHFree(This->pMyPidl);
@ -387,7 +387,7 @@ static HRESULT WINAPI IShellFolder_fnParseDisplayName(
CHAR szTemp[MAX_PATH],szElement[MAX_PATH]; CHAR szTemp[MAX_PATH],szElement[MAX_PATH];
BOOL bIsFile; BOOL bIsFile;
TRACE(shell,"(%p)->(HWND=0x%08x,%p,%p=%s,%p,pidl=%p,%p)\n", TRACE("(%p)->(HWND=0x%08x,%p,%p=%s,%p,pidl=%p,%p)\n",
This,hwndOwner,pbcReserved,lpszDisplayName, This,hwndOwner,pbcReserved,lpszDisplayName,
debugstr_w(lpszDisplayName),pchEaten,ppidl,pdwAttributes); debugstr_w(lpszDisplayName),pchEaten,ppidl,pdwAttributes);
@ -458,11 +458,11 @@ static HRESULT WINAPI IShellFolder_fnEnumObjects(
{ {
ICOM_THIS(IGenericSFImpl, iface); ICOM_THIS(IGenericSFImpl, iface);
TRACE(shell,"(%p)->(HWND=0x%08x flags=0x%08lx pplist=%p)\n",This,hwndOwner,dwFlags,ppEnumIDList); TRACE("(%p)->(HWND=0x%08x flags=0x%08lx pplist=%p)\n",This,hwndOwner,dwFlags,ppEnumIDList);
*ppEnumIDList = NULL; *ppEnumIDList = NULL;
*ppEnumIDList = IEnumIDList_Constructor (This->sMyPath, dwFlags); *ppEnumIDList = IEnumIDList_Constructor (This->sMyPath, dwFlags);
TRACE(shell,"-- (%p)->(new ID List: %p)\n",This,*ppEnumIDList); TRACE("-- (%p)->(new ID List: %p)\n",This,*ppEnumIDList);
if(!*ppEnumIDList) if(!*ppEnumIDList)
{ return E_OUTOFMEMORY; { return E_OUTOFMEMORY;
} }
@ -488,7 +488,7 @@ static HRESULT WINAPI IShellFolder_fnBindToObject( IShellFolder * iface, LPCITEM
WINE_StringFromCLSID(riid,xriid); WINE_StringFromCLSID(riid,xriid);
TRACE(shell,"(%p)->(pidl=%p,%p,\n\tIID:%s,%p)\n",This,pidl,pbcReserved,xriid,ppvOut); TRACE("(%p)->(pidl=%p,%p,\n\tIID:%s,%p)\n",This,pidl,pbcReserved,xriid,ppvOut);
*ppvOut = NULL; *ppvOut = NULL;
@ -499,7 +499,7 @@ static HRESULT WINAPI IShellFolder_fnBindToObject( IShellFolder * iface, LPCITEM
hr = pShellFolder->lpvtbl->fnQueryInterface(pShellFolder, riid, ppvOut); hr = pShellFolder->lpvtbl->fnQueryInterface(pShellFolder, riid, ppvOut);
pShellFolder->lpvtbl->fnRelease(pShellFolder); pShellFolder->lpvtbl->fnRelease(pShellFolder);
TRACE(shell,"-- (%p)->(interface=%p)\n",This, ppvOut); TRACE("-- (%p)->(interface=%p)\n",This, ppvOut);
return hr; return hr;
} }
@ -523,7 +523,7 @@ static HRESULT WINAPI IShellFolder_fnBindToStorage(
char xriid[50]; char xriid[50];
WINE_StringFromCLSID(riid,xriid); WINE_StringFromCLSID(riid,xriid);
FIXME(shell,"(%p)->(pidl=%p,%p,\n\tIID:%s,%p) stub\n",This,pidl,pbcReserved,xriid,ppvOut); FIXME("(%p)->(pidl=%p,%p,\n\tIID:%s,%p) stub\n",This,pidl,pbcReserved,xriid,ppvOut);
*ppvOut = NULL; *ppvOut = NULL;
return E_NOTIMPL; return E_NOTIMPL;
@ -557,7 +557,7 @@ static HRESULT WINAPI IShellFolder_fnCompareIDs(
int nReturn; int nReturn;
LPCITEMIDLIST pidlTemp1 = pidl1, pidlTemp2 = pidl2; LPCITEMIDLIST pidlTemp1 = pidl1, pidlTemp2 = pidl2;
TRACE(shell,"(%p)->(0x%08lx,pidl1=%p,pidl2=%p)\n",This,lParam,pidl1,pidl2); TRACE("(%p)->(0x%08lx,pidl1=%p,pidl2=%p)\n",This,lParam,pidl1,pidl2);
pdump (pidl1); pdump (pidl1);
pdump (pidl2); pdump (pidl2);
@ -621,7 +621,7 @@ static HRESULT WINAPI IShellFolder_fnCreateViewObject( IShellFolder * iface,
HRESULT hr; HRESULT hr;
WINE_StringFromCLSID(riid,xriid); WINE_StringFromCLSID(riid,xriid);
TRACE(shell,"(%p)->(hwnd=0x%x,\n\tIID:\t%s,%p)\n",This,hwndOwner,xriid,ppvOut); TRACE("(%p)->(hwnd=0x%x,\n\tIID:\t%s,%p)\n",This,hwndOwner,xriid,ppvOut);
*ppvOut = NULL; *ppvOut = NULL;
@ -632,7 +632,7 @@ static HRESULT WINAPI IShellFolder_fnCreateViewObject( IShellFolder * iface,
hr = pShellView->lpvtbl->fnQueryInterface(pShellView, riid, ppvOut); hr = pShellView->lpvtbl->fnQueryInterface(pShellView, riid, ppvOut);
pShellView->lpvtbl->fnRelease(pShellView); pShellView->lpvtbl->fnRelease(pShellView);
TRACE(shell,"-- (%p)->(interface=%p)\n",This, ppvOut); TRACE("-- (%p)->(interface=%p)\n",This, ppvOut);
return hr; return hr;
} }
@ -658,7 +658,7 @@ static HRESULT WINAPI IShellFolder_fnGetAttributesOf(IShellFolder * iface,UINT c
LPCITEMIDLIST * pidltemp; LPCITEMIDLIST * pidltemp;
DWORD i; DWORD i;
TRACE(shell,"(%p)->(%d,%p,%p)\n",This,cidl,apidl,rgfInOut); TRACE("(%p)->(%d,%p,%p)\n",This,cidl,apidl,rgfInOut);
if ( (!cidl) || (!apidl) || (!rgfInOut)) if ( (!cidl) || (!apidl) || (!rgfInOut))
return E_INVALIDARG; return E_INVALIDARG;
@ -667,7 +667,7 @@ static HRESULT WINAPI IShellFolder_fnGetAttributesOf(IShellFolder * iface,UINT c
*rgfInOut = 0x00; *rgfInOut = 0x00;
i=cidl; i=cidl;
TRACE(shell,"-- mask=0x%08lx\n",*rgfInOut); TRACE("-- mask=0x%08lx\n",*rgfInOut);
do do
{ if (*pidltemp) { if (*pidltemp)
@ -734,7 +734,7 @@ static HRESULT WINAPI IShellFolder_fnGetUIObjectOf(
WINE_StringFromCLSID(riid,xclsid); WINE_StringFromCLSID(riid,xclsid);
TRACE(shell,"(%p)->(%u,%u,apidl=%p,\n\tIID:%s,%p,%p)\n", TRACE("(%p)->(%u,%u,apidl=%p,\n\tIID:%s,%p,%p)\n",
This,hwndOwner,cidl,apidl,xclsid,prgfInOut,ppvOut); This,hwndOwner,cidl,apidl,xclsid,prgfInOut,ppvOut);
*ppvOut = NULL; *ppvOut = NULL;
@ -771,7 +771,7 @@ static HRESULT WINAPI IShellFolder_fnGetUIObjectOf(
} }
else else
{ {
ERR(shell,"(%p)->E_NOINTERFACE\n",This); ERR("(%p)->E_NOINTERFACE\n",This);
return E_NOINTERFACE; return E_NOINTERFACE;
} }
@ -812,7 +812,7 @@ static HRESULT WINAPI IShellFolder_fnGetDisplayNameOf(
LPITEMIDLIST pidlTemp=NULL; LPITEMIDLIST pidlTemp=NULL;
BOOL bSimplePidl=FALSE; BOOL bSimplePidl=FALSE;
TRACE(shell,"(%p)->(pidl=%p,0x%08lx,%p)\n",This,pidl,dwFlags,lpName); TRACE("(%p)->(pidl=%p,0x%08lx,%p)\n",This,pidl,dwFlags,lpName);
pdump(pidl); pdump(pidl);
szSpecial[0]=0x00; szSpecial[0]=0x00;
@ -824,7 +824,7 @@ static HRESULT WINAPI IShellFolder_fnGetDisplayNameOf(
pidlTemp = ILGetNext(pidl); pidlTemp = ILGetNext(pidl);
if (pidlTemp && pidlTemp->mkid.cb==0x00) if (pidlTemp && pidlTemp->mkid.cb==0x00)
{ bSimplePidl = TRUE; { bSimplePidl = TRUE;
TRACE(shell,"-- simple pidl\n"); TRACE("-- simple pidl\n");
} }
if (_ILIsDesktop( pidl)) if (_ILIsDesktop( pidl))
@ -888,7 +888,7 @@ static HRESULT WINAPI IShellFolder_fnGetDisplayNameOf(
} }
break; break;
default: default:
TRACE(shell,"--- wrong flags=%lx\n", dwFlags); TRACE("--- wrong flags=%lx\n", dwFlags);
return E_INVALIDARG; return E_INVALIDARG;
} }
if ((szText[0]==0x00 && szDrive[0]!=0x00)|| (bSimplePidl && szDrive[0]!=0x00)) if ((szText[0]==0x00 && szDrive[0]!=0x00)|| (bSimplePidl && szDrive[0]!=0x00))
@ -899,7 +899,7 @@ static HRESULT WINAPI IShellFolder_fnGetDisplayNameOf(
} }
} }
TRACE(shell,"-- (%p)->(%s)\n",This,szText); TRACE("-- (%p)->(%s)\n",This,szText);
if(!(lpName)) if(!(lpName))
{ return E_OUTOFMEMORY; { return E_OUTOFMEMORY;
@ -931,7 +931,7 @@ static HRESULT WINAPI IShellFolder_fnSetNameOf(
{ {
ICOM_THIS(IGenericSFImpl, iface); ICOM_THIS(IGenericSFImpl, iface);
FIXME(shell,"(%p)->(%u,pidl=%p,%s,%lu,%p),stub!\n", FIXME("(%p)->(%u,pidl=%p,%s,%lu,%p),stub!\n",
This,hwndOwner,pidl,debugstr_w(lpName),dw,pPidlOut); This,hwndOwner,pidl,debugstr_w(lpName),dw,pPidlOut);
return E_NOTIMPL; return E_NOTIMPL;
@ -946,7 +946,7 @@ static HRESULT WINAPI IShellFolder_fnGetFolderPath(IShellFolder * iface, LPSTR l
ICOM_THIS(IGenericSFImpl, iface); ICOM_THIS(IGenericSFImpl, iface);
DWORD dwSize; DWORD dwSize;
TRACE(shell,"(%p)->(%p %lu)\n",This, lpszOut, dwOutSize); TRACE("(%p)->(%p %lu)\n",This, lpszOut, dwOutSize);
if (!lpszOut) if (!lpszOut)
{ return FALSE; { return FALSE;
} }
@ -961,7 +961,7 @@ static HRESULT WINAPI IShellFolder_fnGetFolderPath(IShellFolder * iface, LPSTR l
return FALSE; return FALSE;
strcpy(lpszOut, This->sMyPath); strcpy(lpszOut, This->sMyPath);
TRACE(shell,"-- (%p)->(return=%s)\n",This, lpszOut); TRACE("-- (%p)->(return=%s)\n",This, lpszOut);
return TRUE; return TRUE;
} }

View file

@ -9,7 +9,7 @@
#include "wine/obj_shellfolder.h" #include "wine/obj_shellfolder.h"
#include "heap.h" #include "heap.h"
#include "debug.h" #include "debugtools.h"
#include "winversion.h" #include "winversion.h"
#include "shell32_main.h" #include "shell32_main.h"
@ -79,7 +79,7 @@ static LPFMINFO FM_SetMenuParameter(
{ {
LPFMINFO menudata; LPFMINFO menudata;
TRACE(shell,"\n"); TRACE("\n");
menudata = FM_GetMenuInfo(hmenu); menudata = FM_GetMenuInfo(hmenu);
@ -111,7 +111,7 @@ static int FM_InitMenuPopup(HMENU hmenu, LPITEMIDLIST pAlternatePidl)
MENUINFO MenuInfo; MENUINFO MenuInfo;
LPFMINFO menudata; LPFMINFO menudata;
TRACE(shell,"\n"); TRACE("\n");
MenuInfo.cbSize = sizeof(MENUINFO); MenuInfo.cbSize = sizeof(MENUINFO);
MenuInfo.fMask = MIM_MENUDATA; MenuInfo.fMask = MIM_MENUDATA;
@ -181,9 +181,9 @@ static int FM_InitMenuPopup(HMENU hmenu, LPITEMIDLIST pAlternatePidl)
if (lpfnCallback) if (lpfnCallback)
{ {
TRACE(shell,"enter callback\n"); TRACE("enter callback\n");
lpfnCallback ( pidl, pidlTemp); lpfnCallback ( pidl, pidlTemp);
TRACE(shell,"leave callback\n"); TRACE("leave callback\n");
} }
NumberOfItems++; NumberOfItems++;
@ -219,7 +219,7 @@ HMENU WINAPI FileMenu_Create (
HMENU hMenu = CreatePopupMenu(); HMENU hMenu = CreatePopupMenu();
TRACE(shell,"0x%08lx 0x%08x 0x%08x 0x%08x 0x%08x hMenu=0x%08x\n", TRACE("0x%08lx 0x%08x 0x%08x 0x%08x 0x%08x hMenu=0x%08x\n",
crBorderColor, nBorderWidth, hBorderBmp, nSelHeight, uFlags, hMenu); crBorderColor, nBorderWidth, hBorderBmp, nSelHeight, uFlags, hMenu);
menudata = (LPFMINFO)HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(FMINFO)); menudata = (LPFMINFO)HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(FMINFO));
@ -246,7 +246,7 @@ void WINAPI FileMenu_Destroy (HMENU hmenu)
{ {
LPFMINFO menudata; LPFMINFO menudata;
TRACE(shell,"0x%08x\n", hmenu); TRACE("0x%08x\n", hmenu);
FileMenu_DeleteAllItems (hmenu); FileMenu_DeleteAllItems (hmenu);
@ -276,7 +276,7 @@ BOOL WINAPI FileMenu_AppendItemA(
MENUITEMINFOA mii; MENUITEMINFOA mii;
LPFMITEM myItem; LPFMITEM myItem;
TRACE(shell,"0x%08x %s 0x%08x 0x%08x 0x%08x 0x%08x\n", TRACE("0x%08x %s 0x%08x 0x%08x 0x%08x 0x%08x\n",
hMenu, (lpszText!=FM_SEPARATOR) ? lpText: NULL, hMenu, (lpszText!=FM_SEPARATOR) ? lpText: NULL,
uID, icon, hMenuPopup, nItemHeight); uID, icon, hMenuPopup, nItemHeight);
@ -353,7 +353,7 @@ int WINAPI FileMenu_InsertUsingPidl (
UINT uEnumFlags, UINT uEnumFlags,
LPFNFMCALLBACK lpfnCallback) LPFNFMCALLBACK lpfnCallback)
{ {
TRACE(shell,"0x%08x 0x%08x %p 0x%08x 0x%08x %p\n", TRACE("0x%08x 0x%08x %p 0x%08x 0x%08x %p\n",
hmenu, uID, pidl, uFlags, uEnumFlags, lpfnCallback); hmenu, uID, pidl, uFlags, uEnumFlags, lpfnCallback);
pdump (pidl); pdump (pidl);
@ -376,7 +376,7 @@ int WINAPI FileMenu_ReplaceUsingPidl(
UINT uEnumFlags, UINT uEnumFlags,
LPFNFMCALLBACK lpfnCallback) LPFNFMCALLBACK lpfnCallback)
{ {
TRACE(shell,"0x%08x 0x%08x %p 0x%08x %p\n", TRACE("0x%08x 0x%08x %p 0x%08x %p\n",
hmenu, uID, pidl, uEnumFlags, lpfnCallback); hmenu, uID, pidl, uEnumFlags, lpfnCallback);
FileMenu_DeleteAllItems (hmenu); FileMenu_DeleteAllItems (hmenu);
@ -391,7 +391,7 @@ int WINAPI FileMenu_ReplaceUsingPidl(
*/ */
void WINAPI FileMenu_Invalidate (HMENU hMenu) void WINAPI FileMenu_Invalidate (HMENU hMenu)
{ {
FIXME(shell,"0x%08x\n",hMenu); FIXME("0x%08x\n",hMenu);
} }
/************************************************************************* /*************************************************************************
@ -401,7 +401,7 @@ HMENU WINAPI FileMenu_FindSubMenuByPidl(
HMENU hMenu, HMENU hMenu,
LPCITEMIDLIST pidl) LPCITEMIDLIST pidl)
{ {
FIXME(shell,"0x%08x %p\n",hMenu, pidl); FIXME("0x%08x %p\n",hMenu, pidl);
return 0; return 0;
} }
@ -424,7 +424,7 @@ HMENU WINAPI FileMenu_AppendFilesForPidl(
if (bAddSeperator) if (bAddSeperator)
FileMenu_AppendItemA (hmenu, FM_SEPARATOR, 0, 0, 0, FM_DEFAULT_HEIGHT); FileMenu_AppendItemA (hmenu, FM_SEPARATOR, 0, 0, 0, FM_DEFAULT_HEIGHT);
TRACE (shell,"0x%08x %p 0x%08x\n",hmenu, pidl,bAddSeperator); TRACE("0x%08x %p 0x%08x\n",hmenu, pidl,bAddSeperator);
return 0; return 0;
} }
@ -443,7 +443,7 @@ int WINAPI FileMenu_AddFilesForPidl (
UINT uEnumFlags, UINT uEnumFlags,
LPFNFMCALLBACK lpfnCallback) LPFNFMCALLBACK lpfnCallback)
{ {
TRACE(shell,"0x%08x 0x%08x 0x%08x %p 0x%08x 0x%08x %p\n", TRACE("0x%08x 0x%08x 0x%08x %p 0x%08x 0x%08x %p\n",
hmenu, uReserved, uID, pidl, uFlags, uEnumFlags, lpfnCallback); hmenu, uReserved, uID, pidl, uFlags, uEnumFlags, lpfnCallback);
return FileMenu_InsertUsingPidl ( hmenu, uID, pidl, uFlags, uEnumFlags, lpfnCallback); return FileMenu_InsertUsingPidl ( hmenu, uID, pidl, uFlags, uEnumFlags, lpfnCallback);
@ -462,7 +462,7 @@ HRESULT WINAPI FileMenu_TrackPopupMenuEx (
HWND hWnd, HWND hWnd,
LPTPMPARAMS lptpm) LPTPMPARAMS lptpm)
{ {
TRACE(shell,"0x%08x 0x%08x 0x%x 0x%x 0x%08x %p\n", TRACE("0x%08x 0x%08x 0x%x 0x%x 0x%08x %p\n",
hMenu, uFlags, x, y, hWnd, lptpm); hMenu, uFlags, x, y, hWnd, lptpm);
return TrackPopupMenuEx(hMenu, uFlags, x, y, hWnd, lptpm); return TrackPopupMenuEx(hMenu, uFlags, x, y, hWnd, lptpm);
} }
@ -475,7 +475,7 @@ BOOL WINAPI FileMenu_GetLastSelectedItemPidls(
LPCITEMIDLIST *ppidlFolder, LPCITEMIDLIST *ppidlFolder,
LPCITEMIDLIST *ppidlItem) LPCITEMIDLIST *ppidlItem)
{ {
FIXME(shell,"0x%08x %p %p\n",uReserved, ppidlFolder, ppidlItem); FIXME("0x%08x %p %p\n",uReserved, ppidlFolder, ppidlItem);
return 0; return 0;
} }
@ -497,7 +497,7 @@ LRESULT WINAPI FileMenu_MeasureItem(
SIZE size; SIZE size;
LPFMINFO menuinfo; LPFMINFO menuinfo;
TRACE(shell,"0x%08x %p %s\n", hWnd, lpmis, pMyItem->szItemText); TRACE("0x%08x %p %s\n", hWnd, lpmis, pMyItem->szItemText);
GetTextExtentPoint32A(hdc, pMyItem->szItemText, pMyItem->cchItemText, &size); GetTextExtentPoint32A(hdc, pMyItem->szItemText, pMyItem->cchItemText, &size);
@ -509,7 +509,7 @@ LRESULT WINAPI FileMenu_MeasureItem(
if (menuinfo->bIsMagic) if (menuinfo->bIsMagic)
lpmis->itemWidth += menuinfo->nBorderWidth; lpmis->itemWidth += menuinfo->nBorderWidth;
TRACE(shell,"-- 0x%04x 0x%04x\n", lpmis->itemWidth, lpmis->itemHeight); TRACE("-- 0x%04x 0x%04x\n", lpmis->itemWidth, lpmis->itemHeight);
ReleaseDC (hWnd, hdc); ReleaseDC (hWnd, hdc);
return 0; return 0;
} }
@ -527,7 +527,7 @@ LRESULT WINAPI FileMenu_DrawItem(
RECT TextRect, BorderRect; RECT TextRect, BorderRect;
LPFMINFO menuinfo; LPFMINFO menuinfo;
TRACE(shell,"0x%08x %p %s\n", hWnd, lpdis, pMyItem->szItemText); TRACE("0x%08x %p %s\n", hWnd, lpdis, pMyItem->szItemText);
if (lpdis->itemState & ODS_SELECTED) if (lpdis->itemState & ODS_SELECTED)
{ {
@ -563,7 +563,7 @@ LRESULT WINAPI FileMenu_DrawItem(
Shell_GetImageList(0, &hImageList); Shell_GetImageList(0, &hImageList);
pImageList_Draw(hImageList, pMyItem->iIconIndex, lpdis->hDC, xi, yi, ILD_NORMAL); pImageList_Draw(hImageList, pMyItem->iIconIndex, lpdis->hDC, xi, yi, ILD_NORMAL);
TRACE(shell,"-- 0x%04x 0x%04x 0x%04x 0x%04x\n", TextRect.left, TextRect.top, TextRect.right, TextRect.bottom); TRACE("-- 0x%04x 0x%04x 0x%04x 0x%04x\n", TextRect.left, TextRect.top, TextRect.right, TextRect.bottom);
SetTextColor(lpdis->hDC, clrPrevText); SetTextColor(lpdis->hDC, clrPrevText);
SetBkColor(lpdis->hDC, clrPrevBkgnd); SetBkColor(lpdis->hDC, clrPrevBkgnd);
@ -592,7 +592,7 @@ LRESULT WINAPI FileMenu_HandleMenuChar(
HMENU hMenu, HMENU hMenu,
WPARAM wParam) WPARAM wParam)
{ {
FIXME(shell,"0x%08x 0x%08x\n",hMenu,wParam); FIXME("0x%08x 0x%08x\n",hMenu,wParam);
return 0; return 0;
} }
@ -609,7 +609,7 @@ BOOL WINAPI FileMenu_DeleteAllItems (HMENU hmenu)
int i; int i;
TRACE(shell,"0x%08x\n", hmenu); TRACE("0x%08x\n", hmenu);
ZeroMemory ( &mii, sizeof(MENUITEMINFOA)); ZeroMemory ( &mii, sizeof(MENUITEMINFOA));
mii.cbSize = sizeof(MENUITEMINFOA); mii.cbSize = sizeof(MENUITEMINFOA);
@ -642,7 +642,7 @@ BOOL WINAPI FileMenu_DeleteItemByCmd (HMENU hMenu, UINT uID)
{ {
MENUITEMINFOA mii; MENUITEMINFOA mii;
TRACE(shell,"0x%08x 0x%08x\n", hMenu, uID); TRACE("0x%08x 0x%08x\n", hMenu, uID);
ZeroMemory ( &mii, sizeof(MENUITEMINFOA)); ZeroMemory ( &mii, sizeof(MENUITEMINFOA));
mii.cbSize = sizeof(MENUITEMINFOA); mii.cbSize = sizeof(MENUITEMINFOA);
@ -662,7 +662,7 @@ BOOL WINAPI FileMenu_DeleteItemByIndex ( HMENU hMenu, UINT uPos)
{ {
MENUITEMINFOA mii; MENUITEMINFOA mii;
TRACE(shell,"0x%08x 0x%08x\n", hMenu, uPos); TRACE("0x%08x 0x%08x\n", hMenu, uPos);
ZeroMemory ( &mii, sizeof(MENUITEMINFOA)); ZeroMemory ( &mii, sizeof(MENUITEMINFOA));
mii.cbSize = sizeof(MENUITEMINFOA); mii.cbSize = sizeof(MENUITEMINFOA);
@ -682,7 +682,7 @@ BOOL WINAPI FileMenu_DeleteItemByFirstID(
HMENU hMenu, HMENU hMenu,
UINT uID) UINT uID)
{ {
TRACE(shell,"0x%08x 0x%08x\n", hMenu, uID); TRACE("0x%08x 0x%08x\n", hMenu, uID);
return 0; return 0;
} }
@ -691,7 +691,7 @@ BOOL WINAPI FileMenu_DeleteItemByFirstID(
*/ */
BOOL WINAPI FileMenu_DeleteSeparator(HMENU hMenu) BOOL WINAPI FileMenu_DeleteSeparator(HMENU hMenu)
{ {
TRACE(shell,"0x%08x\n", hMenu); TRACE("0x%08x\n", hMenu);
return 0; return 0;
} }
@ -703,7 +703,7 @@ BOOL WINAPI FileMenu_EnableItemByCmd(
UINT uID, UINT uID,
BOOL bEnable) BOOL bEnable)
{ {
TRACE(shell,"0x%08x 0x%08x 0x%08x\n", hMenu, uID,bEnable); TRACE("0x%08x 0x%08x 0x%08x\n", hMenu, uID,bEnable);
return 0; return 0;
} }
@ -716,10 +716,10 @@ BOOL WINAPI FileMenu_EnableItemByCmd(
DWORD WINAPI FileMenu_GetItemExtent (HMENU hMenu, UINT uPos) DWORD WINAPI FileMenu_GetItemExtent (HMENU hMenu, UINT uPos)
{ RECT rect; { RECT rect;
FIXME (shell,"0x%08x 0x%08x\n", hMenu, uPos); FIXME("0x%08x 0x%08x\n", hMenu, uPos);
if (GetMenuItemRect(0, hMenu, uPos, &rect)) if (GetMenuItemRect(0, hMenu, uPos, &rect))
{ FIXME (shell,"0x%04x 0x%04x 0x%04x 0x%04x\n", { FIXME("0x%04x 0x%04x 0x%04x 0x%04x\n",
rect.right, rect.left, rect.top, rect.bottom); rect.right, rect.left, rect.top, rect.bottom);
return ((rect.right-rect.left)<<16) + (rect.top-rect.bottom); return ((rect.right-rect.left)<<16) + (rect.top-rect.bottom);
} }
@ -731,7 +731,7 @@ DWORD WINAPI FileMenu_GetItemExtent (HMENU hMenu, UINT uPos)
* *
*/ */
void WINAPI FileMenu_AbortInitMenu (void) void WINAPI FileMenu_AbortInitMenu (void)
{ TRACE(shell,"\n"); { TRACE("\n");
bAbortInit = TRUE; bAbortInit = TRUE;
} }
@ -746,7 +746,7 @@ void WINAPI FileMenu_AbortInitMenu (void)
* x [in] no pointer * x [in] no pointer
*/ */
HRESULT WINAPI SHFind_InitMenuPopup (HMENU hMenu, HWND hWndParent, DWORD w, DWORD x) HRESULT WINAPI SHFind_InitMenuPopup (HMENU hMenu, HWND hWndParent, DWORD w, DWORD x)
{ FIXME(shell,"hmenu=0x%08x hwnd=0x%08x 0x%08lx 0x%08lx stub\n", { FIXME("hmenu=0x%08x hwnd=0x%08x 0x%08lx 0x%08lx stub\n",
hMenu,hWndParent,w,x); hMenu,hWndParent,w,x);
return TRUE; return TRUE;
} }
@ -782,7 +782,7 @@ HRESULT WINAPI Shell_MergeMenus (HMENU hmDst, HMENU hmSrc, UINT uInsert, UINT uI
char szName[256]; char szName[256];
UINT uTemp, uIDMax = uIDAdjust; UINT uTemp, uIDMax = uIDAdjust;
FIXME(shell,"hmenu1=0x%04x hmenu2=0x%04x 0x%04x 0x%04x 0x%04x 0x%04lx stub\n", FIXME("hmenu1=0x%04x hmenu2=0x%04x 0x%04x 0x%04x 0x%04x 0x%04lx stub\n",
hmDst, hmSrc, uInsert, uIDAdjust, uIDAdjustMax, uFlags); hmDst, hmSrc, uInsert, uIDAdjust, uIDAdjustMax, uFlags);
if (!hmDst || !hmSrc) if (!hmDst || !hmSrc)

View file

@ -22,7 +22,7 @@
#include "shresdef.h" #include "shresdef.h"
#include "spy.h" #include "spy.h"
#include "debug.h" #include "debugtools.h"
#include "winerror.h" #include "winerror.h"
#include "docobj.h" #include "docobj.h"
@ -124,7 +124,7 @@ IShellView * IShellView_Constructor( IShellFolder * pFolder, LPCITEMIDLIST pidl)
if(pFolder) if(pFolder)
IShellFolder_AddRef(pFolder); IShellFolder_AddRef(pFolder);
TRACE(shell,"(%p)->(%p pidl=%p)\n",sv, pFolder, pidl); TRACE("(%p)->(%p pidl=%p)\n",sv, pFolder, pidl);
shell32_ObjCount++; shell32_ObjCount++;
return (IShellView *) sv; return (IShellView *) sv;
} }
@ -138,7 +138,7 @@ static BOOL IsInCommDlg(IShellViewImpl * This)
static HRESULT IncludeObject(IShellViewImpl * This, LPCITEMIDLIST pidl) static HRESULT IncludeObject(IShellViewImpl * This, LPCITEMIDLIST pidl)
{ {
if ( IsInCommDlg(This) ) if ( IsInCommDlg(This) )
{ TRACE(shell,"ICommDlgBrowser::IncludeObject pidl=%p\n", pidl); { TRACE("ICommDlgBrowser::IncludeObject pidl=%p\n", pidl);
return (ICommDlgBrowser_IncludeObject(This->pCommDlgBrowser, (IShellView*)This, pidl)); return (ICommDlgBrowser_IncludeObject(This->pCommDlgBrowser, (IShellView*)This, pidl));
} }
return S_OK; return S_OK;
@ -147,7 +147,7 @@ static HRESULT IncludeObject(IShellViewImpl * This, LPCITEMIDLIST pidl)
static HRESULT OnDefaultCommand(IShellViewImpl * This) static HRESULT OnDefaultCommand(IShellViewImpl * This)
{ {
if (IsInCommDlg(This)) if (IsInCommDlg(This))
{ TRACE(shell,"ICommDlgBrowser::OnDefaultCommand\n"); { TRACE("ICommDlgBrowser::OnDefaultCommand\n");
return (ICommDlgBrowser_OnDefaultCommand(This->pCommDlgBrowser, (IShellView*)This)); return (ICommDlgBrowser_OnDefaultCommand(This->pCommDlgBrowser, (IShellView*)This));
} }
return S_FALSE; return S_FALSE;
@ -156,7 +156,7 @@ static HRESULT OnDefaultCommand(IShellViewImpl * This)
static HRESULT OnStateChange(IShellViewImpl * This, UINT uFlags) static HRESULT OnStateChange(IShellViewImpl * This, UINT uFlags)
{ {
if (IsInCommDlg(This)) if (IsInCommDlg(This))
{ TRACE(shell,"ICommDlgBrowser::OnStateChange flags=%x\n", uFlags); { TRACE("ICommDlgBrowser::OnStateChange flags=%x\n", uFlags);
return (ICommDlgBrowser_OnStateChange(This->pCommDlgBrowser, (IShellView*)This, uFlags)); return (ICommDlgBrowser_OnStateChange(This->pCommDlgBrowser, (IShellView*)This, uFlags));
} }
return S_FALSE; return S_FALSE;
@ -164,7 +164,7 @@ static HRESULT OnStateChange(IShellViewImpl * This, UINT uFlags)
static void SetStyle(IShellViewImpl * This, DWORD dwAdd, DWORD dwRemove) static void SetStyle(IShellViewImpl * This, DWORD dwAdd, DWORD dwRemove)
{ DWORD tmpstyle; { DWORD tmpstyle;
TRACE(shell,"(%p)\n", This); TRACE("(%p)\n", This);
tmpstyle = GetWindowLongA(This->hWndList, GWL_STYLE); tmpstyle = GetWindowLongA(This->hWndList, GWL_STYLE);
SetWindowLongA(This->hWndList, GWL_STYLE, dwAdd | (tmpstyle & ~dwRemove)); SetWindowLongA(This->hWndList, GWL_STYLE, dwAdd | (tmpstyle & ~dwRemove));
@ -173,7 +173,7 @@ static void SetStyle(IShellViewImpl * This, DWORD dwAdd, DWORD dwRemove)
static void CheckToolbar(IShellViewImpl * This) static void CheckToolbar(IShellViewImpl * This)
{ LRESULT result; { LRESULT result;
TRACE(shell,"\n"); TRACE("\n");
IShellBrowser_SendControlMsg(This->pShellBrowser, FCW_TOOLBAR, TB_CHECKBUTTON, IShellBrowser_SendControlMsg(This->pShellBrowser, FCW_TOOLBAR, TB_CHECKBUTTON,
FCIDM_TB_SMALLICON, (This->FolderSettings.ViewMode==FVM_LIST)? TRUE : FALSE, &result); FCIDM_TB_SMALLICON, (This->FolderSettings.ViewMode==FVM_LIST)? TRUE : FALSE, &result);
@ -183,7 +183,7 @@ static void CheckToolbar(IShellViewImpl * This)
FCIDM_TB_SMALLICON, TRUE, &result); FCIDM_TB_SMALLICON, TRUE, &result);
IShellBrowser_SendControlMsg(This->pShellBrowser, FCW_TOOLBAR, TB_ENABLEBUTTON, IShellBrowser_SendControlMsg(This->pShellBrowser, FCW_TOOLBAR, TB_ENABLEBUTTON,
FCIDM_TB_REPORTVIEW, TRUE, &result); FCIDM_TB_REPORTVIEW, TRUE, &result);
TRACE(shell,"--\n"); TRACE("--\n");
} }
static void MergeToolBar(IShellViewImpl * This) static void MergeToolBar(IShellViewImpl * This)
@ -205,20 +205,20 @@ static void MergeToolBar(IShellViewImpl * This)
{ VIEW_DETAILS | IN_VIEW_BMP, FCIDM_SHVIEW_REPORTVIEW, TBSTATE_ENABLED, TBSTYLE_BUTTON, {0,0}, 0L, -1 }, { VIEW_DETAILS | IN_VIEW_BMP, FCIDM_SHVIEW_REPORTVIEW, TBSTATE_ENABLED, TBSTYLE_BUTTON, {0,0}, 0L, -1 },
} ; } ;
TRACE(shell,"\n"); TRACE("\n");
ab.hInst = HINST_COMMCTRL; /* hinstCommctrl */ ab.hInst = HINST_COMMCTRL; /* hinstCommctrl */
ab.nID = IDB_STD_SMALL_COLOR; /* std bitmaps */ ab.nID = IDB_STD_SMALL_COLOR; /* std bitmaps */
IShellBrowser_SendControlMsg(This->pShellBrowser,FCW_TOOLBAR, IShellBrowser_SendControlMsg(This->pShellBrowser,FCW_TOOLBAR,
TB_ADDBITMAP, 8, (LPARAM)&ab, &iStdBMOffset); TB_ADDBITMAP, 8, (LPARAM)&ab, &iStdBMOffset);
TRACE(shell,"TB_ADDBITMAP returns %lx\n", iStdBMOffset); TRACE("TB_ADDBITMAP returns %lx\n", iStdBMOffset);
ab.nID = IDB_VIEW_SMALL_COLOR; /* std view bitmaps */ ab.nID = IDB_VIEW_SMALL_COLOR; /* std view bitmaps */
IShellBrowser_SendControlMsg(This->pShellBrowser,FCW_TOOLBAR, IShellBrowser_SendControlMsg(This->pShellBrowser,FCW_TOOLBAR,
TB_ADDBITMAP, 8, (LPARAM)&ab, &iViewBMOffset); TB_ADDBITMAP, 8, (LPARAM)&ab, &iViewBMOffset);
TRACE(shell,"TB_ADDBITMAP returns %lx\n", iViewBMOffset); TRACE("TB_ADDBITMAP returns %lx\n", iViewBMOffset);
for (i=0; i<6; ++i) for (i=0; i<6; ++i)
{ tbActual[i] = c_tbDefault[i]; { tbActual[i] = c_tbDefault[i];
@ -235,7 +235,7 @@ static void MergeToolBar(IShellViewImpl * This)
IShellBrowser_SetToolbarItems(This->pShellBrowser,tbActual, 6, FCT_MERGE); IShellBrowser_SetToolbarItems(This->pShellBrowser,tbActual, 6, FCT_MERGE);
CheckToolbar(This); CheckToolbar(This);
TRACE(shell,"--\n"); TRACE("--\n");
} }
@ -247,7 +247,7 @@ static void MergeToolBar(IShellViewImpl * This)
BOOL ShellView_CreateList (IShellViewImpl * This) BOOL ShellView_CreateList (IShellViewImpl * This)
{ DWORD dwStyle; { DWORD dwStyle;
TRACE(shell,"%p\n",This); TRACE("%p\n",This);
dwStyle = WS_TABSTOP | WS_VISIBLE | WS_CHILD | WS_BORDER | dwStyle = WS_TABSTOP | WS_VISIBLE | WS_CHILD | WS_BORDER |
LVS_SHAREIMAGELISTS | LVS_EDITLABELS | LVS_ALIGNLEFT; LVS_SHAREIMAGELISTS | LVS_EDITLABELS | LVS_ALIGNLEFT;
@ -293,7 +293,7 @@ BOOL ShellView_InitList(IShellViewImpl * This)
{ LVCOLUMNA lvColumn; { LVCOLUMNA lvColumn;
CHAR szString[50]; CHAR szString[50];
TRACE(shell,"%p\n",This); TRACE("%p\n",This);
ListView_DeleteAllItems(This->hWndList); ListView_DeleteAllItems(This->hWndList);
@ -332,13 +332,13 @@ BOOL ShellView_InitList(IShellViewImpl * This)
*/ */
INT CALLBACK ShellView_CompareItems(LPVOID lParam1, LPVOID lParam2, LPARAM lpData) INT CALLBACK ShellView_CompareItems(LPVOID lParam1, LPVOID lParam2, LPARAM lpData)
{ int ret; { int ret;
TRACE(shell,"pidl1=%p pidl2=%p lpsf=%p\n", lParam1, lParam2, (LPVOID) lpData); TRACE("pidl1=%p pidl2=%p lpsf=%p\n", lParam1, lParam2, (LPVOID) lpData);
if(!lpData) if(!lpData)
return 0; return 0;
ret = (int)((LPSHELLFOLDER)lpData)->lpvtbl->fnCompareIDs((LPSHELLFOLDER)lpData, 0, (LPITEMIDLIST)lParam1, (LPITEMIDLIST)lParam2); ret = (int)((LPSHELLFOLDER)lpData)->lpvtbl->fnCompareIDs((LPSHELLFOLDER)lpData, 0, (LPITEMIDLIST)lParam1, (LPITEMIDLIST)lParam2);
TRACE(shell,"ret=%i\n",ret); TRACE("ret=%i\n",ret);
return ret; return ret;
} }
@ -358,7 +358,7 @@ static HRESULT ShellView_FillList(IShellViewImpl * This)
HRESULT hRes; HRESULT hRes;
HDPA hdpa; HDPA hdpa;
TRACE(shell,"%p\n",This); TRACE("%p\n",This);
/* get the itemlist from the shfolder*/ /* get the itemlist from the shfolder*/
hRes = IShellFolder_EnumObjects(This->pSFParent,This->hWnd, SHCONTF_NONFOLDERS | SHCONTF_FOLDERS, &pEnumIDList); hRes = IShellFolder_EnumObjects(This->pSFParent,This->hWnd, SHCONTF_NONFOLDERS | SHCONTF_FOLDERS, &pEnumIDList);
@ -420,7 +420,7 @@ static HRESULT ShellView_FillList(IShellViewImpl * This)
* internal * internal
*/ */
LRESULT ShellView_OnCreate(IShellViewImpl * This) LRESULT ShellView_OnCreate(IShellViewImpl * This)
{ TRACE(shell,"%p\n",This); { TRACE("%p\n",This);
if(ShellView_CreateList(This)) if(ShellView_CreateList(This))
{ if(ShellView_InitList(This)) { if(ShellView_InitList(This))
@ -434,7 +434,7 @@ LRESULT ShellView_OnCreate(IShellViewImpl * This)
* ShellView_OnSize() * ShellView_OnSize()
*/ */
LRESULT ShellView_OnSize(IShellViewImpl * This, WORD wWidth, WORD wHeight) LRESULT ShellView_OnSize(IShellViewImpl * This, WORD wWidth, WORD wHeight)
{ TRACE(shell,"%p width=%u height=%u\n",This, wWidth,wHeight); { TRACE("%p width=%u height=%u\n",This, wWidth,wHeight);
/*resize the ListView to fit our window*/ /*resize the ListView to fit our window*/
if(This->hWndList) if(This->hWndList)
@ -452,7 +452,7 @@ HMENU ShellView_BuildFileMenu(IShellViewImpl * This)
int nTools,i; int nTools,i;
HMENU hSubMenu; HMENU hSubMenu;
TRACE(shell,"(%p) semi-stub\n",This); TRACE("(%p) semi-stub\n",This);
hSubMenu = CreatePopupMenu(); hSubMenu = CreatePopupMenu();
if(hSubMenu) if(hSubMenu)
@ -480,14 +480,14 @@ HMENU ShellView_BuildFileMenu(IShellViewImpl * This)
InsertMenuItemA(hSubMenu, (UINT)-1, TRUE, &mii); InsertMenuItemA(hSubMenu, (UINT)-1, TRUE, &mii);
} }
} }
TRACE(shell,"-- return (menu=0x%x)\n",hSubMenu); TRACE("-- return (menu=0x%x)\n",hSubMenu);
return hSubMenu; return hSubMenu;
} }
/************************************************************************** /**************************************************************************
* ShellView_MergeFileMenu() * ShellView_MergeFileMenu()
*/ */
void ShellView_MergeFileMenu(IShellViewImpl * This, HMENU hSubMenu) void ShellView_MergeFileMenu(IShellViewImpl * This, HMENU hSubMenu)
{ TRACE(shell,"(%p)->(submenu=0x%08x) stub\n",This,hSubMenu); { TRACE("(%p)->(submenu=0x%08x) stub\n",This,hSubMenu);
if(hSubMenu) if(hSubMenu)
{ /*insert This item at the beginning of the menu */ { /*insert This item at the beginning of the menu */
@ -495,7 +495,7 @@ void ShellView_MergeFileMenu(IShellViewImpl * This, HMENU hSubMenu)
_InsertMenuItem(hSubMenu, 0, TRUE, IDM_MYFILEITEM, MFT_STRING, "dummy45", MFS_ENABLED); _InsertMenuItem(hSubMenu, 0, TRUE, IDM_MYFILEITEM, MFT_STRING, "dummy45", MFS_ENABLED);
} }
TRACE(shell,"--\n"); TRACE("--\n");
} }
/************************************************************************** /**************************************************************************
@ -505,7 +505,7 @@ void ShellView_MergeFileMenu(IShellViewImpl * This, HMENU hSubMenu)
void ShellView_MergeViewMenu(IShellViewImpl * This, HMENU hSubMenu) void ShellView_MergeViewMenu(IShellViewImpl * This, HMENU hSubMenu)
{ MENUITEMINFOA mii; { MENUITEMINFOA mii;
TRACE(shell,"(%p)->(submenu=0x%08x)\n",This,hSubMenu); TRACE("(%p)->(submenu=0x%08x)\n",This,hSubMenu);
if(hSubMenu) if(hSubMenu)
{ /*add a separator at the correct position in the menu*/ { /*add a separator at the correct position in the menu*/
@ -530,7 +530,7 @@ BOOL ShellView_CanDoIDockingWindow(IShellViewImpl * This)
LPSERVICEPROVIDER pSP; LPSERVICEPROVIDER pSP;
LPDOCKINGWINDOWFRAME pFrame; LPDOCKINGWINDOWFRAME pFrame;
FIXME(shell,"(%p) stub\n",This); FIXME("(%p) stub\n",This);
/*get the browser's IServiceProvider*/ /*get the browser's IServiceProvider*/
hr = IShellBrowser_QueryInterface(This->pShellBrowser, (REFIID)&IID_IServiceProvider, (LPVOID*)&pSP); hr = IShellBrowser_QueryInterface(This->pShellBrowser, (REFIID)&IID_IServiceProvider, (LPVOID*)&pSP);
@ -549,7 +549,7 @@ BOOL ShellView_CanDoIDockingWindow(IShellViewImpl * This)
* ShellView_UpdateMenu() * ShellView_UpdateMenu()
*/ */
LRESULT ShellView_UpdateMenu(IShellViewImpl * This, HMENU hMenu) LRESULT ShellView_UpdateMenu(IShellViewImpl * This, HMENU hMenu)
{ TRACE(shell,"(%p)->(menu=0x%08x)\n",This,hMenu); { TRACE("(%p)->(menu=0x%08x)\n",This,hMenu);
CheckMenuItem(hMenu, IDM_VIEW_FILES, MF_BYCOMMAND | (g_bViewKeys ? MF_CHECKED: MF_UNCHECKED)); CheckMenuItem(hMenu, IDM_VIEW_FILES, MF_BYCOMMAND | (g_bViewKeys ? MF_CHECKED: MF_UNCHECKED));
if(ShellView_CanDoIDockingWindow(This)) if(ShellView_CanDoIDockingWindow(This))
@ -570,7 +570,7 @@ LRESULT ShellView_UpdateMenu(IShellViewImpl * This, HMENU hMenu)
* internal * internal
*/ */
void ShellView_OnDeactivate(IShellViewImpl * This) void ShellView_OnDeactivate(IShellViewImpl * This)
{ TRACE(shell,"%p\n",This); { TRACE("%p\n",This);
if(This->uState != SVUIA_DEACTIVATE) if(This->uState != SVUIA_DEACTIVATE)
{ if(This->hMenu) { if(This->hMenu)
{ IShellBrowser_SetMenuSB(This->pShellBrowser,0, 0, 0); { IShellBrowser_SetMenuSB(This->pShellBrowser,0, 0, 0);
@ -591,7 +591,7 @@ LRESULT ShellView_OnActivate(IShellViewImpl * This, UINT uState)
MENUITEMINFOA mii; MENUITEMINFOA mii;
CHAR szText[MAX_PATH]; CHAR szText[MAX_PATH];
TRACE(shell,"%p uState=%x\n",This,uState); TRACE("%p uState=%x\n",This,uState);
/*don't do anything if the state isn't really changing */ /*don't do anything if the state isn't really changing */
if(This->uState == uState) if(This->uState == uState)
@ -607,7 +607,7 @@ LRESULT ShellView_OnActivate(IShellViewImpl * This, UINT uState)
if(This->hMenu) if(This->hMenu)
{ IShellBrowser_InsertMenusSB(This->pShellBrowser, This->hMenu, &omw); { IShellBrowser_InsertMenusSB(This->pShellBrowser, This->hMenu, &omw);
TRACE(shell,"-- after fnInsertMenusSB\n"); TRACE("-- after fnInsertMenusSB\n");
/*build the top level menu get the menu item's text*/ /*build the top level menu get the menu item's text*/
strcpy(szText,"dummy 31"); strcpy(szText,"dummy 31");
@ -644,12 +644,12 @@ LRESULT ShellView_OnActivate(IShellViewImpl * This, UINT uState)
{ ShellView_MergeFileMenu(This, mii.hSubMenu); { ShellView_MergeFileMenu(This, mii.hSubMenu);
} }
} }
TRACE(shell,"-- before fnSetMenuSB\n"); TRACE("-- before fnSetMenuSB\n");
IShellBrowser_SetMenuSB(This->pShellBrowser, This->hMenu, 0, This->hWnd); IShellBrowser_SetMenuSB(This->pShellBrowser, This->hMenu, 0, This->hWnd);
} }
} }
This->uState = uState; This->uState = uState;
TRACE(shell,"--\n"); TRACE("--\n");
return S_OK; return S_OK;
} }
@ -660,7 +660,7 @@ LRESULT ShellView_OnActivate(IShellViewImpl * This, UINT uState)
* internal * internal
*/ */
LRESULT ShellView_OnSetFocus(IShellViewImpl * This) LRESULT ShellView_OnSetFocus(IShellViewImpl * This)
{ TRACE(shell,"%p\n",This); { TRACE("%p\n",This);
/* Tell the browser one of our windows has received the focus. This should always /* Tell the browser one of our windows has received the focus. This should always
be done before merging menus (OnActivate merges the menus) if one of our be done before merging menus (OnActivate merges the menus) if one of our
windows has the focus.*/ windows has the focus.*/
@ -674,7 +674,7 @@ LRESULT ShellView_OnSetFocus(IShellViewImpl * This)
* ShellView_OnKillFocus() * ShellView_OnKillFocus()
*/ */
LRESULT ShellView_OnKillFocus(IShellViewImpl * This) LRESULT ShellView_OnKillFocus(IShellViewImpl * This)
{ TRACE(shell,"(%p) stub\n",This); { TRACE("(%p) stub\n",This);
ShellView_OnActivate(This, SVUIA_ACTIVATE_NOFOCUS); ShellView_OnActivate(This, SVUIA_ACTIVATE_NOFOCUS);
return 0; return 0;
} }
@ -688,7 +688,7 @@ BOOL ShellView_AddRemoveDockingWindow(IShellViewImpl * This, BOOL bAdd)
LPSERVICEPROVIDER pSP; LPSERVICEPROVIDER pSP;
LPDOCKINGWINDOWFRAME pFrame; LPDOCKINGWINDOWFRAME pFrame;
WARN(shell,"(%p)->(badd=0x%08x) semi-stub\n",This,bAdd); WARN("(%p)->(badd=0x%08x) semi-stub\n",This,bAdd);
/* get the browser's IServiceProvider */ /* get the browser's IServiceProvider */
hr = IShellBrowser_QueryInterface(This->pShellBrowser, (REFIID)&IID_IServiceProvider, (LPVOID*)&pSP); hr = IShellBrowser_QueryInterface(This->pShellBrowser, (REFIID)&IID_IServiceProvider, (LPVOID*)&pSP);
@ -698,7 +698,7 @@ BOOL ShellView_AddRemoveDockingWindow(IShellViewImpl * This, BOOL bAdd)
if(SUCCEEDED(hr)) if(SUCCEEDED(hr))
{ if(bAdd) { if(bAdd)
{ hr = S_OK; { hr = S_OK;
FIXME(shell,"no docking implemented\n"); FIXME("no docking implemented\n");
#if 0 #if 0
if(!This->pDockingWindow) if(!This->pDockingWindow)
{ /* create the toolbar object */ { /* create the toolbar object */
@ -716,7 +716,7 @@ BOOL ShellView_AddRemoveDockingWindow(IShellViewImpl * This, BOOL bAdd)
#endif #endif
} }
else else
{ FIXME(shell,"no docking implemented\n"); { FIXME("no docking implemented\n");
#if 0 #if 0
if(This->pDockingWindow) if(This->pDockingWindow)
{ hr = pFrame->lpvtbl->fnRemoveToolbar(pFrame, (IDockingWindow*)This->pDockingWindow, DWFRF_NORMAL); { hr = pFrame->lpvtbl->fnRemoveToolbar(pFrame, (IDockingWindow*)This->pDockingWindow, DWFRF_NORMAL);
@ -743,7 +743,7 @@ BOOL ShellView_AddRemoveDockingWindow(IShellViewImpl * This, BOOL bAdd)
* ShellView_UpdateShellSettings() * ShellView_UpdateShellSettings()
*/ */
void ShellView_UpdateShellSettings(IShellViewImpl * This) void ShellView_UpdateShellSettings(IShellViewImpl * This)
{ FIXME(shell,"(%p) stub\n",This); { FIXME("(%p) stub\n",This);
return ; return ;
/* /*
SHELLFLAGSTATE sfs; SHELLFLAGSTATE sfs;
@ -784,7 +784,7 @@ void ShellView_UpdateShellSettings(IShellViewImpl * This)
* ShellView_OnSettingChange() * ShellView_OnSettingChange()
*/ */
LRESULT ShellView_OnSettingChange(IShellViewImpl * This, LPCSTR lpszSection) LRESULT ShellView_OnSettingChange(IShellViewImpl * This, LPCSTR lpszSection)
{ TRACE(shell,"(%p) stub\n",This); { TRACE("(%p) stub\n",This);
/*if(0 == lstrcmpi(lpszSection, "ShellState"))*/ /*if(0 == lstrcmpi(lpszSection, "ShellState"))*/
{ ShellView_UpdateShellSettings(This); { ShellView_UpdateShellSettings(This);
return 0; return 0;
@ -795,7 +795,7 @@ LRESULT ShellView_OnSettingChange(IShellViewImpl * This, LPCSTR lpszSection)
* ShellView_OnCommand() * ShellView_OnCommand()
*/ */
LRESULT ShellView_OnCommand(IShellViewImpl * This,DWORD dwCmdID, DWORD dwCmd, HWND hwndCmd) LRESULT ShellView_OnCommand(IShellViewImpl * This,DWORD dwCmdID, DWORD dwCmd, HWND hwndCmd)
{ TRACE(shell,"(%p)->(0x%08lx 0x%08lx 0x%08x) stub\n",This, dwCmdID, dwCmd, hwndCmd); { TRACE("(%p)->(0x%08lx 0x%08lx 0x%08x) stub\n",This, dwCmdID, dwCmd, hwndCmd);
switch(dwCmdID) switch(dwCmdID)
{ case IDM_VIEW_FILES: { case IDM_VIEW_FILES:
g_bViewKeys = ! g_bViewKeys; g_bViewKeys = ! g_bViewKeys;
@ -832,7 +832,7 @@ LRESULT ShellView_OnCommand(IShellViewImpl * This,DWORD dwCmdID, DWORD dwCmd, HW
break; break;
default: default:
TRACE(shell,"-- COMMAND 0x%04lx unhandled\n", dwCmdID); TRACE("-- COMMAND 0x%04lx unhandled\n", dwCmdID);
} }
return 0; return 0;
} }
@ -855,10 +855,10 @@ UINT ShellView_GetSelections(IShellViewImpl * This)
This->uSelected = ListView_GetSelectedCount(This->hWndList); This->uSelected = ListView_GetSelectedCount(This->hWndList);
This->aSelectedItems = (LPITEMIDLIST*)SHAlloc(This->uSelected * sizeof(LPITEMIDLIST)); This->aSelectedItems = (LPITEMIDLIST*)SHAlloc(This->uSelected * sizeof(LPITEMIDLIST));
TRACE(shell,"selected=%i\n", This->uSelected); TRACE("selected=%i\n", This->uSelected);
if(This->aSelectedItems) if(This->aSelectedItems)
{ TRACE(shell,"-- Items selected =%u\n", This->uSelected); { TRACE("-- Items selected =%u\n", This->uSelected);
ZeroMemory(&lvItem, sizeof(lvItem)); ZeroMemory(&lvItem, sizeof(lvItem));
lvItem.mask = LVIF_STATE | LVIF_PARAM; lvItem.mask = LVIF_STATE | LVIF_PARAM;
lvItem.stateMask = LVIS_SELECTED; lvItem.stateMask = LVIS_SELECTED;
@ -870,7 +870,7 @@ UINT ShellView_GetSelections(IShellViewImpl * This)
{ if(lvItem.state & LVIS_SELECTED) { if(lvItem.state & LVIS_SELECTED)
{ This->aSelectedItems[i] = (LPITEMIDLIST)lvItem.lParam; { This->aSelectedItems[i] = (LPITEMIDLIST)lvItem.lParam;
i++; i++;
TRACE(shell,"-- selected Item found\n"); TRACE("-- selected Item found\n");
} }
lvItem.iItem++; lvItem.iItem++;
} }
@ -892,7 +892,7 @@ void ShellView_DoContextMenu(IShellViewImpl * This, WORD x, WORD y, BOOL fDefaul
LPCONTEXTMENU pContextMenu = NULL; LPCONTEXTMENU pContextMenu = NULL;
CMINVOKECOMMANDINFO cmi; CMINVOKECOMMANDINFO cmi;
TRACE(shell,"(%p)->(0x%08x 0x%08x 0x%08x) stub\n",This, x, y, fDefault); TRACE("(%p)->(0x%08x 0x%08x 0x%08x) stub\n",This, x, y, fDefault);
/* look, what's selected and create a context menu object of it*/ /* look, what's selected and create a context menu object of it*/
if(ShellView_GetSelections(This)) if(ShellView_GetSelections(This))
@ -901,7 +901,7 @@ void ShellView_DoContextMenu(IShellViewImpl * This, WORD x, WORD y, BOOL fDefaul
NULL, (LPVOID *)&pContextMenu); NULL, (LPVOID *)&pContextMenu);
if(pContextMenu) if(pContextMenu)
{ TRACE(shell,"-- pContextMenu\n"); { TRACE("-- pContextMenu\n");
hMenu = CreatePopupMenu(); hMenu = CreatePopupMenu();
if( hMenu ) if( hMenu )
@ -909,7 +909,7 @@ void ShellView_DoContextMenu(IShellViewImpl * This, WORD x, WORD y, BOOL fDefaul
is present, then we are in Explore mode.*/ is present, then we are in Explore mode.*/
if(SUCCEEDED(IShellBrowser_GetControlWindow(This->pShellBrowser,FCW_TREE, &hwndTree)) && hwndTree) if(SUCCEEDED(IShellBrowser_GetControlWindow(This->pShellBrowser,FCW_TREE, &hwndTree)) && hwndTree)
{ TRACE(shell,"-- explore mode\n"); { TRACE("-- explore mode\n");
fExplore = TRUE; fExplore = TRUE;
} }
@ -917,7 +917,7 @@ void ShellView_DoContextMenu(IShellViewImpl * This, WORD x, WORD y, BOOL fDefaul
if (SUCCEEDED(pContextMenu->lpvtbl->fnQueryContextMenu( pContextMenu, hMenu, 0, MENU_OFFSET, MENU_MAX, wFlags ))) if (SUCCEEDED(pContextMenu->lpvtbl->fnQueryContextMenu( pContextMenu, hMenu, 0, MENU_OFFSET, MENU_MAX, wFlags )))
{ if( fDefault ) { if( fDefault )
{ TRACE(shell,"-- get menu default command\n"); { TRACE("-- get menu default command\n");
uCommand = nMenuIndex = 0; uCommand = nMenuIndex = 0;
ZeroMemory(&mii, sizeof(mii)); ZeroMemory(&mii, sizeof(mii));
@ -933,18 +933,18 @@ void ShellView_DoContextMenu(IShellViewImpl * This, WORD x, WORD y, BOOL fDefaul
} }
} }
else else
{ TRACE(shell,"-- track popup\n"); { TRACE("-- track popup\n");
uCommand = TrackPopupMenu( hMenu,TPM_LEFTALIGN | TPM_RETURNCMD,x,y,0,This->hWnd,NULL); uCommand = TrackPopupMenu( hMenu,TPM_LEFTALIGN | TPM_RETURNCMD,x,y,0,This->hWnd,NULL);
} }
if(uCommand > 0) if(uCommand > 0)
{ TRACE(shell,"-- uCommand=%u\n", uCommand); { TRACE("-- uCommand=%u\n", uCommand);
if (IsInCommDlg(This) && (((uCommand-MENU_OFFSET)==IDM_EXPLORE) || ((uCommand-MENU_OFFSET)==IDM_OPEN))) if (IsInCommDlg(This) && (((uCommand-MENU_OFFSET)==IDM_EXPLORE) || ((uCommand-MENU_OFFSET)==IDM_OPEN)))
{ TRACE(shell,"-- dlg: OnDefaultCommand\n"); { TRACE("-- dlg: OnDefaultCommand\n");
OnDefaultCommand(This); OnDefaultCommand(This);
} }
else else
{ TRACE(shell,"-- explore -- invoke command\n"); { TRACE("-- explore -- invoke command\n");
ZeroMemory(&cmi, sizeof(cmi)); ZeroMemory(&cmi, sizeof(cmi));
cmi.cbSize = sizeof(cmi); cmi.cbSize = sizeof(cmi);
cmi.hwnd = This->hWndParent; cmi.hwnd = This->hWndParent;
@ -978,44 +978,44 @@ LRESULT ShellView_OnNotify(IShellViewImpl * This, UINT CtlID, LPNMHDR lpnmh)
DWORD dwCursor; DWORD dwCursor;
STRRET str; STRRET str;
TRACE(shell,"%p CtlID=%u lpnmh->code=%x\n",This,CtlID,lpnmh->code); TRACE("%p CtlID=%u lpnmh->code=%x\n",This,CtlID,lpnmh->code);
switch(lpnmh->code) switch(lpnmh->code)
{ case NM_SETFOCUS: { case NM_SETFOCUS:
TRACE(shell,"-- NM_SETFOCUS %p\n",This); TRACE("-- NM_SETFOCUS %p\n",This);
ShellView_OnSetFocus(This); ShellView_OnSetFocus(This);
break; break;
case NM_KILLFOCUS: case NM_KILLFOCUS:
TRACE(shell,"-- NM_KILLFOCUS %p\n",This); TRACE("-- NM_KILLFOCUS %p\n",This);
ShellView_OnDeactivate(This); ShellView_OnDeactivate(This);
break; break;
case HDN_ENDTRACKA: case HDN_ENDTRACKA:
TRACE(shell,"-- HDN_ENDTRACKA %p\n",This); TRACE("-- HDN_ENDTRACKA %p\n",This);
/*nColumn1 = ListView_GetColumnWidth(This->hWndList, 0); /*nColumn1 = ListView_GetColumnWidth(This->hWndList, 0);
nColumn2 = ListView_GetColumnWidth(This->hWndList, 1);*/ nColumn2 = ListView_GetColumnWidth(This->hWndList, 1);*/
break; break;
case LVN_DELETEITEM: case LVN_DELETEITEM:
TRACE(shell,"-- LVN_DELETEITEM %p\n",This); TRACE("-- LVN_DELETEITEM %p\n",This);
SHFree((LPITEMIDLIST)lpnmlv->lParam); /*delete the pidl because we made a copy of it*/ SHFree((LPITEMIDLIST)lpnmlv->lParam); /*delete the pidl because we made a copy of it*/
break; break;
case LVN_ITEMACTIVATE: case LVN_ITEMACTIVATE:
TRACE(shell,"-- LVN_ITEMACTIVATE %p\n",This); TRACE("-- LVN_ITEMACTIVATE %p\n",This);
OnStateChange(This, CDBOSC_SELCHANGE); /* the browser will get the IDataObject now */ OnStateChange(This, CDBOSC_SELCHANGE); /* the browser will get the IDataObject now */
ShellView_DoContextMenu(This, 0, 0, TRUE); ShellView_DoContextMenu(This, 0, 0, TRUE);
break; break;
case NM_RCLICK: case NM_RCLICK:
TRACE(shell,"-- NM_RCLICK %p\n",This); TRACE("-- NM_RCLICK %p\n",This);
dwCursor = GetMessagePos(); dwCursor = GetMessagePos();
ShellView_DoContextMenu(This, LOWORD(dwCursor), HIWORD(dwCursor), FALSE); ShellView_DoContextMenu(This, LOWORD(dwCursor), HIWORD(dwCursor), FALSE);
break; break;
case LVN_GETDISPINFOA: case LVN_GETDISPINFOA:
TRACE(shell,"-- LVN_GETDISPINFOA %p\n",This); TRACE("-- LVN_GETDISPINFOA %p\n",This);
pidl = (LPITEMIDLIST)lpdi->item.lParam; pidl = (LPITEMIDLIST)lpdi->item.lParam;
@ -1058,7 +1058,7 @@ LRESULT ShellView_OnNotify(IShellViewImpl * This, UINT CtlID, LPNMHDR lpnmh)
break; break;
} }
} }
TRACE(shell,"-- text=%s\n",lpdi->item.pszText); TRACE("-- text=%s\n",lpdi->item.pszText);
} }
} }
else /*the item text is being requested*/ else /*the item text is being requested*/
@ -1072,10 +1072,10 @@ LRESULT ShellView_OnNotify(IShellViewImpl * This, UINT CtlID, LPNMHDR lpnmh)
{ strncpy(lpdi->item.pszText, str.u.cStr, lpdi->item.cchTextMax); { strncpy(lpdi->item.pszText, str.u.cStr, lpdi->item.cchTextMax);
} }
else else
{ FIXME(shell,"type wrong\n"); { FIXME("type wrong\n");
} }
} }
TRACE(shell,"-- text=%s\n",lpdi->item.pszText); TRACE("-- text=%s\n",lpdi->item.pszText);
} }
if(lpdi->item.mask & LVIF_IMAGE) /*is the image being requested?*/ if(lpdi->item.mask & LVIF_IMAGE) /*is the image being requested?*/
@ -1085,13 +1085,13 @@ LRESULT ShellView_OnNotify(IShellViewImpl * This, UINT CtlID, LPNMHDR lpnmh)
break; break;
case LVN_ITEMCHANGED: case LVN_ITEMCHANGED:
TRACE(shell,"-- LVN_ITEMCHANGED %p\n",This); TRACE("-- LVN_ITEMCHANGED %p\n",This);
ShellView_GetSelections(This); ShellView_GetSelections(This);
OnStateChange(This, CDBOSC_SELCHANGE); /* the browser will get the IDataObject now */ OnStateChange(This, CDBOSC_SELCHANGE); /* the browser will get the IDataObject now */
break; break;
default: default:
TRACE (shell,"-- %p WM_COMMAND %s unhandled\n", This, SPY_GetMsgName(lpnmh->code)); TRACE("-- %p WM_COMMAND %s unhandled\n", This, SPY_GetMsgName(lpnmh->code));
break;; break;;
} }
return 0; return 0;
@ -1106,11 +1106,11 @@ LRESULT CALLBACK ShellView_WndProc(HWND hWnd, UINT uMessage, WPARAM wParam, LPAR
LPCREATESTRUCTA lpcs; LPCREATESTRUCTA lpcs;
DWORD dwCursor; DWORD dwCursor;
TRACE(shell,"(hwnd=%x msg=%x wparm=%x lparm=%lx)\n",hWnd, uMessage, wParam, lParam); TRACE("(hwnd=%x msg=%x wparm=%x lparm=%lx)\n",hWnd, uMessage, wParam, lParam);
switch (uMessage) switch (uMessage)
{ case WM_NCCREATE: { case WM_NCCREATE:
{ TRACE(shell,"-- WM_NCCREATE\n"); { TRACE("-- WM_NCCREATE\n");
lpcs = (LPCREATESTRUCTA)lParam; lpcs = (LPCREATESTRUCTA)lParam;
pThis = (IShellViewImpl*)(lpcs->lpCreateParams); pThis = (IShellViewImpl*)(lpcs->lpCreateParams);
SetWindowLongA(hWnd, GWL_USERDATA, (LONG)pThis); SetWindowLongA(hWnd, GWL_USERDATA, (LONG)pThis);
@ -1119,50 +1119,50 @@ LRESULT CALLBACK ShellView_WndProc(HWND hWnd, UINT uMessage, WPARAM wParam, LPAR
break; break;
case WM_SIZE: case WM_SIZE:
TRACE(shell,"-- WM_SIZE\n"); TRACE("-- WM_SIZE\n");
return ShellView_OnSize(pThis,LOWORD(lParam), HIWORD(lParam)); return ShellView_OnSize(pThis,LOWORD(lParam), HIWORD(lParam));
case WM_SETFOCUS: case WM_SETFOCUS:
TRACE(shell,"-- WM_SETFOCUS\n"); TRACE("-- WM_SETFOCUS\n");
return ShellView_OnSetFocus(pThis); return ShellView_OnSetFocus(pThis);
case WM_KILLFOCUS: case WM_KILLFOCUS:
TRACE(shell,"-- WM_KILLFOCUS\n"); TRACE("-- WM_KILLFOCUS\n");
return ShellView_OnKillFocus(pThis); return ShellView_OnKillFocus(pThis);
case WM_CREATE: case WM_CREATE:
TRACE(shell,"-- WM_CREATE\n"); TRACE("-- WM_CREATE\n");
return ShellView_OnCreate(pThis); return ShellView_OnCreate(pThis);
case WM_SHOWWINDOW: case WM_SHOWWINDOW:
TRACE(shell,"-- WM_SHOWWINDOW\n"); TRACE("-- WM_SHOWWINDOW\n");
UpdateWindow(pThis->hWndList); UpdateWindow(pThis->hWndList);
break; break;
case WM_ACTIVATE: case WM_ACTIVATE:
TRACE(shell,"-- WM_ACTIVATE\n"); TRACE("-- WM_ACTIVATE\n");
return ShellView_OnActivate(pThis, SVUIA_ACTIVATE_FOCUS); return ShellView_OnActivate(pThis, SVUIA_ACTIVATE_FOCUS);
case WM_COMMAND: case WM_COMMAND:
TRACE(shell,"-- WM_COMMAND\n"); TRACE("-- WM_COMMAND\n");
return ShellView_OnCommand(pThis, GET_WM_COMMAND_ID(wParam, lParam), return ShellView_OnCommand(pThis, GET_WM_COMMAND_ID(wParam, lParam),
GET_WM_COMMAND_CMD(wParam, lParam), GET_WM_COMMAND_CMD(wParam, lParam),
GET_WM_COMMAND_HWND(wParam, lParam)); GET_WM_COMMAND_HWND(wParam, lParam));
case WM_INITMENUPOPUP: case WM_INITMENUPOPUP:
TRACE(shell,"-- WM_INITMENUPOPUP\n"); TRACE("-- WM_INITMENUPOPUP\n");
return ShellView_UpdateMenu(pThis, (HMENU)wParam); return ShellView_UpdateMenu(pThis, (HMENU)wParam);
case WM_NOTIFY: case WM_NOTIFY:
TRACE(shell,"-- WM_NOTIFY\n"); TRACE("-- WM_NOTIFY\n");
return ShellView_OnNotify(pThis,(UINT)wParam, (LPNMHDR)lParam); return ShellView_OnNotify(pThis,(UINT)wParam, (LPNMHDR)lParam);
case WM_SETTINGCHANGE: case WM_SETTINGCHANGE:
TRACE(shell,"-- WM_SETTINGCHANGE\n"); TRACE("-- WM_SETTINGCHANGE\n");
return ShellView_OnSettingChange(pThis,(LPCSTR)lParam); return ShellView_OnSettingChange(pThis,(LPCSTR)lParam);
case WM_PARENTNOTIFY: case WM_PARENTNOTIFY:
TRACE(shell,"-- WM_PARENTNOTIFY\n"); TRACE("-- WM_PARENTNOTIFY\n");
if ( LOWORD(wParam) == WM_RBUTTONDOWN ) /* fixme: should not be handled here*/ if ( LOWORD(wParam) == WM_RBUTTONDOWN ) /* fixme: should not be handled here*/
{ dwCursor = GetMessagePos(); { dwCursor = GetMessagePos();
ShellView_DoContextMenu(pThis, LOWORD(dwCursor), HIWORD(dwCursor), FALSE); ShellView_DoContextMenu(pThis, LOWORD(dwCursor), HIWORD(dwCursor), FALSE);
@ -1171,7 +1171,7 @@ LRESULT CALLBACK ShellView_WndProc(HWND hWnd, UINT uMessage, WPARAM wParam, LPAR
break; break;
default: default:
TRACE(shell,"-- message %s unhandled\n", SPY_GetMsgName(uMessage)); TRACE("-- message %s unhandled\n", SPY_GetMsgName(uMessage));
break; break;
} }
return DefWindowProcA (hWnd, uMessage, wParam, lParam); return DefWindowProcA (hWnd, uMessage, wParam, lParam);
@ -1191,7 +1191,7 @@ static HRESULT WINAPI IShellView_fnQueryInterface(IShellView * iface,REFIID riid
char xriid[50]; char xriid[50];
WINE_StringFromCLSID((LPCLSID)riid,xriid); WINE_StringFromCLSID((LPCLSID)riid,xriid);
TRACE(shell,"(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj); TRACE("(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj);
*ppvObj = NULL; *ppvObj = NULL;
@ -1213,10 +1213,10 @@ static HRESULT WINAPI IShellView_fnQueryInterface(IShellView * iface,REFIID riid
if(*ppvObj) if(*ppvObj)
{ IShellView_AddRef( (IShellView*) *ppvObj); { IShellView_AddRef( (IShellView*) *ppvObj);
TRACE(shell,"-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj); TRACE("-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj);
return S_OK; return S_OK;
} }
TRACE(shell,"-- Interface: E_NOINTERFACE\n"); TRACE("-- Interface: E_NOINTERFACE\n");
return E_NOINTERFACE; return E_NOINTERFACE;
} }
@ -1227,7 +1227,7 @@ static ULONG WINAPI IShellView_fnAddRef(IShellView * iface)
{ {
ICOM_THIS(IShellViewImpl, iface); ICOM_THIS(IShellViewImpl, iface);
TRACE(shell,"(%p)->(count=%lu)\n",This,This->ref); TRACE("(%p)->(count=%lu)\n",This,This->ref);
shell32_ObjCount++; shell32_ObjCount++;
return ++(This->ref); return ++(This->ref);
@ -1239,11 +1239,11 @@ static ULONG WINAPI IShellView_fnRelease(IShellView * iface)
{ {
ICOM_THIS(IShellViewImpl, iface); ICOM_THIS(IShellViewImpl, iface);
TRACE(shell,"(%p)->()\n",This); TRACE("(%p)->()\n",This);
shell32_ObjCount--; shell32_ObjCount--;
if (!--(This->ref)) if (!--(This->ref))
{ TRACE(shell," destroying IShellView(%p)\n",This); { TRACE(" destroying IShellView(%p)\n",This);
if(This->pSFParent) if(This->pSFParent)
IShellFolder_Release(This->pSFParent); IShellFolder_Release(This->pSFParent);
@ -1266,7 +1266,7 @@ static HRESULT WINAPI IShellView_fnGetWindow(IShellView * iface,HWND * phWnd)
{ {
ICOM_THIS(IShellViewImpl, iface); ICOM_THIS(IShellViewImpl, iface);
TRACE(shell,"(%p)\n",This); TRACE("(%p)\n",This);
*phWnd = This->hWnd; *phWnd = This->hWnd;
@ -1277,7 +1277,7 @@ static HRESULT WINAPI IShellView_fnContextSensitiveHelp(IShellView * iface,BOOL
{ {
ICOM_THIS(IShellViewImpl, iface); ICOM_THIS(IShellViewImpl, iface);
FIXME(shell,"(%p) stub\n",This); FIXME("(%p) stub\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -1291,11 +1291,11 @@ static HRESULT WINAPI IShellView_fnTranslateAccelerator(IShellView * iface,LPMSG
{ {
ICOM_THIS(IShellViewImpl, iface); ICOM_THIS(IShellViewImpl, iface);
FIXME(shell,"(%p)->(%p: hwnd=%x msg=%x lp=%lx wp=%x) stub\n",This,lpmsg, lpmsg->hwnd, lpmsg->message, lpmsg->lParam, lpmsg->wParam); FIXME("(%p)->(%p: hwnd=%x msg=%x lp=%lx wp=%x) stub\n",This,lpmsg, lpmsg->hwnd, lpmsg->message, lpmsg->lParam, lpmsg->wParam);
switch (lpmsg->message) switch (lpmsg->message)
{ case WM_KEYDOWN: TRACE(shell,"-- key=0x04%x",lpmsg->wParam) ; { case WM_KEYDOWN: TRACE("-- key=0x04%x",lpmsg->wParam) ;
} }
return S_FALSE; return S_FALSE;
} }
@ -1304,7 +1304,7 @@ static HRESULT WINAPI IShellView_fnEnableModeless(IShellView * iface,BOOL fEnabl
{ {
ICOM_THIS(IShellViewImpl, iface); ICOM_THIS(IShellViewImpl, iface);
FIXME(shell,"(%p) stub\n",This); FIXME("(%p) stub\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -1317,7 +1317,7 @@ static HRESULT WINAPI IShellView_fnUIActivate(IShellView * iface,UINT uState)
LRESULT lResult; LRESULT lResult;
int nPartArray[1] = {-1}; int nPartArray[1] = {-1};
TRACE(shell,"(%p)->(state=%x) stub\n",This, uState); TRACE("(%p)->(state=%x) stub\n",This, uState);
/*don't do anything if the state isn't really changing*/ /*don't do anything if the state isn't really changing*/
if(This->uState == uState) if(This->uState == uState)
{ return S_OK; { return S_OK;
@ -1357,7 +1357,7 @@ static HRESULT WINAPI IShellView_fnRefresh(IShellView * iface)
{ {
ICOM_THIS(IShellViewImpl, iface); ICOM_THIS(IShellViewImpl, iface);
TRACE(shell,"(%p)\n",This); TRACE("(%p)\n",This);
ListView_DeleteAllItems(This->hWndList); ListView_DeleteAllItems(This->hWndList);
ShellView_FillList(This); ShellView_FillList(This);
@ -1373,8 +1373,8 @@ static HRESULT WINAPI IShellView_fnCreateViewWindow(IShellView * iface, IShellVi
*phWnd = 0; *phWnd = 0;
TRACE(shell,"(%p)->(shlview=%p set=%p shlbrs=%p rec=%p hwnd=%p) incomplete\n",This, lpPrevView,lpfs, psb, prcView, phWnd); TRACE("(%p)->(shlview=%p set=%p shlbrs=%p rec=%p hwnd=%p) incomplete\n",This, lpPrevView,lpfs, psb, prcView, phWnd);
TRACE(shell,"-- vmode=%x flags=%x left=%i top=%i right=%i bottom=%i\n",lpfs->ViewMode, lpfs->fFlags ,prcView->left,prcView->top, prcView->right, prcView->bottom); TRACE("-- vmode=%x flags=%x left=%i top=%i right=%i bottom=%i\n",lpfs->ViewMode, lpfs->fFlags ,prcView->left,prcView->top, prcView->right, prcView->bottom);
/*set up the member variables*/ /*set up the member variables*/
This->pShellBrowser = psb; This->pShellBrowser = psb;
@ -1388,7 +1388,7 @@ static HRESULT WINAPI IShellView_fnCreateViewWindow(IShellView * iface, IShellVi
This->pCommDlgBrowser=NULL; This->pCommDlgBrowser=NULL;
if ( SUCCEEDED (IShellBrowser_QueryInterface( This->pShellBrowser, if ( SUCCEEDED (IShellBrowser_QueryInterface( This->pShellBrowser,
(REFIID)&IID_ICommDlgBrowser, (LPVOID*) &This->pCommDlgBrowser))) (REFIID)&IID_ICommDlgBrowser, (LPVOID*) &This->pCommDlgBrowser)))
{ TRACE(shell,"-- CommDlgBrowser\n"); { TRACE("-- CommDlgBrowser\n");
} }
/*if our window class has not been registered, then do so*/ /*if our window class has not been registered, then do so*/
@ -1425,7 +1425,7 @@ static HRESULT WINAPI IShellView_fnDestroyViewWindow(IShellView * iface)
{ {
ICOM_THIS(IShellViewImpl, iface); ICOM_THIS(IShellViewImpl, iface);
TRACE(shell,"(%p)\n",This); TRACE("(%p)\n",This);
/*Make absolutely sure all our UI is cleaned up.*/ /*Make absolutely sure all our UI is cleaned up.*/
IShellView_UIActivate((IShellView*)This, SVUIA_DEACTIVATE); IShellView_UIActivate((IShellView*)This, SVUIA_DEACTIVATE);
@ -1441,7 +1441,7 @@ static HRESULT WINAPI IShellView_fnGetCurrentInfo(IShellView * iface, LPFOLDERSE
{ {
ICOM_THIS(IShellViewImpl, iface); ICOM_THIS(IShellViewImpl, iface);
TRACE(shell,"(%p)->(%p) vmode=%x flags=%x\n",This, lpfs, TRACE("(%p)->(%p) vmode=%x flags=%x\n",This, lpfs,
This->FolderSettings.ViewMode, This->FolderSettings.fFlags); This->FolderSettings.ViewMode, This->FolderSettings.fFlags);
if (lpfs) if (lpfs)
@ -1456,7 +1456,7 @@ static HRESULT WINAPI IShellView_fnAddPropertySheetPages(IShellView * iface, DWO
{ {
ICOM_THIS(IShellViewImpl, iface); ICOM_THIS(IShellViewImpl, iface);
FIXME(shell,"(%p) stub\n",This); FIXME("(%p) stub\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -1465,7 +1465,7 @@ static HRESULT WINAPI IShellView_fnSaveViewState(IShellView * iface)
{ {
ICOM_THIS(IShellViewImpl, iface); ICOM_THIS(IShellViewImpl, iface);
FIXME(shell,"(%p) stub\n",This); FIXME("(%p) stub\n",This);
return S_OK; return S_OK;
} }
@ -1473,7 +1473,7 @@ static HRESULT WINAPI IShellView_fnSaveViewState(IShellView * iface)
static HRESULT WINAPI IShellView_fnSelectItem(IShellView * iface, LPCITEMIDLIST pidlItem, UINT uFlags) static HRESULT WINAPI IShellView_fnSelectItem(IShellView * iface, LPCITEMIDLIST pidlItem, UINT uFlags)
{ ICOM_THIS(IShellViewImpl, iface); { ICOM_THIS(IShellViewImpl, iface);
FIXME(shell,"(%p)->(pidl=%p, 0x%08x) stub\n",This, pidlItem, uFlags); FIXME("(%p)->(pidl=%p, 0x%08x) stub\n",This, pidlItem, uFlags);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -1486,7 +1486,7 @@ static HRESULT WINAPI IShellView_fnGetItemObject(IShellView * iface, UINT uItem,
char xriid[50]; char xriid[50];
WINE_StringFromCLSID((LPCLSID)riid,xriid); WINE_StringFromCLSID((LPCLSID)riid,xriid);
TRACE(shell,"(%p)->(uItem=0x%08x,\n\tIID=%s, ppv=%p)\n",This, uItem, xriid, ppvOut); TRACE("(%p)->(uItem=0x%08x,\n\tIID=%s, ppv=%p)\n",This, uItem, xriid, ppvOut);
*ppvOut = NULL; *ppvOut = NULL;
if(IsEqualIID(riid, &IID_IContextMenu)) if(IsEqualIID(riid, &IID_IContextMenu))
@ -1498,7 +1498,7 @@ static HRESULT WINAPI IShellView_fnGetItemObject(IShellView * iface, UINT uItem,
pObj =(LPUNKNOWN)IDataObject_Constructor(This->hWndParent, This->pSFParent,This->aSelectedItems,This->uSelected); pObj =(LPUNKNOWN)IDataObject_Constructor(This->hWndParent, This->pSFParent,This->aSelectedItems,This->uSelected);
} }
TRACE(shell,"-- (%p)->(interface=%p)\n",This, ppvOut); TRACE("-- (%p)->(interface=%p)\n",This, ppvOut);
if(!pObj) if(!pObj)
return E_OUTOFMEMORY; return E_OUTOFMEMORY;
@ -1575,7 +1575,7 @@ static HRESULT WINAPI ISVOleCmdTarget_QueryStatus(
{ {
_ICOM_THIS_From_IOleCommandTarget(IShellViewImpl, iface); _ICOM_THIS_From_IOleCommandTarget(IShellViewImpl, iface);
FIXME(shell, "(%p)->(%p 0x%08lx %p %p\n", This, pguidCmdGroup, cCmds, prgCmds, pCmdText); FIXME("(%p)->(%p 0x%08lx %p %p\n", This, pguidCmdGroup, cCmds, prgCmds, pCmdText);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -1592,7 +1592,7 @@ static HRESULT WINAPI ISVOleCmdTarget_Exec(
{ {
_ICOM_THIS_From_IOleCommandTarget(IShellViewImpl, iface); _ICOM_THIS_From_IOleCommandTarget(IShellViewImpl, iface);
FIXME(shell, "(%p)->(%p 0x%08lx 0x%08lx %p %p)\n", This, pguidCmdGroup, nCmdID, nCmdexecopt, pvaIn, pvaOut); FIXME("(%p)->(%p 0x%08lx 0x%08lx %p %p)\n", This, pguidCmdGroup, nCmdID, nCmdexecopt, pvaIn, pvaOut);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -1621,7 +1621,7 @@ static HRESULT WINAPI ISVDropTarget_QueryInterface(
WINE_StringFromCLSID((LPCLSID)riid,xriid); WINE_StringFromCLSID((LPCLSID)riid,xriid);
TRACE(shell,"(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj); TRACE("(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj);
return IShellFolder_QueryInterface((IShellFolder*)This, riid, ppvObj); return IShellFolder_QueryInterface((IShellFolder*)This, riid, ppvObj);
} }
@ -1630,7 +1630,7 @@ static ULONG WINAPI ISVDropTarget_AddRef( IDropTarget *iface)
{ {
_ICOM_THIS_From_IDropTarget(IShellViewImpl, iface); _ICOM_THIS_From_IDropTarget(IShellViewImpl, iface);
TRACE(shell,"(%p)->(count=%lu)\n",This,This->ref); TRACE("(%p)->(count=%lu)\n",This,This->ref);
return IShellFolder_AddRef((IShellFolder*)This); return IShellFolder_AddRef((IShellFolder*)This);
} }
@ -1639,7 +1639,7 @@ static ULONG WINAPI ISVDropTarget_Release( IDropTarget *iface)
{ {
_ICOM_THIS_From_IDropTarget(IShellViewImpl, iface); _ICOM_THIS_From_IDropTarget(IShellViewImpl, iface);
TRACE(shell,"(%p)->(count=%lu)\n",This,This->ref); TRACE("(%p)->(count=%lu)\n",This,This->ref);
return IShellFolder_Release((IShellFolder*)This); return IShellFolder_Release((IShellFolder*)This);
} }
@ -1654,7 +1654,7 @@ static HRESULT WINAPI ISVDropTarget_DragEnter(
_ICOM_THIS_From_IDropTarget(IShellViewImpl, iface); _ICOM_THIS_From_IDropTarget(IShellViewImpl, iface);
FIXME(shell, "Stub: This=%p, DataObject=%p\n",This,pDataObject); FIXME("Stub: This=%p, DataObject=%p\n",This,pDataObject);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -1667,7 +1667,7 @@ static HRESULT WINAPI ISVDropTarget_DragOver(
{ {
_ICOM_THIS_From_IDropTarget(IShellViewImpl, iface); _ICOM_THIS_From_IDropTarget(IShellViewImpl, iface);
FIXME(shell, "Stub: This=%p\n",This); FIXME("Stub: This=%p\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -1677,7 +1677,7 @@ static HRESULT WINAPI ISVDropTarget_DragLeave(
{ {
_ICOM_THIS_From_IDropTarget(IShellViewImpl, iface); _ICOM_THIS_From_IDropTarget(IShellViewImpl, iface);
FIXME(shell, "Stub: This=%p\n",This); FIXME("Stub: This=%p\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -1691,7 +1691,7 @@ static HRESULT WINAPI ISVDropTarget_Drop(
{ {
_ICOM_THIS_From_IDropTarget(IShellViewImpl, iface); _ICOM_THIS_From_IDropTarget(IShellViewImpl, iface);
FIXME(shell, "Stub: This=%p\n",This); FIXME("Stub: This=%p\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -1723,7 +1723,7 @@ static HRESULT WINAPI ISVViewObject_QueryInterface(
WINE_StringFromCLSID((LPCLSID)riid,xriid); WINE_StringFromCLSID((LPCLSID)riid,xriid);
TRACE(shell,"(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj); TRACE("(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj);
return IShellFolder_QueryInterface((IShellFolder*)This, riid, ppvObj); return IShellFolder_QueryInterface((IShellFolder*)This, riid, ppvObj);
} }
@ -1732,7 +1732,7 @@ static ULONG WINAPI ISVViewObject_AddRef( IViewObject *iface)
{ {
_ICOM_THIS_From_IViewObject(IShellViewImpl, iface); _ICOM_THIS_From_IViewObject(IShellViewImpl, iface);
TRACE(shell,"(%p)->(count=%lu)\n",This,This->ref); TRACE("(%p)->(count=%lu)\n",This,This->ref);
return IShellFolder_AddRef((IShellFolder*)This); return IShellFolder_AddRef((IShellFolder*)This);
} }
@ -1741,7 +1741,7 @@ static ULONG WINAPI ISVViewObject_Release( IViewObject *iface)
{ {
_ICOM_THIS_From_IViewObject(IShellViewImpl, iface); _ICOM_THIS_From_IViewObject(IShellViewImpl, iface);
TRACE(shell,"(%p)->(count=%lu)\n",This,This->ref); TRACE("(%p)->(count=%lu)\n",This,This->ref);
return IShellFolder_Release((IShellFolder*)This); return IShellFolder_Release((IShellFolder*)This);
} }
@ -1762,7 +1762,7 @@ static HRESULT WINAPI ISVViewObject_Draw(
_ICOM_THIS_From_IViewObject(IShellViewImpl, iface); _ICOM_THIS_From_IViewObject(IShellViewImpl, iface);
FIXME(shell, "Stub: This=%p\n",This); FIXME("Stub: This=%p\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -1778,7 +1778,7 @@ static HRESULT WINAPI ISVViewObject_GetColorSet(
_ICOM_THIS_From_IViewObject(IShellViewImpl, iface); _ICOM_THIS_From_IViewObject(IShellViewImpl, iface);
FIXME(shell, "Stub: This=%p\n",This); FIXME("Stub: This=%p\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -1792,7 +1792,7 @@ static HRESULT WINAPI ISVViewObject_Freeze(
_ICOM_THIS_From_IViewObject(IShellViewImpl, iface); _ICOM_THIS_From_IViewObject(IShellViewImpl, iface);
FIXME(shell, "Stub: This=%p\n",This); FIXME("Stub: This=%p\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -1803,7 +1803,7 @@ static HRESULT WINAPI ISVViewObject_Unfreeze(
_ICOM_THIS_From_IViewObject(IShellViewImpl, iface); _ICOM_THIS_From_IViewObject(IShellViewImpl, iface);
FIXME(shell, "Stub: This=%p\n",This); FIXME("Stub: This=%p\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -1816,7 +1816,7 @@ static HRESULT WINAPI ISVViewObject_SetAdvise(
_ICOM_THIS_From_IViewObject(IShellViewImpl, iface); _ICOM_THIS_From_IViewObject(IShellViewImpl, iface);
FIXME(shell, "Stub: This=%p\n",This); FIXME("Stub: This=%p\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }
@ -1829,7 +1829,7 @@ static HRESULT WINAPI ISVViewObject_GetAdvise(
_ICOM_THIS_From_IViewObject(IShellViewImpl, iface); _ICOM_THIS_From_IViewObject(IShellViewImpl, iface);
FIXME(shell, "Stub: This=%p\n",This); FIXME("Stub: This=%p\n",This);
return E_NOTIMPL; return E_NOTIMPL;
} }

View file

@ -13,7 +13,7 @@
#include "winaspi.h" #include "winaspi.h"
#include "options.h" #include "options.h"
#include "heap.h" #include "heap.h"
#include "debug.h" #include "debugtools.h"
#include "selectors.h" #include "selectors.h"
#include "miscemu.h" #include "miscemu.h"
@ -56,19 +56,19 @@ ASPI_OpenDevice16(SRB_ExecSCSICmd16 *prb)
sprintf(idstr, "scsi c%1dt%1dd%1d", prb->SRB_HaId, prb->SRB_Target, prb->SRB_Lun); sprintf(idstr, "scsi c%1dt%1dd%1d", prb->SRB_HaId, prb->SRB_Target, prb->SRB_Lun);
if (!PROFILE_GetWineIniString(idstr, "Device", "", device_str, sizeof(device_str))) { if (!PROFILE_GetWineIniString(idstr, "Device", "", device_str, sizeof(device_str))) {
TRACE(aspi, "Trying to open unlisted scsi device %s\n", idstr); TRACE("Trying to open unlisted scsi device %s\n", idstr);
return -1; return -1;
} }
TRACE(aspi, "Opening device %s=%s\n", idstr, device_str); TRACE("Opening device %s=%s\n", idstr, device_str);
fd = open(device_str, O_RDWR); fd = open(device_str, O_RDWR);
if (fd == -1) { if (fd == -1) {
int save_error = errno; int save_error = errno;
#ifdef HAVE_STRERROR #ifdef HAVE_STRERROR
ERR(aspi, "Error opening device %s, error '%s'\n", device_str, strerror(save_error)); ERR("Error opening device %s, error '%s'\n", device_str, strerror(save_error));
#else #else
ERR(aspi, "Error opening device %s, error %d\n", device_str, save_error); ERR("Error opening device %s, error %d\n", device_str, save_error);
#endif #endif
return -1; return -1;
} }
@ -110,52 +110,52 @@ ASPI_DebugPrintCmd(SRB_ExecSCSICmd16 *prb, UINT16 mode)
switch (prb->CDBByte[0]) { switch (prb->CDBByte[0]) {
case CMD_INQUIRY: case CMD_INQUIRY:
TRACE(aspi, "{\n"); TRACE("{\n");
TRACE(aspi, "\tEVPD: %d\n", prb->CDBByte[1] & 1); TRACE("\tEVPD: %d\n", prb->CDBByte[1] & 1);
TRACE(aspi, "\tLUN: %d\n", (prb->CDBByte[1] & 0xc) >> 1); TRACE("\tLUN: %d\n", (prb->CDBByte[1] & 0xc) >> 1);
TRACE(aspi, "\tPAGE CODE: %d\n", prb->CDBByte[2]); TRACE("\tPAGE CODE: %d\n", prb->CDBByte[2]);
TRACE(aspi, "\tALLOCATION LENGTH: %d\n", prb->CDBByte[4]); TRACE("\tALLOCATION LENGTH: %d\n", prb->CDBByte[4]);
TRACE(aspi, "\tCONTROL: %d\n", prb->CDBByte[5]); TRACE("\tCONTROL: %d\n", prb->CDBByte[5]);
TRACE(aspi, "}\n"); TRACE("}\n");
break; break;
case CMD_SCAN_SCAN: case CMD_SCAN_SCAN:
TRACE(aspi, "Transfer Length: %d\n", prb->CDBByte[4]); TRACE("Transfer Length: %d\n", prb->CDBByte[4]);
break; break;
} }
TRACE(aspi, "Host Adapter: %d\n", prb->SRB_HaId); TRACE("Host Adapter: %d\n", prb->SRB_HaId);
TRACE(aspi, "Flags: %d\n", prb->SRB_Flags); TRACE("Flags: %d\n", prb->SRB_Flags);
if (TARGET_TO_HOST(prb)) { if (TARGET_TO_HOST(prb)) {
TRACE(aspi, "\tData transfer: Target to host. Length checked.\n"); TRACE("\tData transfer: Target to host. Length checked.\n");
} }
else if (HOST_TO_TARGET(prb)) { else if (HOST_TO_TARGET(prb)) {
TRACE(aspi, "\tData transfer: Host to target. Length checked.\n"); TRACE("\tData transfer: Host to target. Length checked.\n");
} }
else if (NO_DATA_TRANSFERED(prb)) { else if (NO_DATA_TRANSFERED(prb)) {
TRACE(aspi, "\tData transfer: none\n"); TRACE("\tData transfer: none\n");
} }
else { else {
WARN(aspi, "\tTransfer by scsi cmd. Length not checked\n"); WARN("\tTransfer by scsi cmd. Length not checked\n");
} }
TRACE(aspi, "\tResidual byte length reporting %s\n", prb->SRB_Flags & 0x4 ? "enabled" : "disabled"); TRACE("\tResidual byte length reporting %s\n", prb->SRB_Flags & 0x4 ? "enabled" : "disabled");
TRACE(aspi, "\tLinking %s\n", prb->SRB_Flags & 0x2 ? "enabled" : "disabled"); TRACE("\tLinking %s\n", prb->SRB_Flags & 0x2 ? "enabled" : "disabled");
TRACE(aspi, "\tPosting %s\n", prb->SRB_Flags & 0x1 ? "enabled" : "disabled"); TRACE("\tPosting %s\n", prb->SRB_Flags & 0x1 ? "enabled" : "disabled");
TRACE(aspi, "Target: %d\n", prb->SRB_Target); TRACE("Target: %d\n", prb->SRB_Target);
TRACE(aspi, "Lun: %d\n", prb->SRB_Lun); TRACE("Lun: %d\n", prb->SRB_Lun);
TRACE(aspi, "BufLen: %ld\n", prb->SRB_BufLen); TRACE("BufLen: %ld\n", prb->SRB_BufLen);
TRACE(aspi, "SenseLen: %d\n", prb->SRB_SenseLen); TRACE("SenseLen: %d\n", prb->SRB_SenseLen);
TRACE(aspi, "BufPtr: %lx (%p)\n", prb->SRB_BufPointer, lpBuf); TRACE("BufPtr: %lx (%p)\n", prb->SRB_BufPointer, lpBuf);
TRACE(aspi, "LinkPointer %lx\n", prb->SRB_Rsvd1); TRACE("LinkPointer %lx\n", prb->SRB_Rsvd1);
TRACE(aspi, "CDB Length: %d\n", prb->SRB_CDBLen); TRACE("CDB Length: %d\n", prb->SRB_CDBLen);
TRACE(aspi, "POST Proc: %lx\n", (DWORD) prb->SRB_PostProc); TRACE("POST Proc: %lx\n", (DWORD) prb->SRB_PostProc);
cdb = &prb->CDBByte[0]; cdb = &prb->CDBByte[0];
cmd = prb->CDBByte[0]; cmd = prb->CDBByte[0];
for (i = 0; i < prb->SRB_CDBLen; i++) { for (i = 0; i < prb->SRB_CDBLen; i++) {
if (i != 0) dsprintf(aspi, ","); if (i != 0) dsprintf(aspi, ",");
dsprintf(aspi, "%02x", *cdb++); dsprintf(aspi, "%02x", *cdb++);
} }
TRACE(aspi, "CDB buffer[%s]\n", dbg_str(aspi)); TRACE("CDB buffer[%s]\n", dbg_str(aspi));
} }
static void static void
@ -170,7 +170,7 @@ ASPI_PrintSenseArea16(SRB_ExecSCSICmd16 *prb)
if (i) dsprintf(aspi, ","); if (i) dsprintf(aspi, ",");
dsprintf(aspi, "%02x", *cdb++); dsprintf(aspi, "%02x", *cdb++);
} }
TRACE(aspi, "SenseArea[%s]\n", dbg_str(aspi)); TRACE("SenseArea[%s]\n", dbg_str(aspi));
} }
static void static void
@ -192,7 +192,7 @@ ASPI_DebugPrintResult(SRB_ExecSCSICmd16 *prb, UINT16 mode)
switch (prb->CDBByte[0]) { switch (prb->CDBByte[0]) {
case CMD_INQUIRY: case CMD_INQUIRY:
TRACE(aspi, "Vendor: '%s'\n", lpBuf + INQUIRY_VENDOR); TRACE("Vendor: '%s'\n", lpBuf + INQUIRY_VENDOR);
break; break;
case CMD_TEST_UNIT_READY: case CMD_TEST_UNIT_READY:
ASPI_PrintSenseArea16(prb); ASPI_PrintSenseArea16(prb);
@ -226,7 +226,7 @@ ASPI_ExecScsiCmd(DWORD ptrPRB, UINT16 mode)
fd = ASPI_OpenDevice16(lpPRB); fd = ASPI_OpenDevice16(lpPRB);
if (fd == -1) { if (fd == -1) {
WARN(aspi, "Failed: could not open device. Device permissions !?\n"); WARN("Failed: could not open device. Device permissions !?\n");
lpPRB->SRB_Status = SS_ERR; lpPRB->SRB_Status = SS_ERR;
return SS_ERR; return SS_ERR;
} }
@ -249,7 +249,7 @@ ASPI_ExecScsiCmd(DWORD ptrPRB, UINT16 mode)
} }
if (!lpPRB->SRB_CDBLen) { if (!lpPRB->SRB_CDBLen) {
WARN(aspi, "Failed: lpPRB->SRB_CDBLen = 0.\n"); WARN("Failed: lpPRB->SRB_CDBLen = 0.\n");
lpPRB->SRB_Status = SS_ERR; lpPRB->SRB_Status = SS_ERR;
return SS_ERR; return SS_ERR;
} }
@ -290,15 +290,15 @@ ASPI_ExecScsiCmd(DWORD ptrPRB, UINT16 mode)
if (status < 0 || status != in_len) { if (status < 0 || status != in_len) {
int save_error = errno; int save_error = errno;
WARN(aspi, "Not enough bytes written to scsi device bytes=%d .. %d\n", in_len, status); WARN("Not enough bytes written to scsi device bytes=%d .. %d\n", in_len, status);
if (status < 0) { if (status < 0) {
if (save_error == ENOMEM) { if (save_error == ENOMEM) {
MSG("ASPI: Linux generic scsi driver\n You probably need to re-compile your kernel with a larger SG_BIG_BUFF value (sg.h)\n Suggest 130560\n"); MESSAGE("ASPI: Linux generic scsi driver\n You probably need to re-compile your kernel with a larger SG_BIG_BUFF value (sg.h)\n Suggest 130560\n");
} }
#ifdef HAVE_STRERROR #ifdef HAVE_STRERROR
WARN(aspi, "error:= '%s'\n", strerror(save_error)); WARN("error:= '%s'\n", strerror(save_error));
#else #else
WARN(aspi, "error:= %d\n", save_error); WARN("error:= %d\n", save_error);
#endif #endif
} }
goto error_exit; goto error_exit;
@ -306,13 +306,13 @@ ASPI_ExecScsiCmd(DWORD ptrPRB, UINT16 mode)
status = read(fd, sg_reply_hdr, out_len); status = read(fd, sg_reply_hdr, out_len);
if (status < 0 || status != out_len) { if (status < 0 || status != out_len) {
WARN(aspi, "not enough bytes read from scsi device%d\n", status); WARN("not enough bytes read from scsi device%d\n", status);
goto error_exit; goto error_exit;
} }
if (sg_reply_hdr->result != 0) { if (sg_reply_hdr->result != 0) {
error_code = sg_reply_hdr->result; error_code = sg_reply_hdr->result;
WARN(aspi, "reply header error (%d)\n", sg_reply_hdr->result); WARN("reply header error (%d)\n", sg_reply_hdr->result);
goto error_exit; goto error_exit;
} }
@ -336,7 +336,7 @@ ASPI_ExecScsiCmd(DWORD ptrPRB, UINT16 mode)
/* now do posting */ /* now do posting */
if (ASPI_POSTING(lpPRB) && lpPRB->SRB_PostProc) { if (ASPI_POSTING(lpPRB) && lpPRB->SRB_PostProc) {
TRACE(aspi, "Post Routine (%lx) called\n", (DWORD) lpPRB->SRB_PostProc); TRACE("Post Routine (%lx) called\n", (DWORD) lpPRB->SRB_PostProc);
switch (mode) switch (mode)
{ {
case ASPI_DOS: case ASPI_DOS:
@ -361,17 +361,17 @@ ASPI_ExecScsiCmd(DWORD ptrPRB, UINT16 mode)
error_exit: error_exit:
if (error_code == EBUSY) { if (error_code == EBUSY) {
lpPRB->SRB_Status = SS_ASPI_IS_BUSY; lpPRB->SRB_Status = SS_ASPI_IS_BUSY;
TRACE(aspi, "Device busy\n"); TRACE("Device busy\n");
} }
else { else {
WARN(aspi, "Failed\n"); WARN("Failed\n");
lpPRB->SRB_Status = SS_ERR; lpPRB->SRB_Status = SS_ERR;
} }
/* I'm not sure exactly error codes work here /* I'm not sure exactly error codes work here
* We probably should set lpPRB->SRB_TargStat, SRB_HaStat ? * We probably should set lpPRB->SRB_TargStat, SRB_HaStat ?
*/ */
WARN(aspi, "error_exit\n"); WARN("error_exit\n");
free(sg_reply_hdr); free(sg_reply_hdr);
free(sg_hd); free(sg_hd);
return lpPRB->SRB_Status; return lpPRB->SRB_Status;
@ -386,7 +386,7 @@ error_exit:
WORD WINAPI GetASPISupportInfo16() WORD WINAPI GetASPISupportInfo16()
{ {
#ifdef linux #ifdef linux
TRACE(aspi, "GETASPISupportInfo16\n"); TRACE("GETASPISupportInfo16\n");
/* high byte SS_COMP - low byte number of host adapters */ /* high byte SS_COMP - low byte number of host adapters */
return ((SS_COMP << 8) | HA_Count); return ((SS_COMP << 8) | HA_Count);
#else #else
@ -425,7 +425,7 @@ DWORD ASPI_SendASPICommand(DWORD ptrSRB, UINT16 mode)
case SC_HA_INQUIRY: case SC_HA_INQUIRY:
lpSRB->inquiry.SRB_Status = SS_COMP; /* completed successfully */ lpSRB->inquiry.SRB_Status = SS_COMP; /* completed successfully */
if (lpSRB->inquiry.SRB_55AASignature == 0x55aa) { if (lpSRB->inquiry.SRB_55AASignature == 0x55aa) {
TRACE(aspi, "Extended request detected (Adaptec's ASPIxDOS).\nWe don't support it at the moment.\n"); TRACE("Extended request detected (Adaptec's ASPIxDOS).\nWe don't support it at the moment.\n");
} }
lpSRB->inquiry.SRB_ExtBufferSize = 0x2000; /* bogus value */ lpSRB->inquiry.SRB_ExtBufferSize = 0x2000; /* bogus value */
lpSRB->inquiry.HA_Count = HA_Count; lpSRB->inquiry.HA_Count = HA_Count;
@ -435,19 +435,19 @@ DWORD ASPI_SendASPICommand(DWORD ptrSRB, UINT16 mode)
adapter name */ adapter name */
memset(lpSRB->inquiry.HA_Unique, 0, 16); /* default HA_Unique content */ memset(lpSRB->inquiry.HA_Unique, 0, 16); /* default HA_Unique content */
lpSRB->inquiry.HA_Unique[6] = 0x02; /* Maximum Transfer Length (128K, Byte> 4-7) */ lpSRB->inquiry.HA_Unique[6] = 0x02; /* Maximum Transfer Length (128K, Byte> 4-7) */
FIXME(aspi, "ASPI: Partially implemented SC_HA_INQUIRY for adapter %d.\n", lpSRB->inquiry.SRB_HaId); FIXME("ASPI: Partially implemented SC_HA_INQUIRY for adapter %d.\n", lpSRB->inquiry.SRB_HaId);
return SS_COMP; return SS_COMP;
case SC_GET_DEV_TYPE: case SC_GET_DEV_TYPE:
FIXME(aspi, "Not implemented SC_GET_DEV_TYPE\n"); FIXME("Not implemented SC_GET_DEV_TYPE\n");
break; break;
case SC_EXEC_SCSI_CMD: case SC_EXEC_SCSI_CMD:
return ASPI_ExecScsiCmd((DWORD)ptrSRB, mode); return ASPI_ExecScsiCmd((DWORD)ptrSRB, mode);
break; break;
case SC_RESET_DEV: case SC_RESET_DEV:
FIXME(aspi, "Not implemented SC_RESET_DEV\n"); FIXME("Not implemented SC_RESET_DEV\n");
break; break;
default: default:
FIXME(aspi, "Unknown command %d\n", lpSRB->common.SRB_Cmd); FIXME("Unknown command %d\n", lpSRB->common.SRB_Cmd);
} }
#endif #endif
return SS_INVALID_SRB; return SS_INVALID_SRB;
@ -531,7 +531,7 @@ void ASPI_DOS_HandleInt(CONTEXT *context)
if ((CX_reg(context) == 4) || (CX_reg(context) == 5)) if ((CX_reg(context) == 4) || (CX_reg(context) == 5))
{ {
*p = DPMI_AllocInternalRMCB(ASPI_DOS_func); *p = DPMI_AllocInternalRMCB(ASPI_DOS_func);
TRACE(aspi, "allocated real mode proc %p\n", *p); TRACE("allocated real mode proc %p\n", *p);
AX_reg(context) = CX_reg(context); AX_reg(context) = CX_reg(context);
} }
else else

View file

@ -13,7 +13,7 @@
#include "wnaspi32.h" #include "wnaspi32.h"
#include "options.h" #include "options.h"
#include "heap.h" #include "heap.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(aspi) DEFAULT_DEBUG_CHANNEL(aspi)
@ -50,19 +50,19 @@ ASPI_OpenDevice(SRB_ExecSCSICmd *prb)
sprintf(idstr, "scsi c%1dt%1dd%1d", prb->SRB_HaId, prb->SRB_Target, prb->SRB_Lun); sprintf(idstr, "scsi c%1dt%1dd%1d", prb->SRB_HaId, prb->SRB_Target, prb->SRB_Lun);
if (!PROFILE_GetWineIniString(idstr, "Device", "", device_str, sizeof(device_str))) { if (!PROFILE_GetWineIniString(idstr, "Device", "", device_str, sizeof(device_str))) {
TRACE(aspi, "Trying to open unlisted scsi device %s\n", idstr); TRACE("Trying to open unlisted scsi device %s\n", idstr);
return -1; return -1;
} }
TRACE(aspi, "Opening device %s=%s\n", idstr, device_str); TRACE("Opening device %s=%s\n", idstr, device_str);
fd = open(device_str, O_RDWR); fd = open(device_str, O_RDWR);
if (fd == -1) { if (fd == -1) {
int save_error = errno; int save_error = errno;
#ifdef HAVE_STRERROR #ifdef HAVE_STRERROR
ERR(aspi, "Error opening device %s, error '%s'\n", device_str, strerror(save_error)); ERR("Error opening device %s, error '%s'\n", device_str, strerror(save_error));
#else #else
ERR(aspi, "Error opening device %s, error %d\n", device_str, save_error); ERR("Error opening device %s, error %d\n", device_str, save_error);
#endif #endif
return -1; return -1;
} }
@ -91,51 +91,51 @@ ASPI_DebugPrintCmd(SRB_ExecSCSICmd *prb)
switch (prb->CDBByte[0]) { switch (prb->CDBByte[0]) {
case CMD_INQUIRY: case CMD_INQUIRY:
TRACE(aspi, "{\n"); TRACE("{\n");
TRACE(aspi, "\tEVPD: %d\n", prb->CDBByte[1] & 1); TRACE("\tEVPD: %d\n", prb->CDBByte[1] & 1);
TRACE(aspi, "\tLUN: %d\n", (prb->CDBByte[1] & 0xc) >> 1); TRACE("\tLUN: %d\n", (prb->CDBByte[1] & 0xc) >> 1);
TRACE(aspi, "\tPAGE CODE: %d\n", prb->CDBByte[2]); TRACE("\tPAGE CODE: %d\n", prb->CDBByte[2]);
TRACE(aspi, "\tALLOCATION LENGTH: %d\n", prb->CDBByte[4]); TRACE("\tALLOCATION LENGTH: %d\n", prb->CDBByte[4]);
TRACE(aspi, "\tCONTROL: %d\n", prb->CDBByte[5]); TRACE("\tCONTROL: %d\n", prb->CDBByte[5]);
TRACE(aspi, "}\n"); TRACE("}\n");
break; break;
case CMD_SCAN_SCAN: case CMD_SCAN_SCAN:
TRACE(aspi, "Transfer Length: %d\n", prb->CDBByte[4]); TRACE("Transfer Length: %d\n", prb->CDBByte[4]);
break; break;
} }
TRACE(aspi, "Host Adapter: %d\n", prb->SRB_HaId); TRACE("Host Adapter: %d\n", prb->SRB_HaId);
TRACE(aspi, "Flags: %d\n", prb->SRB_Flags); TRACE("Flags: %d\n", prb->SRB_Flags);
if (TARGET_TO_HOST(prb)) { if (TARGET_TO_HOST(prb)) {
TRACE(aspi, "\tData transfer: Target to host. Length checked.\n"); TRACE("\tData transfer: Target to host. Length checked.\n");
} }
else if (HOST_TO_TARGET(prb)) { else if (HOST_TO_TARGET(prb)) {
TRACE(aspi, "\tData transfer: Host to target. Length checked.\n"); TRACE("\tData transfer: Host to target. Length checked.\n");
} }
else if (NO_DATA_TRANSFERED(prb)) { else if (NO_DATA_TRANSFERED(prb)) {
TRACE(aspi, "\tData transfer: none\n"); TRACE("\tData transfer: none\n");
} }
else { else {
WARN(aspi, "\tTransfer by scsi cmd. Length not checked.\n"); WARN("\tTransfer by scsi cmd. Length not checked.\n");
} }
TRACE(aspi, "\tResidual byte length reporting %s\n", prb->SRB_Flags & 0x4 ? "enabled" : "disabled"); TRACE("\tResidual byte length reporting %s\n", prb->SRB_Flags & 0x4 ? "enabled" : "disabled");
TRACE(aspi, "\tLinking %s\n", prb->SRB_Flags & 0x2 ? "enabled" : "disabled"); TRACE("\tLinking %s\n", prb->SRB_Flags & 0x2 ? "enabled" : "disabled");
TRACE(aspi, "\tPosting %s\n", prb->SRB_Flags & 0x1 ? "enabled" : "disabled"); TRACE("\tPosting %s\n", prb->SRB_Flags & 0x1 ? "enabled" : "disabled");
TRACE(aspi, "Target: %d\n", prb->SRB_Target); TRACE("Target: %d\n", prb->SRB_Target);
TRACE(aspi, "Lun: %d\n", prb->SRB_Lun); TRACE("Lun: %d\n", prb->SRB_Lun);
TRACE(aspi, "BufLen: %ld\n", prb->SRB_BufLen); TRACE("BufLen: %ld\n", prb->SRB_BufLen);
TRACE(aspi, "SenseLen: %d\n", prb->SRB_SenseLen); TRACE("SenseLen: %d\n", prb->SRB_SenseLen);
TRACE(aspi, "BufPtr: %p\n", prb->SRB_BufPointer); TRACE("BufPtr: %p\n", prb->SRB_BufPointer);
TRACE(aspi, "CDB Length: %d\n", prb->SRB_CDBLen); TRACE("CDB Length: %d\n", prb->SRB_CDBLen);
TRACE(aspi, "POST Proc: %lx\n", (DWORD) prb->SRB_PostProc); TRACE("POST Proc: %lx\n", (DWORD) prb->SRB_PostProc);
cdb = &prb->CDBByte[0]; cdb = &prb->CDBByte[0];
cmd = prb->CDBByte[0]; cmd = prb->CDBByte[0];
for (i = 0; i < prb->SRB_CDBLen; i++) { for (i = 0; i < prb->SRB_CDBLen; i++) {
if (i != 0) dsprintf(aspi, ","); if (i != 0) dsprintf(aspi, ",");
dsprintf(aspi, "%02x", *cdb++); dsprintf(aspi, "%02x", *cdb++);
} }
TRACE(aspi, "CDB buffer[%s]\n", dbg_str(aspi)); TRACE("CDB buffer[%s]\n", dbg_str(aspi));
} }
static void static void
@ -150,7 +150,7 @@ ASPI_PrintSenseArea(SRB_ExecSCSICmd *prb)
if (i) dsprintf(aspi, ","); if (i) dsprintf(aspi, ",");
dsprintf(aspi, "%02x", *cdb++); dsprintf(aspi, "%02x", *cdb++);
} }
TRACE(aspi, "SenseArea[%s]\n", dbg_str(aspi)); TRACE("SenseArea[%s]\n", dbg_str(aspi));
} }
static void static void
@ -159,7 +159,7 @@ ASPI_DebugPrintResult(SRB_ExecSCSICmd *prb)
switch (prb->CDBByte[0]) { switch (prb->CDBByte[0]) {
case CMD_INQUIRY: case CMD_INQUIRY:
TRACE(aspi, "Vendor: '%s'\n", prb->SRB_BufPointer + INQUIRY_VENDOR); TRACE("Vendor: '%s'\n", prb->SRB_BufPointer + INQUIRY_VENDOR);
break; break;
case CMD_TEST_UNIT_READY: case CMD_TEST_UNIT_READY:
ASPI_PrintSenseArea(prb); ASPI_PrintSenseArea(prb);
@ -180,7 +180,7 @@ ASPI_ExecScsiCmd(SRB_ExecSCSICmd *lpPRB)
fd = ASPI_OpenDevice(lpPRB); fd = ASPI_OpenDevice(lpPRB);
if (fd == -1) { if (fd == -1) {
ERR(aspi, "Failed: could not open device c%01dt%01dd%01d. Device permissions !?\n", ERR("Failed: could not open device c%01dt%01dd%01d. Device permissions !?\n",
lpPRB->SRB_HaId,lpPRB->SRB_Target,lpPRB->SRB_Lun); lpPRB->SRB_HaId,lpPRB->SRB_Target,lpPRB->SRB_Lun);
lpPRB->SRB_Status = SS_NO_DEVICE; lpPRB->SRB_Status = SS_NO_DEVICE;
return SS_NO_DEVICE; return SS_NO_DEVICE;
@ -192,7 +192,7 @@ ASPI_ExecScsiCmd(SRB_ExecSCSICmd *lpPRB)
lpPRB->SRB_Status = SS_PENDING; lpPRB->SRB_Status = SS_PENDING;
if (!lpPRB->SRB_CDBLen) { if (!lpPRB->SRB_CDBLen) {
WARN(aspi, "Failed: lpPRB->SRB_CDBLen = 0.\n"); WARN("Failed: lpPRB->SRB_CDBLen = 0.\n");
lpPRB->SRB_Status = SS_ERR; lpPRB->SRB_Status = SS_ERR;
return SS_ERR; return SS_ERR;
} }
@ -233,15 +233,15 @@ ASPI_ExecScsiCmd(SRB_ExecSCSICmd *lpPRB)
if (status < 0 || status != in_len) { if (status < 0 || status != in_len) {
int save_error = errno; int save_error = errno;
WARN(aspi, "Not enough bytes written to scsi device bytes=%d .. %d\n", in_len, status); WARN("Not enough bytes written to scsi device bytes=%d .. %d\n", in_len, status);
if (status < 0) { if (status < 0) {
if (save_error == ENOMEM) { if (save_error == ENOMEM) {
MSG("ASPI: Linux generic scsi driver\n You probably need to re-compile your kernel with a larger SG_BIG_BUFF value (sg.h)\n Suggest 130560\n"); MESSAGE("ASPI: Linux generic scsi driver\n You probably need to re-compile your kernel with a larger SG_BIG_BUFF value (sg.h)\n Suggest 130560\n");
} }
#ifdef HAVE_STRERROR #ifdef HAVE_STRERROR
WARN(aspi, "error:= '%s'\n", strerror(save_error)); WARN("error:= '%s'\n", strerror(save_error));
#else #else
WARN(aspi, "error:= %d\n", save_error); WARN("error:= %d\n", save_error);
#endif #endif
} }
goto error_exit; goto error_exit;
@ -249,13 +249,13 @@ ASPI_ExecScsiCmd(SRB_ExecSCSICmd *lpPRB)
status = read(fd, sg_reply_hdr, out_len); status = read(fd, sg_reply_hdr, out_len);
if (status < 0 || status != out_len) { if (status < 0 || status != out_len) {
WARN(aspi, "not enough bytes read from scsi device%d\n", status); WARN("not enough bytes read from scsi device%d\n", status);
goto error_exit; goto error_exit;
} }
if (sg_reply_hdr->result != 0) { if (sg_reply_hdr->result != 0) {
error_code = sg_reply_hdr->result; error_code = sg_reply_hdr->result;
WARN(aspi, "reply header error (%d)\n", sg_reply_hdr->result); WARN("reply header error (%d)\n", sg_reply_hdr->result);
goto error_exit; goto error_exit;
} }
@ -280,12 +280,12 @@ ASPI_ExecScsiCmd(SRB_ExecSCSICmd *lpPRB)
if (lpPRB->SRB_PostProc) { if (lpPRB->SRB_PostProc) {
if (ASPI_POSTING(lpPRB)) { if (ASPI_POSTING(lpPRB)) {
TRACE(aspi, "Post Routine (%lx) called\n", (DWORD) lpPRB->SRB_PostProc); TRACE("Post Routine (%lx) called\n", (DWORD) lpPRB->SRB_PostProc);
(*lpPRB->SRB_PostProc)(lpPRB); (*lpPRB->SRB_PostProc)(lpPRB);
} }
else else
if (lpPRB->SRB_Flags & SRB_EVENT_NOTIFY) { if (lpPRB->SRB_Flags & SRB_EVENT_NOTIFY) {
TRACE(aspi, "Setting event %04x\n", (HANDLE)lpPRB->SRB_PostProc); TRACE("Setting event %04x\n", (HANDLE)lpPRB->SRB_PostProc);
SetEvent((HANDLE)lpPRB->SRB_PostProc); /* FIXME: correct ? */ SetEvent((HANDLE)lpPRB->SRB_PostProc); /* FIXME: correct ? */
} }
} }
@ -297,17 +297,17 @@ ASPI_ExecScsiCmd(SRB_ExecSCSICmd *lpPRB)
error_exit: error_exit:
if (error_code == EBUSY) { if (error_code == EBUSY) {
lpPRB->SRB_Status = SS_ASPI_IS_BUSY; lpPRB->SRB_Status = SS_ASPI_IS_BUSY;
TRACE(aspi, "Device busy\n"); TRACE("Device busy\n");
} }
else { else {
WARN(aspi, "Failed\n"); WARN("Failed\n");
lpPRB->SRB_Status = SS_ERR; lpPRB->SRB_Status = SS_ERR;
} }
/* I'm not sure exactly error codes work here /* I'm not sure exactly error codes work here
* We probably should set lpPRB->SRB_TargStat, SRB_HaStat ? * We probably should set lpPRB->SRB_TargStat, SRB_HaStat ?
*/ */
WARN(aspi, "error_exit\n"); WARN("error_exit\n");
free(sg_reply_hdr); free(sg_reply_hdr);
free(sg_hd); free(sg_hd);
return lpPRB->SRB_Status; return lpPRB->SRB_Status;
@ -346,19 +346,19 @@ DWORD __cdecl SendASPI32Command(LPSRB lpSRB)
strcat(lpSRB->inquiry.HA_Identifier, "Wine host"); /* FIXME: return host adapter name */ strcat(lpSRB->inquiry.HA_Identifier, "Wine host"); /* FIXME: return host adapter name */
memset(lpSRB->inquiry.HA_Unique, 0, 16); /* default HA_Unique content */ memset(lpSRB->inquiry.HA_Unique, 0, 16); /* default HA_Unique content */
lpSRB->inquiry.HA_Unique[6] = 0x02; /* Maximum Transfer Length (128K, Byte> 4-7) */ lpSRB->inquiry.HA_Unique[6] = 0x02; /* Maximum Transfer Length (128K, Byte> 4-7) */
FIXME(aspi, "ASPI: Partially implemented SC_HA_INQUIRY for adapter %d.\n", lpSRB->inquiry.SRB_HaId); FIXME("ASPI: Partially implemented SC_HA_INQUIRY for adapter %d.\n", lpSRB->inquiry.SRB_HaId);
return SS_COMP; return SS_COMP;
case SC_GET_DEV_TYPE: case SC_GET_DEV_TYPE:
FIXME(aspi, "Not implemented SC_GET_DEV_TYPE\n"); FIXME("Not implemented SC_GET_DEV_TYPE\n");
break; break;
case SC_EXEC_SCSI_CMD: case SC_EXEC_SCSI_CMD:
return ASPI_ExecScsiCmd(&lpSRB->cmd); return ASPI_ExecScsiCmd(&lpSRB->cmd);
break; break;
case SC_RESET_DEV: case SC_RESET_DEV:
FIXME(aspi, "Not implemented SC_RESET_DEV\n"); FIXME("Not implemented SC_RESET_DEV\n");
break; break;
default: default:
WARN(aspi, "Unknown command %d\n", lpSRB->common.SRB_Cmd); WARN("Unknown command %d\n", lpSRB->common.SRB_Cmd);
} }
return SS_INVALID_SRB; return SS_INVALID_SRB;
#else #else

View file

@ -21,7 +21,7 @@
#include "process.h" #include "process.h"
#include "snoop.h" #include "snoop.h"
#include "task.h" #include "task.h"
#include "debug.h" #include "debugtools.h"
#include "toolhelp.h" #include "toolhelp.h"
DEFAULT_DEBUG_CHANNEL(module) DEFAULT_DEBUG_CHANNEL(module)
@ -165,7 +165,7 @@ static HMODULE16 BUILTIN_DoLoadModule16( const WIN16_DESCRIPTOR *descr )
if (!hModule) return 0; if (!hModule) return 0;
FarSetOwner16( hModule, hModule ); FarSetOwner16( hModule, hModule );
TRACE(module, "Built-in %s: hmodule=%04x\n", TRACE("Built-in %s: hmodule=%04x\n",
descr->name, hModule ); descr->name, hModule );
pModule = (NE_MODULE *)GlobalLock16( hModule ); pModule = (NE_MODULE *)GlobalLock16( hModule );
pModule->self = hModule; pModule->self = hModule;

View file

@ -3,53 +3,53 @@
*/ */
#include "windef.h" #include "windef.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(relay) DEFAULT_DEBUG_CHANNEL(relay)
long WINAPI stub_GDI_379(HDC16 hdc) { FIXME(relay, "STARTPAGE: stub\n"); return 1; } long WINAPI stub_GDI_379(HDC16 hdc) { FIXME("STARTPAGE: stub\n"); return 1; }
long WINAPI stub_GDI_381(HDC16 hdc, SEGPTR proc) { FIXME(relay, "SETABORTPROC: stub\n"); return 1; } long WINAPI stub_GDI_381(HDC16 hdc, SEGPTR proc) { FIXME("SETABORTPROC: stub\n"); return 1; }
long WINAPI stub_GDI_382(void) { FIXME(relay, "ABORTPROC: stub\n"); return 1; } long WINAPI stub_GDI_382(void) { FIXME("ABORTPROC: stub\n"); return 1; }
long WINAPI stub_GDI_530(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_GDI_530(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_GDI_531(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_GDI_531(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_GDI_532(LPINT16 buffer, INT16 xx) { long WINAPI stub_GDI_532(LPINT16 buffer, INT16 xx) {
FIXME(relay, "(%p, %hd): stub\n",buffer,xx); FIXME("(%p, %hd): stub\n",buffer,xx);
return 0; return 0;
} }
long WINAPI stub_GDI_536(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_GDI_536(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_GDI_538(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_GDI_538(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_GDI_540(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_GDI_540(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_GDI_543(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_GDI_543(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_GDI_555(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_GDI_555(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_GDI_560(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_GDI_560(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_GDI_561(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_GDI_561(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_GDI_564(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_GDI_564(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_GDI_565(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_GDI_565(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_GDI_566(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_GDI_566(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_GDI_571(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_GDI_571(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_GDI_572(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_GDI_572(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_GDI_573(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_GDI_573(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_GDI_556(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_GDI_556(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_GDI_558(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_GDI_558(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_GDI_569(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_GDI_569(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_USER_489(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_USER_489(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_USER_490(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_USER_490(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_USER_492(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_USER_492(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_USER_496(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_USER_496(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_USER_902(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_USER_902(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_USER_905(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_USER_905(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_USER_906(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_USER_906(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_USER_907(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_USER_907(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_USER_909(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_USER_909(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_USER_910(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_USER_910(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_USER_911(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_USER_911(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_USER_912(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_USER_912(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_USER_913(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_USER_913(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_USER_914(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_USER_914(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_USER_915(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_USER_915(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_USER_916(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_USER_916(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_USER_918(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_USER_918(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_USER_919(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_USER_919(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_USER_920(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_USER_920(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_USER_922(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_USER_922(void) { FIXME("stub\n"); return 0; }
long WINAPI stub_USER_923(void) { FIXME(relay, "stub\n"); return 0; } long WINAPI stub_USER_923(void) { FIXME("stub\n"); return 0; }

View file

@ -14,7 +14,7 @@
#include "stackframe.h" #include "stackframe.h"
#include "task.h" #include "task.h"
#include "debugstr.h" #include "debugstr.h"
#include "debug.h" #include "debugtools.h"
#include "main.h" #include "main.h"
DEFAULT_DEBUG_CHANNEL(relay) DEFAULT_DEBUG_CHANNEL(relay)
@ -243,7 +243,7 @@ void RELAY_Unimplemented16(void)
{ {
WORD ordinal; WORD ordinal;
STACK16FRAME *frame = CURRENT_STACK16; STACK16FRAME *frame = CURRENT_STACK16;
MSG("No handler for Win16 routine %s (called from %04x:%04x)\n", MESSAGE("No handler for Win16 routine %s (called from %04x:%04x)\n",
BUILTIN_GetEntryPoint16(frame->entry_cs,frame->entry_ip,&ordinal), BUILTIN_GetEntryPoint16(frame->entry_cs,frame->entry_ip,&ordinal),
frame->cs, frame->ip ); frame->cs, frame->ip );
ExitProcess(1); ExitProcess(1);
@ -413,7 +413,7 @@ void WINAPI Throw16( CONTEXT *context )
DS_reg(context) = lpbuf[6]; DS_reg(context) = lpbuf[6];
if (lpbuf[8] != SS_reg(context)) if (lpbuf[8] != SS_reg(context))
ERR(relay, "Switching stack segment with Throw() not supported; expect crash now\n" ); ERR("Switching stack segment with Throw() not supported; expect crash now\n" );
if (TRACE_ON(relay)) /* Make sure we have a valid entry point address */ if (TRACE_ON(relay)) /* Make sure we have a valid entry point address */
{ {
@ -502,7 +502,7 @@ static DWORD RELAY_CallProc32W(int Ex)
break; break;
default: default:
/* FIXME: should go up to 32 arguments */ /* FIXME: should go up to 32 arguments */
ERR(relay,"Unsupported number of arguments %ld, please report.\n",nrofargs); ERR("Unsupported number of arguments %ld, please report.\n",nrofargs);
ret = 0; ret = 0;
break; break;
} }
@ -510,7 +510,7 @@ static DWORD RELAY_CallProc32W(int Ex)
if (!Ex) STACK16_POP( THREAD_Current(), if (!Ex) STACK16_POP( THREAD_Current(),
(3 + nrofargs) * sizeof(DWORD) ); (3 + nrofargs) * sizeof(DWORD) );
TRACE(relay,"%s - returns %08lx\n",dbg_str(relay),ret); TRACE("%s - returns %08lx\n",dbg_str(relay),ret);
HeapFree( GetProcessHeap(), 0, args ); HeapFree( GetProcessHeap(), 0, args );
SYSLEVEL_RestoreWin16Lock(); SYSLEVEL_RestoreWin16Lock();

View file

@ -14,7 +14,7 @@
#include "stackframe.h" #include "stackframe.h"
#include "snoop.h" #include "snoop.h"
#include "debugstr.h" #include "debugstr.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(snoop) DEFAULT_DEBUG_CHANNEL(snoop)
@ -130,7 +130,7 @@ SNOOP16_RegisterDLL(NE_MODULE *pModule,LPCSTR name) {
(*dll)->funs = GlobalLock16((*dll)->funhandle); (*dll)->funs = GlobalLock16((*dll)->funhandle);
if (!(*dll)->funs) { if (!(*dll)->funs) {
HeapFree(SystemHeap,0,*dll); HeapFree(SystemHeap,0,*dll);
FIXME(snoop,"out of memory\n"); FIXME("out of memory\n");
return; return;
} }
memset((*dll)->funs,0,65535); memset((*dll)->funs,0,65535);
@ -228,7 +228,7 @@ void WINAPI SNOOP16_Entry(CONTEXT *context) {
dll=dll->next; dll=dll->next;
} }
if (!dll) { if (!dll) {
FIXME(snoop,"entrypoint 0x%08lx not found\n",entry); FIXME("entrypoint 0x%08lx not found\n",entry);
return; /* oops */ return; /* oops */
} }
while (*rets) { while (*rets) {
@ -317,7 +317,7 @@ void WINAPI SNOOP16_Return(CONTEXT *context) {
} }
#else /* !__i386__ */ #else /* !__i386__ */
void SNOOP16_RegisterDLL(NE_MODULE *pModule,LPCSTR name) { void SNOOP16_RegisterDLL(NE_MODULE *pModule,LPCSTR name) {
FIXME(snoop,"snooping works only on i386 for now.\n"); FIXME("snooping works only on i386 for now.\n");
return; return;
} }

View file

@ -28,7 +28,7 @@
#include "ldt.h" #include "ldt.h"
#include "process.h" #include "process.h"
#include "miscemu.h" #include "miscemu.h"
#include "debug.h" #include "debugtools.h"
#include "dosexe.h" #include "dosexe.h"
#include "dosmod.h" #include "dosmod.h"
#include "options.h" #include "options.h"
@ -194,7 +194,7 @@ static BOOL MZ_InitMemory( LPDOSTASK lpDosTask, NE_MODULE *pModule )
tmpnam(lpDosTask->mm_name); tmpnam(lpDosTask->mm_name);
/* strcpy(lpDosTask->mm_name,"/tmp/mydosimage"); */ /* strcpy(lpDosTask->mm_name,"/tmp/mydosimage"); */
lpDosTask->mm_fd=open(lpDosTask->mm_name,O_RDWR|O_CREAT /* |O_TRUNC */,S_IRUSR|S_IWUSR); lpDosTask->mm_fd=open(lpDosTask->mm_name,O_RDWR|O_CREAT /* |O_TRUNC */,S_IRUSR|S_IWUSR);
if (lpDosTask->mm_fd<0) ERR(module,"file %s could not be opened\n",lpDosTask->mm_name); if (lpDosTask->mm_fd<0) ERR("file %s could not be opened\n",lpDosTask->mm_name);
/* expand file to 1MB+64K */ /* expand file to 1MB+64K */
lseek(lpDosTask->mm_fd,0x110000-1,SEEK_SET); lseek(lpDosTask->mm_fd,0x110000-1,SEEK_SET);
x=0; write(lpDosTask->mm_fd,&x,1); x=0; write(lpDosTask->mm_fd,&x,1);
@ -202,14 +202,14 @@ static BOOL MZ_InitMemory( LPDOSTASK lpDosTask, NE_MODULE *pModule )
lpDosTask->img=mmap(NULL,0x110000-START_OFFSET,PROT_READ|PROT_WRITE,MAP_SHARED,lpDosTask->mm_fd,0); lpDosTask->img=mmap(NULL,0x110000-START_OFFSET,PROT_READ|PROT_WRITE,MAP_SHARED,lpDosTask->mm_fd,0);
#endif #endif
if (lpDosTask->img==(LPVOID)-1) { if (lpDosTask->img==(LPVOID)-1) {
ERR(module,"could not map shared memory, error=%s\n",strerror(errno)); ERR("could not map shared memory, error=%s\n",strerror(errno));
return FALSE; return FALSE;
} }
TRACE(module,"DOS VM86 image mapped at %08lx\n",(DWORD)lpDosTask->img); TRACE("DOS VM86 image mapped at %08lx\n",(DWORD)lpDosTask->img);
pModule->dos_image=lpDosTask->img; pModule->dos_image=lpDosTask->img;
/* initialize the memory */ /* initialize the memory */
TRACE(module,"Initializing DOS memory structures\n"); TRACE("Initializing DOS memory structures\n");
DOSMEM_Init(lpDosTask->hModule); DOSMEM_Init(lpDosTask->hModule);
MZ_InitHandlers(lpDosTask); MZ_InitHandlers(lpDosTask);
MZ_InitXMS(lpDosTask); MZ_InitXMS(lpDosTask);
@ -253,17 +253,17 @@ static BOOL MZ_LoadImage( HFILE hFile, OFSTRUCT *ofs, LPCSTR cmdline,
env_seg=MZ_InitEnvironment(lpDosTask,env,ofs->szPathName); env_seg=MZ_InitEnvironment(lpDosTask,env,ofs->szPathName);
/* allocate memory for the executable */ /* allocate memory for the executable */
TRACE(module,"Allocating DOS memory (min=%ld, max=%ld)\n",min_size,max_size); TRACE("Allocating DOS memory (min=%ld, max=%ld)\n",min_size,max_size);
avail=DOSMEM_Available(lpDosTask->hModule); avail=DOSMEM_Available(lpDosTask->hModule);
if (avail<min_size) { if (avail<min_size) {
ERR(module, "insufficient DOS memory\n"); ERR("insufficient DOS memory\n");
SetLastError(ERROR_NOT_ENOUGH_MEMORY); SetLastError(ERROR_NOT_ENOUGH_MEMORY);
return FALSE; return FALSE;
} }
if (avail>max_size) avail=max_size; if (avail>max_size) avail=max_size;
psp_start=DOSMEM_GetBlock(lpDosTask->hModule,avail,&lpDosTask->psp_seg); psp_start=DOSMEM_GetBlock(lpDosTask->hModule,avail,&lpDosTask->psp_seg);
if (!psp_start) { if (!psp_start) {
ERR(module, "error allocating DOS memory\n"); ERR("error allocating DOS memory\n");
SetLastError(ERROR_NOT_ENOUGH_MEMORY); SetLastError(ERROR_NOT_ENOUGH_MEMORY);
return FALSE; return FALSE;
} }
@ -272,7 +272,7 @@ static BOOL MZ_LoadImage( HFILE hFile, OFSTRUCT *ofs, LPCSTR cmdline,
MZ_InitPSP(psp_start, cmdline, env_seg); MZ_InitPSP(psp_start, cmdline, env_seg);
/* load executable image */ /* load executable image */
TRACE(module,"loading DOS %s image, %08lx bytes\n",old_com?"COM":"EXE",image_size); TRACE("loading DOS %s image, %08lx bytes\n",old_com?"COM":"EXE",image_size);
_llseek(hFile,image_start,FILE_BEGIN); _llseek(hFile,image_start,FILE_BEGIN);
if ((_lread(hFile,load_start,image_size)) != image_size) { if ((_lread(hFile,load_start,image_size)) != image_size) {
SetLastError(ERROR_BAD_FORMAT); SetLastError(ERROR_BAD_FORMAT);
@ -281,7 +281,7 @@ static BOOL MZ_LoadImage( HFILE hFile, OFSTRUCT *ofs, LPCSTR cmdline,
if (mz_header.e_crlc) { if (mz_header.e_crlc) {
/* load relocation table */ /* load relocation table */
TRACE(module,"loading DOS EXE relocation table, %d entries\n",mz_header.e_crlc); TRACE("loading DOS EXE relocation table, %d entries\n",mz_header.e_crlc);
/* FIXME: is this too slow without read buffering? */ /* FIXME: is this too slow without read buffering? */
_llseek(hFile,mz_header.e_lfarlc,FILE_BEGIN); _llseek(hFile,mz_header.e_lfarlc,FILE_BEGIN);
for (x=0; x<mz_header.e_crlc; x++) { for (x=0; x<mz_header.e_crlc; x++) {
@ -298,7 +298,7 @@ static BOOL MZ_LoadImage( HFILE hFile, OFSTRUCT *ofs, LPCSTR cmdline,
lpDosTask->init_ss=lpDosTask->load_seg+mz_header.e_ss; lpDosTask->init_ss=lpDosTask->load_seg+mz_header.e_ss;
lpDosTask->init_sp=mz_header.e_sp; lpDosTask->init_sp=mz_header.e_sp;
TRACE(module,"entry point: %04x:%04x\n",lpDosTask->init_cs,lpDosTask->init_ip); TRACE("entry point: %04x:%04x\n",lpDosTask->init_cs,lpDosTask->init_ip);
return TRUE; return TRUE;
} }
@ -364,9 +364,9 @@ BOOL MZ_InitTask( LPDOSTASK lpDosTask )
CLIENT_SendRequest( REQ_GET_WRITE_FD, -1, 1, &w_req, sizeof(w_req) ); CLIENT_SendRequest( REQ_GET_WRITE_FD, -1, 1, &w_req, sizeof(w_req) );
CLIENT_WaitReply( NULL, &x_fd, 0 ); CLIENT_WaitReply( NULL, &x_fd, 0 );
TRACE(module,"win32 pipe: read=%d, write=%d, unix pipe: read=%d, write=%d\n", TRACE("win32 pipe: read=%d, write=%d, unix pipe: read=%d, write=%d\n",
lpDosTask->hReadPipe,lpDosTask->hXPipe,lpDosTask->read_pipe,x_fd); lpDosTask->hReadPipe,lpDosTask->hXPipe,lpDosTask->read_pipe,x_fd);
TRACE(module,"outbound unix pipe: read=%d, write=%d, pid=%d\n",write_fd[0],write_fd[1],getpid()); TRACE("outbound unix pipe: read=%d, write=%d, pid=%d\n",write_fd[0],write_fd[1],getpid());
lpDosTask->write_pipe=write_fd[1]; lpDosTask->write_pipe=write_fd[1];
@ -382,7 +382,7 @@ BOOL MZ_InitTask( LPDOSTASK lpDosTask )
fname=fproc; farg=arg; fname=fproc; farg=arg;
} }
TRACE(module,"Loading DOS VM support module (hmodule=%04x)\n",lpDosTask->hModule); TRACE("Loading DOS VM support module (hmodule=%04x)\n",lpDosTask->hModule);
if ((child=fork())<0) { if ((child=fork())<0) {
close(write_fd[0]); close(write_fd[0]);
close(lpDosTask->read_pipe); close(lpDosTask->read_pipe);
@ -404,7 +404,7 @@ BOOL MZ_InitTask( LPDOSTASK lpDosTask )
if (read(lpDosTask->read_pipe,&ret,sizeof(ret))==sizeof(ret)) break; if (read(lpDosTask->read_pipe,&ret,sizeof(ret))==sizeof(ret)) break;
if ((errno==EINTR)||(errno==EAGAIN)) continue; if ((errno==EINTR)||(errno==EAGAIN)) continue;
/* failure */ /* failure */
ERR(module,"dosmod has failed to initialize\n"); ERR("dosmod has failed to initialize\n");
if (lpDosTask->mm_name[0]!=0) unlink(lpDosTask->mm_name); if (lpDosTask->mm_name[0]!=0) unlink(lpDosTask->mm_name);
return FALSE; return FALSE;
} }
@ -414,8 +414,8 @@ BOOL MZ_InitTask( LPDOSTASK lpDosTask )
/* start simulated system timer */ /* start simulated system timer */
MZ_InitTimer(lpDosTask,ret); MZ_InitTimer(lpDosTask,ret);
if (ret<2) { if (ret<2) {
ERR(module,"dosmod version too old! Please install newer dosmod properly\n"); ERR("dosmod version too old! Please install newer dosmod properly\n");
ERR(module,"If you don't, the new dosmod event handling system will not work\n"); ERR("If you don't, the new dosmod event handling system will not work\n");
} }
/* all systems are now go */ /* all systems are now go */
} else { } else {
@ -444,7 +444,7 @@ BOOL MZ_InitTask( LPDOSTASK lpDosTask )
/* and, just for completeness... */ /* and, just for completeness... */
execl("loader/dos/dosmod",fname,farg,NULL); execl("loader/dos/dosmod",fname,farg,NULL);
/* if failure, exit */ /* if failure, exit */
ERR(module,"Failed to spawn dosmod, error=%s\n",strerror(errno)); ERR("Failed to spawn dosmod, error=%s\n",strerror(errno));
exit(1); exit(1);
} }
return TRUE; return TRUE;
@ -512,7 +512,7 @@ void MZ_KillModule( LPDOSTASK lpDosTask )
DOSEVENT *event,*p_event; DOSEVENT *event,*p_event;
DOSSYSTEM *sys,*p_sys; DOSSYSTEM *sys,*p_sys;
TRACE(module,"killing DOS task\n"); TRACE("killing DOS task\n");
if (lpDosTask->mm_name[0]!=0) { if (lpDosTask->mm_name[0]!=0) {
munmap(lpDosTask->img,0x110000-START_OFFSET); munmap(lpDosTask->img,0x110000-START_OFFSET);
close(lpDosTask->mm_fd); close(lpDosTask->mm_fd);
@ -563,7 +563,7 @@ BOOL MZ_CreateProcess( HFILE hFile, OFSTRUCT *ofs, LPCSTR cmdline, LPCSTR env,
BOOL inherit, DWORD flags, LPSTARTUPINFOA startup, BOOL inherit, DWORD flags, LPSTARTUPINFOA startup,
LPPROCESS_INFORMATION info ) LPPROCESS_INFORMATION info )
{ {
WARN(module,"DOS executables not supported on this architecture\n"); WARN("DOS executables not supported on this architecture\n");
SetLastError(ERROR_BAD_FORMAT); SetLastError(ERROR_BAD_FORMAT);
return FALSE; return FALSE;
} }

View file

@ -23,7 +23,7 @@
#include "heap.h" #include "heap.h"
#include "module.h" #include "module.h"
#include "pe_image.h" #include "pe_image.h"
#include "debug.h" #include "debugtools.h"
#include "winerror.h" #include "winerror.h"
#include "elfdll.h" #include "elfdll.h"
@ -162,7 +162,7 @@ FARPROC ELF_FindExportedFunction( WINE_MODREF *wm, LPCSTR funcName)
assert(wm->type == MODULE32_ELF); assert(wm->type == MODULE32_ELF);
if (!HIWORD(funcName)) { if (!HIWORD(funcName)) {
ERR(win32,"Can't import from UNIX dynamic libs by ordinal, sorry.\n"); ERR("Can't import from UNIX dynamic libs by ordinal, sorry.\n");
return (FARPROC)0; return (FARPROC)0;
} }
fun = dlsym(wm->binfmt.elf.dlhandle,funcName); fun = dlsym(wm->binfmt.elf.dlhandle,funcName);
@ -204,7 +204,7 @@ FARPROC ELF_FindExportedFunction( WINE_MODREF *wm, LPCSTR funcName)
stub++; stub++;
} }
if (i==STUBSIZE/sizeof(ELF_STDCALL_STUB)) { if (i==STUBSIZE/sizeof(ELF_STDCALL_STUB)) {
ERR(win32,"please report, that there are not enough slots for stdcall stubs in the ELF loader.\n"); ERR("please report, that there are not enough slots for stdcall stubs in the ELF loader.\n");
assert(i<STUBSIZE/sizeof(ELF_STDCALL_STUB)); assert(i<STUBSIZE/sizeof(ELF_STDCALL_STUB));
} }
if (!stub->origfun) if (!stub->origfun)
@ -247,7 +247,7 @@ FARPROC ELF_FindExportedFunction( WINE_MODREF *wm, LPCSTR funcName)
fun=(FARPROC)stub; fun=(FARPROC)stub;
} }
if (!fun) { if (!fun) {
FIXME(win32,"function %s not found: %s\n",funcName,dlerror()); FIXME("function %s not found: %s\n",funcName,dlerror());
return fun; return fun;
} }
fun = SNOOP_GetProcAddress(wm->module,funcName,stub-wm->binfmt.elf.stubs,fun); fun = SNOOP_GetProcAddress(wm->module,funcName,stub-wm->binfmt.elf.stubs,fun);

View file

@ -8,7 +8,7 @@
#include "wine/winestring.h" #include "wine/winestring.h"
#include "libres.h" #include "libres.h"
#include "resource.h" #include "resource.h"
#include "debug.h" #include "debugtools.h"
#include "heap.h" #include "heap.h"
#include "xmalloc.h" #include "xmalloc.h"
@ -67,7 +67,7 @@ HRSRC LIBRES_FindResource( HINSTANCE hModule, LPCWSTR name, LPCWSTR type )
} }
else else
{ {
TRACE(resource, "(*,*,type=string): Returning 0\n"); TRACE("(*,*,type=string): Returning 0\n");
return 0; return 0;
} }
} }

View file

@ -16,7 +16,7 @@
#include "options.h" #include "options.h"
#include "module.h" #include "module.h"
#include "elfdll.h" #include "elfdll.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(module) DEFAULT_DEBUG_CHANNEL(module)
@ -130,7 +130,7 @@ static BOOL ParseLoadOrder(char *order, module_loadorder_t *mlo)
if(n >= MODULE_LOADORDER_NTYPES) if(n >= MODULE_LOADORDER_NTYPES)
{ {
ERR(module, "More than existing %d module-types specified, rest ignored", MODULE_LOADORDER_NTYPES); ERR("More than existing %d module-types specified, rest ignored", MODULE_LOADORDER_NTYPES);
break; break;
} }
@ -149,7 +149,7 @@ static BOOL ParseLoadOrder(char *order, module_loadorder_t *mlo)
case 'b': type = MODULE_LOADORDER_BI; break; case 'b': type = MODULE_LOADORDER_BI; break;
default: default:
ERR(module, "Invalid load order module-type '%s', ignored\n", cptr); ERR("Invalid load order module-type '%s', ignored\n", cptr);
} }
if(type != MODULE_LOADORDER_INVALID) if(type != MODULE_LOADORDER_INVALID)
@ -179,7 +179,7 @@ static BOOL AddLoadOrder(module_loadorder_t *plo, BOOL override)
if(!cmp_sort_func(plo, &module_loadorder[i])) if(!cmp_sort_func(plo, &module_loadorder[i]))
{ {
if(!override) if(!override)
ERR(module, "Module '%s' is already in the list of overrides, using first definition\n", plo->modulename); ERR("Module '%s' is already in the list of overrides, using first definition\n", plo->modulename);
else else
memcpy(module_loadorder[i].loadorder, plo->loadorder, sizeof(plo->loadorder)); memcpy(module_loadorder[i].loadorder, plo->loadorder, sizeof(plo->loadorder));
return TRUE; return TRUE;
@ -196,7 +196,7 @@ static BOOL AddLoadOrder(module_loadorder_t *plo, BOOL override)
nmodule_loadorder_alloc * sizeof(module_loadorder_t)); nmodule_loadorder_alloc * sizeof(module_loadorder_t));
if(!module_loadorder) if(!module_loadorder)
{ {
MSG("Virtual memory exhausted\n"); MESSAGE("Virtual memory exhausted\n");
exit(1); exit(1);
} }
} }
@ -230,7 +230,7 @@ static BOOL AddLoadOrderSet(char *key, char *order, BOOL override)
if(ext) if(ext)
{ {
if(strlen(ext) == 4 && (!strcasecmp(ext, ".dll") || !strcasecmp(ext, ".exe"))) if(strlen(ext) == 4 && (!strcasecmp(ext, ".dll") || !strcasecmp(ext, ".exe")))
MSG("Warning: Loadorder override '%s' contains an extension and might not be found during lookup\n", cptr); MESSAGE("Warning: Loadorder override '%s' contains an extension and might not be found during lookup\n", cptr);
} }
ldo.modulename = cptr; ldo.modulename = cptr;
@ -279,7 +279,7 @@ static BOOL ParseCommandlineOverrides(void)
*value = '\0'; *value = '\0';
value++; value++;
TRACE(module, "Commandline override '%s' = '%s'\n", key, value); TRACE("Commandline override '%s' = '%s'\n", key, value);
if(!AddLoadOrderSet(key, value, TRUE)) if(!AddLoadOrderSet(key, value, TRUE))
{ {
@ -373,7 +373,7 @@ BOOL MODULE_InitLoadOrder(void)
if(nbuffer) if(nbuffer)
{ {
extra_ld_library_path = HEAP_strdupA(SystemHeap, 0, buffer); extra_ld_library_path = HEAP_strdupA(SystemHeap, 0, buffer);
TRACE(module, "Setting extra LD_LIBRARY_PATH=%s\n", buffer); TRACE("Setting extra LD_LIBRARY_PATH=%s\n", buffer);
} }
#endif #endif
@ -381,11 +381,11 @@ BOOL MODULE_InitLoadOrder(void)
nbuffer = PROFILE_GetWineIniString("DllDefaults", "DefaultLoadOrder", "n,e,s,b", buffer, sizeof(buffer)); nbuffer = PROFILE_GetWineIniString("DllDefaults", "DefaultLoadOrder", "n,e,s,b", buffer, sizeof(buffer));
if(!nbuffer) if(!nbuffer)
{ {
MSG("MODULE_InitLoadOrder: misteriously read nothing from default loadorder\n"); MESSAGE("MODULE_InitLoadOrder: misteriously read nothing from default loadorder\n");
return FALSE; return FALSE;
} }
TRACE(module, "Setting default loadorder=%s\n", buffer); TRACE("Setting default loadorder=%s\n", buffer);
if(!ParseLoadOrder(buffer, &default_loadorder)) if(!ParseLoadOrder(buffer, &default_loadorder))
return FALSE; return FALSE;
@ -405,7 +405,7 @@ BOOL MODULE_InitLoadOrder(void)
nbuffer = PROFILE_GetWineIniString("DllOverrides", NULL, "", buffer, sizeof(buffer)); nbuffer = PROFILE_GetWineIniString("DllOverrides", NULL, "", buffer, sizeof(buffer));
if(nbuffer == BUFFERSIZE-2) if(nbuffer == BUFFERSIZE-2)
{ {
ERR(module, "BUFFERSIZE %d is too small to read [DllOverrides]. Needs to grow in the source\n", BUFFERSIZE); ERR("BUFFERSIZE %d is too small to read [DllOverrides]. Needs to grow in the source\n", BUFFERSIZE);
return FALSE; return FALSE;
} }
if(nbuffer) if(nbuffer)
@ -422,16 +422,16 @@ BOOL MODULE_InitLoadOrder(void)
nbuffer = PROFILE_GetWineIniString("DllOverrides", key, "", value, sizeof(value)); nbuffer = PROFILE_GetWineIniString("DllOverrides", key, "", value, sizeof(value));
if(!nbuffer) if(!nbuffer)
{ {
ERR(module, "Module(s) '%s' will always fail to load. Are you sure you want this?\n", key); ERR("Module(s) '%s' will always fail to load. Are you sure you want this?\n", key);
value[0] = '\0'; /* Just in case */ value[0] = '\0'; /* Just in case */
} }
if(nbuffer == BUFFERSIZE-2) if(nbuffer == BUFFERSIZE-2)
{ {
ERR(module, "BUFFERSIZE %d is too small to read [DllOverrides] key '%s'. Needs to grow in the source\n", BUFFERSIZE, key); ERR("BUFFERSIZE %d is too small to read [DllOverrides] key '%s'. Needs to grow in the source\n", BUFFERSIZE, key);
return FALSE; return FALSE;
} }
TRACE(module, "Key '%s' uses override '%s'\n", key, value); TRACE("Key '%s' uses override '%s'\n", key, value);
if(!AddLoadOrderSet(key, value, TRUE)) if(!AddLoadOrderSet(key, value, TRUE))
return FALSE; return FALSE;
@ -441,7 +441,7 @@ BOOL MODULE_InitLoadOrder(void)
/* Add the commandline overrides to the pool */ /* Add the commandline overrides to the pool */
if(!ParseCommandlineOverrides()) if(!ParseCommandlineOverrides())
{ {
MSG( "Syntax: -dll name[,name[,...]]={native|elfdll|so|builtin}[,{n|e|s|b}[,...]][:...]\n" MESSAGE( "Syntax: -dll name[,name[,...]]={native|elfdll|so|builtin}[,{n|e|s|b}[,...]][:...]\n"
" - 'name' is the name of any dll without extension\n" " - 'name' is the name of any dll without extension\n"
" - the order of loading (native, elfdll, so and builtin) can be abbreviated\n" " - the order of loading (native, elfdll, so and builtin) can be abbreviated\n"
" with the first letter\n" " with the first letter\n"
@ -460,7 +460,7 @@ BOOL MODULE_InitLoadOrder(void)
nbuffer = PROFILE_GetWineIniString("DllPairs", NULL, "", buffer, sizeof(buffer)); nbuffer = PROFILE_GetWineIniString("DllPairs", NULL, "", buffer, sizeof(buffer));
if(nbuffer == BUFFERSIZE-2) if(nbuffer == BUFFERSIZE-2)
{ {
ERR(module, "BUFFERSIZE %d is too small to read [DllPairs]. Needs to grow in the source\n", BUFFERSIZE); ERR("BUFFERSIZE %d is too small to read [DllPairs]. Needs to grow in the source\n", BUFFERSIZE);
return FALSE; return FALSE;
} }
if(nbuffer) if(nbuffer)
@ -479,12 +479,12 @@ BOOL MODULE_InitLoadOrder(void)
nbuffer = PROFILE_GetWineIniString("DllPairs", key, "", value, sizeof(value)); nbuffer = PROFILE_GetWineIniString("DllPairs", key, "", value, sizeof(value));
if(!nbuffer) if(!nbuffer)
{ {
ERR(module, "Module pair '%s' is not associated with another module?\n", key); ERR("Module pair '%s' is not associated with another module?\n", key);
continue; continue;
} }
if(nbuffer == BUFFERSIZE-2) if(nbuffer == BUFFERSIZE-2)
{ {
ERR(module, "BUFFERSIZE %d is too small to read [DllPairs] key '%s'. Needs to grow in the source\n", BUFFERSIZE, key); ERR("BUFFERSIZE %d is too small to read [DllPairs] key '%s'. Needs to grow in the source\n", BUFFERSIZE, key);
return FALSE; return FALSE;
} }
@ -493,7 +493,7 @@ BOOL MODULE_InitLoadOrder(void)
assert(plo1 && plo2); assert(plo1 && plo2);
if(memcmp(plo1->loadorder, plo2->loadorder, sizeof(plo1->loadorder))) if(memcmp(plo1->loadorder, plo2->loadorder, sizeof(plo1->loadorder)))
MSG("Warning: Modules '%s' and '%s' have different loadorder which may cause trouble\n", key, value); MESSAGE("Warning: Modules '%s' and '%s' have different loadorder which may cause trouble\n", key, value);
} }
} }
@ -551,7 +551,7 @@ module_loadorder_t *MODULE_GetLoadOrder(const char *path)
len = strlen(name); len = strlen(name);
if(len >= sizeof(fname) || len <= 0) if(len >= sizeof(fname) || len <= 0)
{ {
ERR(module, "Path '%s' -> '%s' reduces to zilch or just too large...\n", path, name); ERR("Path '%s' -> '%s' reduces to zilch or just too large...\n", path, name);
return &default_loadorder; return &default_loadorder;
} }
@ -562,7 +562,7 @@ module_loadorder_t *MODULE_GetLoadOrder(const char *path)
lo.modulename = fname; lo.modulename = fname;
tmp = bsearch(&lo, module_loadorder, nmodule_loadorder, sizeof(module_loadorder[0]), cmp_sort_func); tmp = bsearch(&lo, module_loadorder, nmodule_loadorder, sizeof(module_loadorder[0]), cmp_sort_func);
TRACE(module, "Looking for '%s' (%s), found '%s'\n", path, fname, tmp ? tmp->modulename : "<nothing>"); TRACE("Looking for '%s' (%s), found '%s'\n", path, fname, tmp ? tmp->modulename : "<nothing>");
if(!tmp) if(!tmp)
return &default_loadorder; return &default_loadorder;

View file

@ -44,7 +44,7 @@
#include "winsock.h" #include "winsock.h"
#include "thread.h" #include "thread.h"
#include "task.h" #include "task.h"
#include "debug.h" #include "debugtools.h"
#include "psdrv.h" #include "psdrv.h"
#include "server.h" #include "server.h"
#include "cursoricon.h" #include "cursoricon.h"

View file

@ -7,7 +7,7 @@
#include <string.h> #include <string.h>
#include "wine/winuser16.h" #include "wine/winuser16.h"
#include "module.h" #include "module.h"
#include "debug.h" #include "debugtools.h"
#include "debugtools.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(resource) DEFAULT_DEBUG_CHANNEL(resource)
@ -407,7 +407,7 @@ HGLOBAL16 NE_LoadPEResource( NE_MODULE *pModule, WORD type, LPVOID bits, DWORD s
{ {
HGLOBAL16 handle; HGLOBAL16 handle;
TRACE( resource, "module=%04x type=%04x\n", pModule->self, type ); TRACE("module=%04x type=%04x\n", pModule->self, type );
if (!pModule || !bits || !size) return 0; if (!pModule || !bits || !size) return 0;
handle = GlobalAlloc16( 0, size ); handle = GlobalAlloc16( 0, size );
@ -427,7 +427,7 @@ HGLOBAL16 NE_LoadPEResource( NE_MODULE *pModule, WORD type, LPVOID bits, DWORD s
break; break;
case RT_STRING16: case RT_STRING16:
FIXME( resource, "not yet implemented!\n" ); FIXME("not yet implemented!\n" );
/* fall through */ /* fall through */
default: default:

View file

@ -26,7 +26,7 @@
#include "toolhelp.h" #include "toolhelp.h"
#include "snoop.h" #include "snoop.h"
#include "stackframe.h" #include "stackframe.h"
#include "debug.h" #include "debugtools.h"
#include "file.h" #include "file.h"
#include "loadorder.h" #include "loadorder.h"
#include "elfdll.h" #include "elfdll.h"
@ -69,72 +69,72 @@ void NE_DumpModule( HMODULE16 hModule )
if (!(pModule = NE_GetPtr( hModule ))) if (!(pModule = NE_GetPtr( hModule )))
{ {
MSG( "**** %04x is not a module handle\n", hModule ); MESSAGE( "**** %04x is not a module handle\n", hModule );
return; return;
} }
/* Dump the module info */ /* Dump the module info */
DUMP( "---\n" ); DPRINTF( "---\n" );
DUMP( "Module %04x:\n", hModule ); DPRINTF( "Module %04x:\n", hModule );
DUMP( "count=%d flags=%04x heap=%d stack=%d\n", DPRINTF( "count=%d flags=%04x heap=%d stack=%d\n",
pModule->count, pModule->flags, pModule->count, pModule->flags,
pModule->heap_size, pModule->stack_size ); pModule->heap_size, pModule->stack_size );
DUMP( "cs:ip=%04x:%04x ss:sp=%04x:%04x ds=%04x nb seg=%d modrefs=%d\n", DPRINTF( "cs:ip=%04x:%04x ss:sp=%04x:%04x ds=%04x nb seg=%d modrefs=%d\n",
pModule->cs, pModule->ip, pModule->ss, pModule->sp, pModule->dgroup, pModule->cs, pModule->ip, pModule->ss, pModule->sp, pModule->dgroup,
pModule->seg_count, pModule->modref_count ); pModule->seg_count, pModule->modref_count );
DUMP( "os_flags=%d swap_area=%d version=%04x\n", DPRINTF( "os_flags=%d swap_area=%d version=%04x\n",
pModule->os_flags, pModule->min_swap_area, pModule->os_flags, pModule->min_swap_area,
pModule->expected_version ); pModule->expected_version );
if (pModule->flags & NE_FFLAGS_WIN32) if (pModule->flags & NE_FFLAGS_WIN32)
DUMP( "PE module=%08x\n", pModule->module32 ); DPRINTF( "PE module=%08x\n", pModule->module32 );
/* Dump the file info */ /* Dump the file info */
DUMP( "---\n" ); DPRINTF( "---\n" );
DUMP( "Filename: '%s'\n", NE_MODULE_NAME(pModule) ); DPRINTF( "Filename: '%s'\n", NE_MODULE_NAME(pModule) );
/* Dump the segment table */ /* Dump the segment table */
DUMP( "---\n" ); DPRINTF( "---\n" );
DUMP( "Segment table:\n" ); DPRINTF( "Segment table:\n" );
pSeg = NE_SEG_TABLE( pModule ); pSeg = NE_SEG_TABLE( pModule );
for (i = 0; i < pModule->seg_count; i++, pSeg++) for (i = 0; i < pModule->seg_count; i++, pSeg++)
DUMP( "%02x: pos=%d size=%d flags=%04x minsize=%d hSeg=%04x\n", DPRINTF( "%02x: pos=%d size=%d flags=%04x minsize=%d hSeg=%04x\n",
i + 1, pSeg->filepos, pSeg->size, pSeg->flags, i + 1, pSeg->filepos, pSeg->size, pSeg->flags,
pSeg->minsize, pSeg->hSeg ); pSeg->minsize, pSeg->hSeg );
/* Dump the resource table */ /* Dump the resource table */
DUMP( "---\n" ); DPRINTF( "---\n" );
DUMP( "Resource table:\n" ); DPRINTF( "Resource table:\n" );
if (pModule->res_table) if (pModule->res_table)
{ {
pword = (WORD *)((BYTE *)pModule + pModule->res_table); pword = (WORD *)((BYTE *)pModule + pModule->res_table);
DUMP( "Alignment: %d\n", *pword++ ); DPRINTF( "Alignment: %d\n", *pword++ );
while (*pword) while (*pword)
{ {
struct resource_typeinfo_s *ptr = (struct resource_typeinfo_s *)pword; struct resource_typeinfo_s *ptr = (struct resource_typeinfo_s *)pword;
struct resource_nameinfo_s *pname = (struct resource_nameinfo_s *)(ptr + 1); struct resource_nameinfo_s *pname = (struct resource_nameinfo_s *)(ptr + 1);
DUMP( "id=%04x count=%d\n", ptr->type_id, ptr->count ); DPRINTF( "id=%04x count=%d\n", ptr->type_id, ptr->count );
for (i = 0; i < ptr->count; i++, pname++) for (i = 0; i < ptr->count; i++, pname++)
DUMP( "offset=%d len=%d id=%04x\n", DPRINTF( "offset=%d len=%d id=%04x\n",
pname->offset, pname->length, pname->id ); pname->offset, pname->length, pname->id );
pword = (WORD *)pname; pword = (WORD *)pname;
} }
} }
else DUMP( "None\n" ); else DPRINTF( "None\n" );
/* Dump the resident name table */ /* Dump the resident name table */
DUMP( "---\n" ); DPRINTF( "---\n" );
DUMP( "Resident-name table:\n" ); DPRINTF( "Resident-name table:\n" );
pstr = (char *)pModule + pModule->name_table; pstr = (char *)pModule + pModule->name_table;
while (*pstr) while (*pstr)
{ {
DUMP( "%*.*s: %d\n", *pstr, *pstr, pstr + 1, DPRINTF( "%*.*s: %d\n", *pstr, *pstr, pstr + 1,
*(WORD *)(pstr + *pstr + 1) ); *(WORD *)(pstr + *pstr + 1) );
pstr += *pstr + 1 + sizeof(WORD); pstr += *pstr + 1 + sizeof(WORD);
} }
/* Dump the module reference table */ /* Dump the module reference table */
DUMP( "---\n" ); DPRINTF( "---\n" );
DUMP( "Module ref table:\n" ); DPRINTF( "Module ref table:\n" );
if (pModule->modref_table) if (pModule->modref_table)
{ {
pword = (WORD *)((BYTE *)pModule + pModule->modref_table); pword = (WORD *)((BYTE *)pModule + pModule->modref_table);
@ -142,44 +142,44 @@ void NE_DumpModule( HMODULE16 hModule )
{ {
char name[10]; char name[10];
GetModuleName16( *pword, name, sizeof(name) ); GetModuleName16( *pword, name, sizeof(name) );
DUMP( "%d: %04x -> '%s'\n", i, *pword, name ); DPRINTF( "%d: %04x -> '%s'\n", i, *pword, name );
} }
} }
else DUMP( "None\n" ); else DPRINTF( "None\n" );
/* Dump the entry table */ /* Dump the entry table */
DUMP( "---\n" ); DPRINTF( "---\n" );
DUMP( "Entry table:\n" ); DPRINTF( "Entry table:\n" );
bundle = (ET_BUNDLE *)((BYTE *)pModule+pModule->entry_table); bundle = (ET_BUNDLE *)((BYTE *)pModule+pModule->entry_table);
do { do {
entry = (ET_ENTRY *)((BYTE *)bundle+6); entry = (ET_ENTRY *)((BYTE *)bundle+6);
DUMP( "Bundle %d-%d: %02x\n", bundle->first, bundle->last, entry->type); DPRINTF( "Bundle %d-%d: %02x\n", bundle->first, bundle->last, entry->type);
ordinal = bundle->first; ordinal = bundle->first;
while (ordinal < bundle->last) while (ordinal < bundle->last)
{ {
if (entry->type == 0xff) if (entry->type == 0xff)
DUMP("%d: %02x:%04x (moveable)\n", ordinal++, entry->segnum, entry->offs); DPRINTF("%d: %02x:%04x (moveable)\n", ordinal++, entry->segnum, entry->offs);
else else
DUMP("%d: %02x:%04x (fixed)\n", ordinal++, entry->segnum, entry->offs); DPRINTF("%d: %02x:%04x (fixed)\n", ordinal++, entry->segnum, entry->offs);
entry++; entry++;
} }
} while ( (bundle->next) } while ( (bundle->next)
&& (bundle = ((ET_BUNDLE *)((BYTE *)pModule + bundle->next))) ); && (bundle = ((ET_BUNDLE *)((BYTE *)pModule + bundle->next))) );
/* Dump the non-resident names table */ /* Dump the non-resident names table */
DUMP( "---\n" ); DPRINTF( "---\n" );
DUMP( "Non-resident names table:\n" ); DPRINTF( "Non-resident names table:\n" );
if (pModule->nrname_handle) if (pModule->nrname_handle)
{ {
pstr = (char *)GlobalLock16( pModule->nrname_handle ); pstr = (char *)GlobalLock16( pModule->nrname_handle );
while (*pstr) while (*pstr)
{ {
DUMP( "%*.*s: %d\n", *pstr, *pstr, pstr + 1, DPRINTF( "%*.*s: %d\n", *pstr, *pstr, pstr + 1,
*(WORD *)(pstr + *pstr + 1) ); *(WORD *)(pstr + *pstr + 1) );
pstr += *pstr + 1 + sizeof(WORD); pstr += *pstr + 1 + sizeof(WORD);
} }
} }
DUMP( "\n" ); DPRINTF( "\n" );
} }
@ -191,16 +191,16 @@ void NE_DumpModule( HMODULE16 hModule )
void NE_WalkModules(void) void NE_WalkModules(void)
{ {
HMODULE16 hModule = hFirstModule; HMODULE16 hModule = hFirstModule;
MSG( "Module Flags Name\n" ); MESSAGE( "Module Flags Name\n" );
while (hModule) while (hModule)
{ {
NE_MODULE *pModule = NE_GetPtr( hModule ); NE_MODULE *pModule = NE_GetPtr( hModule );
if (!pModule) if (!pModule)
{ {
MSG( "Bad module %04x in list\n", hModule ); MESSAGE( "Bad module %04x in list\n", hModule );
return; return;
} }
MSG( " %04x %04x %.*s\n", hModule, pModule->flags, MESSAGE( " %04x %04x %.*s\n", hModule, pModule->flags,
*((char *)pModule + pModule->name_table), *((char *)pModule + pModule->name_table),
(char *)pModule + pModule->name_table + 1 ); (char *)pModule + pModule->name_table + 1 );
hModule = pModule->next; hModule = pModule->next;
@ -232,7 +232,7 @@ WORD NE_GetOrdinal( HMODULE16 hModule, const char *name )
if (!(pModule = NE_GetPtr( hModule ))) return 0; if (!(pModule = NE_GetPtr( hModule ))) return 0;
assert( !(pModule->flags & NE_FFLAGS_WIN32) ); assert( !(pModule->flags & NE_FFLAGS_WIN32) );
TRACE( module, "(%04x,'%s')\n", hModule, name ); TRACE("(%04x,'%s')\n", hModule, name );
/* First handle names of the form '#xxxx' */ /* First handle names of the form '#xxxx' */
@ -254,7 +254,7 @@ WORD NE_GetOrdinal( HMODULE16 hModule, const char *name )
{ {
if (((BYTE)*cpnt == len) && !memcmp( cpnt+1, buffer, len )) if (((BYTE)*cpnt == len) && !memcmp( cpnt+1, buffer, len ))
{ {
TRACE(module, " Found: ordinal=%d\n", TRACE(" Found: ordinal=%d\n",
*(WORD *)(cpnt + *cpnt + 1) ); *(WORD *)(cpnt + *cpnt + 1) );
return *(WORD *)(cpnt + *cpnt + 1); return *(WORD *)(cpnt + *cpnt + 1);
} }
@ -272,7 +272,7 @@ WORD NE_GetOrdinal( HMODULE16 hModule, const char *name )
{ {
if (((BYTE)*cpnt == len) && !memcmp( cpnt+1, buffer, len )) if (((BYTE)*cpnt == len) && !memcmp( cpnt+1, buffer, len ))
{ {
TRACE(module, " Found: ordinal=%d\n", TRACE(" Found: ordinal=%d\n",
*(WORD *)(cpnt + *cpnt + 1) ); *(WORD *)(cpnt + *cpnt + 1) );
return *(WORD *)(cpnt + *cpnt + 1); return *(WORD *)(cpnt + *cpnt + 1);
} }
@ -370,7 +370,7 @@ HANDLE NE_OpenFile( NE_MODULE *pModule )
static HANDLE cachedfd = -1; static HANDLE cachedfd = -1;
TRACE( module, "(%p) cache: mod=%p fd=%d\n", TRACE("(%p) cache: mod=%p fd=%d\n",
pModule, pCachedModule, cachedfd ); pModule, pCachedModule, cachedfd );
if (pCachedModule == pModule) return cachedfd; if (pCachedModule == pModule) return cachedfd;
CloseHandle( cachedfd ); CloseHandle( cachedfd );
@ -378,11 +378,11 @@ HANDLE NE_OpenFile( NE_MODULE *pModule )
name = NE_MODULE_NAME( pModule ); name = NE_MODULE_NAME( pModule );
if ((cachedfd = CreateFileA( name, GENERIC_READ, FILE_SHARE_READ, if ((cachedfd = CreateFileA( name, GENERIC_READ, FILE_SHARE_READ,
NULL, OPEN_EXISTING, 0, -1 )) == -1) NULL, OPEN_EXISTING, 0, -1 )) == -1)
MSG( "Can't open file '%s' for module %04x\n", name, pModule->self ); MESSAGE( "Can't open file '%s' for module %04x\n", name, pModule->self );
else else
/* FIXME: should not be necessary */ /* FIXME: should not be necessary */
cachedfd = ConvertToGlobalHandle(cachedfd); cachedfd = ConvertToGlobalHandle(cachedfd);
TRACE(module, "opened '%s' -> %d\n", TRACE("opened '%s' -> %d\n",
name, cachedfd ); name, cachedfd );
return cachedfd; return cachedfd;
} }
@ -425,7 +425,7 @@ static HMODULE16 NE_LoadExeHeader( HFILE16 hFile, OFSTRUCT *ofs )
if (ne_header.ne_magic != IMAGE_OS2_SIGNATURE) return (HMODULE16)11; /* invalid exe */ if (ne_header.ne_magic != IMAGE_OS2_SIGNATURE) return (HMODULE16)11; /* invalid exe */
if (ne_header.ne_magic == IMAGE_OS2_SIGNATURE_LX) { if (ne_header.ne_magic == IMAGE_OS2_SIGNATURE_LX) {
MSG("Sorry, this is an OS/2 linear executable (LX) file !\n"); MESSAGE("Sorry, this is an OS/2 linear executable (LX) file !\n");
return (HMODULE16)12; return (HMODULE16)12;
} }
@ -475,7 +475,7 @@ static HMODULE16 NE_LoadExeHeader( HFILE16 hFile, OFSTRUCT *ofs )
{ {
fastload_offset=ne_header.fastload_offset<<ne_header.align_shift_count; fastload_offset=ne_header.fastload_offset<<ne_header.align_shift_count;
fastload_length=ne_header.fastload_length<<ne_header.align_shift_count; fastload_length=ne_header.fastload_length<<ne_header.align_shift_count;
TRACE(module, "Using fast-load area offset=%x len=%d\n", TRACE("Using fast-load area offset=%x len=%d\n",
fastload_offset, fastload_length ); fastload_offset, fastload_length );
if ((fastload = HeapAlloc( SystemHeap, 0, fastload_length )) != NULL) if ((fastload = HeapAlloc( SystemHeap, 0, fastload_length )) != NULL)
{ {
@ -483,7 +483,7 @@ static HMODULE16 NE_LoadExeHeader( HFILE16 hFile, OFSTRUCT *ofs )
if (_hread16(hFile, fastload, fastload_length) != fastload_length) if (_hread16(hFile, fastload, fastload_length) != fastload_length)
{ {
HeapFree( SystemHeap, 0, fastload ); HeapFree( SystemHeap, 0, fastload );
WARN( module, "Error reading fast-load area!\n"); WARN("Error reading fast-load area!\n");
fastload = NULL; fastload = NULL;
} }
} }
@ -590,7 +590,7 @@ static HMODULE16 NE_LoadExeHeader( HFILE16 hFile, OFSTRUCT *ofs )
{ {
BYTE nr_entries, type, *s; BYTE nr_entries, type, *s;
TRACE(module, "Converting entry table.\n"); TRACE("Converting entry table.\n");
pModule->entry_table = (int)pData - (int)pModule; pModule->entry_table = (int)pData - (int)pModule;
if (!READ( mz_header.e_lfanew + ne_header.entry_tab_offset, if (!READ( mz_header.e_lfanew + ne_header.entry_tab_offset,
ne_header.entry_tab_length, pTempEntryTable )) ne_header.entry_tab_length, pTempEntryTable ))
@ -603,10 +603,10 @@ static HMODULE16 NE_LoadExeHeader( HFILE16 hFile, OFSTRUCT *ofs )
} }
s = pTempEntryTable; s = pTempEntryTable;
TRACE(module, "entry table: offs %04x, len %04x, entries %d\n", ne_header.entry_tab_offset, ne_header.entry_tab_length, *s); TRACE("entry table: offs %04x, len %04x, entries %d\n", ne_header.entry_tab_offset, ne_header.entry_tab_length, *s);
bundle = (ET_BUNDLE *)pData; bundle = (ET_BUNDLE *)pData;
TRACE(module, "first bundle: %p\n", bundle); TRACE("first bundle: %p\n", bundle);
memset(bundle, 0, sizeof(ET_BUNDLE)); /* in case no entry table exists */ memset(bundle, 0, sizeof(ET_BUNDLE)); /* in case no entry table exists */
entry = (ET_ENTRY *)((BYTE *)bundle+6); entry = (ET_ENTRY *)((BYTE *)bundle+6);
@ -649,7 +649,7 @@ static HMODULE16 NE_LoadExeHeader( HFILE16 hFile, OFSTRUCT *ofs )
oldbundle = bundle; oldbundle = bundle;
oldbundle->next = ((int)entry - (int)pModule); oldbundle->next = ((int)entry - (int)pModule);
bundle = (ET_BUNDLE *)entry; bundle = (ET_BUNDLE *)entry;
TRACE(module, "new bundle: %p\n", bundle); TRACE("new bundle: %p\n", bundle);
bundle->first = bundle->last = bundle->first = bundle->last =
oldbundle->last + nr_entries; oldbundle->last + nr_entries;
bundle->next = 0; bundle->next = 0;
@ -671,7 +671,7 @@ static HMODULE16 NE_LoadExeHeader( HFILE16 hFile, OFSTRUCT *ofs )
2 * (ne_header.entry_tab_length - ne_header.n_mov_entry_points*6); 2 * (ne_header.entry_tab_length - ne_header.n_mov_entry_points*6);
if ((DWORD)entry > (DWORD)pData) if ((DWORD)entry > (DWORD)pData)
ERR(module, "converted entry table bigger than reserved space !!!\nentry: %p, pData: %p. Please report !\n", entry, pData); ERR("converted entry table bigger than reserved space !!!\nentry: %p, pData: %p. Please report !\n", entry, pData);
/* Store the filename information */ /* Store the filename information */
@ -751,7 +751,7 @@ static BOOL NE_LoadDLLs( NE_MODULE *pModule )
memcpy( buffer, pstr + 1, *pstr ); memcpy( buffer, pstr + 1, *pstr );
*(buffer + *pstr) = 0; /* terminate it */ *(buffer + *pstr) = 0; /* terminate it */
TRACE(module, "Loading '%s'\n", buffer ); TRACE("Loading '%s'\n", buffer );
if (!(*pModRef = GetModuleHandle16( buffer ))) if (!(*pModRef = GetModuleHandle16( buffer )))
{ {
/* If the DLL is not loaded yet, load it and store */ /* If the DLL is not loaded yet, load it and store */
@ -762,7 +762,7 @@ static BOOL NE_LoadDLLs( NE_MODULE *pModule )
{ {
/* FIXME: cleanup what was done */ /* FIXME: cleanup what was done */
MSG( "Could not load '%s' required by '%.*s', error=%d\n", MESSAGE( "Could not load '%s' required by '%.*s', error=%d\n",
buffer, *((BYTE*)pModule + pModule->name_table), buffer, *((BYTE*)pModule + pModule->name_table),
(char *)pModule + pModule->name_table + 1, hDLL ); (char *)pModule + pModule->name_table + 1, hDLL );
return FALSE; return FALSE;
@ -887,22 +887,22 @@ HINSTANCE16 MODULE_LoadModule16( LPCSTR libname, BOOL implicit )
switch(plo->loadorder[i]) switch(plo->loadorder[i])
{ {
case MODULE_LOADORDER_DLL: case MODULE_LOADORDER_DLL:
TRACE(module, "Trying native dll '%s'\n", libname); TRACE("Trying native dll '%s'\n", libname);
hinst = NE_LoadModule(libname, implicit); hinst = NE_LoadModule(libname, implicit);
break; break;
case MODULE_LOADORDER_ELFDLL: case MODULE_LOADORDER_ELFDLL:
TRACE(module, "Trying elfdll '%s'\n", libname); TRACE("Trying elfdll '%s'\n", libname);
hinst = ELFDLL_LoadModule16(libname, implicit); hinst = ELFDLL_LoadModule16(libname, implicit);
break; break;
case MODULE_LOADORDER_BI: case MODULE_LOADORDER_BI:
TRACE(module, "Trying built-in '%s'\n", libname); TRACE("Trying built-in '%s'\n", libname);
hinst = fnBUILTIN_LoadModule(libname, TRUE); hinst = fnBUILTIN_LoadModule(libname, TRUE);
break; break;
default: default:
ERR(module, "Got invalid loadorder type %d (%s index %d)\n", plo->loadorder[i], plo->modulename, i); ERR("Got invalid loadorder type %d (%s index %d)\n", plo->loadorder[i], plo->modulename, i);
/* Fall through */ /* Fall through */
case MODULE_LOADORDER_SO: /* This is not supported for NE modules */ case MODULE_LOADORDER_SO: /* This is not supported for NE modules */
@ -921,7 +921,7 @@ HINSTANCE16 MODULE_LoadModule16( LPCSTR libname, BOOL implicit )
hModule = GetModuleHandle16(libname); hModule = GetModuleHandle16(libname);
if(!hModule) if(!hModule)
{ {
ERR(module, "Serious trouble. Just loaded module '%s' (hinst=0x%04x), but can't get module handle\n", ERR("Serious trouble. Just loaded module '%s' (hinst=0x%04x), but can't get module handle\n",
libname, hinst); libname, hinst);
return 6; /* ERROR_INVALID_HANDLE seems most appropriate */ return 6; /* ERROR_INVALID_HANDLE seems most appropriate */
} }
@ -929,12 +929,12 @@ HINSTANCE16 MODULE_LoadModule16( LPCSTR libname, BOOL implicit )
pModule = NE_GetPtr(hModule); pModule = NE_GetPtr(hModule);
if(!pModule) if(!pModule)
{ {
ERR(module, "Serious trouble. Just loaded module '%s' (hinst=0x%04x), but can't get NE_MODULE pointer\n", ERR("Serious trouble. Just loaded module '%s' (hinst=0x%04x), but can't get NE_MODULE pointer\n",
libname, hinst); libname, hinst);
return 6; /* ERROR_INVALID_HANDLE seems most appropriate */ return 6; /* ERROR_INVALID_HANDLE seems most appropriate */
} }
TRACE(module, "Loaded module '%s' at 0x%04x, \n", libname, hinst); TRACE("Loaded module '%s' at 0x%04x, \n", libname, hinst);
/* /*
* Call initialization routines for all loaded DLLs. Note that * Call initialization routines for all loaded DLLs. Note that
@ -1153,7 +1153,7 @@ HINSTANCE16 WINAPI LoadLibrary16( LPCSTR libname )
if (dirsep1) if (dirsep1)
*dirsep1=0; *dirsep1=0;
TRACE( module, "looking for (%p) %s and %s \n", TRACE("looking for (%p) %s and %s \n",
libname, libname,strippedname ); libname, libname,strippedname );
/* Load library module */ /* Load library module */
@ -1178,7 +1178,7 @@ static BOOL16 MODULE_CallWEP( HMODULE16 hModule )
if (ordinal) WEP = NE_GetEntryPoint( hModule, ordinal ); if (ordinal) WEP = NE_GetEntryPoint( hModule, ordinal );
if (!WEP) if (!WEP)
{ {
WARN(module, "module %04x doesn't have a WEP\n", hModule ); WARN("module %04x doesn't have a WEP\n", hModule );
return FALSE; return FALSE;
} }
return Callbacks->CallWindowsExitProc( WEP, WEP_FREE_DLL ); return Callbacks->CallWindowsExitProc( WEP, WEP_FREE_DLL );
@ -1200,7 +1200,7 @@ static BOOL16 NE_FreeModule( HMODULE16 hModule, BOOL call_wep )
if (!(pModule = NE_GetPtr( hModule ))) return FALSE; if (!(pModule = NE_GetPtr( hModule ))) return FALSE;
hModule = pModule->self; hModule = pModule->self;
TRACE( module, "%04x count %d\n", hModule, pModule->count ); TRACE("%04x count %d\n", hModule, pModule->count );
if (((INT16)(--pModule->count)) > 0 ) return TRUE; if (((INT16)(--pModule->count)) > 0 ) return TRUE;
else pModule->count = 0; else pModule->count = 0;
@ -1274,7 +1274,7 @@ BOOL16 WINAPI FreeModule16( HMODULE16 hModule )
*/ */
void WINAPI FreeLibrary16( HINSTANCE16 handle ) void WINAPI FreeLibrary16( HINSTANCE16 handle )
{ {
TRACE(module,"%04x\n", handle ); TRACE("%04x\n", handle );
FreeModule16( handle ); FreeModule16( handle );
} }
@ -1330,7 +1330,7 @@ INT16 WINAPI GetModuleFileName16( HINSTANCE16 hModule, LPSTR lpFileName,
if (!hModule) hModule = GetCurrentTask(); if (!hModule) hModule = GetCurrentTask();
if (!(pModule = NE_GetPtr( hModule ))) return 0; if (!(pModule = NE_GetPtr( hModule ))) return 0;
lstrcpynA( lpFileName, NE_MODULE_NAME(pModule), nSize ); lstrcpynA( lpFileName, NE_MODULE_NAME(pModule), nSize );
TRACE(module, "%s\n", lpFileName ); TRACE("%s\n", lpFileName );
return strlen(lpFileName); return strlen(lpFileName);
} }
@ -1367,7 +1367,7 @@ HMODULE16 WINAPI GetModuleHandle16( LPCSTR name )
char tmpstr[128]; char tmpstr[128];
NE_MODULE *pModule; NE_MODULE *pModule;
TRACE(module, "(%s)\n", name); TRACE("(%s)\n", name);
if (!HIWORD(name)) if (!HIWORD(name))
return GetExePtr(LOWORD(name)); return GetExePtr(LOWORD(name));
@ -1462,7 +1462,7 @@ HMODULE16 WINAPI GetModuleHandle16( LPCSTR name )
if (!strcmp(tmpstr,"TIMER")) if (!strcmp(tmpstr,"TIMER"))
{ {
FIXME(module, "Eh... Should return caller's code segment, expect crash\n"); FIXME("Eh... Should return caller's code segment, expect crash\n");
return 0; return 0;
} }

View file

@ -21,7 +21,7 @@
#include "neexe.h" #include "neexe.h"
#include "resource.h" #include "resource.h"
#include "callback.h" #include "callback.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(resource) DEFAULT_DEBUG_CHANNEL(resource)
@ -53,13 +53,13 @@ static DWORD NE_FindNameTableId( NE_MODULE *pModule, LPCSTR typeId, LPCSTR resId
pNameInfo = (NE_NAMEINFO *)(pTypeInfo + 1); pNameInfo = (NE_NAMEINFO *)(pTypeInfo + 1);
for (count = pTypeInfo->count; count > 0; count--, pNameInfo++) for (count = pTypeInfo->count; count > 0; count--, pNameInfo++)
{ {
TRACE(resource, "NameTable entry: type=%04x id=%04x\n", TRACE("NameTable entry: type=%04x id=%04x\n",
pTypeInfo->type_id, pNameInfo->id ); pTypeInfo->type_id, pNameInfo->id );
handle = LoadResource16( pModule->self, handle = LoadResource16( pModule->self,
(HRSRC16)((int)pNameInfo - (int)pModule) ); (HRSRC16)((int)pNameInfo - (int)pModule) );
for(p = (WORD*)LockResource16(handle); p && *p; p = (WORD *)((char*)p+*p)) for(p = (WORD*)LockResource16(handle); p && *p; p = (WORD *)((char*)p+*p))
{ {
TRACE(resource," type=%04x '%s' id=%04x '%s'\n", TRACE(" type=%04x '%s' id=%04x '%s'\n",
p[1], (char *)(p+3), p[2], p[1], (char *)(p+3), p[2],
(char *)(p+3)+strlen((char *)(p+3))+1 ); (char *)(p+3)+strlen((char *)(p+3))+1 );
/* Check for correct type */ /* Check for correct type */
@ -87,7 +87,7 @@ static DWORD NE_FindNameTableId( NE_MODULE *pModule, LPCSTR typeId, LPCSTR resId
/* If we get here, we've found the entry */ /* If we get here, we've found the entry */
TRACE(resource, " Found!\n" ); TRACE(" Found!\n" );
ret = MAKELONG( p[1], p[2] ); ret = MAKELONG( p[1], p[2] );
break; break;
} }
@ -119,11 +119,11 @@ NE_TYPEINFO *NE_FindTypeSection( LPBYTE pResTab,
BYTE *p = pResTab + pTypeInfo->type_id; BYTE *p = pResTab + pTypeInfo->type_id;
if ((*p == len) && !lstrncmpiA( p+1, str, len )) if ((*p == len) && !lstrncmpiA( p+1, str, len ))
{ {
TRACE(resource, " Found type '%s'\n", str ); TRACE(" Found type '%s'\n", str );
return pTypeInfo; return pTypeInfo;
} }
} }
TRACE(resource, " Skipping type %04x\n", pTypeInfo->type_id ); TRACE(" Skipping type %04x\n", pTypeInfo->type_id );
pTypeInfo = NEXT_TYPEINFO(pTypeInfo); pTypeInfo = NEXT_TYPEINFO(pTypeInfo);
} }
} }
@ -134,10 +134,10 @@ NE_TYPEINFO *NE_FindTypeSection( LPBYTE pResTab,
{ {
if (pTypeInfo->type_id == id) if (pTypeInfo->type_id == id)
{ {
TRACE(resource, " Found type %04x\n", id ); TRACE(" Found type %04x\n", id );
return pTypeInfo; return pTypeInfo;
} }
TRACE(resource, " Skipping type %04x\n", pTypeInfo->type_id ); TRACE(" Skipping type %04x\n", pTypeInfo->type_id );
pTypeInfo = NEXT_TYPEINFO(pTypeInfo); pTypeInfo = NEXT_TYPEINFO(pTypeInfo);
} }
} }
@ -195,7 +195,7 @@ HGLOBAL16 WINAPI NE_DefResourceHandler( HGLOBAL16 hMemObj, HMODULE16 hModule,
WORD sizeShift = *(WORD *)((char *)pModule + pModule->res_table); WORD sizeShift = *(WORD *)((char *)pModule + pModule->res_table);
NE_NAMEINFO* pNameInfo = (NE_NAMEINFO*)((char*)pModule + hRsrc); NE_NAMEINFO* pNameInfo = (NE_NAMEINFO*)((char*)pModule + hRsrc);
TRACE(resource, "loading, pos=%d, len=%d\n", TRACE("loading, pos=%d, len=%d\n",
(int)pNameInfo->offset << sizeShift, (int)pNameInfo->offset << sizeShift,
(int)pNameInfo->length << sizeShift ); (int)pNameInfo->length << sizeShift );
if( hMemObj ) if( hMemObj )
@ -236,7 +236,7 @@ BOOL NE_InitResourceHandler( HMODULE16 hModule )
DefResourceHandlerProc = NULL; DefResourceHandlerProc = NULL;
} }
TRACE(resource,"InitResourceHandler[%04x]\n", hModule ); TRACE("InitResourceHandler[%04x]\n", hModule );
while(pTypeInfo->type_id) while(pTypeInfo->type_id)
{ {
@ -260,7 +260,7 @@ FARPROC16 WINAPI SetResourceHandler16( HMODULE16 hModule, SEGPTR typeId,
if (!pModule || !pModule->res_table) return NULL; if (!pModule || !pModule->res_table) return NULL;
TRACE( resource, "module=%04x type=%s\n", TRACE("module=%04x type=%s\n",
hModule, debugres_a(PTR_SEG_TO_LIN(typeId)) ); hModule, debugres_a(PTR_SEG_TO_LIN(typeId)) );
for (;;) for (;;)
@ -286,7 +286,7 @@ HRSRC16 NE_FindResource( NE_MODULE *pModule, LPCSTR name, LPCSTR type )
if (!pModule || !pModule->res_table) return 0; if (!pModule || !pModule->res_table) return 0;
TRACE( resource, "module=%04x name=%s type=%s\n", TRACE("module=%04x name=%s type=%s\n",
pModule->self, debugres_a(PTR_SEG_TO_LIN(name)), pModule->self, debugres_a(PTR_SEG_TO_LIN(name)),
debugres_a(PTR_SEG_TO_LIN(type)) ); debugres_a(PTR_SEG_TO_LIN(type)) );
@ -296,7 +296,7 @@ HRSRC16 NE_FindResource( NE_MODULE *pModule, LPCSTR name, LPCSTR type )
if (ptr[0] == '#') if (ptr[0] == '#')
if (!(name = (LPCSTR)atoi( ptr + 1 ))) if (!(name = (LPCSTR)atoi( ptr + 1 )))
{ {
WARN(resource, "Incorrect resource name: %s\n", ptr); WARN("Incorrect resource name: %s\n", ptr);
return 0; return 0;
} }
} }
@ -307,7 +307,7 @@ HRSRC16 NE_FindResource( NE_MODULE *pModule, LPCSTR name, LPCSTR type )
if (ptr[0] == '#') if (ptr[0] == '#')
if (!(type = (LPCSTR)atoi( ptr + 1 ))) if (!(type = (LPCSTR)atoi( ptr + 1 )))
{ {
WARN(resource, "Incorrect resource type: %s\n", ptr); WARN("Incorrect resource type: %s\n", ptr);
return 0; return 0;
} }
} }
@ -331,14 +331,14 @@ HRSRC16 NE_FindResource( NE_MODULE *pModule, LPCSTR name, LPCSTR type )
break; break;
if ((pNameInfo = NE_FindResourceFromType( pResTab, pTypeInfo, name ))) if ((pNameInfo = NE_FindResourceFromType( pResTab, pTypeInfo, name )))
{ {
TRACE(resource, " Found id %08lx\n", (DWORD)name ); TRACE(" Found id %08lx\n", (DWORD)name );
return (HRSRC16)( (int)pNameInfo - (int)pModule ); return (HRSRC16)( (int)pNameInfo - (int)pModule );
} }
TRACE(resource, " Not found, going on\n" ); TRACE(" Not found, going on\n" );
pTypeInfo = NEXT_TYPEINFO(pTypeInfo); pTypeInfo = NEXT_TYPEINFO(pTypeInfo);
} }
WARN(resource, "failed!\n"); WARN("failed!\n");
return 0; return 0;
} }
@ -354,7 +354,7 @@ HGLOBAL16 WINAPI AllocResource16( HMODULE16 hModule, HRSRC16 hRsrc, DWORD size)
NE_MODULE *pModule = NE_GetPtr( hModule ); NE_MODULE *pModule = NE_GetPtr( hModule );
if (!pModule || !pModule->res_table || !hRsrc) return 0; if (!pModule || !pModule->res_table || !hRsrc) return 0;
TRACE( resource, "module=%04x res=%04x size=%ld\n", hModule, hRsrc, size ); TRACE("module=%04x res=%04x size=%ld\n", hModule, hRsrc, size );
sizeShift = *(WORD *)((char *)pModule + pModule->res_table); sizeShift = *(WORD *)((char *)pModule + pModule->res_table);
pNameInfo = (NE_NAMEINFO*)((char*)pModule + hRsrc); pNameInfo = (NE_NAMEINFO*)((char*)pModule + hRsrc);
@ -372,12 +372,12 @@ HGLOBAL16 WINAPI AllocResource16( HMODULE16 hModule, HRSRC16 hRsrc, DWORD size)
HGLOBAL16 WINAPI DirectResAlloc16( HINSTANCE16 hInstance, WORD wType, HGLOBAL16 WINAPI DirectResAlloc16( HINSTANCE16 hInstance, WORD wType,
UINT16 wSize ) UINT16 wSize )
{ {
TRACE(resource,"(%04x,%04x,%04x)\n", TRACE("(%04x,%04x,%04x)\n",
hInstance, wType, wSize ); hInstance, wType, wSize );
if (!(hInstance = GetExePtr( hInstance ))) return 0; if (!(hInstance = GetExePtr( hInstance ))) return 0;
if(wType != 0x10) /* 0x10 is the only observed value, passed from if(wType != 0x10) /* 0x10 is the only observed value, passed from
CreateCursorIndirect. */ CreateCursorIndirect. */
TRACE(resource, "(wType=%x)\n", wType); TRACE("(wType=%x)\n", wType);
return GLOBAL_Alloc(GMEM_MOVEABLE, wSize, hInstance, FALSE, FALSE, FALSE); return GLOBAL_Alloc(GMEM_MOVEABLE, wSize, hInstance, FALSE, FALSE, FALSE);
} }
@ -391,7 +391,7 @@ INT16 NE_AccessResource( NE_MODULE *pModule, HRSRC16 hRsrc )
if (!pModule || !pModule->res_table || !hRsrc) return -1; if (!pModule || !pModule->res_table || !hRsrc) return -1;
TRACE(resource, "module=%04x res=%04x\n", pModule->self, hRsrc ); TRACE("module=%04x res=%04x\n", pModule->self, hRsrc );
if ((fd = _lopen16( NE_MODULE_NAME(pModule), OF_READ )) != HFILE_ERROR16) if ((fd = _lopen16( NE_MODULE_NAME(pModule), OF_READ )) != HFILE_ERROR16)
{ {
@ -413,7 +413,7 @@ DWORD NE_SizeofResource( NE_MODULE *pModule, HRSRC16 hRsrc )
if (!pModule || !pModule->res_table) return 0; if (!pModule || !pModule->res_table) return 0;
TRACE(resource, "module=%04x res=%04x\n", pModule->self, hRsrc ); TRACE("module=%04x res=%04x\n", pModule->self, hRsrc );
sizeShift = *(WORD *)((char *)pModule + pModule->res_table); sizeShift = *(WORD *)((char *)pModule + pModule->res_table);
pNameInfo = (NE_NAMEINFO*)((char*)pModule + hRsrc); pNameInfo = (NE_NAMEINFO*)((char*)pModule + hRsrc);
@ -430,7 +430,7 @@ HGLOBAL16 NE_LoadResource( NE_MODULE *pModule, HRSRC16 hRsrc )
NE_NAMEINFO *pNameInfo = NULL; NE_NAMEINFO *pNameInfo = NULL;
int d; int d;
TRACE( resource, "module=%04x res=%04x\n", pModule->self, hRsrc ); TRACE("module=%04x res=%04x\n", pModule->self, hRsrc );
if (!hRsrc || !pModule || !pModule->res_table) return 0; if (!hRsrc || !pModule || !pModule->res_table) return 0;
/* First, verify hRsrc (just an offset from pModule to the needed pNameInfo) */ /* First, verify hRsrc (just an offset from pModule to the needed pNameInfo) */
@ -461,7 +461,7 @@ HGLOBAL16 NE_LoadResource( NE_MODULE *pModule, HRSRC16 hRsrc )
&& !(GlobalFlags16(pNameInfo->handle) & GMEM_DISCARDED)) && !(GlobalFlags16(pNameInfo->handle) & GMEM_DISCARDED))
{ {
pNameInfo->usage++; pNameInfo->usage++;
TRACE(resource, " Already loaded, new count=%d\n", TRACE(" Already loaded, new count=%d\n",
pNameInfo->usage ); pNameInfo->usage );
} }
else else
@ -497,7 +497,7 @@ BOOL16 NE_FreeResource( NE_MODULE *pModule, HGLOBAL16 handle )
if (!handle || !pModule || !pModule->res_table) return handle; if (!handle || !pModule || !pModule->res_table) return handle;
TRACE(resource, "handle=%04x\n", handle ); TRACE("handle=%04x\n", handle );
pTypeInfo = (NE_TYPEINFO *)((char *)pModule + pModule->res_table + 2); pTypeInfo = (NE_TYPEINFO *)((char *)pModule + pModule->res_table + 2);
while (pTypeInfo->type_id) while (pTypeInfo->type_id)

View file

@ -22,7 +22,7 @@
#include "libres.h" #include "libres.h"
#include "stackframe.h" #include "stackframe.h"
#include "neexe.h" #include "neexe.h"
#include "debug.h" #include "debugtools.h"
/********************************************************************** /**********************************************************************
* HMODULE32toPE_MODREF * HMODULE32toPE_MODREF

View file

@ -38,7 +38,7 @@
#include "miscemu.h" #include "miscemu.h"
#include "dosexe.h" #include "dosexe.h"
#include "thread.h" #include "thread.h"
#include "debug.h" #include "debugtools.h"
void (*fnWINE_Debugger)(int,SIGCONTEXT*) = NULL; void (*fnWINE_Debugger)(int,SIGCONTEXT*) = NULL;
void (*ctx_debug_call)(int sig,CONTEXT*ctx)=NULL; void (*ctx_debug_call)(int sig,CONTEXT*ctx)=NULL;
@ -268,22 +268,22 @@ static HANDLER_DEF(SIGNAL_fault)
#endif #endif
if (IS_SELECTOR_SYSTEM(CS_sig(HANDLER_CONTEXT))) if (IS_SELECTOR_SYSTEM(CS_sig(HANDLER_CONTEXT)))
{ {
MSG("%s in 32-bit code (0x%08lx).\n", fault, EIP_sig(HANDLER_CONTEXT)); MESSAGE("%s in 32-bit code (0x%08lx).\n", fault, EIP_sig(HANDLER_CONTEXT));
} }
else else
{ {
MSG("%s in 16-bit code (%04x:%04lx).\n", fault, MESSAGE("%s in 16-bit code (%04x:%04lx).\n", fault,
(WORD)CS_sig(HANDLER_CONTEXT), EIP_sig(HANDLER_CONTEXT) ); (WORD)CS_sig(HANDLER_CONTEXT), EIP_sig(HANDLER_CONTEXT) );
} }
#ifdef CR2_sig #ifdef CR2_sig
MSG("Fault address is 0x%08lx\n",CR2_sig(HANDLER_CONTEXT)); MESSAGE("Fault address is 0x%08lx\n",CR2_sig(HANDLER_CONTEXT));
#endif #endif
#endif #endif
if (fnWINE_Debugger) if (fnWINE_Debugger)
fnWINE_Debugger( signal, HANDLER_CONTEXT ); fnWINE_Debugger( signal, HANDLER_CONTEXT );
else { else {
MSG("stopping pid %d due to unhandled %s.\n",getpid(),fault); MESSAGE("stopping pid %d due to unhandled %s.\n",getpid(),fault);
kill(getpid(),SIGSTOP); kill(getpid(),SIGSTOP);
} }
} }

View file

@ -26,7 +26,6 @@
#else #else
#include "version.h" #include "version.h"
#include "winnls.h" #include "winnls.h"
#include "debug.h"
#endif #endif
static LRESULT DIALOG_PAGESETUP_DlgProc(HWND hDlg, UINT msg, WPARAM wParam, LPARAM lParam); static LRESULT DIALOG_PAGESETUP_DlgProc(HWND hDlg, UINT msg, WPARAM wParam, LPARAM lParam);

View file

@ -12,7 +12,6 @@
#endif #endif
#include "winhelp.h" #include "winhelp.h"
#include "macro.h" #include "macro.h"
#include "debug.h"
VOID MACRO_About(VOID) VOID MACRO_About(VOID)
{ {