diff options
author | Andreas Färber <andreas.faerber@web.de> | 2009-12-13 00:45:40 +0100 |
---|---|---|
committer | malc <av1474@comtv.ru> | 2010-01-07 10:57:32 +0300 |
commit | 44e4c0ba863b0be130d0e87e71f456b8b529addb (patch) | |
tree | 4c9e2986c1b2c638f3305892cfc450be28e3925b /cocoa.m | |
parent | 821b19fe923ac49a24cdb4af902584fdd019cee6 (diff) |
Cocoa: ppc64 host support
Fix integer usage in the Cocoa backend: NSInteger is long on LP64.
http://developer.apple.com/mac/library/documentation/Cocoa/Reference/ApplicationKit/Classes/NSView_Class/Reference/NSView.html#//apple_ref/doc/uid/20000014-BBCFHHCD
This makes the graphical display show up on a ppc64 host.
v3:
- Confine NSInteger to Mac OS X v10.5 and later
Signed-off-by: Andreas Färber <andreas.faerber@web.de>
Signed-off-by: malc <av1474@comtv.ru>
Diffstat (limited to 'cocoa.m')
-rw-r--r-- | cocoa.m | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -28,6 +28,10 @@ #include "console.h" #include "sysemu.h" +#ifndef MAC_OS_X_VERSION_10_5 +#define MAC_OS_X_VERSION_10_5 1050 +#endif + //#define DEBUG @@ -337,7 +341,11 @@ int cocoa_keycode_to_qemu(int keycode) } else { // selective drawing code (draws only dirty rectangles) (OS X >= 10.4) const NSRect *rectList; +#if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5) + NSInteger rectCount; +#else int rectCount; +#endif int i; CGImageRef clipImageRef; CGRect clipRect; |