2012-07-31 Jan Djärv <jan.h.d@swipnet.se>
+ * nsmenu.m (update_frame_tool_bar): Change key from NSObject* to id.
+
+ * nsterm.m (ns_draw_fringe_bitmap, ns_dumpglyphs_image): Use drawInRect
+ instead of compositeToPoint.
+ (applicationShouldTerminate): Pass NS String literal to NSRunAlertPanel.
+
* nsfns.m, nsmenu.m, msterm.m: Adopt to struct frame/FVAR changes.
2012-07-31 Dmitry Antipov <dmantipov@yandex.ru>
NSDictionary *dict = [toolbar configurationDictionary];
NSMutableDictionary *newDict = [dict mutableCopy];
NSEnumerator *keys = [[dict allKeys] objectEnumerator];
- NSObject *key;
+ id key;
while ((key = [keys nextObject]) != nil)
{
NSObject *val = [dict objectForKey: key];
if (p->which)
{
NSRect r = NSMakeRect (p->x+xAdjust, p->y, p->wd, p->h);
- NSPoint pt = r.origin;
EmacsImage *img = bimgs[p->which - 1];
if (!img)
to erase the whole background. */
[ns_lookup_indexed_color(face->background, f) set];
NSRectFill (r);
- pt.y += p->h;
[img setXBMColor: ns_lookup_indexed_color(face->foreground, f)];
- [img compositeToPoint: pt operation: NSCompositeSourceOver];
+ [img drawInRect: r
+ fromRect: NSZeroRect
+ operation: NSCompositeSourceOver
+ fraction: 1.0
+ respectFlipped: YES
+ hints: nil];
}
ns_unfocus (f);
}
/* Draw the image.. do we need to draw placeholder if img ==nil? */
if (img != nil)
- [img compositeToPoint: NSMakePoint (x, y + s->slice.height)
- operation: NSCompositeSourceOver];
+ [img drawInRect: br
+ fromRect: NSZeroRect
+ operation: NSCompositeSourceOver
+ fraction: 1.0
+ respectFlipped: YES
+ hints: nil];
if (s->hl == DRAW_CURSOR)
{
return NSTerminateNow;
ret = NSRunAlertPanel(ns_app_name,
- [NSString stringWithUTF8String:"Exit requested. Would you like to Save Buffers and Exit, or Cancel the request?"],
+ @"Exit requested. Would you like to Save Buffers and Exit, or Cancel the request?",
@"Save Buffers and Exit", @"Cancel", nil);
if (ret == NSAlertDefaultReturn)