[pywin32-checkins] pywin32/win32/src PyWinTypesmodule.cpp, 1.42, 1.43
OLD project page for the Python extensions for Windows
Brought to you by:
mhammond
From: Mark H. <mha...@us...> - 2008-11-11 00:38:27
|
Update of /cvsroot/pywin32/pywin32/win32/src In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv23360/win32/src Modified Files: PyWinTypesmodule.cpp Log Message: Merge 64bit fixes from py3k branch Index: PyWinTypesmodule.cpp =================================================================== RCS file: /cvsroot/pywin32/pywin32/win32/src/PyWinTypesmodule.cpp,v retrieving revision 1.42 retrieving revision 1.43 diff -C2 -d -r1.42 -r1.43 *** PyWinTypesmodule.cpp 11 Nov 2008 00:26:34 -0000 1.42 --- PyWinTypesmodule.cpp 11 Nov 2008 00:38:23 -0000 1.43 *************** *** 740,765 **** BOOL PyWinObject_AsMSG(PyObject *ob, MSG *pMsg) { ! PyObject *obhwnd; ! if (!PyArg_ParseTuple(ob, "Oiiii(ii):MSG param", &obhwnd, // @tupleitem 0|<o PyHANDLE>|hwnd|Handle to the window whose window procedure receives the message. &pMsg->message, // @tupleitem 1|int|message|Specifies the message identifier. ! &pMsg->wParam, // @tupleitem 2|int|wParam|Specifies additional information about the message. ! &pMsg->lParam, // @tupleitem 3|int|lParam|Specifies additional information about the message. &pMsg->time, // @tupleitem 4|int|time|Specifies the time at which the message was posted (retrieved via GetTickCount()). &pMsg->pt.x, // @tupleitem 5|(int, int)|point|Specifies the cursor position, in screen coordinates, when the message was posted. &pMsg->pt.y)) return FALSE; ! if (!PyWinObject_AsHANDLE(obhwnd, (HANDLE *)&pMsg->hwnd)) ! return FALSE; ! return TRUE; } PyObject *PyWinObject_FromMSG(const MSG *pMsg) { ! return Py_BuildValue("Niiii(ii)", PyWinLong_FromHANDLE(pMsg->hwnd), pMsg->message, ! pMsg->wParam, ! pMsg->lParam, pMsg->time, pMsg->pt.x, --- 740,765 ---- BOOL PyWinObject_AsMSG(PyObject *ob, MSG *pMsg) { ! PyObject *obhwnd, *obwParam, *oblParam; ! if (!PyArg_ParseTuple(ob, "OiOOi(ii):MSG param", &obhwnd, // @tupleitem 0|<o PyHANDLE>|hwnd|Handle to the window whose window procedure receives the message. &pMsg->message, // @tupleitem 1|int|message|Specifies the message identifier. ! &obwParam, // @tupleitem 2|int|wParam|Specifies additional information about the message. ! &oblParam, // @tupleitem 3|int|lParam|Specifies additional information about the message. &pMsg->time, // @tupleitem 4|int|time|Specifies the time at which the message was posted (retrieved via GetTickCount()). &pMsg->pt.x, // @tupleitem 5|(int, int)|point|Specifies the cursor position, in screen coordinates, when the message was posted. &pMsg->pt.y)) return FALSE; ! return PyWinObject_AsHANDLE(obhwnd, (HANDLE *)&pMsg->hwnd) ! &&PyWinObject_AsPARAM(obwParam, &pMsg->wParam) ! &&PyWinObject_AsPARAM(oblParam, &pMsg->lParam); } PyObject *PyWinObject_FromMSG(const MSG *pMsg) { ! return Py_BuildValue("NiNNi(ii)", PyWinLong_FromHANDLE(pMsg->hwnd), pMsg->message, ! PyWinObject_FromPARAM(pMsg->wParam), ! PyWinObject_FromPARAM(pMsg->lParam), pMsg->time, pMsg->pt.x, |