U++ framework
Do not panic. Ask here before giving up.

Home » U++ Library support » TreeCtrl » A [TreeCtrl] bug
Re: A [TreeCtrl] bug [message #14592 is a reply to message #14558] Tue, 04 March 2008 11:52 Go to previous messageGo to previous message
huanghuan is currently offline  huanghuan
Messages: 10
Registered: December 2007
Promising Member
Thank you. I will check it in next version.
if key = Null is only an option and not added. the following may half time complex in invalid key situation.
int    TreeCtrl::Find(Value key)
{
	for(int i = 0; i < item.GetCount(); i++)
		if(item[i].free)
		{
			if(Get(i) == key)
				return -1;
		}
		else if(Get(i) == key)
			return i;
	return -1;
}

this is not good. key = Null is nessary. for memory release.
I hope add the "key = Null".
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: FIX - Single Click does not open/close items
Next Topic: problem in Refreshing at end of tree
Goto Forum:
  


Current Time: Wed Oct 07 02:38:36 GMT+2 2026

Total time taken to generate the page: 0.00595 seconds