[kde-edu]: Kalzium-Rewrite
Carsten Niehaus
cniehaus at gmx.de
Sun Dec 7 14:50:17 CET 2003
Hi all
I am currently rewriting Kalzium. I have some reasons for this, eg:
1.) The current code is a mess
2.) For further extending I need a better (--> new) datastructure
3.) I want to offer more the just one PSE-widget. For that I need a better
class-structure
I plan to do something like this:
typedef QValueList<Element*> EList;
class Data
{
public:
Data();
~Data();
/*
This list contains 110 Elements. A Element has all the data
Kalzium knows about the chemical elements.
*/
static EList ElementList;
/*
some methods to access the data
*/
};
My problem is that I don't really know how to do that job. My code works so
far, but only for a non-static EList. That means that the list is created a
lot of times. I wanted to create a global const static Data-object so that I
can access that object from everywhere and it is only created once. But that
simply doesn't work. I would like to hear some input how I should handle this
problem.
In short: How do I create a datastructure which is easy to access and doesn't
wast to much memory? Is DCOP a smart way? I never used it...
There is already a blog online: http://www.kdedevelopers.org/node/view/214
I hope to get some feedback,
Carsten
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: signature
Url : http://mail.kde.org/pipermail/kde-edu/attachments/20031207/382eea87/attachment.pgp
More information about the kde-edu
mailing list