[fpc-pascal] Elegant way to switch sort mechanism in TSortedCollection?

Jim Leonard trixter at oldskool.org
Thu Mar 13 15:43:16 CET 2014


On 3/12/2014 5:06 PM, Frederic Da Vitoria wrote:
> You (or the user) will never need to resotre the first order? I am
> asking because you could as well simply create one SortedCollection for
> each sort order and systematically insert each item in all those
> collections. The overhead would be in the initial loading, but then
> switching would be instantaneous.

The problem is, the workflow makes changes to the list, re-sorts, and 
then this repeats.  It's a processing algorithm for graphics.  So while 
I could make several sorted lists, I'd have to manipulate/change them 
all simultaneously.
-- 
Jim Leonard (trixter at oldskool.org)
Check out some trippy MindCandy: http://www.mindcandydvd.com/
A child borne of the home computer wars: http://trixter.oldskool.org/
You're all insane and trying to steal my magic bag!



More information about the fpc-pascal mailing list