From 227c98614323f346e447264535c4e681948fb502 Mon Sep 17 00:00:00 2001 From: Twinaphex Date: Thu, 25 Jun 2015 17:40:09 +0200 Subject: [PATCH] More CXX_BUILD fixes --- gfx/drivers_context/cgl_ctx.c | 4 ++-- input/drivers_hid/iohidmanager_hid.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/gfx/drivers_context/cgl_ctx.c b/gfx/drivers_context/cgl_ctx.c index 6d92800cdd..9209ec29c2 100644 --- a/gfx/drivers_context/cgl_ctx.c +++ b/gfx/drivers_context/cgl_ctx.c @@ -257,8 +257,8 @@ static CGSSurfaceID attach_gl_context_to_window(CGLContextObj glCtx, /* FIXME/TODO - CGWindowListCopyWindowInfo was introduced on OSX 10.5, * find alternative for lower versions. */ wins = CGWindowListCopyWindowInfo(kCGWindowListOptionIncludingWindow, wid); /* expect one result only */ - win = CFArrayGetValueAtIndex(wins, 0); - bnd = CFDictionaryGetValue(win, kCGWindowBounds); + win = (CFDictionaryRef)CFArrayGetValueAtIndex(wins, 0); + bnd = (CFDictionaryRef)CFDictionaryGetValue(win, kCGWindowBounds); CFNumberGetValue(CFDictionaryGetValue(bnd, CFSTR("Width")), kCFNumberFloat64Type, &w); CFNumberGetValue(CFDictionaryGetValue(bnd, CFSTR("Height")), diff --git a/input/drivers_hid/iohidmanager_hid.c b/input/drivers_hid/iohidmanager_hid.c index 50fb2db07e..2c9456e7fa 100644 --- a/input/drivers_hid/iohidmanager_hid.c +++ b/input/drivers_hid/iohidmanager_hid.c @@ -230,7 +230,7 @@ static void iohidmanager_hid_device_remove(void *data, IOReturn result, void* se static int32_t iohidmanager_hid_device_get_int_property(IOHIDDeviceRef device, CFStringRef key) { int32_t value; - CFNumberRef ref = IOHIDDeviceGetProperty(device, key); + CFNumberRef ref = (CFNumberRef)IOHIDDeviceGetProperty(device, key); if (ref) { @@ -256,7 +256,7 @@ static uint16_t iohidmanager_hid_device_get_product_id(IOHIDDeviceRef device) static void iohidmanager_hid_device_get_product_string(IOHIDDeviceRef device, char *buf, size_t len) { - CFStringRef ref = IOHIDDeviceGetProperty(device, CFSTR(kIOHIDProductKey)); + CFStringRef ref = (CFStringRef)IOHIDDeviceGetProperty(device, CFSTR(kIOHIDProductKey)); if (ref) CFStringGetCString(ref, buf, len, kCFStringEncodingUTF8);