pass through message map
Roger Lamb RAS+ 95 -- rasplus@lambsoftware.com Saturday, February 17, 1996 I have a tree control which I put a message handler on edit, copy, paste, and delete keys. When the in place edit control activates while editing a tree item.. the tree control gets the edit,copy,paste, and delete message first and never gives it to the edit control. Q: Is there a way to pass through the message dynamically? Sincerely, Roger C. Lamb Jr. Lamb Software, Inc. (RAS+ 95) Email: rasplus@lambsoftware.com Upates: http://www.lambsoftware.com
Jim Leavitt -- jimll@halcyon.com Sunday, February 18, 1996 Roger Wrote: I have a tree control which I put a message handler on edit, copy, paste, and delete keys. When the in place edit control activates while editing a tree item.. the tree control gets the edit,copy,paste, and delete message first and never gives it to the edit control. Q: Is there a way to pass through the message dynamically? Roger, This is probably not the preferred method: I've emulated the little popup windows that show the entire text of a tree item if the TreeCtrl window is so small it cuts it off. (Like the tree views in VC 4). I need to get mouse down messages, but I also need to pass them to the tree control so it can select the item, expand it, etc. As you can see, I pack the lparam, take the wparam and call SendMessage. I suppose that Post Message is less draconian, but I wanted an immediate reponse. void CTreePopupWnd::OnLButtonDblClk(UINT nFlags, CPoint point) { DWORD lparam; ClientToScreen(&point); m_pTree->ScreenToClient(&point); lparam = point.y; // pack point into an lparam lparam = lparam << 16; lparam = lparam + point.x; // wparm was the flags in this case. OTHER STUFF.... m_pTree->SendMessage(WM_LBUTTONDBLCLK,nFlags,(long) lparam); OTHER STUFF } Hope this helps, Jim Leavitt
| Вернуться в корень Архива |