On Tue, 16 Mar 2004 04:13:08 +1000 Daniel Stonier <[EMAIL PROTECTED]>
babbled:

>       
> >
> > ie
> >  while ((o = evas_object_bottom_get(evas)) evas_object_del(o);
> >
> > will completely clear all objects in a canvas and empty it out 
> > completely.
> >
> 
> Had some problems with implementing this - have attached a simple test 
> program to illustrate the problem. At the first call of the 
> evas_object_bottom_get function it grabs and then deletes the requested 
> object, but a second call to the function returns exactly the same object. 
> Running it in a while loop as above consequently results in an infinite 
> loop and a hang. Does whatever the bottom_get function looks up need 
> updating before re-use or is it a problem with the function?
> 
> I had a quick snoop at the evas source for the evas_object_bottom_get 
> function and got moosed. I'll have to sit down with a few drinks one day 
> to try and get to grips with it so I can fiddle around with it myself.
> 
> As an aside, the evas_object_top_get used in the same place in the above 
> test program causes a segfault.

aaah oops - thanks! thats a bug on my part. let me explain. in order for evas to
"keep state" objects arent actually deleted when you call evas_object_del. they
are "flagged for deletion" but left there, they will be deleted next
evas_render() cycle when it no longer needs the state for deleted objects. my
code to get the object above/below/on top and on bottom didn't look at the
delete_me flag and just gave u the object anyway. thus the object was still
there but flagged for deletion - thus u always got the same object handle. :)
fixed now in cvs. do a cvs update. :)


-- 
------------- Codito, ergo sum - "I code, therefore I am" --------------
The Rasterman (Carsten Haitzler)    [EMAIL PROTECTED]
熊耳 - 車君 (数田)                  [EMAIL PROTECTED]
Tokyo, Japan (東京 日本)


-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
_______________________________________________
enlightenment-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel

Reply via email to