Extended TreeView

BlitzPlus Forums/BlitzPlus Programming/Extended TreeView

hi

yes using a .dll if you code using c, then you could setup a hook using SetWindowsHookEx() using WH_CALLWNDPROCRET or WH_CALLWNDPROC hook then you could process the messages before or after blitz+ gets them.

somthing this this

HHOOK HookRET = SetWindowsHookEx(WH_CALLWNDPROCRET,GLOBAL_HOOKED_MESSAGE_WINPROC_RET,0,GetCurrentThreadId());


where GLOBAL_HOOKED_MESSAGE_WINPROC_RET is a callback, ie.

LRESULT CALLBACK GLOBAL_HOOKED_MESSAGE_WINPROC_RET(int code,WPARAM wParam,LPARAM lParam){
    if(code<<HC_ACTION){
                    return CallNextHookEx(HookRET,code,wParam,lParam);
            }else{
                    CWPRETSTRUCT *msg = (CWPRETSTRUCT*)lParam;
                    // process you hooked events here
    }
}


kev