Changeset 37 for trunk/src/user32/defwndproc.cpp
- Timestamp:
- Jun 6, 1999, 2:25:49 PM (26 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/user32/defwndproc.cpp
r4 r37 1 /* $Id: defwndproc.cpp,v 1. 1 1999-05-24 20:20:01 ktkExp $ */1 /* $Id: defwndproc.cpp,v 1.2 1999-06-06 12:25:49 cbratschi Exp $ */ 2 2 3 3 /* … … 22 22 #endif 23 23 switch(Msg) { 24 case WM_NCCREATE://SvL: YAFMO (yet another feature missing in Open32) 25 return(TRUE); 26 case WM_CTLCOLORMSGBOX: 27 case WM_CTLCOLOREDIT: 28 case WM_CTLCOLORLISTBOX: 29 case WM_CTLCOLORBTN: 30 case WM_CTLCOLORDLG: 31 case WM_CTLCOLORSTATIC: 32 case WM_CTLCOLORSCROLLBAR: 33 SetBkColor((HDC)wParam, GetSysColor(COLOR_WINDOW)); 34 SetTextColor((HDC)wParam, GetSysColor(COLOR_WINDOWTEXT)); 35 return GetSysColorBrush(COLOR_BTNFACE); 36 37 default: 38 return O32_DefWindowProc(hwnd, Msg, wParam, lParam); 24 case WM_SETREDRAW: //Open32 does not set the visible flag 25 { 26 long dwStyle = GetWindowLongA (hwnd, GWL_STYLE); 27 if(wParam) 28 SetWindowLongA (hwnd, GWL_STYLE, dwStyle | WS_VISIBLE); 29 else 30 SetWindowLongA (hwnd, GWL_STYLE, dwStyle & ~WS_VISIBLE); 31 return O32_DefWindowProc(hwnd, Msg, wParam, lParam); 32 } 33 case WM_NCCREATE://SvL: YAFMO (yet another feature missing in Open32) 34 return(TRUE); 35 case WM_CTLCOLORMSGBOX: 36 case WM_CTLCOLOREDIT: 37 case WM_CTLCOLORLISTBOX: 38 case WM_CTLCOLORBTN: 39 case WM_CTLCOLORDLG: 40 case WM_CTLCOLORSTATIC: 41 case WM_CTLCOLORSCROLLBAR: 42 SetBkColor((HDC)wParam, GetSysColor(COLOR_WINDOW)); 43 SetTextColor((HDC)wParam, GetSysColor(COLOR_WINDOWTEXT)); 44 return GetSysColorBrush(COLOR_BTNFACE); 45 46 default: 47 return O32_DefWindowProc(hwnd, Msg, wParam, lParam); 39 48 } 40 49 } … … 48 57 #endif 49 58 switch(Msg) { 50 case WM_NCCREATE://SvL: YAOFM (yet another open32 feature missing) 51 return(TRUE); 52 case WM_CTLCOLORMSGBOX: 53 case WM_CTLCOLOREDIT: 54 case WM_CTLCOLORLISTBOX: 55 case WM_CTLCOLORBTN: 56 case WM_CTLCOLORDLG: 57 case WM_CTLCOLORSTATIC: 58 case WM_CTLCOLORSCROLLBAR: 59 SetBkColor((HDC)wParam, GetSysColor(COLOR_WINDOW)); 60 SetTextColor((HDC)wParam, GetSysColor(COLOR_WINDOWTEXT)); 61 return GetSysColorBrush(COLOR_BTNFACE); 62 63 default: 64 return O32_DefWindowProc(hwnd, Msg, wParam, lParam); 59 case WM_SETREDRAW: //Open32 does not set the visible flag 60 { 61 long dwStyle = GetWindowLongA (hwnd, GWL_STYLE); 62 if(wParam) 63 SetWindowLongA (hwnd, GWL_STYLE, dwStyle | WS_VISIBLE); 64 else 65 SetWindowLongA (hwnd, GWL_STYLE, dwStyle & ~WS_VISIBLE); 66 return O32_DefWindowProc(hwnd, Msg, wParam, lParam); 67 } 68 case WM_NCCREATE://SvL: YAOFM (yet another open32 feature missing) 69 return(TRUE); 70 case WM_CTLCOLORMSGBOX: 71 case WM_CTLCOLOREDIT: 72 case WM_CTLCOLORLISTBOX: 73 case WM_CTLCOLORBTN: 74 case WM_CTLCOLORDLG: 75 case WM_CTLCOLORSTATIC: 76 case WM_CTLCOLORSCROLLBAR: 77 SetBkColor((HDC)wParam, GetSysColor(COLOR_WINDOW)); 78 SetTextColor((HDC)wParam, GetSysColor(COLOR_WINDOWTEXT)); 79 return GetSysColorBrush(COLOR_BTNFACE); 80 81 default: 82 return O32_DefWindowProc(hwnd, Msg, wParam, lParam); 65 83 } 66 84 } … … 73 91 #endif 74 92 switch(Msg) { 75 case WM_NCCREATE://SvL: YAOFM (yet another open32 feature missing) 76 return(TRUE); 77 case WM_CTLCOLORMSGBOX: 78 case WM_CTLCOLOREDIT: 79 case WM_CTLCOLORLISTBOX: 80 case WM_CTLCOLORBTN: 81 case WM_CTLCOLORDLG: 82 case WM_CTLCOLORSTATIC: 83 case WM_CTLCOLORSCROLLBAR: 84 SetBkColor((HDC)wParam, GetSysColor(COLOR_WINDOW)); 85 SetTextColor((HDC)wParam, GetSysColor(COLOR_WINDOWTEXT)); 86 return GetSysColorBrush(COLOR_BTNFACE); 87 88 default: 89 return O32_DefDlgProc(hwnd, Msg, wParam, lParam); 93 case WM_SETREDRAW: //Open32 does not set the visible flag 94 { 95 long dwStyle = GetWindowLongA (hwnd, GWL_STYLE); 96 if(wParam) 97 SetWindowLongA (hwnd, GWL_STYLE, dwStyle | WS_VISIBLE); 98 else 99 SetWindowLongA (hwnd, GWL_STYLE, dwStyle & ~WS_VISIBLE); 100 return O32_DefWindowProc(hwnd, Msg, wParam, lParam); 101 } 102 case WM_NCCREATE://SvL: YAOFM (yet another open32 feature missing) 103 return(TRUE); 104 case WM_CTLCOLORMSGBOX: 105 case WM_CTLCOLOREDIT: 106 case WM_CTLCOLORLISTBOX: 107 case WM_CTLCOLORBTN: 108 case WM_CTLCOLORDLG: 109 case WM_CTLCOLORSTATIC: 110 case WM_CTLCOLORSCROLLBAR: 111 SetBkColor((HDC)wParam, GetSysColor(COLOR_WINDOW)); 112 SetTextColor((HDC)wParam, GetSysColor(COLOR_WINDOWTEXT)); 113 return GetSysColorBrush(COLOR_BTNFACE); 114 115 default: 116 return O32_DefDlgProc(hwnd, Msg, wParam, lParam); 90 117 } 91 118 } … … 99 126 #endif 100 127 switch(Msg) { 101 case WM_NCCREATE://SvL: YAOFM (yet another open32 feature missing) 102 return(TRUE); 103 case WM_CTLCOLORMSGBOX: 104 case WM_CTLCOLOREDIT: 105 case WM_CTLCOLORLISTBOX: 106 case WM_CTLCOLORBTN: 107 case WM_CTLCOLORDLG: 108 case WM_CTLCOLORSTATIC: 109 case WM_CTLCOLORSCROLLBAR: 110 SetBkColor((HDC)wParam, GetSysColor(COLOR_WINDOW)); 111 SetTextColor((HDC)wParam, GetSysColor(COLOR_WINDOWTEXT)); 112 return GetSysColorBrush(COLOR_BTNFACE); 113 114 default: 115 return O32_DefDlgProc(hwnd, Msg, wParam, lParam); 128 case WM_SETREDRAW: //Open32 does not set the visible flag 129 { 130 long dwStyle = GetWindowLongA (hwnd, GWL_STYLE); 131 if(wParam) 132 SetWindowLongA (hwnd, GWL_STYLE, dwStyle | WS_VISIBLE); 133 else 134 SetWindowLongA (hwnd, GWL_STYLE, dwStyle & ~WS_VISIBLE); 135 return O32_DefWindowProc(hwnd, Msg, wParam, lParam); 136 } 137 case WM_NCCREATE://SvL: YAOFM (yet another open32 feature missing) 138 return(TRUE); 139 case WM_CTLCOLORMSGBOX: 140 case WM_CTLCOLOREDIT: 141 case WM_CTLCOLORLISTBOX: 142 case WM_CTLCOLORBTN: 143 case WM_CTLCOLORDLG: 144 case WM_CTLCOLORSTATIC: 145 case WM_CTLCOLORSCROLLBAR: 146 SetBkColor((HDC)wParam, GetSysColor(COLOR_WINDOW)); 147 SetTextColor((HDC)wParam, GetSysColor(COLOR_WINDOWTEXT)); 148 return GetSysColorBrush(COLOR_BTNFACE); 149 150 default: 151 return O32_DefDlgProc(hwnd, Msg, wParam, lParam); 116 152 } 117 153 } … … 124 160 #endif 125 161 switch(Msg) { 126 case WM_NCCREATE://SvL: YAOFM (yet another open32 feature missing) 127 return(TRUE); 128 case WM_CTLCOLORMSGBOX: 129 case WM_CTLCOLOREDIT: 130 case WM_CTLCOLORLISTBOX: 131 case WM_CTLCOLORBTN: 132 case WM_CTLCOLORDLG: 133 case WM_CTLCOLORSTATIC: 134 case WM_CTLCOLORSCROLLBAR: 135 SetBkColor((HDC)wParam, GetSysColor(COLOR_WINDOW)); 136 SetTextColor((HDC)wParam, GetSysColor(COLOR_WINDOWTEXT)); 137 return GetSysColorBrush(COLOR_BTNFACE); 138 139 default: 140 return O32_DefFrameProc(hwndFrame, hwndClient, Msg, wParam, lParam); 162 case WM_SETREDRAW: //Open32 does not set the visible flag 163 { 164 //Frame 165 long dwStyle = GetWindowLongA (hwndFrame, GWL_STYLE); 166 if(wParam) 167 SetWindowLongA (hwndFrame, GWL_STYLE, dwStyle | WS_VISIBLE); 168 else 169 SetWindowLongA (hwndFrame, GWL_STYLE, dwStyle & ~WS_VISIBLE); 170 return O32_DefWindowProc(hwndFrame, Msg, wParam, lParam); 171 //Client 172 dwStyle = GetWindowLongA (hwndClient, GWL_STYLE); 173 if(wParam) 174 SetWindowLongA (hwndClient, GWL_STYLE, dwStyle | WS_VISIBLE); 175 else 176 SetWindowLongA (hwndClient, GWL_STYLE, dwStyle & ~WS_VISIBLE); 177 return O32_DefWindowProc(hwndClient, Msg, wParam, lParam); 178 } 179 case WM_NCCREATE://SvL: YAOFM (yet another open32 feature missing) 180 return(TRUE); 181 case WM_CTLCOLORMSGBOX: 182 case WM_CTLCOLOREDIT: 183 case WM_CTLCOLORLISTBOX: 184 case WM_CTLCOLORBTN: 185 case WM_CTLCOLORDLG: 186 case WM_CTLCOLORSTATIC: 187 case WM_CTLCOLORSCROLLBAR: 188 SetBkColor((HDC)wParam, GetSysColor(COLOR_WINDOW)); 189 SetTextColor((HDC)wParam, GetSysColor(COLOR_WINDOWTEXT)); 190 return GetSysColorBrush(COLOR_BTNFACE); 191 192 default: 193 return O32_DefFrameProc(hwndFrame, hwndClient, Msg, wParam, lParam); 141 194 } 142 195 } … … 150 203 #endif 151 204 switch(Msg) { 152 case WM_NCCREATE://SvL: YAOFM (yet another open32 feature missing) 153 return(TRUE); 154 case WM_CTLCOLORMSGBOX: 155 case WM_CTLCOLOREDIT: 156 case WM_CTLCOLORLISTBOX: 157 case WM_CTLCOLORBTN: 158 case WM_CTLCOLORDLG: 159 case WM_CTLCOLORSTATIC: 160 case WM_CTLCOLORSCROLLBAR: 161 SetBkColor((HDC)wParam, GetSysColor(COLOR_WINDOW)); 162 SetTextColor((HDC)wParam, GetSysColor(COLOR_WINDOWTEXT)); 163 return GetSysColorBrush(COLOR_BTNFACE); 164 165 default: 166 return O32_DefFrameProc(hwndFrame, hwndClient, Msg, wParam, lParam); 205 case WM_SETREDRAW: //Open32 does not set the visible flag 206 { 207 //Frame 208 long dwStyle = GetWindowLongA (hwndFrame, GWL_STYLE); 209 if(wParam) 210 SetWindowLongA (hwndFrame, GWL_STYLE, dwStyle | WS_VISIBLE); 211 else 212 SetWindowLongA (hwndFrame, GWL_STYLE, dwStyle & ~WS_VISIBLE); 213 return O32_DefWindowProc(hwndFrame, Msg, wParam, lParam); 214 //Client 215 dwStyle = GetWindowLongA (hwndClient, GWL_STYLE); 216 if(wParam) 217 SetWindowLongA (hwndClient, GWL_STYLE, dwStyle | WS_VISIBLE); 218 else 219 SetWindowLongA (hwndClient, GWL_STYLE, dwStyle & ~WS_VISIBLE); 220 return O32_DefWindowProc(hwndClient, Msg, wParam, lParam); 221 } 222 case WM_NCCREATE://SvL: YAOFM (yet another open32 feature missing) 223 return(TRUE); 224 case WM_CTLCOLORMSGBOX: 225 case WM_CTLCOLOREDIT: 226 case WM_CTLCOLORLISTBOX: 227 case WM_CTLCOLORBTN: 228 case WM_CTLCOLORDLG: 229 case WM_CTLCOLORSTATIC: 230 case WM_CTLCOLORSCROLLBAR: 231 SetBkColor((HDC)wParam, GetSysColor(COLOR_WINDOW)); 232 SetTextColor((HDC)wParam, GetSysColor(COLOR_WINDOWTEXT)); 233 return GetSysColorBrush(COLOR_BTNFACE); 234 235 default: 236 return O32_DefFrameProc(hwndFrame, hwndClient, Msg, wParam, lParam); 167 237 } 168 238 } … … 175 245 #endif 176 246 switch(Msg) { 177 case WM_NCCREATE://SvL: YAOFM (yet another open32 feature missing) 178 return(TRUE); 179 case WM_CTLCOLORMSGBOX: 180 case WM_CTLCOLOREDIT: 181 case WM_CTLCOLORLISTBOX: 182 case WM_CTLCOLORBTN: 183 case WM_CTLCOLORDLG: 184 case WM_CTLCOLORSTATIC: 185 case WM_CTLCOLORSCROLLBAR: 186 SetBkColor((HDC)wParam, GetSysColor(COLOR_WINDOW)); 187 SetTextColor((HDC)wParam, GetSysColor(COLOR_WINDOWTEXT)); 188 return GetSysColorBrush(COLOR_BTNFACE); 189 190 default: 191 return O32_DefMDIChildProc(hwnd, Msg, wParam, lParam); 247 case WM_SETREDRAW: //Open32 does not set the visible flag 248 { 249 long dwStyle = GetWindowLongA (hwnd, GWL_STYLE); 250 if(wParam) 251 SetWindowLongA (hwnd, GWL_STYLE, dwStyle | WS_VISIBLE); 252 else 253 SetWindowLongA (hwnd, GWL_STYLE, dwStyle & ~WS_VISIBLE); 254 return O32_DefWindowProc(hwnd, Msg, wParam, lParam); 255 } 256 case WM_NCCREATE://SvL: YAOFM (yet another open32 feature missing) 257 return(TRUE); 258 case WM_CTLCOLORMSGBOX: 259 case WM_CTLCOLOREDIT: 260 case WM_CTLCOLORLISTBOX: 261 case WM_CTLCOLORBTN: 262 case WM_CTLCOLORDLG: 263 case WM_CTLCOLORSTATIC: 264 case WM_CTLCOLORSCROLLBAR: 265 SetBkColor((HDC)wParam, GetSysColor(COLOR_WINDOW)); 266 SetTextColor((HDC)wParam, GetSysColor(COLOR_WINDOWTEXT)); 267 return GetSysColorBrush(COLOR_BTNFACE); 268 269 default: 270 return O32_DefMDIChildProc(hwnd, Msg, wParam, lParam); 192 271 } 193 272 } … … 201 280 #endif 202 281 switch(Msg) { 203 case WM_NCCREATE://SvL: YAOFM (yet another open32 feature missing) 204 return(TRUE); 205 case WM_CTLCOLORMSGBOX: 206 case WM_CTLCOLOREDIT: 207 case WM_CTLCOLORLISTBOX: 208 case WM_CTLCOLORBTN: 209 case WM_CTLCOLORDLG: 210 case WM_CTLCOLORSTATIC: 211 case WM_CTLCOLORSCROLLBAR: 212 SetBkColor((HDC)wParam, GetSysColor(COLOR_WINDOW)); 213 SetTextColor((HDC)wParam, GetSysColor(COLOR_WINDOWTEXT)); 214 return GetSysColorBrush(COLOR_BTNFACE); 215 216 default: 217 return O32_DefMDIChildProc(hwnd, Msg, wParam, lParam); 218 } 219 } 220 //****************************************************************************** 221 //****************************************************************************** 282 case WM_SETREDRAW: //Open32 does not set the visible flag 283 { 284 long dwStyle = GetWindowLongA (hwnd, GWL_STYLE); 285 if(wParam) 286 SetWindowLongA (hwnd, GWL_STYLE, dwStyle | WS_VISIBLE); 287 else 288 SetWindowLongA (hwnd, GWL_STYLE, dwStyle & ~WS_VISIBLE); 289 return O32_DefWindowProc(hwnd, Msg, wParam, lParam); 290 } 291 case WM_NCCREATE://SvL: YAOFM (yet another open32 feature missing) 292 return(TRUE); 293 case WM_CTLCOLORMSGBOX: 294 case WM_CTLCOLOREDIT: 295 case WM_CTLCOLORLISTBOX: 296 case WM_CTLCOLORBTN: 297 case WM_CTLCOLORDLG: 298 case WM_CTLCOLORSTATIC: 299 case WM_CTLCOLORSCROLLBAR: 300 SetBkColor((HDC)wParam, GetSysColor(COLOR_WINDOW)); 301 SetTextColor((HDC)wParam, GetSysColor(COLOR_WINDOWTEXT)); 302 return GetSysColorBrush(COLOR_BTNFACE); 303 304 default: 305 return O32_DefMDIChildProc(hwnd, Msg, wParam, lParam); 306 } 307 } 308 //****************************************************************************** 309 //******************************************************************************
Note:
See TracChangeset
for help on using the changeset viewer.