From 7331900ef83e9b9ab14c60d000a091af6c9f54bd Mon Sep 17 00:00:00 2001 From: Manolo Gouy Date: Thu, 18 Oct 2018 19:33:09 +0000 Subject: [PATCH] Remove compilation error when using clang 8: error: non-constant-expression cannot be narrowed from type 'int' to 'CGFloat' git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@13070 ea41ed52-d2ee-0310-a9c1-e6b18d33e121 --- src/Fl_cocoa.mm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Fl_cocoa.mm b/src/Fl_cocoa.mm index 64a662752..68eaf7168 100644 --- a/src/Fl_cocoa.mm +++ b/src/Fl_cocoa.mm @@ -3922,7 +3922,7 @@ int Fl_Cocoa_Screen_Driver::dnd(int use_selection) NSPasteboardItem *pbItem = [[[NSPasteboardItem alloc] init] autorelease]; [pbItem setData:(NSData*)text forType:UTF8_pasteboard_type]; NSDraggingItem *dragItem = [[[NSDraggingItem alloc] initWithPasteboardWriter:pbItem] autorelease]; - NSRect r = {pt, {width, height}}; + NSRect r = {pt, {CGFloat(width), CGFloat(height)}}; [dragItem setDraggingFrame:r contents:image]; [myview beginDraggingSessionWithItems:[NSArray arrayWithObject:dragItem] event:theEvent source:myview]; } else