Revision 626877

Go back to digest for 28th January 2007

Other in KDE Base

Matthias Kretz committed changes in /trunk/KDE/kdelibs/kdecore:

One more API change for K_GLOBAL_STATIC (from what I know it's not used anywhere yet):
use an anonymous struct (POD) for the global object that provides the following functions:
- bool isDestroyed()
- operator TYPE*()
- TYPE *operator->()
- TYPE &operator*()
- static void destroy()
The latter is used for cleanup and can be used as a post routine with
qAddPostRoutine

This expands to a little more code but a lot nicer API.

File Changes

Added 2 files
  • /trunk/KDE/kdelibs/kdecore/tests
  •   /kglobalstatictest1.cpp
  •   /kglobalstatictest2.cpp
Modified 2 files
  • /trunk/KDE/kdelibs/kdecore
  •   /kernel/kglobal.h
  •   /tests/CMakeLists.txt
4 files changed in total