| [ Return to Bugs & Features | Roadmap 1.3 | SVN ⇄ GIT ]
STR #2917
Application: | FLTK Library |
Status: | 1 - Closed w/Resolution |
Priority: | 3 - Moderate, e.g. unable to compile the software |
Scope: | 2 - Specific to an operating system |
Subsystem: | MacOS |
Summary: | FLTK 1.3.2/trunk does not compile on OS X 10.4 and older |
Version: | 1.3-current |
Created By: | astrand |
Assigned To: | manolo |
Fix Version: | 1.3-current (SVN: v9799) |
Update Notification: | |
Trouble Report Files:
No files
Trouble Report Comments:
|
#1 | astrand 04:13 Jan 16, 2013 |
| FLTK 1.3.2/trunk does not compile on OS X 10.4 and older:
Fl_cocoa.mm:3379:26: error: cannot convert 'objc_object*' to 'CGImage*' in assignment
The fix is simple, we just need a cast:
--- fltk-1.3.2.org/src/Fl_cocoa.mm 2013-01-16 11:32:11.788478228 +0100 +++ fltk-1.3.2/src/Fl_cocoa.mm 2013-01-16 11:32:55.824101285 +0100 @@ -3727,7 +3727,7 @@ CGImageRef Fl_X::CGImage_from_window_rec CGImageRef img; if (fl_mac_os_version >= 100500) { NSBitmapImageRep *bitmap = rect_to_NSBitmapImageRep(win, x, y, w, h); - img = [bitmap CGImage]; // requires Mac OS 10.5 + img = (CGImageRef)[bitmap CGImage]; // requires Mac OS 10.5 CGImageRetain(img); [bitmap release]; }
Another alternative is to use "#if (MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_5)", but that's more code. | |
|
#2 | manolo 09:44 Jan 17, 2013 |
| Fixed in Subversion repository. | |
[ Return to Bugs & Features ]
|
| |