Re: massive amounts of offscreen windows
Re: massive amounts of offscreen windows
- Subject: Re: massive amounts of offscreen windows
- From: Ev <email@hidden>
- Date: Sat, 23 Aug 2003 12:17:54 -0500
On Saturday, August 23, 2003, at 11:43 AM, Adam Thayer wrote:
>
Hmm, my guess is that some reference or copy is being created when you
>
actually draw and that it is getting retained.
>
>
Your draw routine may have an error with the retain count of your
>
drawing objects... try doing an NSLog on various drawing objects.
>
Things that are to be released should show 0 for the retainCount when
>
you go to exit the drawing function.
OK, my experiments came up with this:
In my drawRect: function, I call [waveformImage
compositeToPoint:NSZeroPoint operation:NSCompositeSourceOver]; - and
that's the only thing I'm calling (just for testing, anyway)
(waveformImage is a drawSelector, so it calls a function instead of
getting something from disk or some predetermined image)
If I comment out this call, the offscreen windows stay few and do not
generate. Good thing. So I know it's there somewhere.
So I go to my drawWaveform: method and comment out the *entire* code.
No variable declatrations, nothing. It's an empty method. The offscreen
windows begin to generate themselves again...
So it's something that [NSImage compositeToPoint:] is doing. Either
that or [NSImage recache] isn't doing what it's supposed to be doing.
It can't be anywhere else.
I'm *this* close to going over to Quartz code.
-ev
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.