00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014 #include "user32.h"
00015 #include "syscolor.h"
00016 #include "win32wbase.h"
00017 #include "win32dlg.h"
00018
00019 #define DBG_LOCALLOG DBG_defwndproc
00020 #include "dbglocal.h"
00021
00022 #ifdef DEBUG
00023 char *GetMsgText(int Msg);
00024 #endif
00025
00026
00027
00028 LRESULT WIN32API DefWindowProcA(HWND hwnd, UINT Msg, WPARAM wParam, LPARAM lParam)
00029 {
00030 Win32BaseWindow *window;
00031 LRESULT result;
00032
00033 dprintf2(("DefWindowProcA %x %x %x %x", hwnd, Msg, wParam, lParam));
00034 window = Win32BaseWindow::GetWindowFromHandle(hwnd);
00035 if(!window) {
00036 dprintf(("DefWindowProcA, window %x not found", hwnd));
00037 return 0;
00038 }
00039 result = window->DefWindowProcA(Msg, wParam, lParam);
00040 RELEASE_WNDOBJ(window);
00041 return result;
00042 }
00043
00044
00045 LRESULT WIN32API DefWindowProcW(HWND hwnd, UINT Msg, WPARAM wParam, LPARAM lParam)
00046 {
00047 Win32BaseWindow *window;
00048 LRESULT result;
00049
00050 dprintf2(("DefWindowProcW %x %x %x %x", hwnd, Msg, wParam, lParam));
00051 window = Win32BaseWindow::GetWindowFromHandle(hwnd);
00052 if(!window) {
00053 dprintf(("DefWindowProcW, window %x not found", hwnd));
00054 return 0;
00055 }
00056 result = window->DefWindowProcW(Msg, wParam, lParam);
00057 RELEASE_WNDOBJ(window);
00058 return result;
00059 }
00060
00061
00062 LRESULT WIN32API DefDlgProcA(HWND hwnd, UINT Msg, WPARAM wParam, LPARAM lParam)
00063 {
00064 Win32Dialog *dialog;
00065 LRESULT result;
00066
00067 dialog = (Win32Dialog *)Win32BaseWindow::GetWindowFromHandle(hwnd);
00068
00069
00070 if(!dialog) {
00071 dprintf(("DefDlgProcA, window %x not found", hwnd));
00072 return 0;
00073 }
00074 if(dialog->IsDialog())
00075 result = dialog->DefDlgProcA(Msg, wParam, lParam);
00076 else result = dialog->DefWindowProcA(Msg, wParam, lParam);
00077 RELEASE_WNDOBJ(dialog);
00078 return result;
00079 }
00080
00081
00082 LRESULT WIN32API DefDlgProcW(HWND hwnd, UINT Msg, WPARAM wParam, LPARAM lParam)
00083 {
00084 Win32Dialog *dialog;
00085 LRESULT result;
00086
00087 dialog = (Win32Dialog *)Win32BaseWindow::GetWindowFromHandle(hwnd);
00088
00089
00090 if(!dialog) {
00091 dprintf(("DefDlgProcW, window %x not found", hwnd));
00092 return 0;
00093 }
00094 if(dialog->IsDialog())
00095 result = dialog->DefDlgProcW(Msg, wParam, lParam);
00096 else result = dialog->DefWindowProcW(Msg, wParam, lParam);
00097 RELEASE_WNDOBJ(dialog);
00098 return result;
00099 }
00100
00101