EffectsHandler and Effect become QObjects

This is in preparation for allowing to connect effects with signals and slots.
icc-effect-5.14.5
Martin Gräßlin 2011-02-25 20:25:21 +01:00
parent 3c290e07cd
commit b3a5639967
21 changed files with 25 additions and 23 deletions

View File

@ -34,7 +34,7 @@ namespace KWin
{
class CubeEffect
: public QObject, public Effect
: public Effect
{
Q_OBJECT
public:

View File

@ -31,6 +31,7 @@ namespace KWin
class CubeSlideEffect
: public Effect
{
Q_OBJECT
public:
CubeSlideEffect();
~CubeSlideEffect();

View File

@ -59,7 +59,7 @@ private:
};
class DesktopGridEffect
: public QObject, public Effect
: public Effect
{
Q_OBJECT
public:

View File

@ -28,7 +28,7 @@ namespace KWin
{
class FadeDesktopEffect
: public QObject, public Effect
: public Effect
{
Q_OBJECT
public:

View File

@ -31,7 +31,7 @@ namespace KWin
{
class FlipSwitchEffect
: public QObject, public Effect
: public Effect
{
Q_OBJECT
public:

View File

@ -33,7 +33,7 @@ class GLShader;
* Inverts desktop's colors
**/
class InvertEffect
: public QObject, public Effect
: public Effect
{
Q_OBJECT
public:

View File

@ -43,8 +43,7 @@ KWIN_EFFECT_SUPPORTED(lookingglass, LookingGlassEffect::supported())
LookingGlassEffect::LookingGlassEffect()
: QObject()
, zoom(1.0f)
: zoom(1.0f)
, target_zoom(1.0f)
, polling(false)
, m_texture(NULL)

View File

@ -37,7 +37,7 @@ class GLVertexBuffer;
/**
* Enhanced magnifier
**/
class LookingGlassEffect : public QObject, public Effect
class LookingGlassEffect : public Effect
{
Q_OBJECT
public:

View File

@ -27,7 +27,7 @@ namespace KWin
{
class MagnifierEffect
: public QObject, public Effect
: public Effect
{
Q_OBJECT
public:

View File

@ -28,7 +28,7 @@ namespace KWin
{
class MouseMarkEffect
: public QObject, public Effect
: public Effect
{
Q_OBJECT
public:

View File

@ -63,7 +63,7 @@ private:
* letting the user select active window.
**/
class PresentWindowsEffect
: public QObject, public Effect
: public Effect
{
Q_OBJECT
private:

View File

@ -28,7 +28,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
namespace KWin
{
class ScreenShotEffect : public QObject, public Effect
class ScreenShotEffect : public Effect
{
Q_OBJECT
Q_CLASSINFO("D-Bus Interface", "org.kde.kwin.Screenshot")

View File

@ -29,7 +29,7 @@ namespace KWin
{
class SlideEffect
: public QObject, public Effect
: public Effect
{
Q_OBJECT
public:

View File

@ -30,7 +30,7 @@ namespace KWin
class GLTexture;
class StartupFeedbackEffect
: public QObject, public Effect
: public Effect
{
Q_OBJECT
public:

View File

@ -36,8 +36,7 @@ namespace KWin
{
class ThumbnailAsideEffect
: public QObject
, public Effect
: public Effect
{
Q_OBJECT
public:

View File

@ -31,7 +31,7 @@ namespace KWin
class GLTexture;
class TrackMouseEffect
: public QObject, public Effect
: public Effect
{
Q_OBJECT
public:

View File

@ -26,7 +26,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
namespace KWin
{
class WindowGeometry : public QObject, public Effect
class WindowGeometry : public Effect
{
Q_OBJECT
public:

View File

@ -57,8 +57,7 @@ static int nominalCursorSize(int iconSize)
KWIN_EFFECT(zoom, ZoomEffect)
ZoomEffect::ZoomEffect()
: QObject()
, Effect()
: Effect()
, zoom(1)
, target_zoom(1)
, polling(false)

View File

@ -32,7 +32,7 @@ class GLTexture;
class XRenderPicture;
class ZoomEffect
: public QObject, public Effect
: public Effect
{
Q_OBJECT
public:

View File

@ -1337,3 +1337,5 @@ void EffectFrame::enableCrossFade(bool enable)
}
} // namespace
#include "kwineffects.moc"

View File

@ -263,8 +263,9 @@ QRect infiniteRegion()
* is called for every window which the screen method is usually called just
* once.
**/
class KWIN_EXPORT Effect
class KWIN_EXPORT Effect : public QObject
{
Q_OBJECT
public:
/** Flags controlling how painting is done. */
// TODO: is that ok here?
@ -579,8 +580,9 @@ public:
* desktop or create a special input window to receive mouse and keyboard
* events.
**/
class KWIN_EXPORT EffectsHandler
class KWIN_EXPORT EffectsHandler : public QObject
{
Q_OBJECT
friend class Effect;
public:
EffectsHandler(CompositingType type);