Last change
on this file since 239 was
48,
checked in by sherbold, 13 years ago
|
- code clean-up: moved deprecated filter code to a txt-file for potential reuse
- code clean-up: moved helper functions to separate source code file
|
File size:
2.5 KB
|
Line | |
---|
1 | Code for an inverse filter:
|
---|
2 |
|
---|
3 | // inverse filter: defined messages will be filtered, all else just passes through
|
---|
4 | // may be replaced with a lookup-table to improve perfomance
|
---|
5 | // upon completion of the rules, i.e., when it is clear which messages are required,
|
---|
6 | // this should be changed to a "normal" filter.
|
---|
7 | switch(msg->message) {
|
---|
8 | case WM_NULL:
|
---|
9 | case WM_MOVE:
|
---|
10 | case WM_SIZE:
|
---|
11 | case WM_GETTEXT:
|
---|
12 | case WM_GETTEXTLENGTH:
|
---|
13 | case WM_PAINT:
|
---|
14 | case WM_ERASEBKGND:
|
---|
15 | case WM_SHOWWINDOW:
|
---|
16 | case WM_CANCELMODE:
|
---|
17 | case WM_SETCURSOR:
|
---|
18 | case WM_GETMINMAXINFO:
|
---|
19 | case WM_GETFONT:
|
---|
20 | case WM_WINDOWPOSCHANGING:
|
---|
21 | case WM_WINDOWPOSCHANGED:
|
---|
22 | case WM_NOTIFY:
|
---|
23 | case WM_STYLECHANGING:
|
---|
24 | case WM_STYLECHANGED:
|
---|
25 | case WM_GETICON:
|
---|
26 | case WM_NCCREATE:
|
---|
27 | case WM_NCDESTROY:
|
---|
28 | case WM_NCCALCSIZE:
|
---|
29 | case WM_NCHITTEST:
|
---|
30 | case WM_NCPAINT:
|
---|
31 | case WM_GETDLGCODE:
|
---|
32 | case 0x0090: // WM_UAHDESTROYWINDOW
|
---|
33 | case 0x0091: // WM_UAHDRAWMENU
|
---|
34 | case 0x0092: // WM_UADRAWMENUITEM
|
---|
35 | case 0x0093: // WM_UAHINITMENU
|
---|
36 | case 0x0094: // WM_UAHMEASUREMENUITEM
|
---|
37 | case 0x0095: // WM_UAHNCPAINTMENUPOPUP
|
---|
38 | case WM_NCMOUSEMOVE:
|
---|
39 | case WM_TIMER:
|
---|
40 | case WM_ENTERIDLE:
|
---|
41 | case WM_CTLCOLORMSGBOX:
|
---|
42 | case WM_CTLCOLOREDIT:
|
---|
43 | case WM_CTLCOLORLISTBOX:
|
---|
44 | case WM_CTLCOLORBTN:
|
---|
45 | case WM_CTLCOLORDLG:
|
---|
46 | case WM_CTLCOLORSCROLLBAR:
|
---|
47 | case WM_CTLCOLORSTATIC:
|
---|
48 | case WM_MOUSEMOVE:
|
---|
49 | case WM_PARENTNOTIFY:
|
---|
50 | case WM_MDIGETACTIVE:
|
---|
51 | case WM_IME_NOTIFY:
|
---|
52 | case WM_IME_SETCONTEXT:
|
---|
53 | case WM_AFXFIRST:
|
---|
54 | case WM_AFXFIRST+1:
|
---|
55 | case WM_AFXFIRST+2:
|
---|
56 | case WM_AFXFIRST+3:
|
---|
57 | case WM_AFXFIRST+4:
|
---|
58 | case WM_AFXFIRST+5:
|
---|
59 | case WM_AFXFIRST+6:
|
---|
60 | case WM_AFXFIRST+7:
|
---|
61 | case WM_AFXFIRST+8:
|
---|
62 | case WM_AFXFIRST+9:
|
---|
63 | case WM_AFXFIRST+10:
|
---|
64 | case WM_AFXFIRST+11:
|
---|
65 | case WM_AFXFIRST+12:
|
---|
66 | case WM_AFXFIRST+13:
|
---|
67 | case WM_AFXFIRST+14:
|
---|
68 | case WM_AFXFIRST+15:
|
---|
69 | case WM_AFXFIRST+16:
|
---|
70 | case WM_AFXFIRST+17:
|
---|
71 | case WM_AFXFIRST+18:
|
---|
72 | case WM_AFXFIRST+19:
|
---|
73 | case WM_AFXFIRST+20:
|
---|
74 | case WM_AFXFIRST+21:
|
---|
75 | case WM_AFXFIRST+22:
|
---|
76 | case WM_AFXFIRST+23:
|
---|
77 | case WM_AFXFIRST+24:
|
---|
78 | case WM_AFXFIRST+25:
|
---|
79 | case WM_AFXFIRST+26:
|
---|
80 | case WM_AFXFIRST+27:
|
---|
81 | case WM_AFXFIRST+28:
|
---|
82 | case WM_AFXFIRST+29:
|
---|
83 | case WM_AFXFIRST+30:
|
---|
84 | case WM_AFXLAST:
|
---|
85 | case 1025:
|
---|
86 | case 1031:
|
---|
87 | case 1142:
|
---|
88 | case 2024:
|
---|
89 | case 4100:
|
---|
90 | case 4101:
|
---|
91 | case 4103:
|
---|
92 | case 4352:
|
---|
93 | case 4362:
|
---|
94 | case 4363:
|
---|
95 | case 4364:
|
---|
96 | case 4365:
|
---|
97 | case 4372:
|
---|
98 | case 4613:
|
---|
99 | break;
|
---|
100 | default:
|
---|
101 | // exclude messages 0xC000-0xFFFF
|
---|
102 | if( !(msg->message>=0xC000 && msg->message<=0xFFFF) ) {
|
---|
103 | // CODE HERE!
|
---|
104 | }
|
---|
105 | break;
|
---|
106 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.