[Python-checkins] CVS: python/dist/src/Mac/Modules macosmodule.c,1.52,1.53

Jack Jansen jackjansen@users.sourceforge.net
2001年5月12日 14:31:37 -0700


Update of /cvsroot/python/python/dist/src/Mac/Modules
In directory usw-pr-cvs1:/tmp/cvs-serv12246/Python/Mac/Modules
Modified Files:
	macosmodule.c 
Log Message:
Be more sensible about when to use TARGET_API_MAC_OS8 in stead of !TARGET_API_MAC_CARBON. This should greatly facilitate porting stuff to OSX in its MachO/BSD incarnation.
Index: macosmodule.c
===================================================================
RCS file: /cvsroot/python/python/dist/src/Mac/Modules/macosmodule.c,v
retrieving revision 1.52
retrieving revision 1.53
diff -C2 -r1.52 -r1.53
*** macosmodule.c	2001年01月23日 22:38:23	1.52
--- macosmodule.c	2001年05月12日 21:31:34	1.53
***************
*** 361,365 ****
 #include <Events.h>
 
! #if !TARGET_API_MAC_CARBON
 static char accepthle_doc[] = "Get arguments of pending high-level event";
 
--- 361,365 ----
 #include <Events.h>
 
! #if TARGET_API_MAC_OS8
 static char accepthle_doc[] = "Get arguments of pending high-level event";
 
***************
*** 705,709 ****
 
 static PyMethodDef MacOS_Methods[] = {
! #if !TARGET_API_MAC_CARBON
 	{"AcceptHighLevelEvent",	MacOS_AcceptHighLevelEvent, 1,	accepthle_doc},
 #endif
--- 705,709 ----
 
 static PyMethodDef MacOS_Methods[] = {
! #if TARGET_API_MAC_OS8
 	{"AcceptHighLevelEvent",	MacOS_AcceptHighLevelEvent, 1,	accepthle_doc},
 #endif
***************
*** 761,768 ****
 		return;
 #if TARGET_API_MAC_CARBON
- /* Will need a different name for MachO-carbon later (macho?) */
 #define PY_RUNTIMEMODEL "carbon"
! #else
 #define PY_RUNTIMEMODEL "ppc"
 #endif
 	if (PyDict_SetItemString(d, "runtimemodel", 
--- 761,771 ----
 		return;
 #if TARGET_API_MAC_CARBON
 #define PY_RUNTIMEMODEL "carbon"
! #elif TARGET_API_MAC_OS8
 #define PY_RUNTIMEMODEL "ppc"
+ #elif TARGET_API_MAC_OSX
+ #define PY_RUNTIMEMODEL "macho"
+ #else
+ #error "None of the TARGET_API_MAC_XXX I know about is set"
 #endif
 	if (PyDict_SetItemString(d, "runtimemodel", 

AltStyle によって変換されたページ (->オリジナル) /