bug-gnustep
[Top][All Lists]
Advanced

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

Fix: NSFormCell, copyWithZone:


From: Georg Fleischmann
Subject: Fix: NSFormCell, copyWithZone:
Date: Sat, 16 Dec 2000 01:25:45 +0100

Hi,

here is a fix for NSFormCell (CVS 2000-12-15). It applies the recent changes  
of NSCell to NSFormCell too.

Georg


2000-12-16 Georg Fleischmann

        * gui/Source/NSFormCell.m ([NSFormCell -copyWithZone:]):
        created to retain _titleCell


*** gui/Source/NSFormCell.m.old Sat Dec 16 01:06:10 2000
--- gui/Source/NSFormCell.m     Sat Dec 16 01:09:05 2000
***************
*** 283,288 ****
--- 283,303 ----
    [self drawInteriorWithFrame: cellFrame inView: controlView];
  }

+ /*
+  * Copying
+  */
+ - (id) copyWithZone: (NSZone*)zone
+ {
+   NSCell *c = [super copyWithZone:zone];
+
+   /* Because of performance issues (and because so the doc says) only
+      pointers to the objects are copied.  We need to RETAIN them all
+      though. */
+   TEST_RETAIN (_titleCell);
+
+   return c;
+ }
+
  - (void) encodeWithCoder: (NSCoder*)aCoder
  {
    BOOL tmp;



reply via email to

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