emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

scratch/ns/performance aeb2475 5/6: Fix EmacsSurface definitions


From: Alan Third
Subject: scratch/ns/performance aeb2475 5/6: Fix EmacsSurface definitions
Date: Thu, 31 Dec 2020 10:45:20 -0500 (EST)

branch: scratch/ns/performance
commit aeb2475816bfdf7e52284fedf693d3f36940652a
Author: Alan Third <alan@idiocy.org>
Commit: Alan Third <alan@idiocy.org>

    Fix EmacsSurface definitions
    
    * src/nsterm.h:
    * src/nsterm.m ([EmacsSurface initWithSize:ColorSpace:]): Objective C
    init methods should init the superclass, and return id.
---
 src/nsterm.h | 2 +-
 src/nsterm.m | 6 ++++--
 2 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/src/nsterm.h b/src/nsterm.h
index a1f7fdc..9de4104 100644
--- a/src/nsterm.h
+++ b/src/nsterm.h
@@ -715,7 +715,7 @@ typedef id instancetype;
   IOSurfaceRef lastSurface;
   CGContextRef context;
 }
-- (EmacsSurface *) initWithSize: (NSSize)s ColorSpace: (CGColorSpaceRef)cs;
+- (id) initWithSize: (NSSize)s ColorSpace: (CGColorSpaceRef)cs;
 - (void) dealloc;
 - (NSSize) getSize;
 - (CGContextRef) getContext;
diff --git a/src/nsterm.m b/src/nsterm.m
index 14eabfd..63f48cd 100644
--- a/src/nsterm.m
+++ b/src/nsterm.m
@@ -9526,11 +9526,13 @@ not_in_argv (NSString *arg)
    surfaces.  */
 
 
-- (EmacsSurface *) initWithSize: (NSSize)s
-                     ColorSpace: (CGColorSpaceRef)cs
+- (id) initWithSize: (NSSize)s
+         ColorSpace: (CGColorSpaceRef)cs
 {
   NSTRACE ("[EmacsSurface initWithSize:ColorSpace:]");
 
+  [super init];
+
   cache = [[NSMutableArray arrayWithCapacity:3] retain];
   size = s;
   colorSpace = cs;



reply via email to

[Prev in Thread] Current Thread [Next in Thread]