[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Emacs.app (from BZR) and GNUstep (from SVN)
From: |
Christopher Armstrong |
Subject: |
Re: Emacs.app (from BZR) and GNUstep (from SVN) |
Date: |
Sat, 24 Dec 2011 18:13:53 +1100 |
I believe Pixmap objects are server-allocated resources, but the X client (i.e.
the GNUstep application) is still expected to release the resource when it is
no longer in use to prevent leaking memory on the X server. X resources should
be wrapped in an Objective-C object so they can be retained/released like
normal objects, and have something in their dealloc method to call XFreePixmap
on the stored integer. However, there is no need to wrap them if the lifetime
is well-known during design.
Cheers
Chris
--------
Christopher Armstrong
address@hidden
On 24/12/2011, at 15:47 PM, Germán Arias wrote:
> You are right this is confusing. But maybe is possible delete this code
> that don't have sense.
>
> On 2011-12-23 03:07:24 -0600 Ivan Vučica <address@hidden> wrote:
>
>> I'm new to Xlib, but isn't Pixmap an integer? How could have one ever sent
>> an
>> Objective-C message to an integer?
>>
>> Shouldn't there be a wrapper around this integer if one wants to retain it?
>>
>> Why bother retaining an object which is not a part of Objective-C reference
>> counting system?
>>
>> I'm confused. :)