[pywin32-checkins] pywin32/win32/Demos win32gui_menu.py,1.4,1.5
OLD project page for the Python extensions for Windows
Brought to you by:
mhammond
From: Roger U. <ru...@us...> - 2007-09-06 06:44:52
|
Update of /cvsroot/pywin32/pywin32/win32/Demos In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20690/win32/Demos Modified Files: win32gui_menu.py Log Message: 64-bit fixes Index: win32gui_menu.py =================================================================== RCS file: /cvsroot/pywin32/pywin32/win32/Demos/win32gui_menu.py,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** win32gui_menu.py 2 Jul 2006 23:30:12 -0000 1.4 --- win32gui_menu.py 6 Sep 2007 06:44:54 -0000 1.5 *************** *** 256,260 **** # we pretend we have more than that :) def OnMeasureItem(self, hwnd, msg, wparam, lparam): ! fmt = "6i" buf = PyMakeBuffer(struct.calcsize(fmt), lparam) data = struct.unpack(fmt, buf) --- 256,261 ---- # we pretend we have more than that :) def OnMeasureItem(self, hwnd, msg, wparam, lparam): ! ## Last item of MEASUREITEMSTRUCT is a ULONG_PTR ! fmt = "5iP" buf = PyMakeBuffer(struct.calcsize(fmt), lparam) data = struct.unpack(fmt, buf) *************** *** 284,288 **** def OnDrawItem(self, hwnd, msg, wparam, lparam): ! fmt = "12i" data = struct.unpack(fmt, PyGetString(lparam, struct.calcsize(fmt))) ctlType, ctlID, itemID, itemAction, itemState, hwndItem, \ --- 285,290 ---- def OnDrawItem(self, hwnd, msg, wparam, lparam): ! ## lparam is a DRAWITEMSTRUCT ! fmt = "5i2P4iP" data = struct.unpack(fmt, PyGetString(lparam, struct.calcsize(fmt))) ctlType, ctlID, itemID, itemAction, itemState, hwndItem, \ |