Revision 2468220...
Go back to digest for 2nd December 2012Features in KDE Base
Martin Gräßlin committed changes in [kde-workspace] /:
Introduce a templated animationTime overload for the KConfigXT case
This method can be used to get the animationTime in case a configuration
class generated through KConfigXT is used. In general the configuration
stores the magic value 0 for a property "duration". This magic value
indicates that a hard-coded default value should be used.
So the common logic to test the stored value for 0 and then either pass
the stored value or the default value to animationTime is encapsulated
in this method in a generic way.
A MyEffect can use it in the following way:
animationTime<MyEffectConfig>(200);
FIXED-IN: 4.10
REVIEW: 107460
File Changes
Modified 10 files
- kwin/libkwineffects/kwineffects.h
- kwin/effects/coverswitch/coverswitch.cpp
- kwin/effects/cube/cube.cpp
- kwin/effects/cube/cubeslide.cpp
- kwin/effects/dashboard/dashboard.cpp
- kwin/effects/dashboard/dashboard.h
- kwin/effects/desktopgrid/desktopgrid.cpp
- kwin/effects/flipswitch/flipswitch.cpp
- kwin/effects/glide/glide.cpp
- kwin/effects/magiclamp/magiclamp.cpp
10 files changed in total