Add 2012 to FSF copyright years for Emacs files
[bpt/emacs.git] / src / nsimage.m
index c38cefd..82a1769 100644 (file)
@@ -1,5 +1,5 @@
 /* Image support for the NeXT/Open/GNUstep and MacOSX window system.
-   Copyright (C) 1989, 1992-1994, 2005-2006, 2008-2011
+   Copyright (C) 1989, 1992-1994, 2005-2006, 2008-2012
      Free Software Foundation, Inc.
 
 This file is part of GNU Emacs.
@@ -189,7 +189,11 @@ static EmacsImage *ImageList = nil;
   image = [[EmacsImage alloc] initByReferencingFile:
                      [NSString stringWithUTF8String: SDATA (found)]];
 
+#if defined (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_6
+  imgRep = [NSBitmapImageRep imageRepWithData:[image TIFFRepresentation]];
+#else
   imgRep = [image bestRepresentationForDevice: nil];
+#endif
   if (imgRep == nil)
     {
       [image release];