Some more filter procedure rewriting, preparing for the future dialog message hack attempt.

This commit is contained in:
Pietro Gagliardi 2016-04-22 14:56:09 -04:00
parent 960533ab1f
commit 02b5285aa0
1 changed files with 7 additions and 4 deletions

View File

@ -6,16 +6,19 @@ static HHOOK filter;
static LRESULT CALLBACK filterProc(int code, WPARAM wParam, LPARAM lParam)
{
MSG *msg = (MSG *) lParam;
BOOL discard;
if (code < 0)
goto callNext;
discard = !areaFilter(msg);
if (areaFilter(msg)) // don't continue to our IsDialogMessage() hack if the area handled it
goto discard;
if (discard)
// TODO IsDialogMessage() hack here
// otherwise keep going
goto callNext;
discard:
// we handled it; discard the message so the dialog manager doesn't see it
return 1;