From: Peter Maydell Date: Mon, 22 Apr 2013 10:29:48 +0000 (+0000) Subject: cocoa: Avoid deprecated NSOpenPanel filename method X-Git-Tag: TizenStudio_2.0_p2.3.2~208^2~1758^2~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=8bb3f1e3742ca8d26af7156e14068435437918a1;p=sdk%2Femulator%2Fqemu.git cocoa: Avoid deprecated NSOpenPanel filename method Avoid the NSOpenPanel filename method (deprecated in MacOSX 10.6) in favour of using the URL method and extracting the path from the resulting NSUrl object. Signed-off-by: Peter Maydell Signed-off-by: Andreas Färber --- diff --git a/ui/cocoa.m b/ui/cocoa.m index ec09728..bb59511 100644 --- a/ui/cocoa.m +++ b/ui/cocoa.m @@ -810,7 +810,7 @@ QemuCocoaView *cocoaView; exit(0); } else if(returnCode == NSOKButton) { const char *bin = "qemu"; - char *img = (char*)[ [ sheet filename ] cStringUsingEncoding:NSASCIIStringEncoding]; + char *img = (char*)[ [ [ sheet URL ] path ] cStringUsingEncoding:NSASCIIStringEncoding]; char **argv = (char**)malloc( sizeof(char*)*3 );