I've tried this on the 64-bit versions of GAMBAS 2.13.1 and 2.8.2 included
with Ubuntu 9.04 and 9.10 and the same thing happens. It may also happen
with the listbox, listview or similar controls if they use the same code.

If I set a columnview's Sorted property to TRUE in the GUI it works fine,
but every time I call the Add method of the control it sorts the data in the
columnview. I have a loop that adds 13000+ strings to the control, so
sorting it each time one of these is added makes it incrementally slower.
Eventually it becomes so slow it is useless.

My workaround was to set the Sorted property to FALSE before the loop
starts, add the 13000+ strings, then set the Sorted property back to TRUE.
This would mean the columnview control was only sorted once and would be
much faster. If I set the control's Sorted property through the GUI as
FALSE, run the loop, then programmatically change it to TRUE, it works great
and is fast. However after that if I set the control to FALSE
programmatically it will crash, which leads me to believe it's a bug. I need
to set it to FALSE again because later I have to clear the columnview and
add different items to it. It shouldn't make any difference if I set the
control's Sorted property via the GUI or programmatically, but it does.

If this is a bug, has it been fixed in 2.16.0?

-----
Kevin Fishburne, Eight Virtues
www:  http://sales.eightvirtues.com http://sales.eightvirtues.com 
e-mail:  mailto:sa...@eightvirtues.com sa...@eightvirtues.com 
phone: (770) 853-6271
-- 
View this message in context: 
http://www.nabble.com/GAMBAS-crash-when-setting-columnview%27s-Sorted-property-tp25486385p25486385.html
Sent from the gambas-user mailing list archive at Nabble.com.


------------------------------------------------------------------------------
Come build with us! The BlackBerry® Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9-12, 2009. Register now!
http://p.sf.net/sfu/devconf
_______________________________________________
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user

Reply via email to