[PATCH] explorer: replace existing SHAppBarMessage cases with individual stubs
Vincent Povirk
vincent at codeweavers.com
Tue Sep 2 14:41:31 CDT 2008
---
programs/explorer/appbar.c | 44 ++++++++++++++++----------------------------
1 files changed, 16 insertions(+), 28 deletions(-)
diff --git a/programs/explorer/appbar.c b/programs/explorer/appbar.c
index cb56788..e2e615e 100644
--- a/programs/explorer/appbar.c
+++ b/programs/explorer/appbar.c
@@ -43,56 +43,44 @@ struct appbar_response
static HWND appbarmsg_window = NULL;
-static UINT_PTR handle_appbarmessage(DWORD msg, PAPPBARDATA data)
+static UINT_PTR handle_appbarmessage(DWORD msg, PAPPBARDATA abd)
{
- int width=data->rc.right - data->rc.left;
- int height=data->rc.bottom - data->rc.top;
- RECT rec=data->rc;
-
- WINE_FIXME("msg=%d, data={cb=%d, hwnd=%p, callback=%x, edge=%d, rc=%s, lparam=%lx}: stub\n",
- msg, data->cbSize, data->hWnd, data->uCallbackMessage, data->uEdge,
- wine_dbgstr_rect(&data->rc), data->lParam);
-
switch (msg)
{
case ABM_NEW:
- /* cbSize, hWnd, and uCallbackMessage are used. All other ignored */
- SetWindowPos(data->hWnd,HWND_TOP,0,0,0,0,SWP_SHOWWINDOW|SWP_NOMOVE|SWP_NOSIZE);
+ WINE_FIXME("SHAppBarMessage(ABM_NEW, hwnd=%p, callback=%x): stub\n", abd->hWnd, abd->uCallbackMessage);
return TRUE;
case ABM_REMOVE:
- WINE_FIXME("ABM_REMOVE broken\n");
- /* FIXME: this is wrong; should it be DestroyWindow instead? */
- /*CloseHandle(data->hWnd);*/
+ WINE_FIXME("SHAppBarMessage(ABM_REMOVE, hwnd=%p): stub\n", abd->hWnd);
return TRUE;
case ABM_QUERYPOS:
- GetWindowRect(data->hWnd, &(data->rc));
+ WINE_FIXME("SHAppBarMessage(ABM_QUERYPOS, hwnd=%p, edge=%x, rc=%s): stub\n", abd->hWnd, abd->uEdge, wine_dbgstr_rect(&abd->rc));
return TRUE;
case ABM_SETPOS:
- data->uEdge=(ABE_RIGHT | ABE_LEFT);
- SetWindowPos(data->hWnd,HWND_TOP,data->rc.left,data->rc.top,
- width,height,SWP_SHOWWINDOW);
+ WINE_FIXME("SHAppBarMessage(ABM_SETPOS, hwnd=%p, edge=%x, rc=%s): stub\n", abd->hWnd, abd->uEdge, wine_dbgstr_rect(&abd->rc));
return TRUE;
case ABM_GETSTATE:
+ WINE_FIXME("SHAppBarMessage(ABM_GETSTATE): stub\n");
return ABS_ALWAYSONTOP | ABS_AUTOHIDE;
case ABM_GETTASKBARPOS:
- /* FIXME: This is wrong. It should return the taskbar co-ords and edge from the monitor
- which contains data->hWnd */
- GetWindowRect(data->hWnd, &rec);
- data->rc=rec;
- return TRUE;
+ WINE_FIXME("SHAppBarMessage(ABM_GETTASKBARPOS, hwnd=%p): stub\n", abd->hWnd);
+ return FALSE;
case ABM_ACTIVATE:
- SetActiveWindow(data->hWnd);
+ WINE_FIXME("SHAppBarMessage(ABM_ACTIVATE, hwnd=%p, lparam=%lx): stub\n", abd->hWnd, abd->lParam);
return TRUE;
case ABM_GETAUTOHIDEBAR:
- return 0; /* pretend there is no autohide bar */
+ WINE_FIXME("SHAppBarMessage(ABM_GETAUTOHIDEBAR, hwnd=%p, edge=%x): stub\n", abd->hWnd, abd->uEdge);
+ return 0;
case ABM_SETAUTOHIDEBAR:
- SetWindowPos(data->hWnd,HWND_TOP,rec.left+1000,rec.top,
- width,height,SWP_SHOWWINDOW);
+ WINE_FIXME("SHAppBarMessage(ABM_SETAUTOHIDEBAR, hwnd=%p, edge=%x, lparam=%lx): stub\n", abd->hWnd, abd->uEdge, abd->lParam);
return TRUE;
case ABM_WINDOWPOSCHANGED:
+ WINE_FIXME("SHAppBarMessage(ABM_WINDOWPOSCHANGED, hwnd=%p): stub\n", abd->hWnd);
return TRUE;
+ default:
+ WINE_FIXME("SHAppBarMessage(%x) unimplemented\n", msg);
+ return FALSE;
}
- return FALSE;
}
LRESULT CALLBACK appbar_wndproc(HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam)
--
1.5.4.3
--=-VI1EksEp18P+2Kxevzsw--
More information about the wine-patches
mailing list