[Python-checkins] python/dist/src/Mac/Modules/dlg _Dlgmodule.c,1.17,1.18 dlgscan.py,1.18,1.19

jackjansen@users.sourceforge.net jackjansen@users.sourceforge.net
Thu, 27 Feb 2003 14:50:52 -0800


Update of /cvsroot/python/python/dist/src/Mac/Modules/dlg
In directory sc8-pr-cvs1:/tmp/cvs-serv32629

Modified Files:
	_Dlgmodule.c dlgscan.py 
Log Message:
StdFilterProc() uses InOut parameters.


Index: _Dlgmodule.c
===================================================================
RCS file: /cvsroot/python/python/dist/src/Mac/Modules/dlg/_Dlgmodule.c,v
retrieving revision 1.17
retrieving revision 1.18
diff -C2 -d -r1.17 -r1.18
*** _Dlgmodule.c	23 Dec 2002 23:16:22 -0000	1.17
--- _Dlgmodule.c	27 Feb 2003 22:50:49 -0000	1.18
***************
*** 15,21 ****
  /* Macro to test whether a weak-loaded CFM function exists */
  #define PyMac_PRECHECK(rtn) do { if ( &rtn == NULL )  {\
!     	PyErr_SetString(PyExc_NotImplementedError, \
!     	"Not available in this shared library/OS version"); \
!     	return NULL; \
      }} while(0)
  
--- 15,21 ----
  /* Macro to test whether a weak-loaded CFM function exists */
  #define PyMac_PRECHECK(rtn) do { if ( &rtn == NULL )  {\
!         PyErr_SetString(PyExc_NotImplementedError, \
!         "Not available in this shared library/OS version"); \
!         return NULL; \
      }} while(0)
  
***************
*** 503,507 ****
  	PyMac_PRECHECK(StdFilterProc);
  #endif
! 	if (!PyArg_ParseTuple(_args, ""))
  		return NULL;
  	_rv = StdFilterProc(_self->ob_itself,
--- 503,509 ----
  	PyMac_PRECHECK(StdFilterProc);
  #endif
! 	if (!PyArg_ParseTuple(_args, "O&h",
! 	                      PyMac_GetEventRecord, &event,
! 	                      &itemHit))
  		return NULL;
  	_rv = StdFilterProc(_self->ob_itself,
***************
*** 904,908 ****
  	 PyDoc_STR("(DialogItemIndex itemNo, DialogItemIndex amountToRemove, Boolean disposeItemData) -> None")},
  	{"StdFilterProc", (PyCFunction)DlgObj_StdFilterProc, 1,
! 	 PyDoc_STR("() -> (Boolean _rv, EventRecord event, DialogItemIndex itemHit)")},
  	{"SetDialogDefaultItem", (PyCFunction)DlgObj_SetDialogDefaultItem, 1,
  	 PyDoc_STR("(DialogItemIndex newItem) -> None")},
--- 906,910 ----
  	 PyDoc_STR("(DialogItemIndex itemNo, DialogItemIndex amountToRemove, Boolean disposeItemData) -> None")},
  	{"StdFilterProc", (PyCFunction)DlgObj_StdFilterProc, 1,
! 	 PyDoc_STR("(EventRecord event, DialogItemIndex itemHit) -> (Boolean _rv, EventRecord event, DialogItemIndex itemHit)")},
  	{"SetDialogDefaultItem", (PyCFunction)DlgObj_SetDialogDefaultItem, 1,
  	 PyDoc_STR("(DialogItemIndex newItem) -> None")},

Index: dlgscan.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Mac/Modules/dlg/dlgscan.py,v
retrieving revision 1.18
retrieving revision 1.19
diff -C2 -d -r1.18 -r1.19
*** dlgscan.py	12 Dec 2002 10:31:50 -0000	1.18
--- dlgscan.py	27 Feb 2003 22:50:50 -0000	1.19
***************
*** 100,103 ****
--- 100,110 ----
  			([("WindowPtr", "*", "ReturnMode")],
  			 [("ExistingWindowPtr", "*", "*")]),
+ 			 
+ 			# StdFilterProc
+ 			([('EventRecord', 'event', 'OutMode'), 
+ 			  ('DialogItemIndex', 'itemHit', 'OutMode')],
+ 			 [('EventRecord', 'event', 'InOutMode'), 
+ 			  ('DialogItemIndex', 'itemHit', 'InOutMode')])
+ 
  			]