[Kst] kdeextragear-2/kst/kst

George Staikos staikos at kde.org
Thu Aug 7 22:37:31 CEST 2003


On Thursday 07 August 2003 16:25, C. Barth Netterfield wrote:
> On Thursday 07 August 2003 12:52 pm, George Staikos wrote:
> > - only update the necessary parts of the data manager.  this is
> > implemented in a rather slow way (the code is ~O(n^2)) but it is more
> > reliable for now. In the future we should tell the datamanager what to
> > do, as opposed to telling it to update and having it determine what needs
> > to be updated.
>
> Is this faster than updating everything, as was previous?

  Well, it's hard to say.  I think it's slower on average actually.  It's very 
different in design as you might have noticed.  Instead of clearing the list, 
we do this:

- iterate through and find any deleted items, pushing them onto a trash stack.
- clear the trash stack
- iterate through the data/vector objects and find anything that we aren't 
displaying, adding them in
- update() any other items that weren't touched.


I'm in the process of converting the dataobject vector and scalar lists to 
maps as we discussed before.  I started to use QDict but it seems to be more 
messy than using QMap, and not that much more efficient.  I'll convert scalar 
stuff first, commit, then if it looks clean, do vectors next.

-- 
George Staikos
KDE Developer				http://www.kde.org/
Staikos Computing Services Inc.		http://www.staikos.net/



More information about the Kst mailing list