changeset 111398:4afa0b625189

* nsfont.m (nsfont_draw) * nsimage.m (EmacsImage-setXBMColor:) * nsterm.m (EmacsView-performDragOperation:): Correct empty return statements. Based on a patch by Ismail Donmez <ismail@namtrac.org>.
author Adrian Robert <Adrian.B.Robert@gmail.com>
date Thu, 04 Nov 2010 20:10:50 +0200
parents ee55b6620594
children 301579b5b1b0
files src/ChangeLog src/nsfont.m src/nsimage.m src/nsterm.m
diffstat 4 files changed, 12 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/src/ChangeLog	Thu Nov 04 13:00:43 2010 -0400
+++ b/src/ChangeLog	Thu Nov 04 20:10:50 2010 +0200
@@ -1,3 +1,10 @@
+2010-11-04  Adrian Robert  <Adrian.B.Robert@gmail.com>
+
+	* nsfont.m (nsfont_draw)
+	* nsimage.m (EmacsImage-setXBMColor:)
+	* nsterm.m (EmacsView-performDragOperation:): Correct empty return
+	statements.  Based on a patch by Ismail Donmez <ismail@namtrac.org>.
+
 2010-11-03  Julien Danjou  <julien@danjou.info>
 
 	* image.c (gif_load): Add support for transparency and specified
--- a/src/nsfont.m	Thu Nov 04 13:00:43 2010 -0400
+++ b/src/nsfont.m	Thu Nov 04 20:10:50 2010 +0200
@@ -1211,7 +1211,6 @@
     DPSstroke (context);
 
     DPSgrestore (context);
-    return to-from;
   }
 
 #else  /* NS_IMPL_COCOA */
@@ -1280,10 +1279,9 @@
       }
 
     CGContextRestoreGState (gcontext);
-    return;
   }
 #endif  /* NS_IMPL_COCOA */
-
+  return to-from;
 }
 
 
--- a/src/nsimage.m	Thu Nov 04 13:00:43 2010 -0400
+++ b/src/nsimage.m	Thu Nov 04 20:10:50 2010 +0200
@@ -336,7 +336,7 @@
   NSColor *rgbColor;
 
   if (bmRep == nil || color == nil)
-    return;
+    return self;
 
   if ([color colorSpaceName] != NSCalibratedRGBColorSpace)
     rgbColor = [color colorUsingColorSpaceName: NSCalibratedRGBColorSpace];
@@ -361,6 +361,8 @@
           planes[2][i] = bb;
         }
   }
+
+  return self;
 }
 
 
--- a/src/nsterm.m	Thu Nov 04 13:00:43 2010 -0400
+++ b/src/nsterm.m	Thu Nov 04 20:10:50 2010 +0200
@@ -5436,7 +5436,7 @@
   NSTRACE (performDragOperation);
 
   if (!emacs_event)
-    return;
+    return NO;
 
   position = [self convertPoint: [sender draggingLocation] fromView: nil];
   x = lrint (position.x);  y = lrint (position.y);