RE: Win32LIB V0.57.4 LV onClick
> -----Original Message-----
> From: Matthew Lewis [mailto:matthewwalkerlewis at YAHOO.COM]
>
> Looks like listviews do send NM_CLICK notifications:
In fact, looks like I posted this last year :)
From: Matthew Lewis <matthewwalkerlewis at YAHOO.COM>
Subject: RE: weird listview behavior
> And BTW, listview seems to not have the onClick event. I thought
> listview is like listbox except it has columns. Listbox has
> the onClick
> event; why not also listview?
Listviews handle mouse events a little differently (apparently). You need
to add:
function fDoNM_CLICK(integer id, atom hWnd, atom wParam, atom lParam)
hWnd = fetch( lParam, NMHDR_hwndFrom )
id = getId( hWnd )
invokeHandler( id, w32HClick, {} )
return {}
end function
...and make sure you also modify:
constant kNotifications =
{
TCN_SELCHANGE
, LVN_COLUMNCLICK
, LVN_GETDISPINFO
, LVN_BEGINDRAG
, TVN_GETDISPINFO
, TVN_SELCHANGED
, TVN_DELETEITEM
, TTN_GETDISPINFO
, MCN_SELCHANGE
, TBN_GETBUTTONINFO
, TBN_QUERYINSERT
, TBN_QUERYDELETE
-- added NM_CLICK
, NM_CLICK
}
constant kNotifyHandlers =
{
routine_id("fDoTCN_SELCHANGE")
, routine_id("fDoLVN_COLUMNCLICK")
, routine_id("fDoLVN_GETDISPINFO")
, routine_id("fDoLVN_BEGINDRAG")
, routine_id("fDoTVN_GETDISPINFO")
, routine_id("fDoTVN_SELCHANGED")
, routine_id("fDoTVN_DELETEITEM")
, routine_id("fDoTTN_GETDISPINFO")
, routine_id("fDoMCN_SELCHANGE")
, routine_id("fDoTBN_GETBUTTONINFO")
, routine_id("fDoTBN_QUERYINSERT")
, routine_id("fDoTBN_QUERYDELETE")
-- added fDoNM_CLICK Matt Lewis
, routine_id("fDoNM_CLICK")
It doesn't look like NM_CLICK is defined in the latest version, but I don't
have the value handy at the moment...
Matt Lewis
|
Not Categorized, Please Help
|
|