From cea8e1a286262d593f283eea825d2d60762095bf Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Sat, 31 Jan 2009 09:01:32 +0000 Subject: [PATCH 01/60] Correctly apply the shadow color when in OpenGL mode. BUG: 180536 svn path=/trunk/KDE/kdebase/workspace/; revision=918987 --- effects/shadow.cpp | 47 ++++++++++++++++++++++++++-------------------- effects/shadow.h | 2 +- 2 files changed, 28 insertions(+), 21 deletions(-) diff --git a/effects/shadow.cpp b/effects/shadow.cpp index 967353ee70..6c289d3bfb 100644 --- a/effects/shadow.cpp +++ b/effects/shadow.cpp @@ -109,9 +109,22 @@ void ShadowEffect::reconfigure( ReconfigureFlags ) } } + //------------------------- // Create default textures + mDefaultShadowQuadType = effects->newWindowQuadType(); // TODO: Unregister? - QImage shadowImage( KGlobal::dirs()->findResource( "data", "kwin/shadow-texture.png" )); + QImage shadowImageSrc( KGlobal::dirs()->findResource( "data", "kwin/shadow-texture.png" )); + + // Might as well process the shadow color here + QImage shadowImage( shadowImageSrc.width(), shadowImageSrc.height(), QImage::Format_ARGB32 ); + QPainter painter( &shadowImage ); + //painter.setCompositionMode( QPainter::CompositionMode_Multiply ); + painter.setPen( Qt::NoPen ); + painter.setBrush( shadowColor ); + painter.drawRect( 0, 0, shadowImage.width(), shadowImage.height() ); + painter.end(); + shadowImage.setAlphaChannel( shadowImageSrc.alphaChannel() ); // Cheat, just use the alpha mask + int hw = shadowImage.width() / 2; int hh = shadowImage.height() / 2; mDefaultShadowTextures.append( new GLTexture( shadowImage.copy( 0, 0, hw, hh ))); @@ -611,12 +624,9 @@ void ShadowEffect::prepareRenderStates( GLTexture *texture, double opacity, doub glActiveTexture(GL_TEXTURE0 ); } else*/ if( opacity != 1.0 || brightness != 1.0 ) - { - // the window is additionally configured to have its opacity adjusted, - // do it - float opacityByBrightness = opacity * brightness; + { // The window is additionally configured to have its opacity adjusted glTexEnvi( GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE ); - glColor4f( opacityByBrightness, opacityByBrightness, opacityByBrightness, opacity); + glColor4f( brightness, brightness, brightness, opacity ); } #endif } @@ -638,7 +648,7 @@ void ShadowEffect::restoreRenderStates( GLTexture *texture, double opacity, doub glActiveTexture(GL_TEXTURE0); }*/ glTexEnvi( GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_REPLACE ); - glColor4f( 0, 0, 0, 0 ); + glColor4f( 0.0, 0.0, 0.0, 0.0 ); } glPopAttrib(); // ENABLE_BIT @@ -646,15 +656,12 @@ void ShadowEffect::restoreRenderStates( GLTexture *texture, double opacity, doub } void ShadowEffect::drawShadowQuadOpenGL( GLTexture *texture, QVector verts, QVector texCoords, - QColor color, QRegion region, float opacity, float brightness, float saturation ) + QRegion region, float opacity, float brightness, float saturation ) { #ifdef KWIN_HAVE_OPENGL_COMPOSITING - if( color.isValid() ) - glColor4f( color.redF(), color.greenF(), color.blueF(), 1.0 ); - else - glColor4f( 1.0, 1.0, 1.0, 1.0 ); - glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE); - prepareRenderStates( texture, opacity, brightness, saturation ); + glColor4f( 1.0, 1.0, 1.0, 1.0 ); + glTexEnvi( GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_REPLACE ); + prepareRenderStates( texture, opacity, brightness, saturation ); // Usually overrides the above texture->bind(); texture->enableNormalizedTexCoords(); glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE ); @@ -801,7 +808,7 @@ void ShadowEffect::drawShadow( EffectWindow* window, int mask, QRegion region, c { // Decorated windows // Active shadow drawShadowQuadOpenGL( mShadowTextures.at( texture ).at( quad.id() ), - verts, texcoords, QColor(), region, + verts, texcoords, region, data.opacity * window->shadowOpacity( ShadowBorderedActive ), data.brightness * window->shadowBrightness( ShadowBorderedActive ), data.saturation * window->shadowSaturation( ShadowBorderedActive )); @@ -809,7 +816,7 @@ void ShadowEffect::drawShadow( EffectWindow* window, int mask, QRegion region, c // Inactive shadow texture = effects->shadowTextureList( ShadowBorderedInactive ); drawShadowQuadOpenGL( mShadowTextures.at( texture ).at( quad.id() ), - verts, texcoords, QColor(), region, + verts, texcoords, region, data.opacity * window->shadowOpacity( ShadowBorderedInactive ), data.brightness * window->shadowBrightness( ShadowBorderedInactive ), data.saturation * window->shadowSaturation( ShadowBorderedInactive )); @@ -819,7 +826,7 @@ void ShadowEffect::drawShadow( EffectWindow* window, int mask, QRegion region, c if( effects->activeWindow() == window ) { drawShadowQuadOpenGL( mShadowTextures.at( texture ).at( quad.id() ), - verts, texcoords, QColor(), region, + verts, texcoords, region, data.opacity * window->shadowOpacity( ShadowBorderlessActive ), data.brightness * window->shadowBrightness( ShadowBorderlessActive ), data.saturation * window->shadowSaturation( ShadowBorderlessActive )); @@ -828,7 +835,7 @@ void ShadowEffect::drawShadow( EffectWindow* window, int mask, QRegion region, c { texture = effects->shadowTextureList( ShadowBorderlessInactive ); drawShadowQuadOpenGL( mShadowTextures.at( texture ).at( quad.id() ), - verts, texcoords, QColor(), region, + verts, texcoords, region, data.opacity * window->shadowOpacity( ShadowBorderlessInactive ), data.brightness * window->shadowBrightness( ShadowBorderlessInactive ), data.saturation * window->shadowSaturation( ShadowBorderlessInactive )); @@ -837,7 +844,7 @@ void ShadowEffect::drawShadow( EffectWindow* window, int mask, QRegion region, c else { // Other windows drawShadowQuadOpenGL( mShadowTextures.at( texture ).at( quad.id() ), - verts, texcoords, QColor(), region, + verts, texcoords, region, data.opacity * window->shadowOpacity( ShadowOther ), data.brightness * window->shadowBrightness( ShadowOther ), data.saturation * window->shadowSaturation( ShadowOther )); @@ -851,7 +858,7 @@ void ShadowEffect::drawShadow( EffectWindow* window, int mask, QRegion region, c opacity = 1 - ( 1 - shadowOpacity ) * ( 1 - shadowOpacity ); drawShadowQuadOpenGL( mDefaultShadowTextures.at( quad.id() ), - verts, texcoords, shadowColor, region, + verts, texcoords, region, data.opacity * opacity, data.brightness, data.saturation ); diff --git a/effects/shadow.h b/effects/shadow.h index eafa1cdb45..452e589496 100644 --- a/effects/shadow.h +++ b/effects/shadow.h @@ -54,7 +54,7 @@ class ShadowEffect void restoreRenderStates( GLTexture *texture, double opacity, double brightness, double saturation ); void drawShadowQuadOpenGL( GLTexture *texture, QVector verts, QVector texCoords, - QColor color, QRegion region, float opacity, float brightness, float saturation ); + QRegion region, float opacity, float brightness, float saturation ); void drawShadowQuadXRender( XRenderPicture *picture, QRect rect, float xScale, float yScale, QColor color, float opacity, float brightness, float saturation ); From e93f4306d9edacb2ba32ba13c53843a296b6f074 Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Sat, 31 Jan 2009 09:13:23 +0000 Subject: [PATCH 02/60] Fixed shadow color button signal not being picked up. svn path=/trunk/KDE/kdebase/workspace/; revision=918989 --- effects/shadow_config.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/effects/shadow_config.cpp b/effects/shadow_config.cpp index 61a82a2b5d..a00b15b2a8 100644 --- a/effects/shadow_config.cpp +++ b/effects/shadow_config.cpp @@ -54,7 +54,7 @@ ShadowEffectConfig::ShadowEffectConfig(QWidget* parent, const QVariantList& args connect( m_ui->opacitySpin, SIGNAL( valueChanged( int )), this, SLOT( changed() )); connect( m_ui->fuzzinessSpin, SIGNAL( valueChanged( int )), this, SLOT( changed() )); connect( m_ui->sizeSpin, SIGNAL( valueChanged( int )), this, SLOT( changed() )); - connect( m_ui->colorButton, SIGNAL( changed( int )), this, SLOT( changed() )); + connect( m_ui->colorButton, SIGNAL( changed( QColor )), this, SLOT( changed() )); connect( m_ui->strongerActiveBox, SIGNAL( stateChanged( int )), this, SLOT( changed() )); connect( m_ui->forceDecoratedBox, SIGNAL( stateChanged( int )), this, SLOT( changed() )); From a6fb2688cde63da3601423f300e9ff59227e279f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Sat, 31 Jan 2009 09:49:33 +0000 Subject: [PATCH 03/60] Only clear QLists when they are empty. Prevents crashes. BUG: 182358 svn path=/trunk/KDE/kdebase/workspace/; revision=919007 --- effects/coverswitch.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/effects/coverswitch.cpp b/effects/coverswitch.cpp index b7369a1990..9bba048590 100644 --- a/effects/coverswitch.cpp +++ b/effects/coverswitch.cpp @@ -201,8 +201,10 @@ void CoverSwitchEffect::paintScreen( int mask, QRegion region, ScreenPaintData& rightIndex = 0; EffectWindow* frontWindow = tempList[ index ]; - leftWindows.clear(); - rightWindows.clear(); + if( !leftWindows.isEmpty() ) + leftWindows.clear(); + if( !rightWindows.isEmpty() ) + rightWindows.clear(); bool evenWindows = ( tempList.count() % 2 == 0 ) ? true : false; int leftWindowCount = 0; From 29484aa5fb752b035f7d652ef1e31c71b7f219f8 Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Sat, 31 Jan 2009 11:47:21 +0000 Subject: [PATCH 04/60] Allow snow flakes to completely exit the screen before removing them. Also create the flakes off-screen as well. BUG: 182561 svn path=/trunk/KDE/kdebase/workspace/; revision=919039 --- effects/data/snow.vert | 2 +- effects/snow.cpp | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/effects/data/snow.vert b/effects/data/snow.vert index 48cb854335..06b8462c49 100644 --- a/effects/data/snow.vert +++ b/effects/data/snow.vert @@ -42,6 +42,6 @@ void main() else yCoord = float(height)*0.5; vec2 vertex = vec2( xCoord, yCoord ); - vertex = (vertex)*rotation + vec2( float(x), 0.0 ) + vec2(hSpeed, vSpeed)*float(frames); + vertex = (vertex)*rotation + vec2( float(x), float(-height) ) + vec2(hSpeed, vSpeed)*float(frames); gl_Position = gl_ModelViewProjectionMatrix * vec4(vertex, gl_Vertex.zw); } diff --git a/effects/snow.cpp b/effects/snow.cpp index 377ad20125..477c99d600 100644 --- a/effects/snow.cpp +++ b/effects/snow.cpp @@ -98,7 +98,7 @@ void SnowEffect::prePaintScreen( ScreenPrePaintData& data, int time ) int size = 0; while ( size < mMinFlakeSize ) size = random() % mMaxFlakeSize; - SnowFlake flake = SnowFlake( random() % (displayWidth() - size), -1 * size, size, size, mMaxVSpeed, mMaxHSpeed ); + SnowFlake flake = SnowFlake( random() % (displayWidth() - size), -size, size, size, mMaxVSpeed, mMaxHSpeed ); flakes.append( flake ); // calculation of next time of snowflake @@ -356,9 +356,9 @@ SnowFlake::SnowFlake(int x, int y, int width, int height, int maxVSpeed, int max if(rotationSpeed == 0) rotationSpeed = 0.5; rect = QRect(x, y, width, height); frameCounter = 0; - maxFrames = displayHeight() / vSpeed; + maxFrames = (displayHeight() + 2*height) / vSpeed; if( hSpeed > 0 ) - maxFrames = qMin( maxFrames, (displayWidth() - x)/hSpeed ); + maxFrames = qMin( maxFrames, (displayWidth() + width - x)/hSpeed ); else if( hSpeed < 0 ) maxFrames = qMin( maxFrames, (x + width)/(-hSpeed) ); } From 139b8c8f41345e373d013ed5e302cd199df070e1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Sat, 31 Jan 2009 13:15:14 +0000 Subject: [PATCH 05/60] Revert commit r919007 svn path=/trunk/KDE/kdebase/workspace/; revision=919068 --- effects/coverswitch.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/effects/coverswitch.cpp b/effects/coverswitch.cpp index 9bba048590..b7369a1990 100644 --- a/effects/coverswitch.cpp +++ b/effects/coverswitch.cpp @@ -201,10 +201,8 @@ void CoverSwitchEffect::paintScreen( int mask, QRegion region, ScreenPaintData& rightIndex = 0; EffectWindow* frontWindow = tempList[ index ]; - if( !leftWindows.isEmpty() ) - leftWindows.clear(); - if( !rightWindows.isEmpty() ) - rightWindows.clear(); + leftWindows.clear(); + rightWindows.clear(); bool evenWindows = ( tempList.count() % 2 == 0 ) ? true : false; int leftWindowCount = 0; From 7cb7f17a11c234ab70cf533a828646b77daeb005 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Sat, 31 Jan 2009 13:23:58 +0000 Subject: [PATCH 06/60] Abort effect if the current tab box window is deleted and the tabbox is empty afterwards. This hopefully resolves the crashes when a window is closed during active effect. At least I was not able to reproduce a crash anymore. If further testing shows that it resolves the problem the patch will be backported to branch and to other window switching effects showing the same problem. CCBUG: 182358 svn path=/trunk/KDE/kdebase/workspace/; revision=919075 --- effects/coverswitch.cpp | 19 +++++++++++++++++++ effects/coverswitch.h | 1 + 2 files changed, 20 insertions(+) diff --git a/effects/coverswitch.cpp b/effects/coverswitch.cpp index b7369a1990..de232cc4a5 100644 --- a/effects/coverswitch.cpp +++ b/effects/coverswitch.cpp @@ -101,6 +101,8 @@ void CoverSwitchEffect::prePaintScreen( ScreenPrePaintData& data, int time ) (dynamicThumbnails && effects->currentTabBoxWindowList().size() >= thumbnailWindows)) ) calculateItemSizes(); } + if( effects->currentTabBoxWindow() == NULL ) + abort(); } effects->prePaintScreen(data, time); } @@ -1476,5 +1478,22 @@ void CoverSwitchEffect::windowInputMouseEvent( Window w, QEvent* e ) } } +void CoverSwitchEffect::abort() + { + effects->unrefTabBox(); + effects->setActiveFullScreenEffect( 0 ); + effects->destroyInputWindow( input ); + mActivated = false; + stop = false; + stopRequested = false; + effects->addRepaintFull(); + if( thumbnails && (!dynamicThumbnails || + (dynamicThumbnails && effects->currentTabBoxWindowList().size() >= thumbnailWindows)) ) + { + qDeleteAll( windows ); + windows.clear(); + } + } + } // namespace diff --git a/effects/coverswitch.h b/effects/coverswitch.h index 1ee04e6dfb..3014ed386f 100644 --- a/effects/coverswitch.h +++ b/effects/coverswitch.h @@ -58,6 +58,7 @@ class CoverSwitchEffect void paintWindowCover( EffectWindow* w, bool reflectedWindow, WindowPaintData& data ); void paintFrontWindow( EffectWindow* frontWindow, int width, int leftWindows, int rightWindows, bool reflectedWindow ); void paintWindows( QList< EffectWindow* >* windows, bool left, bool reflectedWindows, EffectWindow* additionalWindow = NULL ); + void abort(); // thumbnail bar class ItemInfo; void calculateFrameSize(); From d6a31bc921fe0ef3ec473dbdd55479acd1ffdc26 Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Sat, 31 Jan 2009 15:12:14 +0000 Subject: [PATCH 07/60] Introducing the highlight window effect. When activated by the X atom all windows are faded out except the one that is being highlighted. It is nowhere near complete but committing it now so that the Plasma developers can start playing around with it. svn path=/trunk/KDE/kdebase/workspace/; revision=919159 --- effects/CMakeLists.txt | 2 + effects/highlightwindow.cpp | 99 +++++++++++++++++++++++++++++++++ effects/highlightwindow.desktop | 16 ++++++ effects/highlightwindow.h | 52 +++++++++++++++++ 4 files changed, 169 insertions(+) create mode 100644 effects/highlightwindow.cpp create mode 100644 effects/highlightwindow.desktop create mode 100644 effects/highlightwindow.h diff --git a/effects/CMakeLists.txt b/effects/CMakeLists.txt index ed96f501c7..62c4b08d18 100644 --- a/effects/CMakeLists.txt +++ b/effects/CMakeLists.txt @@ -42,6 +42,7 @@ SET(kwin4_effect_builtins_sources fade.cpp fadedesktop.cpp fallapart.cpp + highlightwindow.cpp login.cpp logout.cpp magiclamp.cpp @@ -67,6 +68,7 @@ install( FILES fade.desktop fadedesktop.desktop fallapart.desktop + highlightwindow.desktop login.desktop logout.desktop magiclamp.desktop diff --git a/effects/highlightwindow.cpp b/effects/highlightwindow.cpp new file mode 100644 index 0000000000..9c419a0be2 --- /dev/null +++ b/effects/highlightwindow.cpp @@ -0,0 +1,99 @@ +/******************************************************************** + KWin - the KDE window manager + This file is part of the KDE project. + +Copyright (C) 2009 Lucas Murray + +This program is free software; you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation; either version 2 of the License, or +(at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program. If not, see . +*********************************************************************/ + +#include "highlightwindow.h" + +#include + +namespace KWin +{ + +KWIN_EFFECT( highlightwindow, HighlightWindowEffect ) + +HighlightWindowEffect::HighlightWindowEffect() + : m_highlightedWindow( NULL ) + , m_monitorWindow( NULL ) + { + m_atom = XInternAtom( display(), "_KDE_WINDOW_HIGHLIGHT", False ); + effects->registerPropertyType( m_atom, true ); + + // Announce support by creating a dummy version on the root window + unsigned char dummy = 0; + XChangeProperty( display(), rootWindow(), m_atom, m_atom, 8, PropModeReplace, &dummy, 1 ); + } + +HighlightWindowEffect::~HighlightWindowEffect() + { + XDeleteProperty( display(), rootWindow(), m_atom ); + effects->registerPropertyType( m_atom, false ); + } + +void HighlightWindowEffect::prePaintWindow( EffectWindow* w, WindowPrePaintData& data, int time ) + { + // If we are highlighting a window set the translucent flag to all others + if( m_highlightedWindow && m_highlightedWindow != w && m_monitorWindow != w && w->isNormalWindow() ) + data.mask |= PAINT_WINDOW_TRANSLUCENT; + effects->prePaintWindow( w, data, time ); + } + +void HighlightWindowEffect::paintWindow( EffectWindow* w, int mask, QRegion region, WindowPaintData& data ) + { + if( m_highlightedWindow && m_highlightedWindow != w && m_monitorWindow != w && w->isNormalWindow() ) + data.opacity *= 0.15; // TODO: Fade out + effects->paintWindow( w, mask, region, data ); + } + +void HighlightWindowEffect::windowAdded( EffectWindow* w ) + { + propertyNotify( w, m_atom ); // Check initial value + } + +void HighlightWindowEffect::windowDeleted( EffectWindow* w ) + { + if( m_monitorWindow == w ) + { // The monitoring window was destroyed + m_monitorWindow = NULL; + m_highlightedWindow = NULL; + } + } + +void HighlightWindowEffect::propertyNotify( EffectWindow* w, long a ) + { + if( a != m_atom ) + return; // Not our atom + + QByteArray byteData = w->readProperty( m_atom, m_atom, 32 ); + if( byteData.length() < 1 ) + return; // Invalid length + long* data = reinterpret_cast( byteData.data() ); + + if( !data[0] ) + { // Purposely clearing highlight + m_monitorWindow = NULL; + m_highlightedWindow = NULL; + return; + } + m_monitorWindow = w; + m_highlightedWindow = effects->findWindow( data[0] ); + if( !m_highlightedWindow ) + kDebug(1212) << "Invalid window targetted for highlight. Requested:" << data[0]; + } + +} // namespace diff --git a/effects/highlightwindow.desktop b/effects/highlightwindow.desktop new file mode 100644 index 0000000000..68a51c8769 --- /dev/null +++ b/effects/highlightwindow.desktop @@ -0,0 +1,16 @@ +[Desktop Entry] +Name=Highlight Window +Icon=preferences-system-windows-effect-highlightwindow +Comment=Highlight the appropriate window when hovering over taskbar entries + +Type=Service +X-KDE-ServiceTypes=KWin/Effect +X-KDE-PluginInfo-Author=Lucas Murray +X-KDE-PluginInfo-Email=lmurray@undefinedfire.com +X-KDE-PluginInfo-Name=kwin4_effect_highlightwindow +X-KDE-PluginInfo-Version=0.1.0 +X-KDE-PluginInfo-Category=Appearance +X-KDE-PluginInfo-Depends= +X-KDE-PluginInfo-License=GPL +X-KDE-PluginInfo-EnabledByDefault=true +X-KDE-Library=kwin4_effect_builtins diff --git a/effects/highlightwindow.h b/effects/highlightwindow.h new file mode 100644 index 0000000000..58c11eb86a --- /dev/null +++ b/effects/highlightwindow.h @@ -0,0 +1,52 @@ +/******************************************************************** + KWin - the KDE window manager + This file is part of the KDE project. + +Copyright (C) 2009 Lucas Murray + +This program is free software; you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation; either version 2 of the License, or +(at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program. If not, see . +*********************************************************************/ + +#ifndef KWIN_HIGHLIGHTWINDOW_H +#define KWIN_HIGHLIGHTWINDOW_H + +#include + +namespace KWin +{ + +class HighlightWindowEffect + : public Effect + { + public: + HighlightWindowEffect(); + virtual ~HighlightWindowEffect(); + + virtual void prePaintWindow( EffectWindow* w, WindowPrePaintData& data, int time ); + virtual void paintWindow( EffectWindow* w, int mask, QRegion region, WindowPaintData& data ); + + virtual void windowAdded( EffectWindow* w ); + virtual void windowDeleted( EffectWindow* w ); + + virtual void propertyNotify( EffectWindow* w, long atom ); + + private: + long m_atom; + EffectWindow* m_highlightedWindow; + EffectWindow* m_monitorWindow; + }; + +} // namespace + +#endif From 0aa8cd610fe3a3a399910bb82de4a225c3388842 Mon Sep 17 00:00:00 2001 From: Script Kiddy Date: Sat, 31 Jan 2009 15:57:53 +0000 Subject: [PATCH 08/60] SVN_SILENT made messages (.desktop file) svn path=/trunk/KDE/kdebase/workspace/; revision=919234 --- effects/fadedesktop.desktop | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/effects/fadedesktop.desktop b/effects/fadedesktop.desktop index 94f316a9b0..5958a3d03f 100644 --- a/effects/fadedesktop.desktop +++ b/effects/fadedesktop.desktop @@ -1,7 +1,11 @@ [Desktop Entry] Name=Fade Desktop +Name[gl]=Esvair o escritorio +Name[uk]=Затемнювати стільницю Icon=preferences-system-windows-effect-fadedesktop Comment=Fade between virtual desktops when switching between them +Comment[gl]=Emprega un efeito de esvaemento ao trocar de escritorio +Comment[uk]=Затемнення перед час перемикання між віртуальними стільницями Type=Service X-KDE-ServiceTypes=KWin/Effect From 752d5fa642295038155ffdf19e09b2bead520906 Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Sun, 1 Feb 2009 15:16:52 +0000 Subject: [PATCH 09/60] Extracted mouse polling out of the composite timer to allow effects to detect mouse movement and modifier key changes even when KWin is idle. As the track mouse effect requires polling to always be active disabling it by default to prevent wasting CPU usage in the default install. svn path=/trunk/KDE/kdebase/workspace/; revision=919711 --- composite.cpp | 20 ++++++++++++++++---- effects.cpp | 16 ++++++++++++++++ effects.h | 3 +++ effects/cube.cpp | 2 ++ effects/lookingglass.cpp | 11 +++++++++++ effects/lookingglass.h | 1 + effects/magnifier.cpp | 11 +++++++++++ effects/magnifier.h | 1 + effects/mousemark.cpp | 6 ++++++ effects/mousemark.h | 1 + effects/trackmouse.cpp | 2 ++ effects/trackmouse.desktop | 2 +- effects/zoom.cpp | 11 +++++++++++ effects/zoom.h | 1 + lib/kwineffects.h | 4 ++++ workspace.cpp | 1 + workspace.h | 6 ++++++ 17 files changed, 94 insertions(+), 5 deletions(-) diff --git a/composite.cpp b/composite.cpp index 3579c42ff4..6922c2faa0 100644 --- a/composite.cpp +++ b/composite.cpp @@ -336,11 +336,8 @@ void Workspace::performCompositing() } if( !scene->waitSyncAvailable()) nextPaintReference = QTime::currentTime(); - checkCursorPos(); if((( repaints_region.isEmpty() && !windowRepaintsPending()) // no damage - || !overlay_visible ) // nothing is visible anyway - // HACK: don't idle during active full screen effect so that mouse events are not dropped (bug #177226) - && !static_cast< EffectsHandlerImpl* >( effects )->activeFullScreenEffect() ) + || !overlay_visible )) // nothing is visible anyway { scene->idle(); // Note: It would seem here we should undo suspended unredirect, but when scenes need @@ -404,6 +401,11 @@ void Workspace::performCompositing() #endif } +void Workspace::performMousePoll() + { + checkCursorPos(); + } + bool Workspace::windowRepaintsPending() const { foreach( Toplevel* c, clients ) @@ -430,6 +432,16 @@ void Workspace::setCompositeTimer() compositeTimer.start( qBound( 0, nextPaintReference.msecsTo( QTime::currentTime() ), 250 ) % compositeRate ); } +void Workspace::startMousePolling() + { + mousePollingTimer.start( 20 ); // 50Hz. TODO: How often do we really need to poll? + } + +void Workspace::stopMousePolling() + { + mousePollingTimer.stop(); + } + bool Workspace::createOverlay() { assert( overlay == None ); diff --git a/effects.cpp b/effects.cpp index d45bf41333..e0ebb6a755 100644 --- a/effects.cpp +++ b/effects.cpp @@ -52,6 +52,7 @@ EffectsHandlerImpl::EffectsHandlerImpl(CompositingType type) , keyboard_grab_effect( NULL ) , fullscreen_effect( 0 ) , next_window_quad_type( EFFECT_QUAD_TYPE_START ) + , mouse_poll_ref_count( 0 ) { reconfigure(); } @@ -354,6 +355,21 @@ void EffectsHandlerImpl::grabbedKeyboardEvent( QKeyEvent* e ) keyboard_grab_effect->grabbedKeyboardEvent( e ); } +void EffectsHandlerImpl::startMousePolling() + { + if( !mouse_poll_ref_count ) // Start timer if required + Workspace::self()->startMousePolling(); + mouse_poll_ref_count++; + } + +void EffectsHandlerImpl::stopMousePolling() + { + assert( mouse_poll_ref_count ); + mouse_poll_ref_count--; + if( !mouse_poll_ref_count ) // Stop timer if required + Workspace::self()->stopMousePolling(); + } + bool EffectsHandlerImpl::hasKeyboardGrab() const { return keyboard_grab_effect != NULL; diff --git a/effects.h b/effects.h index 8eaeb4fb7c..4bd7412976 100644 --- a/effects.h +++ b/effects.h @@ -65,6 +65,8 @@ class EffectsHandlerImpl : public EffectsHandler virtual QPoint cursorPos() const; virtual bool grabKeyboard( Effect* effect ); virtual void ungrabKeyboard(); + virtual void startMousePolling(); + virtual void stopMousePolling(); virtual EffectWindow* findWindow( WId id ) const; virtual EffectWindowList stackingOrder() const; virtual void setElevatedWindow( EffectWindow* w, bool set ); @@ -168,6 +170,7 @@ class EffectsHandlerImpl : public EffectsHandler QMultiMap< int, EffectPair > effect_order; QHash< long, int > registered_atoms; int next_window_quad_type; + int mouse_poll_ref_count; }; class EffectWindowImpl : public EffectWindow diff --git a/effects/cube.cpp b/effects/cube.cpp index 9298570e54..894bb14fa5 100644 --- a/effects/cube.cpp +++ b/effects/cube.cpp @@ -1537,6 +1537,7 @@ void CubeEffect::setActive( bool active ) { if( active ) { + effects->startMousePolling(); activated = true; activeScreen = effects->activeScreen(); if( !slide ) @@ -1574,6 +1575,7 @@ void CubeEffect::setActive( bool active ) } else { + effects->stopMousePolling(); schedule_close = true; // we have to add a repaint, to start the deactivating effects->addRepaintFull(); diff --git a/effects/lookingglass.cpp b/effects/lookingglass.cpp index a594dc3f52..c362f4e336 100644 --- a/effects/lookingglass.cpp +++ b/effects/lookingglass.cpp @@ -42,6 +42,7 @@ LookingGlassEffect::LookingGlassEffect() : QObject(), ShaderEffect("lookingglass { zoom = 1.0f; target_zoom = 1.0f; + polling = false; actionCollection = new KActionCollection( this ); actionCollection->setConfigGlobal(true); @@ -83,6 +84,11 @@ void LookingGlassEffect::zoomIn() { target_zoom = qMin(7.0, target_zoom + 0.5); setEnabled( true ); + if( !polling ) + { + polling = true; + effects->startMousePolling(); + } effects->addRepaint( cursorPos().x() - radius, cursorPos().y() - radius, 2*radius, 2*radius ); } @@ -94,6 +100,11 @@ void LookingGlassEffect::zoomOut() target_zoom = 1; setEnabled( false ); } + if( polling ) + { + polling = false; + effects->stopMousePolling(); + } effects->addRepaint( cursorPos().x() - radius, cursorPos().y() - radius, 2*radius, 2*radius ); } diff --git a/effects/lookingglass.h b/effects/lookingglass.h index 367d59fbdc..96b4422002 100644 --- a/effects/lookingglass.h +++ b/effects/lookingglass.h @@ -54,6 +54,7 @@ class LookingGlassEffect : public QObject, public ShaderEffect private: double zoom; double target_zoom; + bool polling; // Mouse polling int radius; int initialradius; KActionCollection* actionCollection; diff --git a/effects/magnifier.cpp b/effects/magnifier.cpp index 0bc65c6694..c64737b789 100644 --- a/effects/magnifier.cpp +++ b/effects/magnifier.cpp @@ -42,6 +42,7 @@ const int FRAME_WIDTH = 5; MagnifierEffect::MagnifierEffect() : zoom( 1 ) , target_zoom( 1 ) + , polling( false ) { KActionCollection* actionCollection = new KActionCollection( this ); KAction* a; @@ -144,6 +145,11 @@ QRect MagnifierEffect::magnifierArea( QPoint pos ) const void MagnifierEffect::zoomIn() { target_zoom *= 1.2; + if( !polling ) + { + polling = true; + effects->startMousePolling(); + } effects->addRepaint( magnifierArea().adjusted( -FRAME_WIDTH, -FRAME_WIDTH, FRAME_WIDTH, FRAME_WIDTH )); } @@ -152,6 +158,11 @@ void MagnifierEffect::zoomOut() target_zoom /= 1.2; if( target_zoom < 1 ) target_zoom = 1; + if( polling ) + { + polling = false; + effects->stopMousePolling(); + } effects->addRepaint( magnifierArea().adjusted( -FRAME_WIDTH, -FRAME_WIDTH, FRAME_WIDTH, FRAME_WIDTH )); } diff --git a/effects/magnifier.h b/effects/magnifier.h index 45d467a022..7ed5018846 100644 --- a/effects/magnifier.h +++ b/effects/magnifier.h @@ -47,6 +47,7 @@ class MagnifierEffect QRect magnifierArea( QPoint pos = cursorPos()) const; double zoom; double target_zoom; + bool polling; // Mouse polling QSize magnifier_size; }; diff --git a/effects/mousemark.cpp b/effects/mousemark.cpp index 93ba41cb06..8f5e3fcf33 100644 --- a/effects/mousemark.cpp +++ b/effects/mousemark.cpp @@ -58,6 +58,12 @@ MouseMarkEffect::MouseMarkEffect() connect( a, SIGNAL( triggered( bool )), this, SLOT( clearLast())); reconfigure( ReconfigureAll ); arrow_start = NULL_POINT; + effects->startMousePolling(); // We require it to detect activation as well + } + +MouseMarkEffect::~MouseMarkEffect() + { + effects->stopMousePolling(); } void MouseMarkEffect::reconfigure( ReconfigureFlags ) diff --git a/effects/mousemark.h b/effects/mousemark.h index 217aa61262..11edfb7f4d 100644 --- a/effects/mousemark.h +++ b/effects/mousemark.h @@ -33,6 +33,7 @@ class MouseMarkEffect Q_OBJECT public: MouseMarkEffect(); + ~MouseMarkEffect(); virtual void reconfigure( ReconfigureFlags ); virtual void paintScreen( int mask, QRegion region, ScreenPaintData& data ); virtual void mouseChanged( const QPoint& pos, const QPoint& old, diff --git a/effects/trackmouse.cpp b/effects/trackmouse.cpp index 1d3573d05b..91a8481821 100644 --- a/effects/trackmouse.cpp +++ b/effects/trackmouse.cpp @@ -48,10 +48,12 @@ TrackMouseEffect::TrackMouseEffect() , angle( 0 ) , texture( NULL ) { + effects->startMousePolling(); // We require it to detect activation as well } TrackMouseEffect::~TrackMouseEffect() { + effects->stopMousePolling(); delete texture; } diff --git a/effects/trackmouse.desktop b/effects/trackmouse.desktop index 51ad6164ff..621277d1f5 100644 --- a/effects/trackmouse.desktop +++ b/effects/trackmouse.desktop @@ -120,5 +120,5 @@ X-KDE-PluginInfo-Version=0.1.0 X-KDE-PluginInfo-Category=Accessibility X-KDE-PluginInfo-Depends= X-KDE-PluginInfo-License=GPL -X-KDE-PluginInfo-EnabledByDefault=true +X-KDE-PluginInfo-EnabledByDefault=false X-KDE-Library=kwin4_effect_builtins diff --git a/effects/zoom.cpp b/effects/zoom.cpp index 27c64b1103..8a57e35946 100644 --- a/effects/zoom.cpp +++ b/effects/zoom.cpp @@ -32,6 +32,7 @@ KWIN_EFFECT( zoom, ZoomEffect ) ZoomEffect::ZoomEffect() : zoom( 1 ) , target_zoom( 1 ) + , polling( false ) { KActionCollection* actionCollection = new KActionCollection( this ); KAction* a; @@ -82,6 +83,11 @@ void ZoomEffect::postPaintScreen() void ZoomEffect::zoomIn() { target_zoom *= 1.2; + if( !polling ) + { + polling = true; + effects->startMousePolling(); + } effects->addRepaintFull(); } @@ -90,6 +96,11 @@ void ZoomEffect::zoomOut() target_zoom /= 1.2; if( target_zoom < 1 ) target_zoom = 1; + if( polling ) + { + polling = false; + effects->stopMousePolling(); + } effects->addRepaintFull(); } diff --git a/effects/zoom.h b/effects/zoom.h index d805ce2ea2..44037ccbbf 100644 --- a/effects/zoom.h +++ b/effects/zoom.h @@ -45,6 +45,7 @@ class ZoomEffect private: double zoom; double target_zoom; + bool polling; // Mouse polling }; } // namespace diff --git a/lib/kwineffects.h b/lib/kwineffects.h index dbd10f8b6e..94a7088a7c 100644 --- a/lib/kwineffects.h +++ b/lib/kwineffects.h @@ -508,6 +508,10 @@ class KWIN_EXPORT EffectsHandler virtual bool grabKeyboard( Effect* effect ) = 0; virtual void ungrabKeyboard() = 0; + // Mouse polling + virtual void startMousePolling() = 0; + virtual void stopMousePolling() = 0; + virtual void checkElectricBorder(const QPoint &pos, Time time) = 0; virtual void reserveElectricBorder( ElectricBorder border ) = 0; virtual void unreserveElectricBorder( ElectricBorder border ) = 0; diff --git a/workspace.cpp b/workspace.cpp index c46c6272ba..e5a9e0142e 100644 --- a/workspace.cpp +++ b/workspace.cpp @@ -354,6 +354,7 @@ void Workspace::init() connect( &reconfigureTimer, SIGNAL( timeout() ), this, SLOT( slotReconfigure() )); connect( &updateToolWindowsTimer, SIGNAL( timeout() ), this, SLOT( slotUpdateToolWindows() )); connect( &compositeTimer, SIGNAL( timeout() ), SLOT( performCompositing() )); + connect( &mousePollingTimer, SIGNAL( timeout() ), SLOT( performMousePoll() )); connect( KGlobalSettings::self(), SIGNAL( appearanceChanged() ), this, SLOT( reconfigure() )); connect( KGlobalSettings::self(), SIGNAL( settingsChanged(int) ), this, SLOT( slotSettingsChanged(int) )); diff --git a/workspace.h b/workspace.h index 1157689d80..b3835c9d6c 100644 --- a/workspace.h +++ b/workspace.h @@ -357,6 +357,10 @@ class Workspace : public QObject, public KDecorationDefines void checkUnredirect( bool force = false ); void checkCompositeTimer(); + // Mouse polling + void startMousePolling(); + void stopMousePolling(); + public slots: void addRepaintFull(); void refresh(); @@ -517,6 +521,7 @@ class Workspace : public QObject, public KDecorationDefines void setPopupClientOpacity( QAction* action ); void setupCompositing(); void performCompositing(); + void performMousePoll(); void lostCMSelection(); void updateElectricBorders(); void resetCursorPosTime(); @@ -765,6 +770,7 @@ class Workspace : public QObject, public KDecorationDefines QTimer compositeTimer; QTime lastCompositePaint; QTime nextPaintReference; + QTimer mousePollingTimer; int compositeRate; QRegion repaints_region; Window overlay; // XComposite overlay window From a8e370fa34a4d786f3ba924465c7d593543dcb52 Mon Sep 17 00:00:00 2001 From: Script Kiddy Date: Sun, 1 Feb 2009 16:24:40 +0000 Subject: [PATCH 10/60] SVN_SILENT made messages (.desktop file) svn path=/trunk/KDE/kdebase/workspace/; revision=919783 The following changes were in SVN, but were removed from git: M wallpapers/HighTide/metadata.desktop --- effects/fadedesktop.desktop | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/effects/fadedesktop.desktop b/effects/fadedesktop.desktop index 5958a3d03f..0e81af39d7 100644 --- a/effects/fadedesktop.desktop +++ b/effects/fadedesktop.desktop @@ -1,10 +1,16 @@ [Desktop Entry] Name=Fade Desktop Name[gl]=Esvair o escritorio +Name[pt]=Desvanecer o Ecrã +Name[pt_BR]=Desvanecer o Ecrã +Name[sv]=Tona skrivbord Name[uk]=Затемнювати стільницю Icon=preferences-system-windows-effect-fadedesktop Comment=Fade between virtual desktops when switching between them Comment[gl]=Emprega un efeito de esvaemento ao trocar de escritorio +Comment[pt]=Desvanece entre os ecrãs virtuais, ao circular entre eles +Comment[pt_BR]=Desvanece entre os ecrãs virtuais, ao circular entre eles +Comment[sv]=Tona mellan virtuella skrivbord vid byte mellan dem Comment[uk]=Затемнення перед час перемикання між віртуальними стільницями Type=Service From d12b115dbe8dddb7124a07f0288865a19469bac4 Mon Sep 17 00:00:00 2001 From: Script Kiddy Date: Mon, 2 Feb 2009 15:35:50 +0000 Subject: [PATCH 11/60] SVN_SILENT made messages (.desktop file) svn path=/trunk/KDE/kdebase/workspace/; revision=920235 --- effects/desktopgrid.desktop | 1 + effects/diminactive.desktop | 1 + effects/diminactive_config.desktop | 1 + effects/dimscreen.desktop | 2 ++ effects/fadedesktop.desktop | 2 ++ effects/fallapart.desktop | 1 + effects/highlightwindow.desktop | 5 +++++ effects/invert.desktop | 1 + effects/magiclamp.desktop | 2 ++ effects/magiclamp_config.desktop | 1 + effects/magnifier.desktop | 1 + effects/maketransparent.desktop | 1 + effects/test/demo_liquid.desktop | 1 + effects/test/demo_shiftworkspaceup.desktop | 1 + effects/test/demo_showpicture.desktop | 1 + effects/test/drunken.desktop | 1 + effects/test/videorecord.desktop | 1 + kwin.notifyrc | 2 ++ 18 files changed, 26 insertions(+) diff --git a/effects/desktopgrid.desktop b/effects/desktopgrid.desktop index 1d5a9ca81c..6a660b73c7 100644 --- a/effects/desktopgrid.desktop +++ b/effects/desktopgrid.desktop @@ -76,6 +76,7 @@ Comment[de]=Verkleinert die Arbeitsflächen, sodass sie in einem Raster nebenein Comment[el]=Σμίκρυνση όλων των επιφανειών εργασίας και εμφάνιση σε παράθεση σε έναν κάνναβο Comment[es]=Alejarse de forma que todos los escritorios se muestren uno al lado del otro en una rejilla Comment[et]=Vähendamine, et kõik töölauad oleks üksteise kõrval võrgustikus näha +Comment[eu]=Zooma urrundu mahaigain guztiak bata bestearen ondoan sareta batean bistaratu daitezen Comment[fr]=Faire un zoom arrière de manière à afficher tous les bureaux côte à côte dans une grille Comment[gl]=Reduce de maneira que os escritorios son mostrados lado por lado en grella Comment[gu]=નાનું કરો જેથી બધાં ડેસ્કટોપ્સ બાજુ-બાજુ પર જાળીમાં દેખાય diff --git a/effects/diminactive.desktop b/effects/diminactive.desktop index 1ffeca38a8..cb67836a9c 100644 --- a/effects/diminactive.desktop +++ b/effects/diminactive.desktop @@ -11,6 +11,7 @@ Name[el]=Θαμπάδα ανενεργού Name[eo]=Malheligi neaktivajn Name[es]=Oscurecer inactiva Name[et]=Tuhm mitteaktiivne +Name[eu]=Ilundu ez aktibo Name[fi]=Himmennä passiivinen Name[fr]=Estompe les inactifs Name[fy]=Net aktive dimme diff --git a/effects/diminactive_config.desktop b/effects/diminactive_config.desktop index fc0d3029a1..79ea4c75d9 100644 --- a/effects/diminactive_config.desktop +++ b/effects/diminactive_config.desktop @@ -18,6 +18,7 @@ Name[el]=Θαμπάδα ανενεργού Name[eo]=Malheligi neaktivajn Name[es]=Oscurecer inactiva Name[et]=Tuhm mitteaktiivne +Name[eu]=Ilundu ez aktibo Name[fi]=Himmennä passiivinen Name[fr]=Estompe les inactifs Name[fy]=Net aktive dimme diff --git a/effects/dimscreen.desktop b/effects/dimscreen.desktop index 34f4f67bbe..3fdcb74774 100644 --- a/effects/dimscreen.desktop +++ b/effects/dimscreen.desktop @@ -10,6 +10,7 @@ Name[el]=Θάμπωμα οθόνης σε λειτουργία διαχειρι Name[eo]=Malheligi la ekranon en administra reĝimo Name[es]=Aclarar la pantalla en el modo administrador Name[et]=Tuhm ekraan administraatori režiimis +Name[eu]=Ilundu leihoa administratzaile modurako Name[fi]=Tummena näyttö pääkäyttäjätilassa Name[fr]=Assombrir l'écran en mode administrateur Name[fy]=Yn administratormodus it skerm dimme @@ -61,6 +62,7 @@ Comment[de]=Dunkelt den gesamten Bildschirm ab, wenn nach dem Systemverwalter-Pa Comment[el]=Σκίαση ολόκληρης της οθόνης όταν απαιτούνται διακαιώματα ριζικού χρήστη root Comment[es]=Oscurece la pantalla completa cuando se requieran privilegios de root Comment[et]=Tumendab administraatori õiguste nõudmisel kogu ekraani +Comment[eu]=Pantaila osoa iluntzen du root eskubideak eskatzerakoan Comment[fr]=Noircit l'ensemble du bureau quand les privilèges administrateurs sont requis Comment[fy]=It gehiele skerm donker meitsje as der om root-rjochten frege wurdt Comment[gl]=Escurece toda a pantalla cando se piden os privilexios de root diff --git a/effects/fadedesktop.desktop b/effects/fadedesktop.desktop index 0e81af39d7..7877f638e6 100644 --- a/effects/fadedesktop.desktop +++ b/effects/fadedesktop.desktop @@ -5,6 +5,7 @@ Name[pt]=Desvanecer o Ecrã Name[pt_BR]=Desvanecer o Ecrã Name[sv]=Tona skrivbord Name[uk]=Затемнювати стільницю +Name[zh_TW]=淡出淡入桌面 Icon=preferences-system-windows-effect-fadedesktop Comment=Fade between virtual desktops when switching between them Comment[gl]=Emprega un efeito de esvaemento ao trocar de escritorio @@ -12,6 +13,7 @@ Comment[pt]=Desvanece entre os ecrãs virtuais, ao circular entre eles Comment[pt_BR]=Desvanece entre os ecrãs virtuais, ao circular entre eles Comment[sv]=Tona mellan virtuella skrivbord vid byte mellan dem Comment[uk]=Затемнення перед час перемикання між віртуальними стільницями +Comment[zh_TW]=在虛擬桌面間切換時使用淡出/淡入效果 Type=Service X-KDE-ServiceTypes=KWin/Effect diff --git a/effects/fallapart.desktop b/effects/fallapart.desktop index 47aed45e10..541e7588e8 100644 --- a/effects/fallapart.desktop +++ b/effects/fallapart.desktop @@ -72,6 +72,7 @@ Comment[el]=Τα παράθυρα που κλείνουν διαλύονται Comment[eo]=Fermantaj fenestroj disiĝas en pecoj Comment[es]=Las ventanas cerradas caen en trozos Comment[et]=Suletud aknad lagunevad tükkideks +Comment[eu]=Itxitako leihoak zatika erortzen dira Comment[fi]=Suljetut ikkunat hajoavat palasiksi. Comment[fr]=Les fenêtres fermées s'effondrent Comment[fy]=Sluten finsters falle útelkoar diff --git a/effects/highlightwindow.desktop b/effects/highlightwindow.desktop index 68a51c8769..8bc57f86bb 100644 --- a/effects/highlightwindow.desktop +++ b/effects/highlightwindow.desktop @@ -1,7 +1,12 @@ [Desktop Entry] Name=Highlight Window +Name[eu]=Leihoa nabarmendu +Name[uk]=Підсвітити вікно +Name[zh_TW]=突顯視窗 Icon=preferences-system-windows-effect-highlightwindow Comment=Highlight the appropriate window when hovering over taskbar entries +Comment[uk]=Підсвітити відповідне вікно, коли курсор знаходиться над елементом панелі задач +Comment[zh_TW]=當游標停在工作列的按鈕上面時,突顯視窗 Type=Service X-KDE-ServiceTypes=KWin/Effect diff --git a/effects/invert.desktop b/effects/invert.desktop index a3fbc85659..efe59ed245 100644 --- a/effects/invert.desktop +++ b/effects/invert.desktop @@ -79,6 +79,7 @@ Comment[de]=Invertiert die Farben der Arbeitsfläche und Fenster. Comment[el]=Αντιστροφή του χρώματος της επιφάνειας εργασίας και των παραθύρων Comment[es]=Invierte el color del escritorio y ventanas Comment[et]=Muudab töölaua ja akende värvi vastupidiseks +Comment[eu]=Mahaigain eta leihoen koloreak alderantzikatzen ditu Comment[fr]=Inverse la couleur du bureau et des fenêtres Comment[fy]=De kleur fan buroblêden en finster omdraaie Comment[gl]=Inverte a cor do escritorio e das fiestras diff --git a/effects/magiclamp.desktop b/effects/magiclamp.desktop index b8f1cf68b1..3c55d2e163 100644 --- a/effects/magiclamp.desktop +++ b/effects/magiclamp.desktop @@ -10,6 +10,7 @@ Name[de]=Wunderlampe Name[el]=Μαγικό λυχνάρι Name[es]=Lámpara mágica Name[et]=Võlulatern +Name[eu]=Lanpara magikoa Name[fr]=Lampe Magique Name[fy]=Magyske lamp Name[gl]=Lámpada máxica @@ -62,6 +63,7 @@ Comment[de]=Simuliert zum Minimieren von Fenstern den Effekt einer Wunderlampe. Comment[el]=Εξομοίωση ενός μαγικού λυχναριού κατά την ελαχιστοποίηση παραθύρων Comment[es]=Simula una lámpara mágica en la minimización de ventanas Comment[et]=Võlulaterna simuleerimine akende minimeerimisel +Comment[eu]=Lanpara magiko bat simulatu leihoak minimizatzerakoan Comment[fr]=Simule une lampe magique lors de la réduction des fenêtres Comment[fy]=Docht sich foar as in magyske lampe ûnder it minimalisearjen fan finsters Comment[gl]=Simula unha lámpada máxica ao minimizar as fiestras diff --git a/effects/magiclamp_config.desktop b/effects/magiclamp_config.desktop index 95a992164b..ecce4657f2 100644 --- a/effects/magiclamp_config.desktop +++ b/effects/magiclamp_config.desktop @@ -17,6 +17,7 @@ Name[de]=Wunderlampe Name[el]=Μαγικό λυχνάρι Name[es]=Lámpara mágica Name[et]=Võlulatern +Name[eu]=Lanpara magikoa Name[fr]=Lampe Magique Name[fy]=Magyske lamp Name[gl]=Lámpada máxica diff --git a/effects/magnifier.desktop b/effects/magnifier.desktop index 638fcc9126..b8865157ad 100644 --- a/effects/magnifier.desktop +++ b/effects/magnifier.desktop @@ -85,6 +85,7 @@ Comment[de]=Vergrößert den Arbeitsflächenbereich unter der Maus. Comment[el]=Μεγέθυνση του τμήματος της οθόνης που βρίσκεται κοντά στο ποντίκι Comment[es]=Amplía la parte de la pantalla que cerca bajo el ratón Comment[et]=Suurendab hiirekursori ümbruses asuvat ekraaniosa +Comment[eu]=Handitu sagu kurtsorearen ondoan dagoen leihoaren zatia Comment[fr]=Agrandit la partie de l'écran proche du pointeur de la souris Comment[fy]=Fergruttet it part fan it skerm dat him ûnder de mûs befynt Comment[ga]=Formhéadaigh an pháirt den scáileán i ngar do chúrsóir na luiche diff --git a/effects/maketransparent.desktop b/effects/maketransparent.desktop index 0e5fe846fe..a9a5d36590 100644 --- a/effects/maketransparent.desktop +++ b/effects/maketransparent.desktop @@ -81,6 +81,7 @@ Comment[de]=Lässt Fenster unter festgelegten Bedingungen durchscheinen. Comment[el]=Εμφάνιση ημιδιαφανών παραθύρων σε διάφορες περιπτώσεις Comment[es]=Hace la ventana translúcida en distintas condiciones Comment[et]=Akende muutmine läbipaistvaks teatavatel tingimustel +Comment[eu]=Leihoak zeharrargitsu egiten ditu baldintza desberdinetan Comment[fr]=Affiche des fenêtres translucides en fonction de diverses conditions Comment[fy]=Meitsje finsters trochsichtich ûnder oare kondysjes Comment[gl]=Fai translúcidas as fiestras en diferentes casos diff --git a/effects/test/demo_liquid.desktop b/effects/test/demo_liquid.desktop index d4a561af19..24cb6fc236 100644 --- a/effects/test/demo_liquid.desktop +++ b/effects/test/demo_liquid.desktop @@ -10,6 +10,7 @@ Name[de]=Demo: Liquid Name[el]=Επίδειξη του Liquid Name[eo]=Demonstro likvaĵo Name[es]=Demostración de Liquid +Name[eu]=Liquid demo Name[fr]=Démo liquide Name[ga]=Maisíocht Taispeána: Leacht Name[gl]=Demostración de Liquid diff --git a/effects/test/demo_shiftworkspaceup.desktop b/effects/test/demo_shiftworkspaceup.desktop index 76fa455640..5ff745c1de 100644 --- a/effects/test/demo_shiftworkspaceup.desktop +++ b/effects/test/demo_shiftworkspaceup.desktop @@ -9,6 +9,7 @@ Name[de]=Demo: Arbeitsfläche nach oben Name[el]=Επίδειξη του ShiftWorkspaceUp Name[eo]=Demonstro movi laborspacon supren Name[es]=Demostración de ShiftWorkspaceUp +Name[eu]=ShiftWorkspaceUp demo Name[fi]=Demo "siirrä työpöytä ylös" Name[fr]=Démo de changement d'espace de travail Name[ga]=Maisíocht Taispeána: Bog Spás Oibre Suas diff --git a/effects/test/demo_showpicture.desktop b/effects/test/demo_showpicture.desktop index 0bc95a57f4..bffc9bc7b1 100644 --- a/effects/test/demo_showpicture.desktop +++ b/effects/test/demo_showpicture.desktop @@ -9,6 +9,7 @@ Name[de]=Demo: Bild anzeigen Name[el]=Επίδειξη της Εμφάνισης φωτογραφίας Name[eo]=Demonstro montru bildon Name[es]=Demostración de ShowPicture +Name[eu]=ShowPicture demo Name[fi]=Demo "Näytä kuva" Name[fr]=Démo d'affichage d'image Name[ga]=Maisíocht Taispeána: Taispeáin Pictiúr diff --git a/effects/test/drunken.desktop b/effects/test/drunken.desktop index 3cf557db90..03e7482a55 100644 --- a/effects/test/drunken.desktop +++ b/effects/test/drunken.desktop @@ -9,6 +9,7 @@ Name[el]=Κούνημα Name[eo]=Ebria Name[es]=Borracho Name[et]=Purjus +Name[eu]=Mozkorra Name[fi]=Juopunut Name[fr]=Ivre Name[fy]=Dronken diff --git a/effects/test/videorecord.desktop b/effects/test/videorecord.desktop index 869baf2dd4..0611e89ccd 100644 --- a/effects/test/videorecord.desktop +++ b/effects/test/videorecord.desktop @@ -81,6 +81,7 @@ Comment[de]=Zeichnet Videos von der Arbeitsfläche auf. Comment[el]=Εγγραφή ενός βίντεο της επιφάνειας εργασίας σας Comment[es]=Le permite grabar vídeos de su escritorio Comment[et]=Võimaldab salvestada videoid töölauast +Comment[eu]=Zure mahaigainaren bideo bat grabatu Comment[fr]=Enregistre des vidéos de votre bureau Comment[fy]=In fideo opnimme fan jo buroblêd Comment[ga]=Taifead fís de do dheasc diff --git a/kwin.notifyrc b/kwin.notifyrc index 6f03cb9828..a88c380d8b 100644 --- a/kwin.notifyrc +++ b/kwin.notifyrc @@ -5849,6 +5849,7 @@ Name[de]=Die Composit-Geschwindigkeit ist niedrig Name[el]=Οι επιδόσεις σύνθεσης της εικόνας είναι χαμηλές Name[es]=El rendimiento de composición es lento Name[et]=Komposiidi jõudlus on nõrk +Name[eu]=Konposaketaren performantzia motela da Name[fr]=La performances de composition est basse Name[fy]=De prestaasje fan compositing binne traach Name[gl]=O rendemento da composición é pobre @@ -5892,6 +5893,7 @@ Comment[de]=Die Composit-Geschwindigkeit ist niedrig, daher wurde die Compositin Comment[el]=Οι επιδόσεις σύνθεσης της εικόνας ήταν πολύ χαμηλές και η σύνθεση εικόνας αναστάλθηκε Comment[es]=El rendimiento de composición era tan lento que se ha suspendido Comment[et]=Komposiidi jõudlus oli kesine ja komposiit peatati +Comment[eu]=Konposaketaren performantzia motelegia zen eta konposaketa eseki egin da Comment[fr]=La performance de composition était trop basse et celle-ci a due être suspendue Comment[fy]=De prestaasje fan compositing wie te traach en is ûnderbrútsen Comment[gl]=O rendeento da composición era baixo de máis polo que se detivo a composición From 6763fd5728bb8da63dff0dbdde9cec862f0cf3f0 Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Tue, 3 Feb 2009 09:39:48 +0000 Subject: [PATCH 12/60] Use the opacity of the window that a taskbar thumbnail is displayed on when displaying the thumbnail. This allows thumbnails to fade in and out with the Plasma tooltip for example instead of always being opaque. svn path=/trunk/KDE/kdebase/workspace/; revision=920573 --- effects/taskbarthumbnail.cpp | 14 +++++++++----- effects/taskbarthumbnail.desktop | 1 + 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/effects/taskbarthumbnail.cpp b/effects/taskbarthumbnail.cpp index 8bcd3adfb1..a16327cbc8 100644 --- a/effects/taskbarthumbnail.cpp +++ b/effects/taskbarthumbnail.cpp @@ -67,18 +67,22 @@ void TaskbarThumbnailEffect::paintWindow( EffectWindow* w, int mask, QRegion reg effects->paintWindow( w, mask, region, data ); // paint window first if( thumbnails.contains( w )) { // paint thumbnails on it + int mask = PAINT_WINDOW_TRANSFORMED; + if( data.opacity == 1.0 ) + mask |= PAINT_WINDOW_OPAQUE; + else + mask |= PAINT_WINDOW_TRANSLUCENT; foreach( const Data &thumb, thumbnails.values( w )) { EffectWindow* thumbw = effects->findWindow( thumb.window ); if( thumbw == NULL ) continue; - WindowPaintData data( thumbw ); + WindowPaintData thumbData( thumbw ); + thumbData.opacity = data.opacity; QRect r; - setPositionTransformations( data, r, + setPositionTransformations( thumbData, r, thumbw, thumb.rect.translated( w->pos()), Qt::KeepAspectRatio ); - effects->drawWindow( thumbw, - PAINT_WINDOW_OPAQUE | PAINT_WINDOW_TRANSFORMED, - r, data ); + effects->drawWindow( thumbw, mask, r, thumbData ); } } } diff --git a/effects/taskbarthumbnail.desktop b/effects/taskbarthumbnail.desktop index 3b3ff9781c..27f63ef48d 100644 --- a/effects/taskbarthumbnail.desktop +++ b/effects/taskbarthumbnail.desktop @@ -116,4 +116,5 @@ X-KDE-PluginInfo-Category=Appearance X-KDE-PluginInfo-Depends= X-KDE-PluginInfo-License=GPL X-KDE-PluginInfo-EnabledByDefault=true +X-KDE-Ordering=70 X-KDE-Library=kwin4_effect_builtins From 8c55ce79cf9e4e6bff5be57e9c9d9dc3a77c9e96 Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Tue, 3 Feb 2009 10:51:36 +0000 Subject: [PATCH 13/60] Remove the fade effect dependency from the highlight window effect by implementing the fade internally. Fixes some fading bugs and will make off-screen window highlighting easier to implement whenever I get around to doing it. svn path=/trunk/KDE/kdebase/workspace/; revision=920590 --- effects/highlightwindow.cpp | 78 +++++++++++++++++++++++++++------ effects/highlightwindow.desktop | 1 + effects/highlightwindow.h | 8 ++++ 3 files changed, 74 insertions(+), 13 deletions(-) diff --git a/effects/highlightwindow.cpp b/effects/highlightwindow.cpp index 9c419a0be2..8623f7c61a 100644 --- a/effects/highlightwindow.cpp +++ b/effects/highlightwindow.cpp @@ -28,7 +28,9 @@ namespace KWin KWIN_EFFECT( highlightwindow, HighlightWindowEffect ) HighlightWindowEffect::HighlightWindowEffect() - : m_highlightedWindow( NULL ) + : m_finishing( false ) + , m_fadeDuration( double( animationTime( 150 ))) + , m_highlightedWindow( NULL ) , m_monitorWindow( NULL ) { m_atom = XInternAtom( display(), "_KDE_WINDOW_HIGHLIGHT", False ); @@ -47,31 +49,61 @@ HighlightWindowEffect::~HighlightWindowEffect() void HighlightWindowEffect::prePaintWindow( EffectWindow* w, WindowPrePaintData& data, int time ) { - // If we are highlighting a window set the translucent flag to all others - if( m_highlightedWindow && m_highlightedWindow != w && m_monitorWindow != w && w->isNormalWindow() ) - data.mask |= PAINT_WINDOW_TRANSLUCENT; + // Calculate window opacities + if( m_highlightedWindow ) + { // Initial fade out and changing highlight animation + double oldOpacity = m_windowOpacity[w]; + if( m_highlightedWindow == w ) + m_windowOpacity[w] = qMin( 1.0, m_windowOpacity[w] + time / m_fadeDuration ); + else if( w->isNormalWindow() ) // Only fade out normal windows + m_windowOpacity[w] = qMax( 0.15, m_windowOpacity[w] - time / m_fadeDuration ); + + if( m_windowOpacity[w] != 1.0 ) + data.setTranslucent(); + if( oldOpacity != m_windowOpacity[w] ) + w->addRepaintFull(); + } + else if( m_finishing && m_windowOpacity.contains( w )) + { // Final fading back in animation + double oldOpacity = m_windowOpacity[w]; + m_windowOpacity[w] = qMin( 1.0, m_windowOpacity[w] + time / m_fadeDuration ); + + if( m_windowOpacity[w] != 1.0 ) + data.setTranslucent(); + if( oldOpacity != m_windowOpacity[w] ) + w->addRepaintFull(); + + if( m_windowOpacity[w] == 1.0 ) + m_windowOpacity.remove( w ); // We default to 1.0 + } + effects->prePaintWindow( w, data, time ); } void HighlightWindowEffect::paintWindow( EffectWindow* w, int mask, QRegion region, WindowPaintData& data ) { - if( m_highlightedWindow && m_highlightedWindow != w && m_monitorWindow != w && w->isNormalWindow() ) - data.opacity *= 0.15; // TODO: Fade out + if( m_windowOpacity.contains( w )) + data.opacity *= m_windowOpacity[w]; effects->paintWindow( w, mask, region, data ); } void HighlightWindowEffect::windowAdded( EffectWindow* w ) { + if( m_highlightedWindow ) + { // The effect is activated thus we need to add it to the opacity hash + if( w->isNormalWindow() ) // Only fade out normal windows + m_windowOpacity[w] = 0.15; + else + m_windowOpacity[w] = 1.0; + } propertyNotify( w, m_atom ); // Check initial value } void HighlightWindowEffect::windowDeleted( EffectWindow* w ) { - if( m_monitorWindow == w ) - { // The monitoring window was destroyed - m_monitorWindow = NULL; - m_highlightedWindow = NULL; - } + m_windowOpacity.remove( w ); + if( m_monitorWindow == w ) // The monitoring window was destroyed + finishHighlighting(); } void HighlightWindowEffect::propertyNotify( EffectWindow* w, long a ) @@ -86,14 +118,34 @@ void HighlightWindowEffect::propertyNotify( EffectWindow* w, long a ) if( !data[0] ) { // Purposely clearing highlight - m_monitorWindow = NULL; - m_highlightedWindow = NULL; + finishHighlighting(); return; } m_monitorWindow = w; m_highlightedWindow = effects->findWindow( data[0] ); if( !m_highlightedWindow ) + { kDebug(1212) << "Invalid window targetted for highlight. Requested:" << data[0]; + return; + } + prepareHighlighting(); + m_windowOpacity[w] = 1.0; // Because it's not in stackingOrder() yet + } + +void HighlightWindowEffect::prepareHighlighting() + { + // Create window data for every window. Just calling [w] creates it. + m_finishing = false; + foreach( EffectWindow *w, effects->stackingOrder() ) + if( !m_windowOpacity.contains( w )) // Just in case we are still finishing from last time + m_windowOpacity[w] = 1.0; + } + +void HighlightWindowEffect::finishHighlighting() + { + m_finishing = true; + m_monitorWindow = NULL; + m_highlightedWindow = NULL; } } // namespace diff --git a/effects/highlightwindow.desktop b/effects/highlightwindow.desktop index 8bc57f86bb..5a9ac7c6c9 100644 --- a/effects/highlightwindow.desktop +++ b/effects/highlightwindow.desktop @@ -18,4 +18,5 @@ X-KDE-PluginInfo-Category=Appearance X-KDE-PluginInfo-Depends= X-KDE-PluginInfo-License=GPL X-KDE-PluginInfo-EnabledByDefault=true +X-KDE-Ordering=70 X-KDE-Library=kwin4_effect_builtins diff --git a/effects/highlightwindow.h b/effects/highlightwindow.h index 58c11eb86a..414d880555 100644 --- a/effects/highlightwindow.h +++ b/effects/highlightwindow.h @@ -42,6 +42,14 @@ class HighlightWindowEffect virtual void propertyNotify( EffectWindow* w, long atom ); private: + void prepareHighlighting(); + void finishHighlighting(); + + bool m_finishing; + + double m_fadeDuration; + QHash m_windowOpacity; + long m_atom; EffectWindow* m_highlightedWindow; EffectWindow* m_monitorWindow; From 4de600e9c1ea2fa533cbcb232a568d2cb7b876e8 Mon Sep 17 00:00:00 2001 From: Script Kiddy Date: Tue, 3 Feb 2009 14:52:58 +0000 Subject: [PATCH 14/60] SVN_SILENT made messages (.desktop file, second try) svn path=/trunk/KDE/kdebase/workspace/; revision=920635 --- effects/fadedesktop.desktop | 2 ++ effects/highlightwindow.desktop | 4 ++++ 2 files changed, 6 insertions(+) diff --git a/effects/fadedesktop.desktop b/effects/fadedesktop.desktop index 7877f638e6..4ececa25fd 100644 --- a/effects/fadedesktop.desktop +++ b/effects/fadedesktop.desktop @@ -1,5 +1,6 @@ [Desktop Entry] Name=Fade Desktop +Name[et]=Töölaua hääbumine Name[gl]=Esvair o escritorio Name[pt]=Desvanecer o Ecrã Name[pt_BR]=Desvanecer o Ecrã @@ -8,6 +9,7 @@ Name[uk]=Затемнювати стільницю Name[zh_TW]=淡出淡入桌面 Icon=preferences-system-windows-effect-fadedesktop Comment=Fade between virtual desktops when switching between them +Comment[et]=Hääbumisefekt ühelt virtuaalselt töölaualt teisele lülitudes Comment[gl]=Emprega un efeito de esvaemento ao trocar de escritorio Comment[pt]=Desvanece entre os ecrãs virtuais, ao circular entre eles Comment[pt_BR]=Desvanece entre os ecrãs virtuais, ao circular entre eles diff --git a/effects/highlightwindow.desktop b/effects/highlightwindow.desktop index 5a9ac7c6c9..fa73767179 100644 --- a/effects/highlightwindow.desktop +++ b/effects/highlightwindow.desktop @@ -1,10 +1,14 @@ [Desktop Entry] Name=Highlight Window +Name[et]=Akna esiletõstmine Name[eu]=Leihoa nabarmendu +Name[ga]=Aibhsigh Fuinneog Name[uk]=Підсвітити вікно Name[zh_TW]=突顯視窗 Icon=preferences-system-windows-effect-highlightwindow Comment=Highlight the appropriate window when hovering over taskbar entries +Comment[et]=Akende esiletõstmine, kui kursor on nende tegumiriba kirje kohal +Comment[ga]=Aibhsigh an fhuinneog chuí nuair atá an cúrsóir os cionn iontrála sa tascbharra Comment[uk]=Підсвітити відповідне вікно, коли курсор знаходиться над елементом панелі задач Comment[zh_TW]=當游標停在工作列的按鈕上面時,突顯視窗 From 9e9c18796f8600210941c1fa68234075ef4dcd22 Mon Sep 17 00:00:00 2001 From: "Friedrich W. H. Kossebau" Date: Wed, 4 Feb 2009 01:11:19 +0000 Subject: [PATCH 15/60] make const-to-be arrays (of pointers) const and non-variable svn path=/trunk/KDE/kdebase/workspace/; revision=920918 --- clients/kwmtheme/kwmthemeclient.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/clients/kwmtheme/kwmthemeclient.cpp b/clients/kwmtheme/kwmthemeclient.cpp index 7db77b2bfe..7b120a54c7 100644 --- a/clients/kwmtheme/kwmthemeclient.cpp +++ b/clients/kwmtheme/kwmthemeclient.cpp @@ -92,7 +92,7 @@ static bool titleTransparent; static void create_pixmaps() { - const char *keys[] = {"wm_top", "wm_bottom", "wm_left", "wm_right", + const char * const keys[] = {"wm_top", "wm_bottom", "wm_left", "wm_right", "wm_topleft", "wm_topright", "wm_bottomleft", "wm_bottomright"}; if(pixmaps_created) @@ -292,7 +292,7 @@ void KWMThemeClient::init() QString val; MyButton *btn; int i; - static const char *defaultButtons[]={"Menu","Sticky","Off","Iconify", + static const char * const defaultButtons[]={"Menu","Sticky","Off","Iconify", "Maximize","Close"}; static const char keyOffsets[]={"ABCDEF"}; for(i=0; i < 6; ++i){ From d0b6642abddda460c63b99223f062cbd8209f522 Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Wed, 4 Feb 2009 06:48:25 +0000 Subject: [PATCH 16/60] Prevent the fade effect from constantly issuing repaint requests when it is not needed. Prevents desktop grid excessive CPU usage. CCBUG: 182997 svn path=/trunk/KDE/kdebase/workspace/; revision=920960 --- effects/fade.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/effects/fade.cpp b/effects/fade.cpp index e376fd5172..47a2c15d9e 100644 --- a/effects/fade.cpp +++ b/effects/fade.cpp @@ -42,8 +42,11 @@ void FadeEffect::reconfigure( ReconfigureFlags ) // Add all existing windows to the window list // TODO: Enabling desktop effects should trigger windowAdded() on all windows windows.clear(); + if( !fadeWindows ) + return; foreach( EffectWindow *w, effects->stackingOrder() ) - windows[ w ].opacity = 1.0; + if( w && isFadeWindow( w )) // TODO: Apparently w can == NULL here? + windows[ w ] = WindowInfo(); } void FadeEffect::prePaintScreen( ScreenPrePaintData& data, int time ) @@ -76,7 +79,7 @@ void FadeEffect::prePaintWindow( EffectWindow* w, WindowPrePaintData& data, int } } effects->prePaintWindow( w, data, time ); - if( windows.contains( w ) && !w->isPaintingEnabled()) + if( windows.contains( w ) && !w->isPaintingEnabled() && !effects->activeFullScreenEffect() ) { // if the window isn't to be painted, then let's make sure // to track its progress if( windows[ w ].fadeInStep < 1.0 From cbea2199640f23e1f44df690f3b1a661b3a73053 Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Wed, 4 Feb 2009 07:09:47 +0000 Subject: [PATCH 17/60] Missing code from mouse polling commit. Stop polling when compositing is disabled and increment the effect API version number. svn path=/trunk/KDE/kdebase/workspace/; revision=920963 --- composite.cpp | 1 + lib/kwineffects.h | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/composite.cpp b/composite.cpp index 6922c2faa0..36a3b3fe76 100644 --- a/composite.cpp +++ b/composite.cpp @@ -247,6 +247,7 @@ void Workspace::finishCompositing() delete scene; scene = NULL; compositeTimer.stop(); + mousePollingTimer.stop(); repaints_region = QRegion(); for( ClientList::ConstIterator it = clients.constBegin(); it != clients.constEnd(); diff --git a/lib/kwineffects.h b/lib/kwineffects.h index 94a7088a7c..540eb91fa2 100644 --- a/lib/kwineffects.h +++ b/lib/kwineffects.h @@ -164,7 +164,7 @@ X-KDE-Library=kwin4_effect_cooleffect #define KWIN_EFFECT_API_MAKE_VERSION( major, minor ) (( major ) << 8 | ( minor )) #define KWIN_EFFECT_API_VERSION_MAJOR 0 -#define KWIN_EFFECT_API_VERSION_MINOR 57 +#define KWIN_EFFECT_API_VERSION_MINOR 58 #define KWIN_EFFECT_API_VERSION KWIN_EFFECT_API_MAKE_VERSION( \ KWIN_EFFECT_API_VERSION_MAJOR, KWIN_EFFECT_API_VERSION_MINOR ) From 71cdab755e7bd3625094261c85f25a32cfda6d0a Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Wed, 4 Feb 2009 15:10:20 +0000 Subject: [PATCH 18/60] Change motion dynamics algorithm and class structure. Animations are now smoother and less "bouncy" than before and produce the same result at any framerate. The Motion1D and Motion2D classes are now available and replace the Motion template for external use. svn path=/trunk/KDE/kdebase/workspace/; revision=921104 --- lib/kwineffects.cpp | 59 ++++++++++++++++++++++++++------- lib/kwineffects.h | 80 +++++++++++++++++++++++++++++---------------- 2 files changed, 99 insertions(+), 40 deletions(-) diff --git a/lib/kwineffects.cpp b/lib/kwineffects.cpp index 9e16e28058..342cdbf744 100644 --- a/lib/kwineffects.cpp +++ b/lib/kwineffects.cpp @@ -1069,6 +1069,42 @@ void TimeLine::setCurveShape(CurveShape curveShape) m_CurveShape = curveShape; } +/*************************************************************** + Motion1D +***************************************************************/ + +Motion1D::Motion1D( double initial, double strength, double smoothness ) + : Motion( initial, strength, smoothness ) + { + } + +Motion1D::Motion1D( const Motion1D &other ) + : Motion( other ) + { + } + +Motion1D::~Motion1D() + { + } + +/*************************************************************** + Motion2D +***************************************************************/ + +Motion2D::Motion2D( QPointF initial, double strength, double smoothness ) + : Motion( initial, strength, smoothness ) + { + } + +Motion2D::Motion2D( const Motion2D &other ) + : Motion( other ) + { + } + +Motion2D::~Motion2D() + { + } + /*************************************************************** WindowMotionManager ***************************************************************/ @@ -1088,18 +1124,19 @@ void WindowMotionManager::manage( EffectWindow *w ) if( m_managedWindows.contains( w )) return; - double strength = 0.9; - double decay = 0.75; - if( m_useGlobalAnimationModifier ) - { - if( effects->animationTimeFactor() ) // If == 0 we just skip the calculation - strength = 0.9 / effects->animationTimeFactor(); - decay = effects->animationTimeFactor() / ( effects->animationTimeFactor() + 0.3333333 ); + double strength = 0.08; + double smoothness = 4.0; + if( m_useGlobalAnimationModifier && effects->animationTimeFactor() ) + { // If the factor is == 0 then we just skip the calculation completely + strength = 0.08 / effects->animationTimeFactor(); + smoothness = effects->animationTimeFactor() * 4.0; } m_managedWindows[ w ] = WindowMotion(); - m_managedWindows[ w ].translation.setStrengthDecay( strength, decay ); - m_managedWindows[ w ].scale.setStrengthDecay( strength, decay / 2.0 ); + m_managedWindows[ w ].translation.setStrength( strength ); + m_managedWindows[ w ].translation.setSmoothness( smoothness ); + m_managedWindows[ w ].scale.setStrength( strength * 1.33 ); + m_managedWindows[ w ].scale.setSmoothness( smoothness / 2.0 ); m_managedWindows[ w ].translation.setValue( w->pos() ); m_managedWindows[ w ].scale.setValue( QPointF( 1.0, 1.0 )); @@ -1166,8 +1203,8 @@ void WindowMotionManager::calculate( int time ) { // Still scaling motion->scale.calculate( time ); diffS = motion->scale.distance(); - if( qAbs( diffS.x() ) < 0.002 && qAbs( motion->scale.velocity().x() ) < 0.05 && - qAbs( diffS.y() ) < 0.002 && qAbs( motion->scale.velocity().y() ) < 0.05 ) + if( qAbs( diffS.x() ) < 0.001 && qAbs( motion->scale.velocity().x() ) < 0.05 && + qAbs( diffS.y() ) < 0.001 && qAbs( motion->scale.velocity().y() ) < 0.05 ) { // Hide tiny oscillations motion->scale.finish(); diffS = QPoint( 0.0, 0.0 ); diff --git a/lib/kwineffects.h b/lib/kwineffects.h index 540eb91fa2..baa17382c7 100644 --- a/lib/kwineffects.h +++ b/lib/kwineffects.h @@ -1260,14 +1260,7 @@ class KWIN_EXPORT TimeLine }; /** - * @short A single motion dynamics object. - * - * This class represents a single object that can be moved around a - * n-dimensional space. Although it can be used directly by itself - * it is recommended to use a motion manager instead. - * - * To create a 1D motion object use Motion - * To create a 2D motion object use Motion + * @internal */ template class KWIN_EXPORT Motion @@ -1276,12 +1269,10 @@ class KWIN_EXPORT Motion /** * Creates a new motion object. "Strength" is the amount of * acceleration that is applied to the object when the target - * changes and "decay" relates to the amount of overshoot - * once the object reaches the target. A decay of 1.0 will - * cause never-ending oscillation and while a decay of 0.0 - * will cause no overshoot. + * changes and "smoothness" relates to how fast the object + * can change its direction and speed. */ - explicit Motion( T initial = T(), double strength = 7.5, double decay = 0.5 ); + explicit Motion( T initial, double strength, double smoothness ); /** * Creates an exact copy of another motion object, including * position, target and velocity. @@ -1298,10 +1289,8 @@ class KWIN_EXPORT Motion inline double strength() const { return m_strength; } inline void setStrength( const double strength ) { m_strength = strength; } - inline double decay() const { return m_decay; } - inline void setDecay( const double decay ) { m_decay = decay; } - inline void setStrengthDecay( const double strength, const double decay ) - { m_strength = strength; m_decay = decay; } + inline double smoothness() const { return m_smoothness; } + inline void setSmoothness( const double smoothness ) { m_smoothness = smoothness; } /** * The distance between the current position and the target. @@ -1325,7 +1314,37 @@ class KWIN_EXPORT Motion T m_target; T m_velocity; double m_strength; - double m_decay; + double m_smoothness; + }; + +/** + * @short A single 1D motion dynamics object. + * + * This class represents a single object that can be moved around a + * 1D space. Although it can be used directly by itself it is + * recommended to use a motion manager instead. + */ +class KWIN_EXPORT Motion1D : public Motion + { + public: + explicit Motion1D( double initial = 0.0, double strength = 0.08, double smoothness = 4.0 ); + Motion1D( const Motion1D &other ); + ~Motion1D(); + }; + +/** + * @short A single 2D motion dynamics object. + * + * This class represents a single object that can be moved around a + * 2D space. Although it can be used directly by itself it is + * recommended to use a motion manager instead. + */ +class KWIN_EXPORT Motion2D : public Motion + { + public: + explicit Motion2D( QPointF initial = QPointF(), double strength = 0.08, double smoothness = 4.0 ); + Motion2D( const Motion2D &other ); + ~Motion2D(); }; /** @@ -1456,8 +1475,8 @@ class KWIN_EXPORT WindowMotionManager bool m_useGlobalAnimationModifier; struct WindowMotion { // TODO: Rotation, etc? - Motion translation; // Absolute position - Motion scale; // xScale and yScale + Motion2D translation; // Absolute position + Motion2D scale; // xScale and yScale }; QHash m_managedWindows; uint m_movingWindows; @@ -1674,12 +1693,12 @@ double WindowQuad::originalBottom() const ***************************************************************/ template -Motion::Motion( T initial, double strength, double decay ) +Motion::Motion( T initial, double strength, double smoothness ) : m_value( initial ) , m_target( initial ) , m_velocity() , m_strength( strength ) - , m_decay( decay ) + , m_smoothness( smoothness ) { } @@ -1689,7 +1708,7 @@ Motion::Motion( const Motion &other ) , m_target( other.target() ) , m_velocity( other.velocity() ) , m_strength( other.strength() ) - , m_decay( other.decay() ) + , m_smoothness( other.smoothness() ) { } @@ -1704,12 +1723,15 @@ void Motion::calculate( const int msec ) if( m_value == m_target && m_velocity == T() ) // At target and not moving return; - double delta = qMin( 1.0, double( msec ) / 100.0 ); - T diff = m_target - m_value; - T strength = diff * m_strength; - m_velocity = m_decay * m_velocity * ( 1.0 - delta ) * ( 1.0 - delta ) - + strength * delta; // TODO/HACK: Need to work out correct formula - m_value += m_velocity; + // Poor man's time independent calculation + int steps = qMax( 1, msec / 5 ); + for( int i = 0; i < steps; i++ ) + { + T diff = m_target - m_value; + T strength = diff * m_strength; + m_velocity = ( m_smoothness * m_velocity + strength ) / ( m_smoothness + 1.0 ); + m_value += m_velocity; + } } template From 47ff12a419583ae9d1accf95d5d79620b0c42f04 Mon Sep 17 00:00:00 2001 From: Script Kiddy Date: Wed, 4 Feb 2009 16:27:07 +0000 Subject: [PATCH 19/60] SVN_SILENT made messages (.desktop file) svn path=/trunk/KDE/kdebase/workspace/; revision=921220 --- effects/fadedesktop.desktop | 2 ++ effects/highlightwindow.desktop | 2 ++ 2 files changed, 4 insertions(+) diff --git a/effects/fadedesktop.desktop b/effects/fadedesktop.desktop index 4ececa25fd..ab591b4087 100644 --- a/effects/fadedesktop.desktop +++ b/effects/fadedesktop.desktop @@ -2,6 +2,7 @@ Name=Fade Desktop Name[et]=Töölaua hääbumine Name[gl]=Esvair o escritorio +Name[nds]=Schriefdisch överblennen Name[pt]=Desvanecer o Ecrã Name[pt_BR]=Desvanecer o Ecrã Name[sv]=Tona skrivbord @@ -11,6 +12,7 @@ Icon=preferences-system-windows-effect-fadedesktop Comment=Fade between virtual desktops when switching between them Comment[et]=Hääbumisefekt ühelt virtuaalselt töölaualt teisele lülitudes Comment[gl]=Emprega un efeito de esvaemento ao trocar de escritorio +Comment[nds]=Bi't Wesseln de Schriefdischen överenanner blennen Comment[pt]=Desvanece entre os ecrãs virtuais, ao circular entre eles Comment[pt_BR]=Desvanece entre os ecrãs virtuais, ao circular entre eles Comment[sv]=Tona mellan virtuella skrivbord vid byte mellan dem diff --git a/effects/highlightwindow.desktop b/effects/highlightwindow.desktop index fa73767179..70c43e9924 100644 --- a/effects/highlightwindow.desktop +++ b/effects/highlightwindow.desktop @@ -3,12 +3,14 @@ Name=Highlight Window Name[et]=Akna esiletõstmine Name[eu]=Leihoa nabarmendu Name[ga]=Aibhsigh Fuinneog +Name[nds]=Finster rutheven Name[uk]=Підсвітити вікно Name[zh_TW]=突顯視窗 Icon=preferences-system-windows-effect-highlightwindow Comment=Highlight the appropriate window when hovering over taskbar entries Comment[et]=Akende esiletõstmine, kui kursor on nende tegumiriba kirje kohal Comment[ga]=Aibhsigh an fhuinneog chuí nuair atá an cúrsóir os cionn iontrála sa tascbharra +Comment[nds]=Bi't Wiesen op Programmbalken-Indrääg de tohören Finstern rutheven Comment[uk]=Підсвітити відповідне вікно, коли курсор знаходиться над елементом панелі задач Comment[zh_TW]=當游標停在工作列的按鈕上面時,突顯視窗 From bc6415ef54cd8b3ca7d835bfcd521ee9a06d5f0a Mon Sep 17 00:00:00 2001 From: Script Kiddy Date: Thu, 5 Feb 2009 14:09:41 +0000 Subject: [PATCH 20/60] SVN_SILENT made messages (.desktop file) svn path=/trunk/KDE/kdebase/workspace/; revision=921684 The following changes were in SVN, but were removed from git: M wallpapers/Blue_Curl/metadata.desktop M wallpapers/Code_Poets_Dream/metadata.desktop M wallpapers/Curls_on_Green/metadata.desktop M wallpapers/Fields_of_Peace/metadata.desktop M wallpapers/Finally_Summer_in_Germany/metadata.desktop M wallpapers/Flower_drops/metadata.desktop M wallpapers/Fresh_Morning/metadata.desktop M wallpapers/HighTide/metadata.desktop M wallpapers/Ladybuggin/metadata.desktop M wallpapers/Red_Leaf/metadata.desktop M wallpapers/There_is_Rain_on_the_Table/metadata.desktop --- clients/kwmtheme/kwmtheme.desktop | 1 + clients/laptop/laptop.desktop | 1 + clients/modernsystem/modernsystem.desktop | 1 + clients/test/test.desktop | 1 + data/fsp_workarounds_1.kwinrules | 1 + effects/blur.desktop | 2 + effects/boxswitch.desktop | 2 + effects/boxswitch_config.desktop | 1 + effects/coverswitch.desktop | 2 + effects/coverswitch_config.desktop | 1 + effects/cube.desktop | 2 + effects/cube_config.desktop | 1 + effects/cylinder.desktop | 2 + effects/cylinder_config.desktop | 1 + effects/desktopgrid.desktop | 2 + effects/desktopgrid_config.desktop | 1 + effects/dialogparent.desktop | 2 + effects/diminactive.desktop | 2 + effects/diminactive_config.desktop | 1 + effects/dimscreen.desktop | 2 + effects/explosion.desktop | 2 + effects/fade.desktop | 2 + effects/fadedesktop.desktop | 6 +- effects/fallapart.desktop | 2 + effects/flipswitch.desktop | 2 + effects/flipswitch_config.desktop | 1 + effects/highlightwindow.desktop | 6 ++ effects/invert.desktop | 2 + effects/invert_config.desktop | 1 + effects/kwineffect.desktop | 1 + effects/login.desktop | 2 + effects/logout.desktop | 2 + effects/lookingglass.desktop | 2 + effects/lookingglass_config.desktop | 1 + effects/magiclamp.desktop | 2 + effects/magiclamp_config.desktop | 1 + effects/magnifier.desktop | 2 + effects/magnifier_config.desktop | 1 + effects/maketransparent.desktop | 2 + effects/maketransparent_config.desktop | 1 + effects/minimizeanimation.desktop | 2 + effects/mousemark.desktop | 2 + effects/mousemark_config.desktop | 1 + effects/presentwindows.desktop | 2 + effects/presentwindows_config.desktop | 1 + effects/scalein.desktop | 2 + effects/shadow.desktop | 2 + effects/shadow_config.desktop | 1 + effects/sharpen.desktop | 2 + effects/sharpen_config.desktop | 1 + effects/showfps.desktop | 2 + effects/showfps_config.desktop | 1 + effects/showpaint.desktop | 2 + effects/slide.desktop | 2 + effects/snow.desktop | 2 + effects/snow_config.desktop | 1 + effects/sphere.desktop | 2 + effects/sphere_config.desktop | 1 + effects/taskbarthumbnail.desktop | 2 + effects/test/demo_liquid.desktop | 1 + effects/test/demo_shakymove.desktop | 1 + effects/test/demo_shiftworkspaceup.desktop | 1 + effects/test/demo_showpicture.desktop | 1 + effects/test/demo_wavywindows.desktop | 1 + effects/test/drunken.desktop | 1 + effects/test/flame.desktop | 1 + effects/test/test_fbo.desktop | 1 + effects/test/test_input.desktop | 1 + effects/test/test_thumbnail.desktop | 1 + effects/test/videorecord.desktop | 2 + effects/test/videorecord_config.desktop | 1 + effects/thumbnailaside.desktop | 2 + effects/thumbnailaside_config.desktop | 1 + effects/trackmouse.desktop | 2 + effects/trackmouse_config.desktop | 1 + effects/wobblywindows.desktop | 2 + effects/wobblywindows_config.desktop | 1 + effects/zoom.desktop | 1 + .../kwincompositing/kwincompositing.desktop | 2 + kcmkwin/kwindecoration/kwindecoration.desktop | 2 + kcmkwin/kwindesktop/desktop.desktop | 2 + kcmkwin/kwinoptions/kwinactions.desktop | 2 + kcmkwin/kwinoptions/kwinadvanced.desktop | 2 + kcmkwin/kwinoptions/kwinfocus.desktop | 1 + kcmkwin/kwinoptions/kwinmoving.desktop | 2 + kcmkwin/kwinoptions/kwinoptions.desktop | 2 + kcmkwin/kwinrules/kwinrules.desktop | 2 + kwin.notifyrc | 83 +++++++++++++++++++ 88 files changed, 222 insertions(+), 2 deletions(-) diff --git a/clients/kwmtheme/kwmtheme.desktop b/clients/kwmtheme/kwmtheme.desktop index 0e4e9c2482..57b0c9fe8e 100644 --- a/clients/kwmtheme/kwmtheme.desktop +++ b/clients/kwmtheme/kwmtheme.desktop @@ -9,6 +9,7 @@ Name[bn]=KWM থীম Name[bn_IN]=KWM থিম Name[br]=Gwiskad KWM Name[ca]=Tema KWM +Name[ca@valencia]=Tema KWM Name[cs]=Téma KWM Name[csb]=Témë KWM Name[cy]=Thema KWM diff --git a/clients/laptop/laptop.desktop b/clients/laptop/laptop.desktop index 2be9482e5c..009a204320 100644 --- a/clients/laptop/laptop.desktop +++ b/clients/laptop/laptop.desktop @@ -8,6 +8,7 @@ Name[bn]=ল্যাপটপ Name[bn_IN]=ল্যাপ-টপ Name[br]=Hezoug Name[ca]=Portàtil +Name[ca@valencia]=Portàtil Name[cs]=Notebook Name[cy]=Gluniadur Name[da]=Bærbar diff --git a/clients/modernsystem/modernsystem.desktop b/clients/modernsystem/modernsystem.desktop index 310f86f6f7..c1ca227b95 100644 --- a/clients/modernsystem/modernsystem.desktop +++ b/clients/modernsystem/modernsystem.desktop @@ -9,6 +9,7 @@ Name[bn]=মডার্ন সিস্টেম Name[bn_IN]=আধুনিক সিস্টেম Name[br]=Reizhiad Nevez Name[ca]=Sistema modern +Name[ca@valencia]=Sistema modern Name[cs]=Moderní systém Name[csb]=Mòdernô systema Name[cy]=Cysawd Cyfoes diff --git a/clients/test/test.desktop b/clients/test/test.desktop index 2ef1ca79c5..f61b3a8fec 100644 --- a/clients/test/test.desktop +++ b/clients/test/test.desktop @@ -8,6 +8,7 @@ Name[bg]=Тест KWin Name[bn]=Kwin পরীক্ষা Name[bn_IN]=KWin পরীক্ষা Name[ca]=Test de KWin +Name[ca@valencia]=Test de KWin Name[csb]=Test KWin Name[cy]=arbrawf KWin Name[da]=KWin-test diff --git a/data/fsp_workarounds_1.kwinrules b/data/fsp_workarounds_1.kwinrules index 460d101118..8b6e42aed6 100644 --- a/data/fsp_workarounds_1.kwinrules +++ b/data/fsp_workarounds_1.kwinrules @@ -4,6 +4,7 @@ Description[ar]=(مبدئي) عطّل تكبير XV للمحافظة على مو Description[be@latin]=(Zmoŭčana) Vyklučy abaronu ad zachopu fokusu dla prahramy „XV” Description[bg]=(По подразбиране) Изключване открадването на фокуса за XV Description[ca]=(Per omissió) Desactiva la prevenció de robatori del focus a l'XV +Description[ca@valencia]=(Per omissió) Desactiva la prevenció de robatori del focus a l'XV Description[cs]=(Výchozí) Zakázat prevenci ukradění zaměření pro XV Description[da]=(Standard) Deaktivér forhindring af fokustyveri for XV Description[de]=(Standard) Aktivierungsübernahme verhindern für XV diff --git a/effects/blur.desktop b/effects/blur.desktop index d52af1769f..964e29c93c 100644 --- a/effects/blur.desktop +++ b/effects/blur.desktop @@ -5,6 +5,7 @@ Name[bg]=Замъгляване Name[bn]=ব্লার Name[bn_IN]=Blur (ব্লার) Name[ca]=Desdibuixa +Name[ca@valencia]=Desdibuixa Name[cs]=Rozostření Name[da]=Slør Name[de]=Verwischen @@ -68,6 +69,7 @@ Comment=Blurs the background behind semi-transparent windows Comment[ar]=تغشي الخلفية التي خلف النوافذ شبه الشفافة. Comment[bg]=Замъгляване на фона на полупрозрачни прозорци Comment[ca]=Desdibuixa el fons de darrere de les finestres semitransparents +Comment[ca@valencia]=Desdibuixa el fons de darrere de les finestres semitransparents Comment[cs]=Rozostří pozadí poloprůhledných oken Comment[da]=Slører baggrunden bag halvgennemsigtige vinduer Comment[de]=Verwischt den Hintergrund halbtransparenter Fenster. diff --git a/effects/boxswitch.desktop b/effects/boxswitch.desktop index e58d73c1e0..8bfaa6482f 100644 --- a/effects/boxswitch.desktop +++ b/effects/boxswitch.desktop @@ -5,6 +5,7 @@ Name[bg]=Превключване между прозорци Name[bn]=বাক্স বদল Name[bn_IN]=বাক্স বদল Name[ca]=Canvi d'aplicació +Name[ca@valencia]=Canvi d'aplicació Name[de]=Kasten mit Minibildern Name[el]=Εναλλαγή πλαισίου Name[eo]=Alt-taba ŝanĝilo @@ -59,6 +60,7 @@ Comment=Display thumbnails of windows in the alt+tab window switcher Comment[ar]=تعرض مصغرات للنوافذ في مبدل النوافذ alt+tab Comment[be@latin]=Pakazvaj padhlady akon u pieraklučniku, jaki vyklikajecca skarotam „Alt+Tab” Comment[ca]=Mostra les miniatures de les finestres al commutador de finestres amb alt+tab +Comment[ca@valencia]=Mostra les miniatures de les finestres al commutador de finestres amb alt+tab Comment[da]=Vis miniaturer af vinduer i alt+tab vinduesskifter Comment[de]=Fenstervorschaubilder werden in einem Kasten angezeigt und durchlaufen. Comment[el]=Εμφάνιση επισκοπήσεων των παραθύρων στην εναλλαγή παραθύρων alt+tab diff --git a/effects/boxswitch_config.desktop b/effects/boxswitch_config.desktop index a0959a3c54..1c1b642805 100644 --- a/effects/boxswitch_config.desktop +++ b/effects/boxswitch_config.desktop @@ -12,6 +12,7 @@ Name[bg]=Превключване между прозорци Name[bn]=বাক্স বদল Name[bn_IN]=বাক্স বদল Name[ca]=Canvi d'aplicació +Name[ca@valencia]=Canvi d'aplicació Name[de]=Kasten mit Minibildern Name[el]=Εναλλαγή πλαισίου Name[eo]=Alt-taba ŝanĝilo diff --git a/effects/coverswitch.desktop b/effects/coverswitch.desktop index a4f22d430d..732c45374a 100644 --- a/effects/coverswitch.desktop +++ b/effects/coverswitch.desktop @@ -5,6 +5,7 @@ Name[bg]=Превключване между прозорци Name[bn]=আবরণ বদল Name[bn_IN]=আবরণ বদল Name[ca]=Canvi de capa +Name[ca@valencia]=Canvi de capa Name[da]=Cover-skifter Name[de]=3D-Fenstergalerie Name[eo]=Kovra ŝanĝilo @@ -52,6 +53,7 @@ Icon=preferences-system-windows-effect-coverswitch Comment=Display a Cover Flow effect for the alt+tab window switcher Comment[ar]=تعرض تأثير تتابع الأغلفة في مبدل النوافذ alt+tab Comment[ca]=Mostra un efecte de capes en el commutador de finestres amb alt+tab +Comment[ca@valencia]=Mostra un efecte de capes en el commutador de finestres amb alt+tab Comment[da]=Vis en cover flow-effekt som alt+tab vinduesskifter Comment[de]=3D-Fenstergalerie - Fenster laufen von links nach rechts durch Comment[el]=Εμφάνιση ενός εφέ ροής εξωφύλλου για την εναλλαγή παραθύρων alt+tab diff --git a/effects/coverswitch_config.desktop b/effects/coverswitch_config.desktop index e401b602bc..78faf79107 100644 --- a/effects/coverswitch_config.desktop +++ b/effects/coverswitch_config.desktop @@ -12,6 +12,7 @@ Name[bg]=Превключване между прозорци Name[bn]=আবরণ বদল Name[bn_IN]=আবরণ বদল Name[ca]=Canvi de capa +Name[ca@valencia]=Canvi de capa Name[da]=Cover-skifter Name[de]=3D-Fenstergalerie Name[eo]=Kovra ŝanĝilo diff --git a/effects/cube.desktop b/effects/cube.desktop index 46eb887047..98953ed2c6 100644 --- a/effects/cube.desktop +++ b/effects/cube.desktop @@ -6,6 +6,7 @@ Name[bg]=Кубичен работен плот Name[bn]=ডেস্কটপ কিউব Name[bn_IN]=ডেস্কটপ কিউব Name[ca]=Cub d'escriptori +Name[ca@valencia]=Cub d'escriptori Name[csb]=Szescan pùltu Name[da]=Desktop-terning Name[de]=Arbeitsflächen-Würfel @@ -68,6 +69,7 @@ Comment[bg]=Всеки виртуален работен плот се пока Comment[bn]=প্রত্যেকটি ভার্চুয়াল ডেস্কটপ একটি কিউব-এর ধারে দেখাও Comment[bn_IN]=প্রত্যেকটি ভার্চুয়াল ডেস্কটপ একটি কিউব-এর ধারে দেখাও Comment[ca]=Visualitza cada escriptori virtual a la cara d'un cub +Comment[ca@valencia]=Visualitza cada escriptori virtual a la cara d'un cub Comment[csb]=Wëskrzëniô wirtualny pùlt na scanie szescanu Comment[da]=Vis hver virtuel desktop på en side af en terning Comment[de]=Zeigt jede virtuelle Arbeitsfläche auf einer Würfelseite an. diff --git a/effects/cube_config.desktop b/effects/cube_config.desktop index ee920a05d0..6105698a69 100644 --- a/effects/cube_config.desktop +++ b/effects/cube_config.desktop @@ -13,6 +13,7 @@ Name[bg]=Кубичен работен плот Name[bn]=ডেস্কটপ কিউব Name[bn_IN]=ডেস্কটপ কিউব Name[ca]=Cub d'escriptori +Name[ca@valencia]=Cub d'escriptori Name[csb]=Szescan pùltu Name[da]=Desktop-terning Name[de]=Arbeitsflächen-Würfel diff --git a/effects/cylinder.desktop b/effects/cylinder.desktop index b9ec17ea64..5a9b3ac2df 100644 --- a/effects/cylinder.desktop +++ b/effects/cylinder.desktop @@ -6,6 +6,7 @@ Name[bg]=Цилиндричен работен плот Name[bn]=ডেস্কটপ সিলিন্ডার Name[bn_IN]=ডেস্কটপ সিলিন্ডার Name[ca]=Cilindre d'escriptori +Name[ca@valencia]=Cilindre d'escriptori Name[csb]=Cylinder pùltu Name[da]=Desktop-cylinder Name[de]=Arbeitsflächen-Zylinder @@ -64,6 +65,7 @@ Comment[bg]=Всеки виртуален работен плот се пока Comment[bn]=প্রত্যেকটি ভার্চুয়াল ডেস্কটপ একটি সিলিণ্ডার-এর ধারে দেখাও Comment[bn_IN]=প্রত্যেকটি ভার্চুয়াল ডেস্কটপ একটি সিলিণ্ডার-এর ধারে দেখাও Comment[ca]=Visualitza cada escriptori virtual a la cara d'un cilindre +Comment[ca@valencia]=Visualitza cada escriptori virtual a la cara d'un cilindre Comment[da]=Vis hver virtuel desktop på en side af en cylinder Comment[de]=Zeigt jede virtuelle Arbeitsfläche auf einer Zylinderseite an. Comment[el]=Εμφάνιση κάθε εικονικής επιφάνειας εργασίας στην πλευρά ενός κυλίνδρου diff --git a/effects/cylinder_config.desktop b/effects/cylinder_config.desktop index 72e6d12a94..667976a704 100644 --- a/effects/cylinder_config.desktop +++ b/effects/cylinder_config.desktop @@ -13,6 +13,7 @@ Name[bg]=Цилиндричен работен плот Name[bn]=ডেস্কটপ সিলিন্ডার Name[bn_IN]=ডেস্কটপ সিলিন্ডার Name[ca]=Cilindre d'escriptori +Name[ca@valencia]=Cilindre d'escriptori Name[csb]=Cylinder pùltu Name[da]=Desktop-cylinder Name[de]=Arbeitsflächen-Zylinder diff --git a/effects/desktopgrid.desktop b/effects/desktopgrid.desktop index 6a660b73c7..b0be19e9b3 100644 --- a/effects/desktopgrid.desktop +++ b/effects/desktopgrid.desktop @@ -8,6 +8,7 @@ Name[bg]=Мрежест работен плот Name[bn]=ডেস্কটপ গ্রিড Name[bn_IN]=ডেস্কটপ গ্রিড Name[ca]=Graella de l'escriptori +Name[ca@valencia]=Graella de l'escriptori Name[cs]=Mřížka plochy Name[da]=Desktop-gitter Name[de]=Arbeitsflächen-Umschalter (Raster) @@ -71,6 +72,7 @@ Name[zh_TW]=桌面格 Icon=preferences-system-windows-effect-desktop-grid Comment=Zoom out so all desktops are displayed side-by-side in a grid Comment[ca]=Redueix tots els escriptoris per a visualitzar-los un al costat de l'altre en una graella +Comment[ca@valencia]=Redueix tots els escriptoris per a visualitzar-los un al costat de l'altre en una graella Comment[da]=Zoom ud så alle desktoppe vises side om side i et gitter Comment[de]=Verkleinert die Arbeitsflächen, sodass sie in einem Raster nebeneinander zu sehen sind. Comment[el]=Σμίκρυνση όλων των επιφανειών εργασίας και εμφάνιση σε παράθεση σε έναν κάνναβο diff --git a/effects/desktopgrid_config.desktop b/effects/desktopgrid_config.desktop index 4dc7ce6a24..b1d39142a5 100644 --- a/effects/desktopgrid_config.desktop +++ b/effects/desktopgrid_config.desktop @@ -15,6 +15,7 @@ Name[bg]=Мрежест работен плот Name[bn]=ডেস্কটপ গ্রিড Name[bn_IN]=ডেস্কটপ গ্রিড Name[ca]=Graella de l'escriptori +Name[ca@valencia]=Graella de l'escriptori Name[cs]=Mřížka plochy Name[da]=Desktop-gitter Name[de]=Arbeitsflächen-Umschalter (Raster) diff --git a/effects/dialogparent.desktop b/effects/dialogparent.desktop index b71f4dcca4..8dfdc3f455 100644 --- a/effects/dialogparent.desktop +++ b/effects/dialogparent.desktop @@ -6,6 +6,7 @@ Name[be]=Бацькоўскае акно Name[be@latin]=Бацькоўскае акно Name[bg]=Редактор на диалози Name[ca]=Diàleg principal +Name[ca@valencia]=Diàleg principal Name[cs]=Předek dialogu Name[da]=Dialogens forældrevindue Name[de]=Eltern-Fenster abdunkeln @@ -70,6 +71,7 @@ Comment=Darkens the parent window of the currently active dialog Comment[ar]=تعتم النافذة المولدة الحوار النشط الحالي Comment[bg]=Потъмнение на главните от активните прозорци Comment[ca]=Enfosqueix la finestra principal del diàleg actual actiu +Comment[ca@valencia]=Enfosqueix la finestra principal del diàleg actual actiu Comment[da]=Gør forældrevindue til aktuelt aktiv dialog mørkere Comment[de]=Dunkelt das Eltern-Fenster des aktiven Dialogs ab. Comment[el]=Σκίαση του γονικού παραθύρου του τρέχοντος ενεργού διαλόγου diff --git a/effects/diminactive.desktop b/effects/diminactive.desktop index cb67836a9c..e0b945cdd8 100644 --- a/effects/diminactive.desktop +++ b/effects/diminactive.desktop @@ -4,6 +4,7 @@ Name[af]=Verdof wanneer onaktief Name[ar]=تعتيم الخامل Name[bg]=Замъгляване на неактивния Name[ca]=Enfosqueix les inactives +Name[ca@valencia]=Enfosqueix les inactives Name[cs]=Ztmavit neaktivní Name[da]=Gør inaktiv mat Name[de]=Inaktive abdunkeln @@ -64,6 +65,7 @@ Comment[ar]=تعتم النوافذ الخاملة Comment[bg]=Потъмнява неактивните прозорци Comment[bn_IN]=নিষ্ক্রিয় উইন্ডোগুলি অনুজ্জ্বল করা হবে Comment[ca]=Enfosqueix les finestres inactives +Comment[ca@valencia]=Enfosqueix les finestres inactives Comment[cs]=Ztmavit neaktivní okna Comment[csb]=Zacemniô nieaktiwné òkna Comment[da]=Gør inaktive vinduer mørkere diff --git a/effects/diminactive_config.desktop b/effects/diminactive_config.desktop index 79ea4c75d9..d712af07f2 100644 --- a/effects/diminactive_config.desktop +++ b/effects/diminactive_config.desktop @@ -11,6 +11,7 @@ Name[af]=Verdof wanneer onaktief Name[ar]=تعتيم الخامل Name[bg]=Замъгляване на неактивния Name[ca]=Enfosqueix les inactives +Name[ca@valencia]=Enfosqueix les inactives Name[cs]=Ztmavit neaktivní Name[da]=Gør inaktiv mat Name[de]=Inaktive abdunkeln diff --git a/effects/dimscreen.desktop b/effects/dimscreen.desktop index 3fdcb74774..baab2efea1 100644 --- a/effects/dimscreen.desktop +++ b/effects/dimscreen.desktop @@ -3,6 +3,7 @@ Name=Dim Screen for Administrator Mode Name[af]=Verdof vir Administrateurmodus Name[ar]=تعتم الشاشة لنمط المدير Name[ca]=Enfosqueix la pantalla pel mode administrador +Name[ca@valencia]=Enfosqueix la pantalla pel mode administrador Name[cs]=Ztmavit obrazovku v administrátorském režimu Name[da]=Dæmp skærmen til administratortilstand Name[de]=Bildschirm für Systemverwaltungsmodus abdunkeln @@ -57,6 +58,7 @@ Icon=preferences-system-windows-effect-dimscreen Comment=Darkens the entire screen when requesting root privileges Comment[ar]=تعتم كامل الشاشة عند طلب صلاحيات الجذر Comment[ca]=Enfosqueix tota la pantalla en demanar privilegis d'administrador +Comment[ca@valencia]=Enfosqueix tota la pantalla en demanar privilegis d'administrador Comment[da]=Gør hele skærmen mørkere når der bedes om root-privilegier Comment[de]=Dunkelt den gesamten Bildschirm ab, wenn nach dem Systemverwalter-Passwort gefragt wird. Comment[el]=Σκίαση ολόκληρης της οθόνης όταν απαιτούνται διακαιώματα ριζικού χρήστη root diff --git a/effects/explosion.desktop b/effects/explosion.desktop index bc35123ad9..acb9e0ac7a 100644 --- a/effects/explosion.desktop +++ b/effects/explosion.desktop @@ -7,6 +7,7 @@ Name[bn]=বিস্ফোরণ Name[bn_IN]=বিস্ফোরণ Name[br]=Tarzhad Name[ca]=Explosió +Name[ca@valencia]=Explosió Name[cs]=Exploze Name[csb]=Wëbùch Name[da]=Eksplosion @@ -70,6 +71,7 @@ Comment[ar]=تفجر النافذة عند إغلاقها Comment[be@latin]=Vokny začyniajucca z vybucham. Comment[bg]=Създава ефект на експлозия при затваряне на прозорците Comment[ca]=Provoca l'explosió de les finestres quan es tanquin +Comment[ca@valencia]=Provoca l'explosió de les finestres quan es tanquen Comment[cs]=Nechá okna explodovat, pokud jsou uzavřena Comment[da]=Få vinduer til at eksplodere når de lukkes Comment[de]=Lässt Fenster beim Schließen explodieren. diff --git a/effects/fade.desktop b/effects/fade.desktop index 2b17738c43..3d686f1455 100644 --- a/effects/fade.desktop +++ b/effects/fade.desktop @@ -8,6 +8,7 @@ Name[bg]=Избледняване Name[bn]=ফেড Name[bn_IN]=ফেড Name[ca]=Apagat gradual +Name[ca@valencia]=Apagat gradual Name[cs]=Blednutí Name[da]=Udtone Name[de]=Verblassen @@ -72,6 +73,7 @@ Comment=Make windows smoothly fade in and out when they are shown or hidden Comment[ar]=اجعل النوافذ تختفي للداخل والخارج بنعومة عند إظهاراها و إخفائها Comment[bg]=Постепенно избледняване при показване/скриване на прозорците Comment[ca]=Fa que les finestres s'encenguin o s'apaguin de manera gradual quan es mostren o s'oculten +Comment[ca@valencia]=Fa que les finestres s'encenguin o s'apaguin de manera gradual quan es mostren o s'oculten Comment[cs]=Nechá okna plynule zmizet/objevit se, pokud jsou zobrazeny resp. skryty Comment[da]=Få vinduer til at tone blidt ud og ind når de vises eller skjules Comment[de]=Blendet Fenster beim Öffnen/Schließen langsam ein bzw. aus. diff --git a/effects/fadedesktop.desktop b/effects/fadedesktop.desktop index ab591b4087..3b9941d8f1 100644 --- a/effects/fadedesktop.desktop +++ b/effects/fadedesktop.desktop @@ -4,9 +4,10 @@ Name[et]=Töölaua hääbumine Name[gl]=Esvair o escritorio Name[nds]=Schriefdisch överblennen Name[pt]=Desvanecer o Ecrã -Name[pt_BR]=Desvanecer o Ecrã +Name[pt_BR]=Desaparecimento da área de trabalho Name[sv]=Tona skrivbord Name[uk]=Затемнювати стільницю +Name[x-test]=xxFade Desktopxx Name[zh_TW]=淡出淡入桌面 Icon=preferences-system-windows-effect-fadedesktop Comment=Fade between virtual desktops when switching between them @@ -14,9 +15,10 @@ Comment[et]=Hääbumisefekt ühelt virtuaalselt töölaualt teisele lülitudes Comment[gl]=Emprega un efeito de esvaemento ao trocar de escritorio Comment[nds]=Bi't Wesseln de Schriefdischen överenanner blennen Comment[pt]=Desvanece entre os ecrãs virtuais, ao circular entre eles -Comment[pt_BR]=Desvanece entre os ecrãs virtuais, ao circular entre eles +Comment[pt_BR]=Desaparece entre as áreas de trabalho virtuais, ao alternar entre elas Comment[sv]=Tona mellan virtuella skrivbord vid byte mellan dem Comment[uk]=Затемнення перед час перемикання між віртуальними стільницями +Comment[x-test]=xxFade between virtual desktops when switching between themxx Comment[zh_TW]=在虛擬桌面間切換時使用淡出/淡入效果 Type=Service diff --git a/effects/fallapart.desktop b/effects/fallapart.desktop index 541e7588e8..bde4b97cba 100644 --- a/effects/fallapart.desktop +++ b/effects/fallapart.desktop @@ -4,6 +4,7 @@ Name[af]=Val uitmekaar Name[ar]=سقوط حاد Name[bg]=Разпадане Name[ca]=Trencament +Name[ca@valencia]=Trencament Name[cs]=Rozpad Name[da]=Gå i stykker Name[de]=Auseinanderfallen @@ -65,6 +66,7 @@ Comment[af]=Toegemaakte venster val in stukke uitmekaar Comment[ar]=قطع النوافذ عند الإغلاق Comment[bg]=Затваряните прзорци се разпадат на парчета Comment[ca]=Les finestres tancades es trenquen en peces +Comment[ca@valencia]=Les finestres tancades es trenquen en peces Comment[cs]=Uzavřená okna se rozpadnou na kousky Comment[da]=Lukkede vinduer falder i små stykker Comment[de]=Lässt geschlossene Fenster auseinanderfallen. diff --git a/effects/flipswitch.desktop b/effects/flipswitch.desktop index 1e1b4af801..49500ffdb3 100644 --- a/effects/flipswitch.desktop +++ b/effects/flipswitch.desktop @@ -3,6 +3,7 @@ Name=Flip Switch Name[af]=Wissel skakelaar Name[ar]=تبديل بالتقليب Name[ca]=Canvi en roda +Name[ca@valencia]=Canvi en roda Name[da]=Vippeskifter Name[de]=3D-Fensterstapel Name[el]=Εναλλαγή πλαισίου @@ -51,6 +52,7 @@ Icon=preferences-system-windows-effect-flipswitch Comment=Flip through windows that are in a stack for the alt+tab window switcher Comment[ar]=تقلب النوافذ التي في القائمة لمبدل النوافذ alt+tab Comment[ca]=Roda a través de les finestres que estan en una pila en el commutador de finestres alt+tab +Comment[ca@valencia]=Roda a través de les finestres que estan en una pila en el commutador de finestres alt+tab Comment[da]=Vip gennem vinduer i en stak som alt+tab vinduesskifter Comment[de]=3D-Fensterstapel - Fenster werden auf einem Stapel durchgeblättert. Comment[el]=Εναλλαγή των παραθύρων ως μια στοίβα για την εναλλαγή παραθύρων με το alt+tab diff --git a/effects/flipswitch_config.desktop b/effects/flipswitch_config.desktop index b8674367a1..f1debbe3d0 100644 --- a/effects/flipswitch_config.desktop +++ b/effects/flipswitch_config.desktop @@ -10,6 +10,7 @@ Name=Flip Switch Name[af]=Wissel skakelaar Name[ar]=تبديل بالتقليب Name[ca]=Canvi en roda +Name[ca@valencia]=Canvi en roda Name[da]=Vippeskifter Name[de]=3D-Fensterstapel Name[el]=Εναλλαγή πλαισίου diff --git a/effects/highlightwindow.desktop b/effects/highlightwindow.desktop index 70c43e9924..c429f10d48 100644 --- a/effects/highlightwindow.desktop +++ b/effects/highlightwindow.desktop @@ -4,14 +4,20 @@ Name[et]=Akna esiletõstmine Name[eu]=Leihoa nabarmendu Name[ga]=Aibhsigh Fuinneog Name[nds]=Finster rutheven +Name[pt]=Realçar a Janela +Name[pt_BR]=Janela realçada Name[uk]=Підсвітити вікно +Name[x-test]=xxHighlight Windowxx Name[zh_TW]=突顯視窗 Icon=preferences-system-windows-effect-highlightwindow Comment=Highlight the appropriate window when hovering over taskbar entries Comment[et]=Akende esiletõstmine, kui kursor on nende tegumiriba kirje kohal Comment[ga]=Aibhsigh an fhuinneog chuí nuair atá an cúrsóir os cionn iontrála sa tascbharra Comment[nds]=Bi't Wiesen op Programmbalken-Indrääg de tohören Finstern rutheven +Comment[pt]=Realçar a janela apropriada ao passar o rato sobre os itens da barra de tarefas +Comment[pt_BR]=Realçar a janela apropriada ao passar o ponteiro do mouse sobre as entradas da barra de tarefas Comment[uk]=Підсвітити відповідне вікно, коли курсор знаходиться над елементом панелі задач +Comment[x-test]=xxHighlight the appropriate window when hovering over taskbar entriesxx Comment[zh_TW]=當游標停在工作列的按鈕上面時,突顯視窗 Type=Service diff --git a/effects/invert.desktop b/effects/invert.desktop index efe59ed245..77910c5dcd 100644 --- a/effects/invert.desktop +++ b/effects/invert.desktop @@ -6,6 +6,7 @@ Name[be]=Інвертаваць Name[be@latin]=Invercyja Name[bg]=Инвертиране Name[ca]=Inverteix +Name[ca@valencia]=Inverteix Name[cs]=Invertovat Name[csb]=Inwertëje Name[da]=Invertér @@ -73,6 +74,7 @@ Comment[ar]=تعكس ألوان سطح المكتب و النوافذ Comment[be@latin]=Invertuje kolery stała j akon Comment[bg]=Цветовете се инвертират Comment[ca]=Inverteix el color de l'escriptori i les finestres +Comment[ca@valencia]=Inverteix el color de l'escriptori i les finestres Comment[cs]=Invertuje barvy plochy a oken Comment[da]=Inverterer farven på desktoppen og vinduer Comment[de]=Invertiert die Farben der Arbeitsfläche und Fenster. diff --git a/effects/invert_config.desktop b/effects/invert_config.desktop index 2213ebb0fd..d707c50a63 100644 --- a/effects/invert_config.desktop +++ b/effects/invert_config.desktop @@ -13,6 +13,7 @@ Name[be]=Інвертаваць Name[be@latin]=Invercyja Name[bg]=Инвертиране Name[ca]=Inverteix +Name[ca@valencia]=Inverteix Name[cs]=Invertovat Name[csb]=Inwertëje Name[da]=Invertér diff --git a/effects/kwineffect.desktop b/effects/kwineffect.desktop index 5ad7e887b0..4b012dd23f 100644 --- a/effects/kwineffect.desktop +++ b/effects/kwineffect.desktop @@ -10,6 +10,7 @@ Comment[be@latin]=Efekty akońnika „KWin” Comment[bg]=Ефект KWin Comment[bn_IN]=KWin ইফেক্ট Comment[ca]=Efecte del KWin +Comment[ca@valencia]=Efecte del KWin Comment[cs]=KWin efekt Comment[csb]=Efektë òknów Comment[da]=KWin-effekt diff --git a/effects/login.desktop b/effects/login.desktop index 83319deb57..305b58678a 100644 --- a/effects/login.desktop +++ b/effects/login.desktop @@ -8,6 +8,7 @@ Name[bg]=Вход Name[bn]=লগ-ইন Name[bn_IN]=লগ-ইন করুন Name[ca]=Entrada +Name[ca@valencia]=Entrada Name[cs]=Přihlášení Name[csb]=Logòwanié Name[de]=Anmeldung @@ -77,6 +78,7 @@ Comment=Smoothly fade to the desktop when logging in Comment[ar]=اظهار سطح المكتب بنعومة عند الولوج Comment[bg]=Плавен преход към работния плот при влизане Comment[ca]=Transició suau a l'escriptori en connectar-se +Comment[ca@valencia]=Transició suau a l'escriptori en connectar-se Comment[da]=Fader blidt til desktoppen når der logges ind Comment[de]=Blendet die Arbeitsfläche bei nach der Anmeldung langsam ein. Comment[el]=Ομαλή εμφάνιση της επιφάνειας εργασίας κατά τη σύνδεση diff --git a/effects/logout.desktop b/effects/logout.desktop index 18c44b26b1..7162d837e4 100644 --- a/effects/logout.desktop +++ b/effects/logout.desktop @@ -8,6 +8,7 @@ Name[bg]=Изход Name[bn]=লগ-আউট Name[bn_IN]=লগ-আউট করুন Name[ca]=Sortida +Name[ca@valencia]=Eixida Name[cs]=Odhlášení Name[csb]=Wëlogòwanié Name[da]=Log ud @@ -78,6 +79,7 @@ Comment=Desaturate the desktop when displaying the logout dialog Comment[ar]=إلغاء تشبع ألوان سطح المكتب عن ظهور حور الخروج Comment[bg]=Избледняване на работния плот при показване на прозореца за изход Comment[ca]=Reducció de la saturació de l'escriptori en mostar el diàleg de sortida +Comment[ca@valencia]=Reducció de la saturació de l'escriptori en mostar el diàleg d'eixida Comment[da]=Afmæt farverne på desktoppen når log ud-dialogen vises Comment[de]=Färbt die Arbeitsfläche in Grautöne, wenn der Abmelde-Dialog erscheint. Comment[el]=Αποχρωματισμός της επιφάνειας εργασίας κατά την εμφάνιση του διαλόγου αποσύνδεσης diff --git a/effects/lookingglass.desktop b/effects/lookingglass.desktop index 3ac9464b29..91c6d1090d 100644 --- a/effects/lookingglass.desktop +++ b/effects/lookingglass.desktop @@ -4,6 +4,7 @@ Name[af]=Vergrootglas Name[ar]=مظهر زجاجي Name[bg]=Лупа Name[ca]=Aparença de vidre +Name[ca@valencia]=Aparença de vidre Name[csb]=Lupa Name[da]=Kikkert Name[de]=Bildschirmlupe @@ -55,6 +56,7 @@ Comment=A screen magnifier that looks like a fisheye lens Comment[ar]=مكبر الشاشة الذي يبدو مثل عدسة عين السمكة Comment[bg]=Увеличаване като с лупа Comment[ca]=Una lupa de pantalla que sembla un objectiu d'ull de peix +Comment[ca@valencia]=Una lupa de pantalla que sembla un objectiu d'ull de peix Comment[da]=Skærmforstørrelsesglas som ligner en fiskeøje-linse Comment[de]=Eine Lupe, die wie eine Fischaugen-Linse funktioniert. Comment[el]=Ένας μεγεθυντικός φακός οθόνης με έντονη ευρυγώνια οπτική diff --git a/effects/lookingglass_config.desktop b/effects/lookingglass_config.desktop index 6453d351d1..d21aa44e2f 100644 --- a/effects/lookingglass_config.desktop +++ b/effects/lookingglass_config.desktop @@ -11,6 +11,7 @@ Name[af]=Vergrootglas Name[ar]=مظهر زجاجي Name[bg]=Лупа Name[ca]=Aparença de vidre +Name[ca@valencia]=Aparença de vidre Name[csb]=Lupa Name[da]=Kikkert Name[de]=Bildschirmlupe diff --git a/effects/magiclamp.desktop b/effects/magiclamp.desktop index 3c55d2e163..b953f0f7b5 100644 --- a/effects/magiclamp.desktop +++ b/effects/magiclamp.desktop @@ -4,6 +4,7 @@ Name[ar]=المصباح السحري Name[be@latin]=Mahičnaja lampa Name[bg]=Вълшебна лампа Name[ca]=Làmpada màgica +Name[ca@valencia]=Làmpada màgica Name[cs]=Magická lampa Name[da]=Magisk lampe Name[de]=Wunderlampe @@ -56,6 +57,7 @@ Comment[ar]=تحاكي المصباح السحري عند تصغير النوا Comment[be@latin]=Minimalizuje vokny ŭ mahičnuju lampu. Comment[bg]=Симулация на вълшебна лампа при минимизация на прозорците Comment[ca]=Simula una làmpada màgica en minimitzar les finestres +Comment[ca@valencia]=Simula una làmpada màgica en minimitzar les finestres Comment[cs]=Simuluje magickou lampu při minimalizaci oken Comment[csb]=Symùlëjë magiczną lampã przë minimalizacëji òknów Comment[da]=Simulér en magisk lampe når vinduer minimeres diff --git a/effects/magiclamp_config.desktop b/effects/magiclamp_config.desktop index ecce4657f2..1bdfea04f2 100644 --- a/effects/magiclamp_config.desktop +++ b/effects/magiclamp_config.desktop @@ -11,6 +11,7 @@ Name[ar]=المصباح السحري Name[be@latin]=Mahičnaja lampa Name[bg]=Вълшебна лампа Name[ca]=Làmpada màgica +Name[ca@valencia]=Làmpada màgica Name[cs]=Magická lampa Name[da]=Magisk lampe Name[de]=Wunderlampe diff --git a/effects/magnifier.desktop b/effects/magnifier.desktop index b8865157ad..fa77ee6c71 100644 --- a/effects/magnifier.desktop +++ b/effects/magnifier.desktop @@ -8,6 +8,7 @@ Name[bg]=Увеличител Name[bn]=ম্যাগনিফায়ার Name[bn_IN]=ম্যাগনিফায়ার Name[ca]=Lupa +Name[ca@valencia]=Lupa Name[cs]=Lupa Name[csb]=Zwikszanié Name[da]=Forstørrelsesglas @@ -78,6 +79,7 @@ Comment[ar]=تكبر الجزء من الشاشة الذي يوجد بالقرب Comment[be@latin]=Pavialičvaje častku ekrana pad kursoram myšy. Comment[bg]=Увеличава частта от екрана, която е под мишката Comment[ca]=Amplia la secció de la pantalla que està prop del cursor del ratolí +Comment[ca@valencia]=Amplia la secció de la pantalla que està prop del cursor del ratolí Comment[cs]=Zvětší část obrazovky, která je poblíž ukazatele myši Comment[csb]=Zwikszô dzél ekranë pòd kùrsorã mëszë Comment[da]=Forstørrer den del af skærmen som er omkring musemarkøren diff --git a/effects/magnifier_config.desktop b/effects/magnifier_config.desktop index 75986be7b4..c34a9873fb 100644 --- a/effects/magnifier_config.desktop +++ b/effects/magnifier_config.desktop @@ -15,6 +15,7 @@ Name[bg]=Увеличител Name[bn]=ম্যাগনিফায়ার Name[bn_IN]=ম্যাগনিফায়ার Name[ca]=Lupa +Name[ca@valencia]=Lupa Name[cs]=Lupa Name[csb]=Zwikszanié Name[da]=Forstørrelsesglas diff --git a/effects/maketransparent.desktop b/effects/maketransparent.desktop index a9a5d36590..cd706f9153 100644 --- a/effects/maketransparent.desktop +++ b/effects/maketransparent.desktop @@ -9,6 +9,7 @@ Name[bn]=সমস্বচ্ছতা Name[bn_IN]=সমস্বচ্ছতা Name[br]=Treuzwel Name[ca]=Translucidesa +Name[ca@valencia]=Translucidesa Name[cs]=Průhlednost Name[csb]=Transparentnosc Name[da]=Gennemsigtighed @@ -76,6 +77,7 @@ Comment[ar]=تجعل النوافذ شبه شفافة في شروط مختلفة Comment[be@latin]=Robić vokny prazrystymi dla peŭnych umovaŭ Comment[bg]=Прозрачност на прозорците при определени условия Comment[ca]=Torna translúcides les finestres en diverses condicions +Comment[ca@valencia]=Torna translúcides les finestres en diverses condicions Comment[da]=Gør vinduer gennemsigtige under forskellige omstændigheder Comment[de]=Lässt Fenster unter festgelegten Bedingungen durchscheinen. Comment[el]=Εμφάνιση ημιδιαφανών παραθύρων σε διάφορες περιπτώσεις diff --git a/effects/maketransparent_config.desktop b/effects/maketransparent_config.desktop index 5ff368f005..4cf8349629 100644 --- a/effects/maketransparent_config.desktop +++ b/effects/maketransparent_config.desktop @@ -16,6 +16,7 @@ Name[bn]=সমস্বচ্ছতা Name[bn_IN]=সমস্বচ্ছতা Name[br]=Treuzwel Name[ca]=Translucidesa +Name[ca@valencia]=Translucidesa Name[cs]=Průhlednost Name[csb]=Transparentnosc Name[da]=Gennemsigtighed diff --git a/effects/minimizeanimation.desktop b/effects/minimizeanimation.desktop index bc435ce08b..eb0847094d 100644 --- a/effects/minimizeanimation.desktop +++ b/effects/minimizeanimation.desktop @@ -6,6 +6,7 @@ Name[be]=Анімацыя змяншэння Name[be@latin]=Animacyja minimalizacyi akna Name[bg]=Анимирана минимизация Name[ca]=Animació de minimització +Name[ca@valencia]=Animació de minimització Name[cs]=Animace minimalizace Name[csb]=Minimalizëjë animacëjã Name[da]=Minimér-animation @@ -71,6 +72,7 @@ Comment[ar]=تحرك عملية تصغير النوافذ Comment[be@latin]=Animuje minimalizacyju akon. Comment[bg]=Анимирана минимизация на прозорците Comment[ca]=Anima la minimització de les finestres +Comment[ca@valencia]=Anima la minimització de les finestres Comment[cs]=Animuje minimalizaci oken Comment[csb]=Animùjë minimalizacëjã òknów Comment[da]=Animér minimering af vinduer diff --git a/effects/mousemark.desktop b/effects/mousemark.desktop index 44e6240081..7ec7d01960 100644 --- a/effects/mousemark.desktop +++ b/effects/mousemark.desktop @@ -6,6 +6,7 @@ Name[be]=Адметка мышы Name[be@latin]=Malavańnie myššu Name[bg]=Чертане с мишката Name[ca]=Marca amb el ratolí +Name[ca@valencia]=Marca amb el ratolí Name[cs]=Značkovač Name[csb]=Merk mëszë Name[da]=Muse-tusch @@ -70,6 +71,7 @@ Comment[ar]=يتيح لك رسم خطوط على سطح المكتب Comment[be@latin]=Uklučaje malavańnie rysaŭ na rabočym stale. Comment[bg]=Можете да чертаете линии на работния плот Comment[ca]=Us permet dibuixar línies a l'escriptori +Comment[ca@valencia]=Vos permet dibuixar línies a l'escriptori Comment[cs]=Umožní kreslit čáry na ploše Comment[csb]=Zezwôlô céchòwac linije na pùlce Comment[da]=Lader dig tegne streger på desktoppen diff --git a/effects/mousemark_config.desktop b/effects/mousemark_config.desktop index a87962ae54..c21d843145 100644 --- a/effects/mousemark_config.desktop +++ b/effects/mousemark_config.desktop @@ -13,6 +13,7 @@ Name[be]=Адметка мышы Name[be@latin]=Malavańnie myššu Name[bg]=Чертане с мишката Name[ca]=Marca amb el ratolí +Name[ca@valencia]=Marca amb el ratolí Name[cs]=Značkovač Name[csb]=Merk mëszë Name[da]=Muse-tusch diff --git a/effects/presentwindows.desktop b/effects/presentwindows.desktop index f75f374caf..58e5af732a 100644 --- a/effects/presentwindows.desktop +++ b/effects/presentwindows.desktop @@ -6,6 +6,7 @@ Name[be]=Існуючыя вокны Name[be@latin]=Najaŭnyja vokny Name[bg]=Представяне на прозорци Name[ca]=Presenta les finestres +Name[ca@valencia]=Presenta les finestres Name[cs]=Prezentace oken Name[csb]=Prezentëjë òkna Name[da]=Præsentér vinduer @@ -68,6 +69,7 @@ Comment=Zoom out until all opened windows can be displayed side-by-side Comment[ar]=تصغر جميع النوافذ المفتوحة حتى يمكن عرضها جنب إلى جنب Comment[bg]=Мащабиране докато всички прозорци могат да се видят един до друг Comment[ca]=Redueix fins que totes les finestres obertes es poden mostrar una al costat de l'altra +Comment[ca@valencia]=Redueix fins que totes les finestres obertes es poden mostrar una al costat de l'altra Comment[da]=Zoom ud indtil alle åbne vinduer kan vises side om side Comment[de]=Verkleinert Fenster auf der Arbeitsfläche, sodass sie alle nebeneinander sichtbar sind. Comment[el]=Σμίκρυνση έως ότου όλα τα ανοιχτά παράθυρα να εμφανίζονται σε παράθεση diff --git a/effects/presentwindows_config.desktop b/effects/presentwindows_config.desktop index 444a882854..1f40a88f94 100644 --- a/effects/presentwindows_config.desktop +++ b/effects/presentwindows_config.desktop @@ -13,6 +13,7 @@ Name[be]=Існуючыя вокны Name[be@latin]=Najaŭnyja vokny Name[bg]=Представяне на прозорци Name[ca]=Presenta les finestres +Name[ca@valencia]=Presenta les finestres Name[cs]=Prezentace oken Name[csb]=Prezentëjë òkna Name[da]=Præsentér vinduer diff --git a/effects/scalein.desktop b/effects/scalein.desktop index aa1426794c..eea39a6708 100644 --- a/effects/scalein.desktop +++ b/effects/scalein.desktop @@ -4,6 +4,7 @@ Name[af]=Rek-verskyn Name[ar]=تحجيم النوافذ Name[bg]=Увеличаване Name[ca]=Escalat +Name[ca@valencia]=Escalat Name[cs]=Zvětšení Name[csb]=Skalowanié Name[da]=Skalér ind @@ -69,6 +70,7 @@ Comment[ar]=تحرك عملية ظهور النوافذ Comment[be@latin]=Animuje źjaŭleńnie akon. Comment[bg]=Анимирано показване на прозорците Comment[ca]=Anima l'aparició de finestres +Comment[ca@valencia]=Anima l'aparició de finestres Comment[cs]=Animuje objevení oken Comment[csb]=Animùjë pòkazëwanié sã òkna Comment[da]=Animér vinduers fremkomst diff --git a/effects/shadow.desktop b/effects/shadow.desktop index fa99ff54b5..c219fb12eb 100644 --- a/effects/shadow.desktop +++ b/effects/shadow.desktop @@ -8,6 +8,7 @@ Name[bg]=Сянка Name[bn]=ছায়া Name[bn_IN]=ছায়া Name[ca]=Ombra +Name[ca@valencia]=Ombra Name[cs]=Stín Name[csb]=Ceniô Name[da]=Skygge @@ -78,6 +79,7 @@ Comment[ar]=يضيف ظل تحت النوافذ Comment[be@latin]=Maluj cień pad voknami. Comment[bg]=Добавяне на сянка под прозорците Comment[ca]=Afegeix ombres a sota de les finestres +Comment[ca@valencia]=Afig ombres a sota de les finestres Comment[cs]=Přidává stíny pod okna Comment[csb]=Céchùje ceniô pòd òknama Comment[da]=Tegn skygger under vinduer diff --git a/effects/shadow_config.desktop b/effects/shadow_config.desktop index 6729d9b800..194d6106db 100644 --- a/effects/shadow_config.desktop +++ b/effects/shadow_config.desktop @@ -15,6 +15,7 @@ Name[bg]=Сянка Name[bn]=ছায়া Name[bn_IN]=ছায়া Name[ca]=Ombra +Name[ca@valencia]=Ombra Name[cs]=Stín Name[csb]=Ceniô Name[da]=Skygge diff --git a/effects/sharpen.desktop b/effects/sharpen.desktop index 9fce7f352d..9d60328a6b 100644 --- a/effects/sharpen.desktop +++ b/effects/sharpen.desktop @@ -4,6 +4,7 @@ Name[af]=Verskerp Name[ar]=حاد Name[bg]=Отчетливост Name[ca]=Aguditza +Name[ca@valencia]=Aguditza Name[cs]=Zaostření Name[csb]=Wëòstrzëc Name[da]=Gør skarpere @@ -68,6 +69,7 @@ Comment=Make the entire desktop look sharper Comment[ar]=يعطي كامل سطح المكتب شكلا حادا Comment[bg]=Прави работния плот по-отчетлив Comment[ca]=Fa que tot l'escriptori sembli més definit +Comment[ca@valencia]=Fa que tot l'escriptori sembli més definit Comment[cs]=Zaostří celou vaši plochu Comment[csb]=Sprôwiô to, że pùlt wëzdrzi barżi òstro Comment[da]=Får hele desktoppen til at se skarpere ud diff --git a/effects/sharpen_config.desktop b/effects/sharpen_config.desktop index 3927b39fa1..17566766c6 100644 --- a/effects/sharpen_config.desktop +++ b/effects/sharpen_config.desktop @@ -11,6 +11,7 @@ Name[af]=Verskerp Name[ar]=حاد Name[bg]=Отчетливост Name[ca]=Aguditza +Name[ca@valencia]=Aguditza Name[cs]=Zaostření Name[csb]=Wëòstrzëc Name[da]=Gør skarpere diff --git a/effects/showfps.desktop b/effects/showfps.desktop index a9eccd2d28..2fde32570f 100644 --- a/effects/showfps.desktop +++ b/effects/showfps.desktop @@ -6,6 +6,7 @@ Name[be@latin]=Vyjaŭleńnie „FPS” Name[bg]=Показване на FPS Name[bn_IN]=FPS প্রদর্শন করা হবে Name[ca]=Mostra els FPS +Name[ca@valencia]=Mostra els FPS Name[cs]=Zobrazit FPS Name[csb]=Wëskrzëni FPS Name[da]=Vis FPS @@ -70,6 +71,7 @@ Comment=Display KWin's performance in the corner of the screen Comment[ar]=تظهر أداء كوين في زاوية الشاشة Comment[bg]=Производителността на KWin се показва в ъгъла на екрана Comment[ca]=Mostra el rendiment del KWin a la cantonada de la pantalla +Comment[ca@valencia]=Mostra el rendiment del KWin a la cantonada de la pantalla Comment[cs]=Zobrazuje výkon KWin v rohu obrazovky Comment[da]=Vis KWins ydelse i hjørnet af skærmen Comment[de]=Zeigt die Leistung von KWin in Bildern pro Sekunde an. diff --git a/effects/showfps_config.desktop b/effects/showfps_config.desktop index 8999d73bda..7828d3dd7f 100644 --- a/effects/showfps_config.desktop +++ b/effects/showfps_config.desktop @@ -13,6 +13,7 @@ Name[be@latin]=Vyjaŭleńnie „FPS” Name[bg]=Показване на FPS Name[bn_IN]=FPS প্রদর্শন করা হবে Name[ca]=Mostra els FPS +Name[ca@valencia]=Mostra els FPS Name[cs]=Zobrazit FPS Name[csb]=Wëskrzëni FPS Name[da]=Vis FPS diff --git a/effects/showpaint.desktop b/effects/showpaint.desktop index 3ac5920cc6..7eb9ff9b97 100644 --- a/effects/showpaint.desktop +++ b/effects/showpaint.desktop @@ -4,6 +4,7 @@ Name[af]=Wys inkleur Name[ar]=اظهر الطلاء Name[bn_IN]=Paint প্রদর্শন করা হবে Name[ca]=Mostra la pintura +Name[ca@valencia]=Mostra la pintura Name[cs]=Zobrazit kreslení Name[csb]=Pòkôżë Paint Name[da]=Vis tegning @@ -65,6 +66,7 @@ Comment=Highlight areas of the desktop that have been recently updated Comment[ar]=تبرز المناطق التي تم تحديثها مؤخرا في سطح المكتب Comment[bg]=Осветяване на частите от екрана, които са били променени скоро Comment[ca]=Resalta les àrees de l'escriptori que s'han actualitzat darrerament +Comment[ca@valencia]=Resalta les àrees de l'escriptori que s'han actualitzat darrerament Comment[da]=Fremhæv områder af desktoppen som er blevet opdateret for nyligt Comment[de]=Hebt die Bereiche der Arbeitsfläche farbig hervor, die kürzlich aktualisiert wurden. Comment[el]=Τονισμός περιοχών της επιφάνειας εργασίας που ενημερώθηκαν πρόσφατα diff --git a/effects/slide.desktop b/effects/slide.desktop index f9fbafb09d..7d025819fe 100644 --- a/effects/slide.desktop +++ b/effects/slide.desktop @@ -3,6 +3,7 @@ Name=Slide Name[ar]=النقل Name[bg]=Приплъзване Name[ca]=Diapositiva +Name[ca@valencia]=Diapositiva Name[cs]=Sklouznutí Name[da]=Glid Name[de]=Gleiten @@ -54,6 +55,7 @@ Comment=Slide windows across the screen when switching virtual desktops Comment[ar]=تنقل النوافذ عبر الشاشة عند التبديل بين الأسطح الافتراضية Comment[bg]=Приплъзване на прозорците при превключване на плотовете Comment[ca]=Desplaça les finestres per la pantalla en canviar els escriptoris virtuals +Comment[ca@valencia]=Desplaça les finestres per la pantalla en canviar els escriptoris virtuals Comment[cs]=Sklouzne okna přes obrazovku při přepínání virtuálních ploch Comment[da]=Glid vinduer henover skærmen ved skift af virtuel desktop Comment[de]=Lässt Fenster beim Arbeitsflächenwechsel über den Bildschirm gleiten. diff --git a/effects/snow.desktop b/effects/snow.desktop index 6525fa95da..856ff01aa3 100644 --- a/effects/snow.desktop +++ b/effects/snow.desktop @@ -8,6 +8,7 @@ Name[bg]=Сняг Name[bn]=বরফ Name[bn_IN]=Snow (তুষার) Name[ca]=Neu +Name[ca@valencia]=Neu Name[cs]=Sníh Name[csb]=Sniég Name[da]=Sne @@ -75,6 +76,7 @@ Comment[be@latin]=Uklučaje śniehapad na rabočym stale. Comment[bg]=Сняг върху работния плот Comment[bn_IN]=ডেস্কটপে তুষারপাত প্রদর্শন করা হবে Comment[ca]=Simula que cau neu sobre l'escriptori +Comment[ca@valencia]=Simula que cau neu sobre l'escriptori Comment[cs]=Simuluje sněžení na ploše Comment[csb]=Symùlëjë padający sniég na pùlce Comment[da]=Simulér snefald over desktoppen diff --git a/effects/snow_config.desktop b/effects/snow_config.desktop index 868c19bfce..fef39cdf0a 100644 --- a/effects/snow_config.desktop +++ b/effects/snow_config.desktop @@ -14,6 +14,7 @@ Name[bg]=Сняг Name[bn]=বরফ Name[bn_IN]=Snow (তুষার) Name[ca]=Neu +Name[ca@valencia]=Neu Name[cs]=Sníh Name[csb]=Sniég Name[da]=Sne diff --git a/effects/sphere.desktop b/effects/sphere.desktop index 0816944c38..d4e6ba8369 100644 --- a/effects/sphere.desktop +++ b/effects/sphere.desktop @@ -4,6 +4,7 @@ Name[ar]=دائرة سطح المكتب Name[be@latin]=Rabočaja kula Name[bg]=Сферичен работен плот Name[ca]=Esfera d'escriptori +Name[ca@valencia]=Esfera d'escriptori Name[csb]=Sfera pùltu Name[da]=Desktop-sfære Name[de]=Arbeitsflächen-Kugel @@ -60,6 +61,7 @@ Comment[bg]=Всеки виртуален работен плот се пока Comment[bn]=প্রত্যেকটি ভার্চুয়াল ডেস্কটপ একটি গোলক-এর ধারে দেখাও Comment[bn_IN]=প্রত্যেকটি ভার্চুয়াল ডেস্কটপ একটি গোলক-এর ধারে দেখাও Comment[ca]=Visualitza cada escriptori virtual als costats d'una esfera +Comment[ca@valencia]=Visualitza cada escriptori virtual als costats d'una esfera Comment[csb]=Wëszkrzëniô wirtualny pùlt na starnie sferë Comment[da]=Vis hver virtuel desktop på en siden af en sfære Comment[de]=Zeigt die virtuellen Arbeitsflächen auf einer Kugel an. diff --git a/effects/sphere_config.desktop b/effects/sphere_config.desktop index ead3ddf973..c389a39ac0 100644 --- a/effects/sphere_config.desktop +++ b/effects/sphere_config.desktop @@ -11,6 +11,7 @@ Name[ar]=دائرة سطح المكتب Name[be@latin]=Rabočaja kula Name[bg]=Сферичен работен плот Name[ca]=Esfera d'escriptori +Name[ca@valencia]=Esfera d'escriptori Name[csb]=Sfera pùltu Name[da]=Desktop-sfære Name[de]=Arbeitsflächen-Kugel diff --git a/effects/taskbarthumbnail.desktop b/effects/taskbarthumbnail.desktop index 27f63ef48d..246544ebdb 100644 --- a/effects/taskbarthumbnail.desktop +++ b/effects/taskbarthumbnail.desktop @@ -6,6 +6,7 @@ Name[be@latin]=Padhlady dla paneli zadańniaŭ Name[bg]=Умаления копия на задачите Name[bn_IN]=টাস্ক-বার থাম্‌বনেইল Name[ca]=Miniatures a la barra de tasques +Name[ca@valencia]=Miniatures a la barra de tasques Name[cs]=Miniatury v pruhu úloh Name[csb]=Miniaturczi w listwie dzejaniów Name[da]=Opgavelinjeminiaturer @@ -64,6 +65,7 @@ Comment[ar]=اظهر مصغرات النوافذ عند المرور على شر Comment[be@latin]=Pakazvaje padhlady akon, kali kursor nad adpaviednym zadańniem u paneli. Comment[bg]=Показване на умалени копия, когато курсора е върху лентата с инструменти Comment[ca]=Mostra les miniatures de les finestres quan el cursor està sobre les entrades de la barra de tasques +Comment[ca@valencia]=Mostra les miniatures de les finestres quan el cursor està sobre les entrades de la barra de tasques Comment[cs]=Zobrazí miniatury oken pokud je kurzor nad jejich položkou v pruhu úloh Comment[csb]=Wëskrzëniô miniaturczi òknów, jak kùrsor nachôdô sã na jich pòłożeniu w listwie dzejaniów Comment[da]=Vis miniaturer af vinduer når musen er over deres opgavelinje-punkt diff --git a/effects/test/demo_liquid.desktop b/effects/test/demo_liquid.desktop index 24cb6fc236..2c65c9bb7d 100644 --- a/effects/test/demo_liquid.desktop +++ b/effects/test/demo_liquid.desktop @@ -3,6 +3,7 @@ Name=Demo Liquid Name[ar]=مثال السائل Name[bg]=Демо на Liquid Name[ca]=Demostració del Liquid +Name[ca@valencia]=Demostració del Liquid Name[cs]=Liquid demo Name[csb]=Ceklëna (démònstarcëjô) Name[da]=Demo af Liquid diff --git a/effects/test/demo_shakymove.desktop b/effects/test/demo_shakymove.desktop index 6afb7da092..543ad24421 100644 --- a/effects/test/demo_shakymove.desktop +++ b/effects/test/demo_shakymove.desktop @@ -3,6 +3,7 @@ Name=Demo Shaky Move Name[ar]=مثال الحركة المهزوز Name[bg]=Демо на Shaky Move Name[ca]=Demostració de sacsejada +Name[ca@valencia]=Demostració de sacsejada Name[csb]=Niespòkójnô rësznota (démònstarcëjô) Name[da]=Demo af Shaky Move Name[de]=Demo: Zitternde Bewegung diff --git a/effects/test/demo_shiftworkspaceup.desktop b/effects/test/demo_shiftworkspaceup.desktop index 5ff745c1de..4edb043e62 100644 --- a/effects/test/demo_shiftworkspaceup.desktop +++ b/effects/test/demo_shiftworkspaceup.desktop @@ -3,6 +3,7 @@ Name=Demo ShiftWorkspaceUp Name[ar]=مثال نقل مكان العمل إلى الأعلى Name[bg]=Демо на ShiftWorkspaceUp Name[ca]=Demostració ShiftWorkspaceUp +Name[ca@valencia]=Demostració ShiftWorkspaceUp Name[csb]=Òdwarcenié pùltu (démònstarcëjô) Name[da]=Demo af ShiftWorkspaceUp Name[de]=Demo: Arbeitsfläche nach oben diff --git a/effects/test/demo_showpicture.desktop b/effects/test/demo_showpicture.desktop index bffc9bc7b1..bce0411169 100644 --- a/effects/test/demo_showpicture.desktop +++ b/effects/test/demo_showpicture.desktop @@ -3,6 +3,7 @@ Name=Demo ShowPicture Name[ar]=مثال عرض الصورة Name[bg]=Демо на ShowPicture Name[ca]=Demostració ShowPicture +Name[ca@valencia]=Demostració ShowPicture Name[csb]=Wëszkënienié òbrôzka (démònstarcëjô) Name[da]=Demo af ShowPicture Name[de]=Demo: Bild anzeigen diff --git a/effects/test/demo_wavywindows.desktop b/effects/test/demo_wavywindows.desktop index 6d2c3226e6..db6b68d3d9 100644 --- a/effects/test/demo_wavywindows.desktop +++ b/effects/test/demo_wavywindows.desktop @@ -5,6 +5,7 @@ Name[be]=Хвалістыя вокны Name[be@latin]=Хвалістыя вокны Name[bg]=Демо на Wavy Windows Name[ca]=Demostració de finestres ondulants +Name[ca@valencia]=Demostració de finestres ondulants Name[da]=Demo af Wavy Windows Name[de]=Demo: Wellige Fenster Name[el]=Επίδειξη των Κυματιστών παραθύρων diff --git a/effects/test/drunken.desktop b/effects/test/drunken.desktop index 03e7482a55..c454f58cbc 100644 --- a/effects/test/drunken.desktop +++ b/effects/test/drunken.desktop @@ -3,6 +3,7 @@ Name=Drunken Name[af]=Dronk Name[ar]=سكران Name[ca]=Begut +Name[ca@valencia]=Begut Name[da]=Fordrukken Name[de]=Betrunken Name[el]=Κούνημα diff --git a/effects/test/flame.desktop b/effects/test/flame.desktop index a7f1f7ba7b..95f0176741 100644 --- a/effects/test/flame.desktop +++ b/effects/test/flame.desktop @@ -6,6 +6,7 @@ Name[be]=Полымя Name[be@latin]=Połymia Name[br]=Flamm Name[ca]=Flama +Name[ca@valencia]=Flama Name[cs]=Plamen Name[da]=Flamme Name[de]=Flamme diff --git a/effects/test/test_fbo.desktop b/effects/test/test_fbo.desktop index 6574ba1301..0ab85deb24 100644 --- a/effects/test/test_fbo.desktop +++ b/effects/test/test_fbo.desktop @@ -4,6 +4,7 @@ Name[ar]=اختبار_FBO Name[be]=Праверка_FBO Name[be@latin]=Праверка_FBO Name[ca]=Prova FBO +Name[ca@valencia]=Prova FBO Name[de]=Test: FBO Name[el]=Δοκιμή_FBO Name[gu]=ચકાસણી_FBO diff --git a/effects/test/test_input.desktop b/effects/test/test_input.desktop index b809f9311e..3d2a279e43 100644 --- a/effects/test/test_input.desktop +++ b/effects/test/test_input.desktop @@ -4,6 +4,7 @@ Name[ar]=اختبار_الإدخال Name[be]=Праверка_уводу Name[be@latin]=Праверка_уводу Name[ca]=Prova d'entrada +Name[ca@valencia]=Prova d'entrada Name[csb]=Test_Wpisania Name[de]=Test: Eingabe Name[el]=Δοκιμή εισόδου diff --git a/effects/test/test_thumbnail.desktop b/effects/test/test_thumbnail.desktop index 8654037e66..739de67e16 100644 --- a/effects/test/test_thumbnail.desktop +++ b/effects/test/test_thumbnail.desktop @@ -4,6 +4,7 @@ Name[ar]=اختبار_مصغّرات Name[be]=Праверка_мініяцюр Name[be@latin]=Праверка_мініяцюр Name[ca]=Prova de miniatura +Name[ca@valencia]=Prova de miniatura Name[csb]=Test_Miniaturczi Name[de]=Test: Vorschaubilder Name[el]=Δοκιμή εικόνας επισκόπησης diff --git a/effects/test/videorecord.desktop b/effects/test/videorecord.desktop index 0611e89ccd..e130559bd9 100644 --- a/effects/test/videorecord.desktop +++ b/effects/test/videorecord.desktop @@ -8,6 +8,7 @@ Name[bg]=Запис на звук Name[bn]=ভিডিও রেকর্ড Name[bn_IN]=ভিডিও রেকর্ড Name[ca]=Gravador de vídeo +Name[ca@valencia]=Gravador de vídeo Name[cs]=Nahrávání videa Name[csb]=Nagranié wideò Name[da]=Videooptagelse @@ -75,6 +76,7 @@ Comment[be@latin]=Zapisvaje videa z rabočaha stała. Comment[bg]=Запис на видео върху работния плот Comment[bn_IN]=ডেস্কটপের ভিডিও রেকর্ড করুন Comment[ca]=Grava un vídeo de l'escriptori +Comment[ca@valencia]=Grava un vídeo de l'escriptori Comment[csb]=Nagriwô wideò na twòjim pùlce Comment[da]=Optag en video af din desktop Comment[de]=Zeichnet Videos von der Arbeitsfläche auf. diff --git a/effects/test/videorecord_config.desktop b/effects/test/videorecord_config.desktop index 57a4f4e50e..2b77be163b 100644 --- a/effects/test/videorecord_config.desktop +++ b/effects/test/videorecord_config.desktop @@ -15,6 +15,7 @@ Name[bg]=Запис на звук Name[bn]=ভিডিও রেকর্ড Name[bn_IN]=ভিডিও রেকর্ড Name[ca]=Gravador de vídeo +Name[ca@valencia]=Gravador de vídeo Name[cs]=Nahrávání videa Name[csb]=Nagranié wideò Name[da]=Videooptagelse diff --git a/effects/thumbnailaside.desktop b/effects/thumbnailaside.desktop index 69fa9baec7..e47dab831d 100644 --- a/effects/thumbnailaside.desktop +++ b/effects/thumbnailaside.desktop @@ -5,6 +5,7 @@ Name[ar]=مصغرات على الجانب Name[be@latin]=Padhlady akon Name[bg]=Манипулатор на умалени копия Name[ca]=Miniatures de costat +Name[ca@valencia]=Miniatures de costat Name[cs]=Postranní miniatura Name[csb]=Miniaturka Aside Name[da]=Væk med miniature @@ -66,6 +67,7 @@ Comment[ar]=تعرض مصغرات النوافذ على حافة الشاشة Comment[be@latin]=Pakazvaje padhlady akon na krai ekrana. Comment[bg]=Показване на умалени копия, когато курсора е върху лентата с инструменти Comment[ca]=Mostra les miniatures de les finestres a la vora de la pantalla +Comment[ca@valencia]=Mostra les miniatures de les finestres a la vora de la pantalla Comment[da]=Vis miniaturer af vinduer ved kanten af skærmen Comment[de]=Zeigt Vorschaubilder von Fenstern in einer Bildschirmecke an. Comment[el]=Εμφανίζει στην άκρη της οθόνης την εικόνα επισκόπησης του παραθύρου diff --git a/effects/thumbnailaside_config.desktop b/effects/thumbnailaside_config.desktop index 3de8d435a1..172a29e720 100644 --- a/effects/thumbnailaside_config.desktop +++ b/effects/thumbnailaside_config.desktop @@ -12,6 +12,7 @@ Name[ar]=مصغرات على الجانب Name[be@latin]=Padhlady akon Name[bg]=Манипулатор на умалени копия Name[ca]=Miniatures de costat +Name[ca@valencia]=Miniatures de costat Name[cs]=Postranní miniatura Name[csb]=Miniaturka Aside Name[da]=Væk med miniature diff --git a/effects/trackmouse.desktop b/effects/trackmouse.desktop index 621277d1f5..00ffeaeb23 100644 --- a/effects/trackmouse.desktop +++ b/effects/trackmouse.desktop @@ -8,6 +8,7 @@ Name[bg]=Мишка Name[bn]=মাউস ট্র্যাক করো Name[bn_IN]=মাউস ট্র্যাক করো Name[ca]=Seguiment del ratolí +Name[ca@valencia]=Seguiment del ratolí Name[cs]=Sledování myši Name[da]=Sporing af mus Name[de]=Maus-Position finden @@ -70,6 +71,7 @@ Comment=Display a mouse cursor locating effect when activated Comment[ar]=تعرض موقع الفارة عند التفعيل Comment[be@latin]=Vyjaŭlaje miesca kursora. Comment[ca]=Mostra un efecte de posició del cursor del ratolí quan està activat +Comment[ca@valencia]=Mostra un efecte de posició del cursor del ratolí quan està activat Comment[da]=Vis en effekt til lokalisering af musemarkøren, når den aktiveres Comment[de]=Hebt bei Bedarf die Position des Mauszeigers hervor. Comment[el]=Εμφάνιση εφέ υπόδειξης της θέσης του ποντικιού όταν ενεργοποιηθεί diff --git a/effects/trackmouse_config.desktop b/effects/trackmouse_config.desktop index 156819fb9f..12e5c2da16 100644 --- a/effects/trackmouse_config.desktop +++ b/effects/trackmouse_config.desktop @@ -15,6 +15,7 @@ Name[bg]=Мишка Name[bn]=মাউস ট্র্যাক করো Name[bn_IN]=মাউস ট্র্যাক করো Name[ca]=Seguiment del ratolí +Name[ca@valencia]=Seguiment del ratolí Name[cs]=Sledování myši Name[da]=Sporing af mus Name[de]=Maus-Position finden diff --git a/effects/wobblywindows.desktop b/effects/wobblywindows.desktop index c0369be932..6f47f4f9d9 100644 --- a/effects/wobblywindows.desktop +++ b/effects/wobblywindows.desktop @@ -4,6 +4,7 @@ Name[ar]=نوافذ متقلبة Name[be@latin]=Skryŭleńnie akon Name[bg]=Желирани прозорци Name[ca]=Finestres sacsejades +Name[ca@valencia]=Finestres sacsejades Name[cs]=Chvějící se okna Name[csb]=Òkna Wobbly Name[da]=Blævrende vinduer @@ -60,6 +61,7 @@ Comment[ar]=غير شكل النوافذ عند تحركها Comment[be@latin]=Skryŭlaje vokny padčas pierasoŭvańnia. Comment[bg]=Прозорците изглеждат като желирани при местене Comment[ca]=Deforma les finestres quan es mouen +Comment[ca@valencia]=Deforma les finestres quan es mouen Comment[csb]=Defòrmùjë òkna przë jich rëszaniô Comment[da]=Deformér vinduer mens de flyttes Comment[de]=Lässt Fenster beim Verschieben wackeln. diff --git a/effects/wobblywindows_config.desktop b/effects/wobblywindows_config.desktop index 8cc3a6114b..38bd0a98af 100644 --- a/effects/wobblywindows_config.desktop +++ b/effects/wobblywindows_config.desktop @@ -11,6 +11,7 @@ Name[ar]=نوافذ متقلبة Name[be@latin]=Skryŭleńnie akon Name[bg]=Желирани прозорци Name[ca]=Finestres sacsejades +Name[ca@valencia]=Finestres sacsejades Name[cs]=Chvějící se okna Name[csb]=Òkna Wobbly Name[da]=Blævrende vinduer diff --git a/effects/zoom.desktop b/effects/zoom.desktop index 4dc9b44602..9365ff998b 100644 --- a/effects/zoom.desktop +++ b/effects/zoom.desktop @@ -66,6 +66,7 @@ Comment[ar]=تكبر سطح المكتب بالكامل Comment[be@latin]=Maštabuje ŭvieś stoł. Comment[bg]=Увеличаване на работния плот Comment[ca]=Amplia l'escriptori sencer +Comment[ca@valencia]=Amplia l'escriptori sencer Comment[cs]=Přiblíží celou plochu Comment[da]=Forstør hele desktoppen Comment[de]=Vergrößert die gesamte Arbeitsfläche. diff --git a/kcmkwin/kwincompositing/kwincompositing.desktop b/kcmkwin/kwincompositing/kwincompositing.desktop index dd22ee9436..24e9d521ef 100644 --- a/kcmkwin/kwincompositing/kwincompositing.desktop +++ b/kcmkwin/kwincompositing/kwincompositing.desktop @@ -20,6 +20,7 @@ Name[bg]=Ефекти на работните плотове Name[bn]=ডেস্কটপ এফেক্টস Name[bn_IN]=ডেস্কটপ ইফেক্ট Name[ca]=Efectes d'escriptori +Name[ca@valencia]=Efectes d'escriptori Name[cs]=Efekty na ploše Name[csb]=Efektë desktopù Name[da]=Desktop-effekter @@ -93,6 +94,7 @@ Comment[bg]=Настройване активирането на прозорц Comment[bn]=ডেস্কটপ এফেক্টস কনফিগার করুন Comment[bn_IN]=ডেস্কটপ ইফেক্ট কনফিগার করুন Comment[ca]=Configuració del efectes d'escriptori +Comment[ca@valencia]=Configuració del efectes d'escriptori Comment[cs]=Nastavení efektů pracovní plochy Comment[csb]=Kònfigùracëjô efektów desktopù Comment[da]=Indstil desktop-effekter diff --git a/kcmkwin/kwindecoration/kwindecoration.desktop b/kcmkwin/kwindecoration/kwindecoration.desktop index 1d97a5dd10..420c162f64 100644 --- a/kcmkwin/kwindecoration/kwindecoration.desktop +++ b/kcmkwin/kwindecoration/kwindecoration.desktop @@ -20,6 +20,7 @@ Name[bg]=Прозорци Name[bn]=উইণ্ডো Name[bn_IN]=উইন্ডো Name[ca]=Finestres +Name[ca@valencia]=Finestres Name[cs]=Okna Name[csb]=Òkna Name[da]=Vinduer @@ -92,6 +93,7 @@ Comment[bn]=উইণ্ডো শিরোনামের চেহারা Comment[bn_IN]=উইন্ডোর শিরোনামের চেহারাছবি কনফিগার করতে ব্যবহৃত হয় Comment[br]=Kefluniañ neuz ha feson titloù ar prenester Comment[ca]=Configura l'aspecte i efecte dels títols de la finestra +Comment[ca@valencia]=Configura l'aspecte i efecte dels títols de la finestra Comment[cs]=Nastavení vzhledu a dekorací oken Comment[csb]=Kònfigùracëjô wëzdrzatkù ë ùchòwaniô titlowi listwë òknów Comment[cy]=Ffurfweddu golwg a theimlad teitlau ffenestri diff --git a/kcmkwin/kwindesktop/desktop.desktop b/kcmkwin/kwindesktop/desktop.desktop index 5d28d7891b..34fbbcd773 100644 --- a/kcmkwin/kwindesktop/desktop.desktop +++ b/kcmkwin/kwindesktop/desktop.desktop @@ -21,6 +21,7 @@ Name[bn]=একাধিক ডেস্কটপ Name[bn_IN]=একাধিক ডেস্কটপ Name[br]=Lies burev Name[ca]=Múltiples escriptoris +Name[ca@valencia]=Múltiples escriptoris Name[cs]=Virtuální plochy Name[csb]=Wiele pùltów Name[cy]=Penbyrddau Lluosol @@ -99,6 +100,7 @@ Comment[bn]=কটি ভার্চুয়াল ডেস্কটপ থা Comment[bn_IN]=ভার্চুয়াল ডেস্কটপের সংখ্যা কনফিগার করা যাবে। Comment[br]=Amañ e c'hellit kefluniañ pet burev galloudel ez eus. Comment[ca]=Podeu configurar quants escriptoris virtuals ha d'haver-hi. +Comment[ca@valencia]=Podeu configurar quants escriptoris virtuals ha d'haver-hi. Comment[cs]=Zde je možné nastavit, kolik si přejete virtuálních ploch. Comment[csb]=Kònfigùracëjô wielënë wirtualnëch pùltów. Comment[cy]=Gallwch ffurfweddu faint o benbyrddau sydd ar gael diff --git a/kcmkwin/kwinoptions/kwinactions.desktop b/kcmkwin/kwinoptions/kwinactions.desktop index 4ced59c0cb..c4f7abb64b 100644 --- a/kcmkwin/kwinoptions/kwinactions.desktop +++ b/kcmkwin/kwinoptions/kwinactions.desktop @@ -19,6 +19,7 @@ Name[bn]=কাজ Name[bn_IN]=কর্ম Name[br]=Oberoù Name[ca]=Accions +Name[ca@valencia]=Accions Name[cs]=Činnosti Name[csb]=Dzejania Name[cy]=Gweithredoedd @@ -98,6 +99,7 @@ Comment[bn]=কীবোর্ড এবং মাউস সেটিংস ক Comment[bn_IN]=কি-বোর্ড ও মাউস সংক্রান্ত বৈশিষ্ট্য কনফিগার করা যাবে Comment[br]=Kefluniañ ar stokellaoueg hag al logodenn Comment[ca]=Aquí podeu configurar l'arranjament del teclat i del ratolí +Comment[ca@valencia]=Ací podeu configurar l'arranjament del teclat i del ratolí Comment[cs]=Nastavení klávesnice a myši Comment[csb]=Kònfigùracëjô nastôwù klawiaturë ë mëszë Comment[cy]=Ffurfweddu gosodiadau bysellfwrdd a llygoden diff --git a/kcmkwin/kwinoptions/kwinadvanced.desktop b/kcmkwin/kwinoptions/kwinadvanced.desktop index dc8928fe63..1754db9272 100644 --- a/kcmkwin/kwinoptions/kwinadvanced.desktop +++ b/kcmkwin/kwinoptions/kwinadvanced.desktop @@ -18,6 +18,7 @@ Name[bn]=অগ্রসর Name[bn_IN]=উন্নত বৈশিষ্ট্য Name[br]=Barek Name[ca]=Avançat +Name[ca@valencia]=Avançat Name[cs]=Pokročilé Name[csb]=Awansowóné Name[cy]=Uwch @@ -97,6 +98,7 @@ Comment[bg]=Настройване допълнителните параметр Comment[bn]=উইণ্ডো ম্যানেজমেন্টের ক্ষুদ্রাতিক্ষুদ্র বৈশিষ্ট্য কনফিগার করুন Comment[bn_IN]=উইন্ডো পরিচালনার উন্নত বৈশিষ্ট্য কনফিগার করুন Comment[ca]=Aquí podeu configurar les característiques avançades de la gestió de finestres +Comment[ca@valencia]=Ací podeu configurar les característiques avançades de la gestió de finestres Comment[cs]=Nastavení pokročilých vlastností správce oken Comment[csb]=Kònfigùracëjô awansowónëch òptacëji sprôwianiô òknama Comment[cy]=Ffurfweddu Nodweddion Uwch Trefnu Ffenestri diff --git a/kcmkwin/kwinoptions/kwinfocus.desktop b/kcmkwin/kwinoptions/kwinfocus.desktop index 1a42a994b0..eb88d883de 100644 --- a/kcmkwin/kwinoptions/kwinfocus.desktop +++ b/kcmkwin/kwinoptions/kwinfocus.desktop @@ -90,6 +90,7 @@ Comment[bn]=উইণ্ডো ফোকাস পলিসি কনফিগ Comment[bn_IN]=উইণ্ডো ফোকাস পলিসি কনফিগার করুন Comment[br]=Kefluniañ politikerez fokus ar prenestr Comment[ca]=Aquí podeu configurar la política del focus +Comment[ca@valencia]=Ací podeu configurar la política del focus Comment[cs]=Nastavení způsobu zaměřování oken Comment[csb]=Kònfigùracëjô zrëszaniô òknów Comment[cy]=Ffurfweddu'r polisi canolbyntio ffenestri diff --git a/kcmkwin/kwinoptions/kwinmoving.desktop b/kcmkwin/kwinoptions/kwinmoving.desktop index 178e0624ad..02af4f87b4 100644 --- a/kcmkwin/kwinoptions/kwinmoving.desktop +++ b/kcmkwin/kwinoptions/kwinmoving.desktop @@ -19,6 +19,7 @@ Name[bn]=সরানো হচ্ছে Name[bn_IN]=সরানো হচ্ছে Name[br]=O tilec'hiañ Name[ca]=Moviment +Name[ca@valencia]=Moviment Name[cs]=Přesouvání Name[csb]=Przesëwanié Name[cy]=Symud @@ -97,6 +98,7 @@ Comment[bn]=উইণ্ডো কিভাবে সরানো হবে ত Comment[bn_IN]=উইণ্ডো কিভাবে সরানো হবে তা কনফিগার করুন Comment[br]=Kefluniañ an daoare e vez fiñvalet ar prenester Comment[ca]=Aquí podeu configurar els valors per quan es moguin les finestres +Comment[ca@valencia]=Ací podeu configurar els valors per quan es moguin les finestres Comment[cs]=Nastavení způsobu přesouvání oken Comment[csb]=Kònfigùracëjô sztélu przesëwaniô òknów Comment[cy]=Ffurfweddu'r ffordd y symudir ffenestri diff --git a/kcmkwin/kwinoptions/kwinoptions.desktop b/kcmkwin/kwinoptions/kwinoptions.desktop index f995c6483e..ff376bd520 100644 --- a/kcmkwin/kwinoptions/kwinoptions.desktop +++ b/kcmkwin/kwinoptions/kwinoptions.desktop @@ -22,6 +22,7 @@ Name[bn]=উইণ্ডো আচরণ Name[bn_IN]=উইন্ডোর আচরণ Name[br]=Emzalc'h ar prenester Name[ca]=Comportament de les finestres +Name[ca@valencia]=Comportament de les finestres Name[cs]=Chování oken Name[csb]=Ùchòwanié òkna Name[cy]=Ymddygiad Ffenestri @@ -101,6 +102,7 @@ Comment[bn]=উইণ্ডোটির আচরণ কনফিগার ক Comment[bn_IN]=উইন্ডোর আচরণ কনফিগার করুন Comment[br]=Kefluniañ emzalc'h ar prenester Comment[ca]=Configura el comportament de finestra +Comment[ca@valencia]=Configura el comportament de finestra Comment[cs]=Nastavení chování oken Comment[csb]=Kònfigùracëjô ùchòwaniô òkna Comment[cy]=Ffurfweddu ymddygiad y ffenestr diff --git a/kcmkwin/kwinrules/kwinrules.desktop b/kcmkwin/kwinrules/kwinrules.desktop index bdc3935b1a..53e6ac382f 100644 --- a/kcmkwin/kwinrules/kwinrules.desktop +++ b/kcmkwin/kwinrules/kwinrules.desktop @@ -18,6 +18,7 @@ Name[be]=Настаўленні для асобных вокнаў Name[be@latin]=Dla peŭnych voknaŭ Name[bg]=Потребителски Name[ca]=Específic de finestra +Name[ca@valencia]=Específic de finestra Name[cs]=Specifická nastavení oken Name[csb]=Nastôw specyficzny dlô òkna Name[da]=Vinduesspecifikt @@ -87,6 +88,7 @@ Comment[bg]=Потребителски настройки на прозорци Comment[bn]=শুধুমাত্র এই বিশেষ উইণ্ডো-টির সেটিংস কনফিগার করুন Comment[bn_IN]=কোনো উইন্ডোর জন্য সুনির্দিষ্ট বৈশিষ্ট্য কনফিগার করুন Comment[ca]=Configura l'arranjament específicament per a una finestra +Comment[ca@valencia]=Configura l'arranjament específicament per a una finestra Comment[cs]=Nastavení specifická pro okno Comment[csb]=Kònfigùracëjô nastôwów specyficznëch dlô wëbrónegò òkna Comment[cy]=Ffurfweddu gosodiadau yn benodol ar gyfer ffenestr diff --git a/kwin.notifyrc b/kwin.notifyrc index a88c380d8b..e07edb8c25 100644 --- a/kwin.notifyrc +++ b/kwin.notifyrc @@ -10,6 +10,7 @@ Comment[bn]=কে.ডি.ই উইণ্ডো ম্যানেজার Comment[bn_IN]=KDE উইন্ডো ম্যানেজার Comment[br]=Merour prenester KDE Comment[ca]=El gestor de finestres del KDE +Comment[ca@valencia]=El gestor de finestres del KDE Comment[cs]=Správce oken KDE Comment[csb]=Menadżer òknów KDE Comment[cy]=Y Trefnydd Ffenestri KDE @@ -88,6 +89,7 @@ Name[bn]=ডেস্কটপ ১-এ যাও Name[bn_IN]=ডেস্কটপ ১-এ পরিবর্তন করুন Name[br]=Gwintañ da vurev 1 Name[ca]=Canvia a l'escriptori 1 +Name[ca@valencia]=Canvia a l'escriptori 1 Name[cs]=Přepnout se na plochu 1 Name[csb]=Skòknie na pùlt 1 Name[cy]=Newid i Penbwrdd 1 @@ -162,6 +164,7 @@ Comment[bn]=প্রথম ভার্চুয়াল ডেস্কটপ Comment[bn_IN]=ভার্চুয়াল ডেস্কটপ এক নির্বাচিত হয়েছে Comment[br]=Burev galloudel Unan a zo diuzet Comment[ca]=Se selecciona l'escriptori virtual u +Comment[ca@valencia]=Se selecciona l'escriptori virtual u Comment[cs]=Je vybrána virtuální plocha 1 Comment[da]=Virtuel desktop én er valgt Comment[de]=Arbeitsfläche 1 ist ausgewählt @@ -238,6 +241,7 @@ Name[bn]=ডেস্কটপ ২-এ যাও Name[bn_IN]=ডেস্কটপ ২-এ পরিবর্তন করুন Name[br]=Gwintañ da vurev 2 Name[ca]=Canvia a l'escriptori 2 +Name[ca@valencia]=Canvia a l'escriptori 2 Name[cs]=Přepnout se na plochu 2 Name[csb]=Skòknie na pùlt 2 Name[cy]=Newid i Penbwrdd 2 @@ -312,6 +316,7 @@ Comment[bn]=দ্বিতীয় ভার্চুয়াল ডেস্কট Comment[bn_IN]=ভার্চুয়াল ডেস্কটপ দুই নির্বাচিত হয়েছে Comment[br]=Burev galloudel Daou a zo diuzet Comment[ca]=Se selecciona l'escriptori virtual dos +Comment[ca@valencia]=Se selecciona l'escriptori virtual dos Comment[cs]=Je vybrána virtuální plocha 2 Comment[da]=Virtuel desktop to er valgt Comment[de]=Arbeitsfläche 2 ist ausgewählt @@ -389,6 +394,7 @@ Name[bn]=ডেস্কটপ ৩-এ যাও Name[bn_IN]=ডেস্কটপ ৩-এ পরিবর্তন করুন Name[br]=Gwintañ da vurev 3 Name[ca]=Canvia a l'escriptori 3 +Name[ca@valencia]=Canvia a l'escriptori 3 Name[cs]=Přepnout se na plochu 3 Name[csb]=Skòknie na pùlt 3 Name[cy]=Newid i Penbwrdd 3 @@ -463,6 +469,7 @@ Comment[bn]=তৃতীয় ভার্চুয়াল ডেস্কটপ Comment[bn_IN]=ভার্চুয়াল ডেস্কটপ তিন নির্বাচিত হয়েছে Comment[br]=Burev galloudel Tri a zo diuzet Comment[ca]=Se selecciona l'escriptori virtual tres +Comment[ca@valencia]=Se selecciona l'escriptori virtual tres Comment[cs]=Je vybrána virtuální plocha 3 Comment[da]=Virtuel desktop tre er valgt Comment[de]=Arbeitsfläche 3 ist ausgewählt @@ -540,6 +547,7 @@ Name[bn]=ডেস্কটপ ৪-এ যাও Name[bn_IN]=ডেস্কটপ ৪-এ পরিবর্তন করুন Name[br]=Gwintañ da vurev 4 Name[ca]=Canvia a l'escriptori 4 +Name[ca@valencia]=Canvia a l'escriptori 4 Name[cs]=Přepnout se na plochu 4 Name[csb]=Skòknie na pùlt 4 Name[cy]=Newid i Penbwrdd 4 @@ -614,6 +622,7 @@ Comment[bn]=চতুর্থ ভার্চুয়াল ডেস্কটপ Comment[bn_IN]=ভার্চুয়াল ডেস্কটপ চার নির্বাচিত হয়েছে Comment[br]=Burev galloudel Pevar a zo diuzet Comment[ca]=Se selecciona l'escriptori virtual quatre +Comment[ca@valencia]=Se selecciona l'escriptori virtual quatre Comment[cs]=Je vybrána virtuální plocha 4 Comment[da]=Virtuel desktop fire er valgt Comment[de]=Arbeitsfläche 4 ist ausgewählt @@ -690,6 +699,7 @@ Name[bn]=ডেস্কটপ ৫-এ যাও Name[bn_IN]=ডেস্কটপ ৫-এ পরিবর্তন করুন Name[br]=Gwintañ da vurev 5 Name[ca]=Canvia a l'escriptori 5 +Name[ca@valencia]=Canvia a l'escriptori 5 Name[cs]=Přepnout se na plochu 5 Name[csb]=Skòknie na pùlt 5 Name[cy]=Newid i Penbwrdd 5 @@ -764,6 +774,7 @@ Comment[bn]=পঞ্চম ভার্চুয়াল ডেস্কটপ Comment[bn_IN]=ভার্চুয়াল ডেস্কটপ পাঁচ নির্বাচিত হয়েছে Comment[br]=Burev galloudel Pemp a zo diuzet Comment[ca]=Se selecciona l'escriptori virtual cinc +Comment[ca@valencia]=Se selecciona l'escriptori virtual cinc Comment[cs]=Je vybrána virtuální plocha 5 Comment[da]=Virtuel desktop fem er valgt Comment[de]=Arbeitsfläche 5 ist ausgewählt @@ -841,6 +852,7 @@ Name[bn]=ডেস্কটপ ৬-এ যাও Name[bn_IN]=ডেস্কটপ ৬-এ পরিবর্তন করুন Name[br]=Gwintañ da vurev 6 Name[ca]=Canvia a l'escriptori 6 +Name[ca@valencia]=Canvia a l'escriptori 6 Name[cs]=Přepnout se na plochu 6 Name[csb]=Skòknie na pùlt 6 Name[cy]=Newid i Penbwrdd 6 @@ -915,6 +927,7 @@ Comment[bn]=ষষ্ঠ ভার্চুয়াল ডেস্কটপ ন Comment[bn_IN]=ভার্চুয়াল ডেস্কটপ ছয় নির্বাচিত হয়েছে Comment[br]=Burev galloudel C'hwec'h a zo diuzet Comment[ca]=Se selecciona l'escriptori virtual sis +Comment[ca@valencia]=Se selecciona l'escriptori virtual sis Comment[cs]=Je vybrána virtuální plocha 6 Comment[da]=Virtuel desktop seks er valgt Comment[de]=Arbeitsfläche 6 ist ausgewählt @@ -990,6 +1003,7 @@ Name[bn]=ডেস্কটপ ৭-এ যাও Name[bn_IN]=ডেস্কটপ ৭-এ পরিবর্তন করুন Name[br]=Gwintañ da vurev 7 Name[ca]=Canvia a l'escriptori 7 +Name[ca@valencia]=Canvia a l'escriptori 7 Name[cs]=Přepnout se na plochu 7 Name[csb]=Skòknie na pùlt 7 Name[cy]=Newid i Penbwrdd 7 @@ -1064,6 +1078,7 @@ Comment[bn]=সপ্তম ভার্চুয়াল ডেস্কটপ Comment[bn_IN]=ভার্চুয়াল ডেস্কটপ সাত নির্বাচিত হয়েছে Comment[br]=Burev galloudel Seizh a zo diuzet Comment[ca]=Se selecciona l'escriptori virtual set +Comment[ca@valencia]=Se selecciona l'escriptori virtual set Comment[cs]=Je vybrána virtuální plocha 7 Comment[da]=Virtuel desktop syv er valgt Comment[de]=Arbeitsfläche 7 ist ausgewählt @@ -1141,6 +1156,7 @@ Name[bn]=ডেস্কটপ ৮-এ যাও Name[bn_IN]=ডেস্কটপ ৮-এ পরিবর্তন করুন Name[br]=Gwintañ da vurev 8 Name[ca]=Canvia a l'escriptori 8 +Name[ca@valencia]=Canvia a l'escriptori 8 Name[cs]=Přepnout se na plochu 8 Name[csb]=Skòknie na pùlt 8 Name[cy]=Newid i Penbwrdd 8 @@ -1215,6 +1231,7 @@ Comment[bn]=অষ্টম ভার্চুয়াল ডেস্কটপ Comment[bn_IN]=ভার্চুয়াল ডেস্কটপ আট নির্বাচিত হয়েছে Comment[br]=Burev galloudel Eizh a zo diuzet Comment[ca]=Se selecciona l'escriptori virtual vuit +Comment[ca@valencia]=Se selecciona l'escriptori virtual vuit Comment[cs]=Je vybrána virtuální plocha 8 Comment[da]=Virtuel desktop otte er valgt Comment[de]=Arbeitsfläche 8 ist ausgewählt @@ -1292,6 +1309,7 @@ Name[bn]=ডেস্কটপ ৯-এ যাও Name[bn_IN]=ডেস্কটপ ৯-এ পরিবর্তন করুন Name[br]=Gwintañ da vurev 9 Name[ca]=Canvia a l'escriptori 9 +Name[ca@valencia]=Canvia a l'escriptori 9 Name[cs]=Přepnout se na plochu 9 Name[csb]=Skòknie na pùlt 9 Name[da]=Skift til desktop 9 @@ -1364,6 +1382,7 @@ Comment[bn]=নবম ভার্চুয়াল ডেস্কটপ নি Comment[bn_IN]=ভার্চুয়াল ডেস্কটপ নয় নির্বাচিত হয়েছে Comment[br]=Burev galloudel Nav a zo dibabet Comment[ca]=Se selecciona l'escriptori virtual nou +Comment[ca@valencia]=Se selecciona l'escriptori virtual nou Comment[cs]=Je vybrána virtuální plocha 9 Comment[da]=Virtuel desktop ni er valgt Comment[de]=Arbeitsfläche 9 ist ausgewählt @@ -1439,6 +1458,7 @@ Name[bn]=ডেস্কটপ ১০-এ যাও Name[bn_IN]=ডেস্কটপ ১০-এ পরিবর্তন করুন Name[br]=Gwintañ da vurev 10 Name[ca]=Canvia a l'escriptori 10 +Name[ca@valencia]=Canvia a l'escriptori 10 Name[cs]=Přepnout se na plochu 10 Name[csb]=Skòknie na pùlt 10 Name[da]=Skift til desktop 10 @@ -1511,6 +1531,7 @@ Comment[bn]=দশম ভার্চুয়াল ডেস্কটপ নি Comment[bn_IN]=ভার্চুয়াল ডেস্কটপ দশ নির্বাচিত হয়েছে Comment[br]=Burev galloudel Dek a zo dibabet Comment[ca]=Se selecciona l'escriptori virtual deu +Comment[ca@valencia]=Se selecciona l'escriptori virtual deu Comment[cs]=Je vybrána virtuální plocha 10 Comment[da]=Virtuel desktop ti er valgt Comment[de]=Arbeitsfläche 10 ist ausgewählt @@ -1586,6 +1607,7 @@ Name[bn]=ডেস্কটপ ১১-য় যাও Name[bn_IN]=ডেস্কটপ ১১-এ পরিবর্তন করুন Name[br]=Gwintañ da vurev 11 Name[ca]=Canvia a l'escriptori 11 +Name[ca@valencia]=Canvia a l'escriptori 11 Name[cs]=Přepnout se na plochu 11 Name[csb]=Skòknie na pùlt 11 Name[da]=Skift til desktop 11 @@ -1658,6 +1680,7 @@ Comment[bn]=একাদশ ভার্চুয়াল ডেস্কটপ Comment[bn_IN]=ভার্চুয়াল ডেস্কটপ এগারো নির্বাচিত হয়েছে Comment[br]=Burev galloudel Unnek a zo dibabet Comment[ca]=Se selecciona l'escriptori virtual onze +Comment[ca@valencia]=Se selecciona l'escriptori virtual onze Comment[cs]=Je vybrána virtuální plocha 11 Comment[da]=Virtuel desktop elleve er valgt Comment[de]=Arbeitsfläche 11 ist ausgewählt @@ -1732,6 +1755,7 @@ Name[bn]=ডেস্কটপ ১২-য় যাওও Name[bn_IN]=ডেস্কটপ ১২-এ পরিবর্তন করুন Name[br]=Gwintañ da vurev 12 Name[ca]=Canvia a l'escriptori 12 +Name[ca@valencia]=Canvia a l'escriptori 12 Name[cs]=Přepnout se na plochu 12 Name[csb]=Skòknie na pùlt 12 Name[da]=Skift til desktop 12 @@ -1804,6 +1828,7 @@ Comment[bn]=দ্বাদশ ভার্চুয়াল ডেস্কটপ Comment[bn_IN]=ভার্চুয়াল ডেস্কটপ বারো নির্বাচিত হয়েছে Comment[br]=Burev galloudel daouzek a zo dibabet Comment[ca]=Se selecciona l'escriptori virtual dotze +Comment[ca@valencia]=Se selecciona l'escriptori virtual dotze Comment[cs]=Je vybrána virtuální plocha 12 Comment[da]=Virtuel desktop tolv er valgt Comment[de]=Arbeitsfläche 12 ist ausgewählt @@ -1878,6 +1903,7 @@ Name[bn]=ডেস্কটপ ১৩-য় যাও Name[bn_IN]=ডেস্কটপ ১৩-এ পরিবর্তন করুন Name[br]=Gwintañ da vurev 13 Name[ca]=Canvia a l'escriptori 13 +Name[ca@valencia]=Canvia a l'escriptori 13 Name[cs]=Přepnout se na plochu 13 Name[csb]=Skòknie na pùlt 13 Name[da]=Skift til desktop 13 @@ -1950,6 +1976,7 @@ Comment[bn]=ত্রয়োদশ ভার্চুয়াল ডেস্কট Comment[bn_IN]=ভার্চুয়াল ডেস্কটপ তেরো নির্বাচিত হয়েছে Comment[br]=Burev galloudel trizek a zo dibabet Comment[ca]=Se selecciona l'escriptori virtual tretze +Comment[ca@valencia]=Se selecciona l'escriptori virtual tretze Comment[cs]=Je vybrána virtuální plocha 13 Comment[da]=Virtuel desktop tretten er valgt Comment[de]=Arbeitsfläche 13 ist ausgewählt @@ -2025,6 +2052,7 @@ Name[bn]=ডেস্কটপ ১৪-য় যাও Name[bn_IN]=ডেস্কটপ ১৪-এ পরিবর্তন করুন Name[br]=Gwintañ da vurev 14 Name[ca]=Canvia a l'escriptori 14 +Name[ca@valencia]=Canvia a l'escriptori 14 Name[cs]=Přepnout se na plochu 14 Name[csb]=Skòknie na pùlt 14 Name[da]=Skift til desktop 14 @@ -2097,6 +2125,7 @@ Comment[bn]=চতুর্দশ ভার্চুয়াল ডেস্কট Comment[bn_IN]=ভার্চুয়াল ডেস্কটপ চোদ্দ নির্বাচিত হয়েছে Comment[br]=Burev galloudel pevarezk a zo dibabet Comment[ca]=Se selecciona l'escriptori virtual catorze +Comment[ca@valencia]=Se selecciona l'escriptori virtual catorze Comment[cs]=Je vybrána virtuální plocha 14 Comment[da]=Virtuel desktop fjorten er valgt Comment[de]=Arbeitsfläche 14 ist ausgewählt @@ -2171,6 +2200,7 @@ Name[bn]=ডেস্কটপ ১৫-য় যাও Name[bn_IN]=ডেস্কটপ ১৫-এ পরিবর্তন করুন Name[br]=Gwintañ da vurev 15 Name[ca]=Canvia a l'escriptori 15 +Name[ca@valencia]=Canvia a l'escriptori 15 Name[cs]=Přepnout se na plochu 15 Name[csb]=Skòknie na pùlt 15 Name[da]=Skift til desktop 15 @@ -2243,6 +2273,7 @@ Comment[bn]=পঞ্চদশ ভার্চুয়াল ডেস্কটপ Comment[bn_IN]=ভার্চুয়াল ডেস্কটপ পনেরো নির্বাচিত হয়েছে Comment[br]=Burev galloudel pempzek a zo dibabet Comment[ca]=Se selecciona l'escriptori virtual quinze +Comment[ca@valencia]=Se selecciona l'escriptori virtual quinze Comment[cs]=Je vybrána virtuální plocha 15 Comment[da]=Virtuel desktop femten er valgt Comment[de]=Arbeitsfläche 15 ist ausgewählt @@ -2318,6 +2349,7 @@ Name[bn]=ডেস্কটপ ১৬-য় যাও Name[bn_IN]=ডেস্কটপ ১৬-এ পরিবর্তন করুন Name[br]=Gwintañ da vurev 16 Name[ca]=Canvia a l'escriptori 16 +Name[ca@valencia]=Canvia a l'escriptori 16 Name[cs]=Přepnout se na plochu 16 Name[csb]=Skòknie na pùlt 16 Name[da]=Skift til desktop 16 @@ -2390,6 +2422,7 @@ Comment[bn]=ষোড়শ ভার্চুয়াল ডেস্কটপ ন Comment[bn_IN]=ভার্চুয়াল ডেস্কটপ ষোল নির্বাচিত হয়েছে Comment[br]=Burev galloudel c'hwezek a zo dibabet Comment[ca]=Se selecciona l'escriptori virtual setze +Comment[ca@valencia]=Se selecciona l'escriptori virtual setze Comment[cs]=Je vybrána virtuální plocha 16 Comment[da]=Virtuel desktop seksten er valgt Comment[de]=Arbeitsfläche 16 ist ausgewählt @@ -2465,6 +2498,7 @@ Name[bn]=ডেস্কটপ ১৭-য় যাও Name[bn_IN]=ডেস্কটপ ১৭-এ পরিবর্তন করুন Name[br]=Gwintañ da vurev 17 Name[ca]=Canvia a l'escriptori 17 +Name[ca@valencia]=Canvia a l'escriptori 17 Name[cs]=Přepnout se na plochu 17 Name[csb]=Skòknie na pùlt 17 Name[da]=Skift til desktop 17 @@ -2537,6 +2571,7 @@ Comment[bn]=সপ্তদশ ভার্চুয়াল ডেস্কটপ Comment[bn_IN]=ভার্চুয়াল ডেস্কটপ সতেরো নির্বাচিত হয়েছে Comment[br]=Burev galloudel seitek a zo dibabet Comment[ca]=Se selecciona l'escriptori virtual disset +Comment[ca@valencia]=Se selecciona l'escriptori virtual disset Comment[cs]=Je vybrána virtuální plocha 17 Comment[da]=Virtuel desktop sytten er valgt Comment[de]=Arbeitsfläche 17 ist ausgewählt @@ -2611,6 +2646,7 @@ Name[bn]=ডেস্কটপ ১৮-য় যাও Name[bn_IN]=ডেস্কটপ ১৮-এ পরিবর্তন করুন Name[br]=Gwintañ da vurev 18 Name[ca]=Canvia a l'escriptori 18 +Name[ca@valencia]=Canvia a l'escriptori 18 Name[cs]=Přepnout se na plochu 18 Name[csb]=Skòknie na pùlt 18 Name[da]=Skift til desktop 18 @@ -2683,6 +2719,7 @@ Comment[bn]=অষ্টাদশ ভার্চুয়াল ডেস্কট Comment[bn_IN]=ভার্চুয়াল ডেস্কটপ আঠারো নির্বাচিত হয়েছে Comment[br]=Burev galloudel triwec'h a zo dibabet Comment[ca]=Se selecciona l'escriptori virtual divuit +Comment[ca@valencia]=Se selecciona l'escriptori virtual divuit Comment[cs]=Je vybrána virtuální plocha 18 Comment[da]=Virtuel desktop atten er valgt Comment[de]=Arbeitsfläche 18 ist ausgewählt @@ -2758,6 +2795,7 @@ Name[bn]=ডেস্কটপ ১৯-এ যাও Name[bn_IN]=ডেস্কটপ ১৯-এ পরিবর্তন করুন Name[br]=Gwintañ da vurev 19 Name[ca]=Canvia a l'escriptori 19 +Name[ca@valencia]=Canvia a l'escriptori 19 Name[cs]=Přepnout se na plochu 19 Name[csb]=Skòknie na pùlt 19 Name[da]=Skift til desktop 19 @@ -2830,6 +2868,7 @@ Comment[bn]=উনবিংশ ভার্চুয়াল ডেস্কটপ Comment[bn_IN]=ভার্চুয়াল ডেস্কটপ উনিশ নির্বাচিত হয়েছে Comment[br]=Burev galloudel naontek a zo dibabet Comment[ca]=Se selecciona l'escriptori virtual dinou +Comment[ca@valencia]=Se selecciona l'escriptori virtual dinou Comment[cs]=Je vybrána virtuální plocha 19 Comment[da]=Virtuel desktop nitten er valgt Comment[de]=Arbeitsfläche 19 ist ausgewählt @@ -2905,6 +2944,7 @@ Name[bn]=ডেস্কটপ ২০-তে যাও Name[bn_IN]=ডেস্কটপ ২০-এ পরিবর্তন করুন Name[br]=Gwintañ da vurev 20 Name[ca]=Canvia a l'escriptori 20 +Name[ca@valencia]=Canvia a l'escriptori 20 Name[cs]=Přepnout se na plochu 20 Name[csb]=Skòknie na pùlt 20 Name[da]=Skift til desktop 20 @@ -2977,6 +3017,7 @@ Comment[bn]=বিংশ ভার্চুয়াল ডেস্কটপ ন Comment[bn_IN]=ভার্চুয়াল ডেস্কটপ কুড়ি নির্বাচিত হয়েছে Comment[br]=Burev galloudel warn-ugent a zo dibabet Comment[ca]=Se selecciona l'escriptori virtual vint +Comment[ca@valencia]=Se selecciona l'escriptori virtual vint Comment[cs]=Je vybrána virtuální plocha 20 Comment[da]=Virtuel desktop tyve er valgt Comment[de]=Arbeitsfläche 20 ist ausgewählt @@ -3050,6 +3091,7 @@ Name[bg]=Активиране на прозорец Name[bn]=উইণ্ডো সক্রিয় করো Name[bn_IN]=উইন্ডো সক্রিয় করুন Name[ca]=Activa finestra +Name[ca@valencia]=Activa finestra Name[cs]=Aktivace okna Name[csb]=Aktiwacëjô òkna Name[da]=Aktivér vindue @@ -3122,6 +3164,7 @@ Comment[bn]=অন্য একটি উইণ্ডো সক্রিয় ক Comment[bn_IN]=অন্য একটি উইণ্ডো সক্রিয় করা হয়েছে Comment[br]=Ur prenestr all a zo dihunet Comment[ca]=S'activa una altra finestra +Comment[ca@valencia]=S'activa una altra finestra Comment[cs]=Jiné okna je aktivováno Comment[csb]=Jinszé òkno bãdze aktiwòwóné Comment[da]=Et andet vindue er aktiveret @@ -3196,6 +3239,7 @@ Name[bn]=নতুন উইণ্ডো Name[bn_IN]=নতুন উইন্ডো Name[br]=Prenestr nevez Name[ca]=Nova finestra +Name[ca@valencia]=Nova finestra Name[cs]=Nové okno Name[csb]=Nowé òkno Name[cy]=Ffenestr Newydd @@ -3275,6 +3319,7 @@ Comment[bg]=Нов прозорец Comment[bn]=নতুন উইণ্ডো Comment[bn_IN]=নতুন উইন্ডো Comment[ca]=Finestra nova +Comment[ca@valencia]=Finestra nova Comment[cs]=Nové okno Comment[csb]=Nowé òkno Comment[da]=Nyt vindue @@ -3352,6 +3397,7 @@ Name[bg]=Изтриване на прозореца Name[bn]=উইণ্ডো বন্ধ করো Name[bn_IN]=উইন্ডো মুছে ফেলুন Name[ca]=Elimina finestra +Name[ca@valencia]=Elimina finestra Name[cs]=Zrušit okno Name[csb]=Rëmôj òkno Name[da]=Slet vindue @@ -3423,6 +3469,7 @@ Comment[bn]=উইণ্ডো বন্ধ করো Comment[bn_IN]=উইন্ডো মুছে ফেলুন Comment[br]=Lemel ur prenestr Comment[ca]=Elimina una finestra +Comment[ca@valencia]=Elimina una finestra Comment[cs]=Zrušit okno Comment[csb]=Rëmôj òkno Comment[da]=Slet vindue @@ -3499,6 +3546,7 @@ Name[bn]=উইণ্ডো বন্ধ Name[bn_IN]=উইন্ডো বন্ধ করুন Name[br]=Serriñ ar Prenestr Name[ca]=Tanca finestra +Name[ca@valencia]=Tanca finestra Name[cs]=Zavření okna Name[csb]=Zamkni òkno Name[da]=Vindueslukning @@ -3571,6 +3619,7 @@ Comment[bn]=একটি উইণ্ডো বন্ধ করা হয়েছ Comment[bn_IN]=একটি উইন্ডো বন্ধ করা হয় Comment[br]=Sarret eo ur prenestr Comment[ca]=Es tanca una finestra +Comment[ca@valencia]=Es tanca una finestra Comment[cs]=Okno se zavírá Comment[csb]=Òkno bãdze zamkłé Comment[da]=Et vindue lukker @@ -3647,6 +3696,7 @@ Name[bn]=উইণ্ডো উপরে গুটিয়ে নাও Name[bn_IN]=উইণ্ডো উপরে গুটিয়ে নাও Name[br]=Rollañ ar prenestr Name[ca]=Enrotlla finestra +Name[ca@valencia]=Enrotlla finestra Name[cs]=Zarolování okna Name[csb]=Złożë òkno Name[cy]=Rholio'r Ffenestr i Fyny @@ -3714,6 +3764,7 @@ Comment[bn]=একটি উইণ্ডো গুটানো হয়েছে Comment[bn_IN]=একটি উইণ্ডো গুটানো হয়েছে Comment[br]=Rollet eo ur prenestr Comment[ca]=Enrotlla una finestra +Comment[ca@valencia]=Enrotlla una finestra Comment[cs]=Okna je zarolováno Comment[csb]=Òkno bãdze złożoné Comment[da]=Et vindue skygges op @@ -3783,6 +3834,7 @@ Name[bn]=উইণ্ডো নামাও Name[bn_IN]=উইণ্ডো নামাও Name[br]=Dirollañ ar Prenestr Name[ca]=Desenrotlla finestra +Name[ca@valencia]=Desenrotlla finestra Name[cs]=Vyrolování okna Name[csb]=Rozłożë òkno Name[cy]=Rholio'r Ffenestr i Lawr @@ -3849,6 +3901,7 @@ Comment[bn]=একটি উইণ্ডো নামানো হয়েছে Comment[bn_IN]=একটি উইণ্ডো নামানো হয়েছে Comment[br]=Dirollet eo ur prenestr Comment[ca]=Desenrotlla una finestra +Comment[ca@valencia]=Desenrotlla una finestra Comment[cs]=Okna je vyrolováno Comment[csb]=Òkno bãdze rozłożoné Comment[da]=Et vindue skygges ned @@ -3917,6 +3970,7 @@ Name[bn]=উইণ্ডো মিনিমাইজ Name[bn_IN]=উইণ্ডো মিনিমাইজ Name[br]=Kilbleg ar prenestr Name[ca]=Minimitza finestra +Name[ca@valencia]=Minimitza finestra Name[cs]=Minimalizace okna Name[csb]=Minimalizëjë òkno Name[cy]=Lleihau Ffenestr @@ -3990,6 +4044,7 @@ Comment[bn]=একটি উইণ্ডো মিনিমাইজ করা Comment[bn_IN]=একটি উইণ্ডো মিনিমাইজ করা হয়েছে Comment[br]=Kilbleget eo ur prenestr Comment[ca]=Es minimitza una finestra +Comment[ca@valencia]=Es minimitza una finestra Comment[cs]=Okno je minimalizováno Comment[csb]=Òkno bãdze zminimalizowóné Comment[da]=Et vindue minimeres @@ -4064,6 +4119,7 @@ Name[bg]=Възстановяване на прозорец Name[bn]=উইণ্ডো আনমিনিমাইজ Name[bn_IN]=উইণ্ডো আনমিনিমাইজ Name[ca]=Desminimitza finestra +Name[ca@valencia]=Desminimitza finestra Name[cs]=Zrušení mininimalizace okna Name[csb]=Doprowôdzë òkno nazôd Name[cy]=Dad-leihau Ffenestr @@ -4132,6 +4188,7 @@ Comment[bn]=একটি উইণ্ডো রিস্টোর করা হ Comment[bn_IN]=একটি উইণ্ডো রিস্টোর করা হয়েছে Comment[br]=Assavet eo ur prenestr Comment[ca]=Es restaura una finestra +Comment[ca@valencia]=Es restaura una finestra Comment[cs]=Okno je obnoveno Comment[csb]=Òkno bãdze doprowadzoné nazôd Comment[da]=Et vindue genetableres @@ -4206,6 +4263,7 @@ Name[bn]=উইণ্ডো ম্যাক্সিমাইজ Name[bn_IN]=উইণ্ডো ম্যাক্সিমাইজ Name[br]=Astenn ar Prenestr Name[ca]=Maximitza finestra +Name[ca@valencia]=Maximitza finestra Name[cs]=Maximalizace okna Name[csb]=Maksymilizëjë òkno Name[cy]=Ehangu Ffenestr @@ -4279,6 +4337,7 @@ Comment[bn]=একটি উইণ্ডো ম্যাক্সিমাইজ Comment[bn_IN]=একটি উইণ্ডো ম্যাক্সিমাইজ করা হয়েছে Comment[br]=Astennet eo ur prenestr Comment[ca]=Es maximitza una finestra +Comment[ca@valencia]=Es maximitza una finestra Comment[cs]=Okno je maximalizováno Comment[csb]=Òkno bãdze zmaksymilizowóné Comment[da]=Et vindue maksimeres @@ -4353,6 +4412,7 @@ Name[bn]=উইণ্ডো আনম্যাক্সিমাইজ Name[bn_IN]=উইণ্ডো আনম্যাক্সিমাইজ Name[br]=Krennañ ar Prenestr Name[ca]=Desmaximitza finestra +Name[ca@valencia]=Desmaximitza finestra Name[cs]=Zrušení maximalizace okna Name[csb]=Doprowôdzë nazôd maksymilizowanié òkna Name[cy]=Dad_ehangu Ffenestr @@ -4423,6 +4483,7 @@ Comment[bn]=একটি উইণ্ডো ম্যাক্সিমাইজ Comment[bn_IN]=একটি উইণ্ডো ম্যাক্সিমাইজেশন হারিয়েছে Comment[br]=Koll a ra ur prenestr e astenn Comment[ca]=Una finestra perd la maximització +Comment[ca@valencia]=Una finestra perd la maximització Comment[cs]=Okno ztrácí maximalizaci Comment[csb]=Òkno nie bãdze wicy maksymilizowóné Comment[da]=Et vindue afmaksimeres @@ -4493,6 +4554,7 @@ Name[bg]=Прозорец на всички работни плотове Name[bn]=উইণ্ডো সব ডেস্কটপে Name[bn_IN]=সকল ডেস্কটপের উপর উইন্ডো স্থাপনা Name[ca]=Finestra a tots els escriptoris +Name[ca@valencia]=Finestra a tots els escriptoris Name[cs]=Okno na všech plochách Name[csb]=Òkno na wszëtczich pùltach Name[da]=Vindue på alle desktoppe @@ -4560,6 +4622,7 @@ Comment[bg]=Прозорецът ще бъде видим на всички ра Comment[bn]=একটি উইণ্ডো এখন থেকে সব ডেস্কটপে দেখা যাবে Comment[bn_IN]=উইন্ডোটি সকল ডেস্কটপের উপর প্রদর্শিত হবে Comment[ca]=Una finestra serà visible en tots els escriptoris +Comment[ca@valencia]=Una finestra serà visible en tots els escriptoris Comment[cs]=Okno je zviditelněné na všech plochách Comment[csb]=Òkno pòkôże sã na wszëtczich pùltach Comment[da]=Et vindue gøres synligt på alle desktoppe @@ -4631,6 +4694,7 @@ Name[be@latin]=Akno nie na ŭsie stały Name[bn]=উইণ্ডো সব ডেস্কটপে নয় Name[bn_IN]=উইণ্ডো সব ডেস্কটপে নয় Name[ca]=Finestra no a tots els escriptoris +Name[ca@valencia]=Finestra no a tots els escriptoris Name[cs]=Okno ne na všech plochách Name[csb]=Òkno nié na wszëtczich pùltach Name[da]=Vindue ikke på alle desktoppe @@ -4696,6 +4760,7 @@ Comment[be@latin]=Akno bolš nia bačnaje na ŭsich stałach. Comment[bn]=একটি উইণ্ডো আর সব ডেস্কটপে দেখা যাচ্ছে না Comment[bn_IN]=একটি উইণ্ডো আর সব ডেস্কটপে দেখা যাচ্ছে না Comment[ca]=Una finestra no serà visible en tots els escriptoris +Comment[ca@valencia]=Una finestra no serà visible en tots els escriptoris Comment[cs]=Okno již není na všech plochách Comment[csb]=Òkno nié ma sã pòkôzac na wszëtczich pùltach Comment[da]=Et vindue er ikke længere synligt på alle desktoppe @@ -4770,6 +4835,7 @@ Name[bn]=নতুন ডায়ালগ Name[bn_IN]=নতুন ডায়লগ Name[br]=Kendiviz nevez Name[ca]=Diàleg nou +Name[ca@valencia]=Diàleg nou Name[cs]=Nový dialog Name[csb]=Nowi dialog Name[cy]=Ymgom Newydd @@ -4843,6 +4909,7 @@ Comment[be@latin]=Uźnikła dyjalohavaje akno. Comment[bn]=একটি সাময়িক উইণ্ডো (ডায়ালগ) আবির্ভূত হয়েছে Comment[bn_IN]=একটি সাময়িক উইণ্ডো (ডায়ালগ) আবির্ভূত হয়েছে Comment[ca]=Apareix una finestra transitòria (un diàleg) +Comment[ca@valencia]=Apareix una finestra transitòria (un diàleg) Comment[cs]=Objevilo se dialogové okno Comment[da]=Midlertidigt vindue (en dialog) viser sig Comment[de]=Transientes Fenster (Dialog) wird angezeigt @@ -4912,6 +4979,7 @@ Name[bn]=ডায়ালগ মুছে ফেল Name[bn_IN]=ডায়লগ মুছে ফেলুন Name[br]=Lemel ar gendiviz Name[ca]=Elimina un diàleg +Name[ca@valencia]=Elimina un diàleg Name[cs]=Odstranění dialogu Name[csb]=Zamkni dialog Name[cy]=Dileu Ymgom @@ -4983,6 +5051,7 @@ Comment[be@latin]=Dyjalohavaje akno vydalenaje. Comment[bn]=একটি সাময়িক উইণ্ডো (ডায়ালগ) সরিয়ে ফেলা হয়েছে Comment[bn_IN]=একটি সাময়িক উইণ্ডো (ডায়ালগ) সরিয়ে ফেলা হয়েছে Comment[ca]=S'esborra una finestra transitòria (un diàleg) +Comment[ca@valencia]=S'esborra una finestra transitòria (un diàleg) Comment[cs]=Dialog byl odstraněn Comment[da]=Midlertidigt vindue (en dialog) fjernes Comment[de]=Transientes Fenster (Dialog) wird entfernt @@ -5052,6 +5121,7 @@ Name[bn]=উইণ্ডো সরানো শুরু Name[bn_IN]=উইণ্ডো সরানো শুরু Name[br]=Kregiñ da zilec'hiañ ar prenestr Name[ca]=Inici de moviment de finestra +Name[ca@valencia]=Inici de moviment de finestra Name[cs]=Začátek přesunu okna Name[csb]=Przesëwanié òknów (Sztart) Name[cy]=Cychwyn Symud y Ffenestr @@ -5120,6 +5190,7 @@ Comment[be@latin]=Akno pačało pierasoŭvacca. Comment[bn]=একটি উইণ্ডো সরানো শুরু হয়েছে Comment[bn_IN]=একটি উইণ্ডো সরানো শুরু হয়েছে Comment[ca]=Una finestra ha iniciat el moviment +Comment[ca@valencia]=Una finestra ha iniciat el moviment Comment[cs]=Okno započalo přesun Comment[csb]=Òkno bãdze przesëniãté (sztart) Comment[da]=Et vindue er begyndt at flyttes @@ -5189,6 +5260,7 @@ Name[bn]=উইণ্ডো সরানো শেষ Name[bn_IN]=উইণ্ডো সরানো শেষ Name[br]=Echuiñ da zilec'hiañ ar prenestr Name[ca]=Final de moviment de finestra +Name[ca@valencia]=Final de moviment de finestra Name[cs]=Konec přesunu okna Name[csb]=Przesëwanié òknów (kùńc) Name[cy]=Gorffen Symud y Ffenestr @@ -5258,6 +5330,7 @@ Comment[be@latin]=Akno skončyła pierasoŭvacca. Comment[bn]=একটি উইণ্ডো সরানো শেষ হয়েছে Comment[bn_IN]=একটি উইণ্ডো সরানো শেষ হয়েছে Comment[ca]=Una finestra ha finalitzat el seu moviment +Comment[ca@valencia]=Una finestra ha finalitzat el seu moviment Comment[cs]=Okno dokončilo přesun Comment[csb]=Òkno bãdze przesëniãté (kùńc) Comment[da]=Et vindue er færdigt med at flytte @@ -5328,6 +5401,7 @@ Name[bn]=উইণ্ডো মাপ বদল শুরু Name[bn_IN]=উইণ্ডো মাপ বদল শুরু Name[br]=Kregiñ da adventañ ar prenestr Name[ca]=Inici de redimensionament de finestra +Name[ca@valencia]=Inici de redimensionament de finestra Name[cs]=Začátek změny velikosti okna Name[csb]=Zmiana miarë òkna (sztart) Name[cy]=Cychwyn Newid Maint y Ffenestr @@ -5397,6 +5471,7 @@ Comment[be@latin]=Akno pačało źmianiać svaje pamiery. Comment[bn]=একটি উইণ্ডোর মাপ বদলানো শুরু হয়েছে Comment[bn_IN]=একটি উইণ্ডোর মাপ বদলানো শুরু হয়েছে Comment[ca]=Una finestra ha iniciat el redimensionament +Comment[ca@valencia]=Una finestra ha iniciat el redimensionament Comment[cs]=Okno začalo měnit velikost Comment[csb]=Zôczątk zmianë miarë òkna Comment[da]=Et vindue er begyndt at ændre størrelse @@ -5466,6 +5541,7 @@ Name[bn]=উইণ্ডো মাপ বদল শেষ Name[bn_IN]=উইণ্ডো মাপ বদল শেষ Name[br]=Echuiñ da adventañ ar prenestr Name[ca]=Final de redimensionament de finestra +Name[ca@valencia]=Final de redimensionament de finestra Name[cs]=Konec změny velikosti okna Name[csb]=Zmiana miarë òkna (kùńc) Name[cy]=Gorffen Newid Maint y Ffenestr @@ -5535,6 +5611,7 @@ Comment[be@latin]=Akno skončyła źmianiać svaje pamiery. Comment[bn]=একটি উইণ্ডোর মাপ বদলানো শেষ হয়েছে Comment[bn_IN]=একটি উইণ্ডোর মাপ বদলানো শেষ হয়েছে Comment[ca]=Una finestra ha finalitzat el redimensionament +Comment[ca@valencia]=Una finestra ha finalitzat el redimensionament Comment[cs]=Okno dokončilo změnu velikosti Comment[csb]=Zakùńczonô zmiana miarë òkna Comment[da]=Et vindue er færdigt med at ændre størrelse @@ -5603,6 +5680,7 @@ Name[be@latin]=Akno na dziejnym stale vymahaje ŭvahi Name[bn]=বর্তমান ডেস্কটপে উইণ্ডো দৃষ্টি আকর্ষণ করার চেষ্টা করছে Name[bn_IN]=বর্তমান ডেস্কটপে উইণ্ডো দৃষ্টি আকর্ষণ করার চেষ্টা করছে Name[ca]=Una finestra de l'escriptori actual demana atenció +Name[ca@valencia]=Una finestra de l'escriptori actual demana atenció Name[cs]=Okno na aktuální ploše vyžaduje pozornost Name[da]=Vindue på aktuel desktop kræver opmærksomhed Name[de]=Fenster auf aktueller Arbeitsfläche erfordert Aufmerksamkeit @@ -5662,6 +5740,7 @@ Comment[be@latin]=Akno na dziejnym virtualnym stale vymahaje ŭvahi. Comment[bn]=বর্তমান ভার্চুয়াল ডেস্কটপে একটি উইণ্ডো আপনার দৃষ্টি আকর্ষণ করার চেষ্টা করছে Comment[bn_IN]=বর্তমান ভার্চুয়াল ডেস্কটপে একটি উইণ্ডো আপনার দৃষ্টি আকর্ষণ করার চেষ্টা করছে Comment[ca]=Una finestra de l'escriptori actual demana atenció +Comment[ca@valencia]=Una finestra de l'escriptori actual demana atenció Comment[cs]=Okno na aktuální virtuální ploše vyžaduje pozornost Comment[da]=Et vindue på den nuværende desktop kræver opmærksomhed Comment[de]=Ein Fenster auf der aktuellen virtuellen Arbeitsfläche erfordert Ihre Aufmerksamkeit @@ -5726,6 +5805,7 @@ Name[be@latin]=Akno na inšym stale vymahaje ŭvahi Name[bn]=অন্য ডেস্কটপে উইণ্ডো দৃষ্টি আকর্ষণ করার চেষ্টা করছে Name[bn_IN]=অন্য ডেস্কটপে উইণ্ডো দৃষ্টি আকর্ষণ করার চেষ্টা করছে Name[ca]=Una finestra d'un altre escriptori demana atenció +Name[ca@valencia]=Una finestra d'un altre escriptori demana atenció Name[cs]=Okno na jiné ploše vyžaduje pozornost Name[da]=Vindue på anden desktop kræver opmærksomhed Name[de]=Fenster auf anderer Arbeitsfläche erfordert Aufmerksamkeit @@ -5785,6 +5865,7 @@ Comment[be@latin]=Akno na niadziejnym virtualnym stale vymahaje ŭvahi. Comment[bn]=অন্য একটি ভার্চুয়াল ডেস্কটপে একটি উইণ্ডো আপনার দৃষ্টি আকর্ষণ করার চেষ্টা করছে Comment[bn_IN]=অন্য একটি ভার্চুয়াল ডেস্কটপে একটি উইণ্ডো আপনার দৃষ্টি আকর্ষণ করার চেষ্টা করছে Comment[ca]=Una finestra en un escriptori virtual inactiu demana atenció +Comment[ca@valencia]=Una finestra en un escriptori virtual inactiu demana atenció Comment[cs]=Okno na neaktivní virtuální ploše vyžaduje pozornost Comment[da]=Vindue på anden desktop kræver opmærksomhed Comment[de]=Ein Fenster auf einer virtuellen Arbeitsfläche erfordert Ihre Aufmerksamkeit @@ -5843,6 +5924,7 @@ Name=Compositing Performance Is Slow Name[ar]=أداء التكوين بطيء Name[be@latin]=Kampazycyja zamarudnaja Name[ca]=El rendiment de la composició és lent +Name[ca@valencia]=El rendiment de la composició és lent Name[cs]=Výkon kompozice je pomalý Name[da]=Compositing-ydelsen er langsom Name[de]=Die Composit-Geschwindigkeit ist niedrig @@ -5888,6 +5970,7 @@ Comment=The compositing performance was too slow and compositing has been suspen Comment[ar]=أداء التكوين بطيء جدا و تم تعليقه. Comment[be@latin]=Chutkaść kampazycyi była zamałoj, i tamu jana była vyklučanaja. Comment[ca]=El rendiment de la composició era massa lent i s'ha suspès +Comment[ca@valencia]=El rendiment de la composició era massa lent i s'ha suspès Comment[da]=Compositing-ydelsen var for langsom, og compositing er blevet suspenderet Comment[de]=Die Composit-Geschwindigkeit ist niedrig, daher wurde die Compositing ausgesetzt. Comment[el]=Οι επιδόσεις σύνθεσης της εικόνας ήταν πολύ χαμηλές και η σύνθεση εικόνας αναστάλθηκε From 846496d2c17535d862087cb010008d1c0b66569d Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Thu, 5 Feb 2009 15:35:38 +0000 Subject: [PATCH 21/60] Cleaned up the effects/ directory by moving each individual effect into its own directory, cleaned up the effect config macros and renamed "MakeTransparent" to "Translucency" so that it matches its visible name. svn path=/trunk/KDE/kdebase/workspace/; revision=921749 --- effects/CMakeLists.txt | 319 ++++++------------ effects/{data => _data}/circle-edgy.png | Bin effects/{data => _data}/circle.png | Bin effects/{test => _test}/CMakeLists.txt | 0 effects/{test => _test}/data/liquid.frag | 0 effects/{test => _test}/data/liquid.vert | 0 effects/{test => _test}/demo_liquid.cpp | 0 effects/{test => _test}/demo_liquid.desktop | 0 effects/{test => _test}/demo_liquid.h | 0 effects/{test => _test}/demo_shakymove.cpp | 0 .../{test => _test}/demo_shakymove.desktop | 0 effects/{test => _test}/demo_shakymove.h | 0 .../{test => _test}/demo_shiftworkspaceup.cpp | 0 .../demo_shiftworkspaceup.desktop | 0 .../{test => _test}/demo_shiftworkspaceup.h | 0 effects/{test => _test}/demo_showpicture.cpp | 0 .../{test => _test}/demo_showpicture.desktop | 0 effects/{test => _test}/demo_showpicture.h | 0 effects/{test => _test}/demo_wavywindows.cpp | 0 .../{test => _test}/demo_wavywindows.desktop | 0 effects/{test => _test}/demo_wavywindows.h | 0 effects/{test => _test}/drunken.cpp | 0 effects/{test => _test}/drunken.desktop | 0 effects/{test => _test}/drunken.h | 0 effects/{test => _test}/flame.cpp | 0 effects/{test => _test}/flame.desktop | 0 effects/{test => _test}/flame.h | 0 effects/{test => _test}/howto.cpp | 0 effects/{test => _test}/howto.desktop | 0 effects/{test => _test}/howto.h | 0 effects/{test => _test}/test_fbo.cpp | 0 effects/{test => _test}/test_fbo.desktop | 0 effects/{test => _test}/test_fbo.h | 0 effects/{test => _test}/test_input.cpp | 0 effects/{test => _test}/test_input.desktop | 0 effects/{test => _test}/test_input.h | 0 effects/{test => _test}/test_thumbnail.cpp | 0 .../{test => _test}/test_thumbnail.desktop | 0 effects/{test => _test}/test_thumbnail.h | 0 effects/{test => _test}/videorecord.cpp | 0 effects/{test => _test}/videorecord.desktop | 0 effects/{test => _test}/videorecord.h | 0 .../{test => _test}/videorecord_config.cpp | 0 .../videorecord_config.desktop | 0 effects/{test => _test}/videorecord_config.h | 0 effects/blur/CMakeLists.txt | 20 ++ effects/{ => blur}/blur.cpp | 0 effects/{ => blur}/blur.desktop | 0 effects/{ => blur}/blur.h | 0 effects/{ => blur}/data/blur-render.frag | 0 effects/{ => blur}/data/blur-render.vert | 0 effects/{ => blur}/data/blur.frag | 0 effects/{ => blur}/data/blur.vert | 0 effects/boxswitch/CMakeLists.txt | 26 ++ effects/{ => boxswitch}/boxswitch.cpp | 0 effects/{ => boxswitch}/boxswitch.desktop | 0 effects/{ => boxswitch}/boxswitch.h | 0 effects/{ => boxswitch}/boxswitch_config.cpp | 5 +- .../{ => boxswitch}/boxswitch_config.desktop | 0 effects/{ => boxswitch}/boxswitch_config.h | 0 effects/{ => boxswitch}/boxswitch_config.ui | 0 effects/configs_builtins.cpp | 127 +++---- effects/coverswitch/CMakeLists.txt | 26 ++ effects/{ => coverswitch}/coverswitch.cpp | 0 effects/{ => coverswitch}/coverswitch.desktop | 0 effects/{ => coverswitch}/coverswitch.h | 0 .../{ => coverswitch}/coverswitch_config.cpp | 5 +- .../coverswitch_config.desktop | 0 .../{ => coverswitch}/coverswitch_config.h | 0 .../{ => coverswitch}/coverswitch_config.ui | 0 effects/cube/CMakeLists.txt | 44 +++ effects/{ => cube}/cube.cpp | 0 effects/{ => cube}/cube.desktop | 0 effects/{ => cube}/cube.h | 0 effects/{ => cube}/cube_config.cpp | 5 +- effects/{ => cube}/cube_config.desktop | 0 effects/{ => cube}/cube_config.h | 0 effects/{ => cube}/cube_config.ui | 0 effects/{ => cube}/cylinder.cpp | 0 effects/{ => cube}/cylinder.desktop | 0 effects/{ => cube}/cylinder.h | 0 effects/{ => cube}/cylinder_config.cpp | 5 +- effects/{ => cube}/cylinder_config.desktop | 0 effects/{ => cube}/cylinder_config.h | 0 effects/{ => cube}/cylinder_config.ui | 0 effects/{ => cube}/data/cubecap.png | Bin effects/{ => cube}/data/cylinder.frag | 0 effects/{ => cube}/data/cylinder.vert | 0 effects/{ => cube}/data/sphere.vert | 0 effects/{ => cube}/sphere.cpp | 0 effects/{ => cube}/sphere.desktop | 0 effects/{ => cube}/sphere.h | 0 effects/{ => cube}/sphere_config.cpp | 5 +- effects/{ => cube}/sphere_config.desktop | 0 effects/{ => cube}/sphere_config.h | 0 effects/{ => cube}/sphere_config.ui | 0 effects/desktopgrid/CMakeLists.txt | 26 ++ effects/{ => desktopgrid}/desktopgrid.cpp | 0 effects/{ => desktopgrid}/desktopgrid.desktop | 0 effects/{ => desktopgrid}/desktopgrid.h | 0 .../{ => desktopgrid}/desktopgrid_config.cpp | 5 +- .../desktopgrid_config.desktop | 0 .../{ => desktopgrid}/desktopgrid_config.h | 0 .../{ => desktopgrid}/desktopgrid_config.ui | 0 effects/dialogparent/CMakeLists.txt | 12 + effects/{ => dialogparent}/dialogparent.cpp | 0 .../{ => dialogparent}/dialogparent.desktop | 0 effects/{ => dialogparent}/dialogparent.h | 0 effects/diminactive/CMakeLists.txt | 26 ++ effects/{ => diminactive}/diminactive.cpp | 0 effects/{ => diminactive}/diminactive.desktop | 0 effects/{ => diminactive}/diminactive.h | 0 .../{ => diminactive}/diminactive_config.cpp | 4 +- .../diminactive_config.desktop | 0 .../{ => diminactive}/diminactive_config.h | 0 .../{ => diminactive}/diminactive_config.ui | 0 effects/dimscreen/CMakeLists.txt | 12 + effects/{ => dimscreen}/dimscreen.cpp | 0 effects/{ => dimscreen}/dimscreen.desktop | 0 effects/{ => dimscreen}/dimscreen.h | 0 effects/explosion/CMakeLists.txt | 20 ++ .../{ => explosion}/data/explosion-end.png | Bin .../{ => explosion}/data/explosion-start.png | Bin effects/{ => explosion}/data/explosion.frag | 0 effects/{ => explosion}/data/explosion.vert | 0 .../explosion.cpp} | 2 +- effects/{ => explosion}/explosion.desktop | 0 .../explosion.h} | 0 effects/fade/CMakeLists.txt | 12 + effects/{ => fade}/fade.cpp | 0 effects/{ => fade}/fade.desktop | 0 effects/{ => fade}/fade.h | 0 effects/fadedesktop/CMakeLists.txt | 12 + effects/{ => fadedesktop}/fadedesktop.cpp | 0 effects/{ => fadedesktop}/fadedesktop.desktop | 0 effects/{ => fadedesktop}/fadedesktop.h | 0 effects/fallapart/CMakeLists.txt | 12 + effects/{ => fallapart}/fallapart.cpp | 0 effects/{ => fallapart}/fallapart.desktop | 0 effects/{ => fallapart}/fallapart.h | 0 effects/flipswitch/CMakeLists.txt | 26 ++ effects/{ => flipswitch}/flipswitch.cpp | 0 effects/{ => flipswitch}/flipswitch.desktop | 0 effects/{ => flipswitch}/flipswitch.h | 0 .../{ => flipswitch}/flipswitch_config.cpp | 5 +- .../flipswitch_config.desktop | 0 effects/{ => flipswitch}/flipswitch_config.h | 0 effects/{ => flipswitch}/flipswitch_config.ui | 0 effects/highlightwindow/CMakeLists.txt | 12 + .../{ => highlightwindow}/highlightwindow.cpp | 0 .../highlightwindow.desktop | 0 .../{ => highlightwindow}/highlightwindow.h | 0 effects/invert/CMakeLists.txt | 31 ++ effects/{ => invert}/data/invert.frag | 0 effects/{ => invert}/data/invert.vert | 0 effects/{ => invert}/invert.cpp | 0 effects/{ => invert}/invert.desktop | 0 effects/{ => invert}/invert.h | 0 effects/{ => invert}/invert_config.cpp | 6 +- effects/{ => invert}/invert_config.desktop | 0 effects/{ => invert}/invert_config.h | 0 effects/login/CMakeLists.txt | 12 + effects/{ => login}/login.cpp | 0 effects/{ => login}/login.desktop | 0 effects/{ => login}/login.h | 0 effects/logout/CMakeLists.txt | 12 + effects/{ => logout}/logout.cpp | 0 effects/{ => logout}/logout.desktop | 0 effects/{ => logout}/logout.h | 0 effects/lookingglass/CMakeLists.txt | 32 ++ .../{ => lookingglass}/data/lookingglass.frag | 0 .../{ => lookingglass}/data/lookingglass.vert | 0 effects/{ => lookingglass}/lookingglass.cpp | 0 .../{ => lookingglass}/lookingglass.desktop | 0 effects/{ => lookingglass}/lookingglass.h | 0 .../lookingglass_config.cpp | 4 +- .../lookingglass_config.desktop | 0 .../{ => lookingglass}/lookingglass_config.h | 0 .../{ => lookingglass}/lookingglass_config.ui | 0 effects/magiclamp/CMakeLists.txt | 26 ++ effects/{ => magiclamp}/magiclamp.cpp | 0 effects/{ => magiclamp}/magiclamp.desktop | 0 effects/{ => magiclamp}/magiclamp.h | 0 effects/{ => magiclamp}/magiclamp_config.cpp | 5 +- .../{ => magiclamp}/magiclamp_config.desktop | 0 effects/{ => magiclamp}/magiclamp_config.h | 0 effects/{ => magiclamp}/magiclamp_config.ui | 0 effects/magnifier/CMakeLists.txt | 26 ++ effects/{ => magnifier}/magnifier.cpp | 0 effects/{ => magnifier}/magnifier.desktop | 0 effects/{ => magnifier}/magnifier.h | 0 effects/{ => magnifier}/magnifier_config.cpp | 4 +- .../{ => magnifier}/magnifier_config.desktop | 0 effects/{ => magnifier}/magnifier_config.h | 0 effects/{ => magnifier}/magnifier_config.ui | 0 effects/minimizeanimation/CMakeLists.txt | 12 + .../minimizeanimation.cpp | 0 .../minimizeanimation.desktop | 0 .../minimizeanimation.h | 0 effects/mousemark/CMakeLists.txt | 26 ++ effects/{ => mousemark}/mousemark.cpp | 0 effects/{ => mousemark}/mousemark.desktop | 0 effects/{ => mousemark}/mousemark.h | 0 effects/{ => mousemark}/mousemark_config.cpp | 4 +- .../{ => mousemark}/mousemark_config.desktop | 0 effects/{ => mousemark}/mousemark_config.h | 0 effects/{ => mousemark}/mousemark_config.ui | 0 effects/presentwindows/CMakeLists.txt | 26 ++ .../{ => presentwindows}/presentwindows.cpp | 0 .../presentwindows.desktop | 0 effects/{ => presentwindows}/presentwindows.h | 0 .../presentwindows_config.cpp | 5 +- .../presentwindows_config.desktop | 0 .../presentwindows_config.h | 0 .../presentwindows_config.ui | 0 effects/scalein/CMakeLists.txt | 12 + effects/{ => scalein}/scalein.cpp | 0 effects/{ => scalein}/scalein.desktop | 0 effects/{ => scalein}/scalein.h | 0 effects/shadow/CMakeLists.txt | 31 ++ effects/{ => shadow}/data/shadow-texture.png | Bin effects/{ => shadow}/shadow.cpp | 0 effects/{ => shadow}/shadow.desktop | 0 effects/{ => shadow}/shadow.h | 0 effects/{ => shadow}/shadow_config.cpp | 5 +- effects/{ => shadow}/shadow_config.desktop | 0 effects/{ => shadow}/shadow_config.h | 0 effects/{ => shadow}/shadow_config.ui | 0 effects/{ => shadow}/shadow_helper.h | 0 effects/sharpen/CMakeLists.txt | 31 ++ effects/{ => sharpen}/data/sharpen.frag | 0 effects/{ => sharpen}/data/sharpen.vert | 0 effects/{ => sharpen}/sharpen.cpp | 0 effects/{ => sharpen}/sharpen.desktop | 0 effects/{ => sharpen}/sharpen.h | 0 effects/{ => sharpen}/sharpen_config.cpp | 6 +- effects/{ => sharpen}/sharpen_config.desktop | 0 effects/{ => sharpen}/sharpen_config.h | 0 effects/showfps/CMakeLists.txt | 26 ++ effects/{ => showfps}/showfps.cpp | 0 effects/{ => showfps}/showfps.desktop | 0 effects/{ => showfps}/showfps.h | 0 effects/{ => showfps}/showfps_config.cpp | 6 +- effects/{ => showfps}/showfps_config.desktop | 0 effects/{ => showfps}/showfps_config.h | 0 effects/{ => showfps}/showfps_config.ui | 0 effects/showpaint/CMakeLists.txt | 12 + effects/{ => showpaint}/showpaint.cpp | 0 effects/{ => showpaint}/showpaint.desktop | 0 effects/{ => showpaint}/showpaint.h | 0 effects/slide/CMakeLists.txt | 12 + effects/{ => slide}/slide.cpp | 0 effects/{ => slide}/slide.desktop | 0 effects/{ => slide}/slide.h | 0 effects/snow/CMakeLists.txt | 33 ++ effects/{ => snow}/data/snow.frag | 0 effects/{ => snow}/data/snow.vert | 0 effects/{ => snow}/data/snowflake.png | Bin effects/{ => snow}/snow.cpp | 0 effects/{ => snow}/snow.desktop | 0 effects/{ => snow}/snow.h | 0 effects/{ => snow}/snow_config.cpp | 6 +- effects/{ => snow}/snow_config.desktop | 0 effects/{ => snow}/snow_config.h | 0 effects/{ => snow}/snow_config.ui | 0 effects/taskbarthumbnail/CMakeLists.txt | 12 + .../taskbarthumbnail.cpp | 0 .../taskbarthumbnail.desktop | 0 .../{ => taskbarthumbnail}/taskbarthumbnail.h | 0 effects/thumbnailaside/CMakeLists.txt | 26 ++ .../{ => thumbnailaside}/thumbnailaside.cpp | 0 .../thumbnailaside.desktop | 0 effects/{ => thumbnailaside}/thumbnailaside.h | 0 .../thumbnailaside_config.cpp | 4 +- .../thumbnailaside_config.desktop | 0 .../thumbnailaside_config.h | 0 .../thumbnailaside_config.ui | 0 effects/trackmouse/CMakeLists.txt | 30 ++ effects/{ => trackmouse}/data/trackmouse.png | Bin effects/{ => trackmouse}/trackmouse.cpp | 0 effects/{ => trackmouse}/trackmouse.desktop | 0 effects/{ => trackmouse}/trackmouse.h | 0 .../{ => trackmouse}/trackmouse_config.cpp | 6 +- .../trackmouse_config.desktop | 0 effects/{ => trackmouse}/trackmouse_config.h | 0 effects/translucency/CMakeLists.txt | 26 ++ .../translucency.cpp} | 20 +- .../translucency.desktop} | 4 +- .../translucency.h} | 8 +- .../translucency_config.cpp} | 29 +- .../translucency_config.desktop} | 4 +- .../translucency_config.h} | 16 +- .../translucency_config.ui} | 4 +- effects/wobblywindows/CMakeLists.txt | 26 ++ effects/{ => wobblywindows}/wobblywindows.cpp | 0 .../{ => wobblywindows}/wobblywindows.desktop | 0 effects/{ => wobblywindows}/wobblywindows.h | 0 .../wobblywindows_config.cpp | 6 +- .../wobblywindows_config.desktop | 0 .../wobblywindows_config.h | 0 .../wobblywindows_config.ui | 0 effects/zoom/CMakeLists.txt | 25 ++ effects/{ => zoom}/zoom.cpp | 0 effects/{ => zoom}/zoom.desktop | 0 effects/{ => zoom}/zoom.h | 0 effects/{ => zoom}/zoom_config.cpp | 6 +- effects/{ => zoom}/zoom_config.desktop | 0 effects/{ => zoom}/zoom_config.h | 0 lib/kwineffects.h | 22 +- 309 files changed, 1046 insertions(+), 412 deletions(-) rename effects/{data => _data}/circle-edgy.png (100%) rename effects/{data => _data}/circle.png (100%) rename effects/{test => _test}/CMakeLists.txt (100%) rename effects/{test => _test}/data/liquid.frag (100%) rename effects/{test => _test}/data/liquid.vert (100%) rename effects/{test => _test}/demo_liquid.cpp (100%) rename effects/{test => _test}/demo_liquid.desktop (100%) rename effects/{test => _test}/demo_liquid.h (100%) rename effects/{test => _test}/demo_shakymove.cpp (100%) rename effects/{test => _test}/demo_shakymove.desktop (100%) rename effects/{test => _test}/demo_shakymove.h (100%) rename effects/{test => _test}/demo_shiftworkspaceup.cpp (100%) rename effects/{test => _test}/demo_shiftworkspaceup.desktop (100%) rename effects/{test => _test}/demo_shiftworkspaceup.h (100%) rename effects/{test => _test}/demo_showpicture.cpp (100%) rename effects/{test => _test}/demo_showpicture.desktop (100%) rename effects/{test => _test}/demo_showpicture.h (100%) rename effects/{test => _test}/demo_wavywindows.cpp (100%) rename effects/{test => _test}/demo_wavywindows.desktop (100%) rename effects/{test => _test}/demo_wavywindows.h (100%) rename effects/{test => _test}/drunken.cpp (100%) rename effects/{test => _test}/drunken.desktop (100%) rename effects/{test => _test}/drunken.h (100%) rename effects/{test => _test}/flame.cpp (100%) rename effects/{test => _test}/flame.desktop (100%) rename effects/{test => _test}/flame.h (100%) rename effects/{test => _test}/howto.cpp (100%) rename effects/{test => _test}/howto.desktop (100%) rename effects/{test => _test}/howto.h (100%) rename effects/{test => _test}/test_fbo.cpp (100%) rename effects/{test => _test}/test_fbo.desktop (100%) rename effects/{test => _test}/test_fbo.h (100%) rename effects/{test => _test}/test_input.cpp (100%) rename effects/{test => _test}/test_input.desktop (100%) rename effects/{test => _test}/test_input.h (100%) rename effects/{test => _test}/test_thumbnail.cpp (100%) rename effects/{test => _test}/test_thumbnail.desktop (100%) rename effects/{test => _test}/test_thumbnail.h (100%) rename effects/{test => _test}/videorecord.cpp (100%) rename effects/{test => _test}/videorecord.desktop (100%) rename effects/{test => _test}/videorecord.h (100%) rename effects/{test => _test}/videorecord_config.cpp (100%) rename effects/{test => _test}/videorecord_config.desktop (100%) rename effects/{test => _test}/videorecord_config.h (100%) create mode 100644 effects/blur/CMakeLists.txt rename effects/{ => blur}/blur.cpp (100%) rename effects/{ => blur}/blur.desktop (100%) rename effects/{ => blur}/blur.h (100%) rename effects/{ => blur}/data/blur-render.frag (100%) rename effects/{ => blur}/data/blur-render.vert (100%) rename effects/{ => blur}/data/blur.frag (100%) rename effects/{ => blur}/data/blur.vert (100%) create mode 100644 effects/boxswitch/CMakeLists.txt rename effects/{ => boxswitch}/boxswitch.cpp (100%) rename effects/{ => boxswitch}/boxswitch.desktop (100%) rename effects/{ => boxswitch}/boxswitch.h (100%) rename effects/{ => boxswitch}/boxswitch_config.cpp (99%) rename effects/{ => boxswitch}/boxswitch_config.desktop (100%) rename effects/{ => boxswitch}/boxswitch_config.h (100%) rename effects/{ => boxswitch}/boxswitch_config.ui (100%) create mode 100644 effects/coverswitch/CMakeLists.txt rename effects/{ => coverswitch}/coverswitch.cpp (100%) rename effects/{ => coverswitch}/coverswitch.desktop (100%) rename effects/{ => coverswitch}/coverswitch.h (100%) rename effects/{ => coverswitch}/coverswitch_config.cpp (99%) rename effects/{ => coverswitch}/coverswitch_config.desktop (100%) rename effects/{ => coverswitch}/coverswitch_config.h (100%) rename effects/{ => coverswitch}/coverswitch_config.ui (100%) create mode 100644 effects/cube/CMakeLists.txt rename effects/{ => cube}/cube.cpp (100%) rename effects/{ => cube}/cube.desktop (100%) rename effects/{ => cube}/cube.h (100%) rename effects/{ => cube}/cube_config.cpp (99%) rename effects/{ => cube}/cube_config.desktop (100%) rename effects/{ => cube}/cube_config.h (100%) rename effects/{ => cube}/cube_config.ui (100%) rename effects/{ => cube}/cylinder.cpp (100%) rename effects/{ => cube}/cylinder.desktop (100%) rename effects/{ => cube}/cylinder.h (100%) rename effects/{ => cube}/cylinder_config.cpp (99%) rename effects/{ => cube}/cylinder_config.desktop (100%) rename effects/{ => cube}/cylinder_config.h (100%) rename effects/{ => cube}/cylinder_config.ui (100%) rename effects/{ => cube}/data/cubecap.png (100%) rename effects/{ => cube}/data/cylinder.frag (100%) rename effects/{ => cube}/data/cylinder.vert (100%) rename effects/{ => cube}/data/sphere.vert (100%) rename effects/{ => cube}/sphere.cpp (100%) rename effects/{ => cube}/sphere.desktop (100%) rename effects/{ => cube}/sphere.h (100%) rename effects/{ => cube}/sphere_config.cpp (99%) rename effects/{ => cube}/sphere_config.desktop (100%) rename effects/{ => cube}/sphere_config.h (100%) rename effects/{ => cube}/sphere_config.ui (100%) create mode 100644 effects/desktopgrid/CMakeLists.txt rename effects/{ => desktopgrid}/desktopgrid.cpp (100%) rename effects/{ => desktopgrid}/desktopgrid.desktop (100%) rename effects/{ => desktopgrid}/desktopgrid.h (100%) rename effects/{ => desktopgrid}/desktopgrid_config.cpp (99%) rename effects/{ => desktopgrid}/desktopgrid_config.desktop (100%) rename effects/{ => desktopgrid}/desktopgrid_config.h (100%) rename effects/{ => desktopgrid}/desktopgrid_config.ui (100%) create mode 100644 effects/dialogparent/CMakeLists.txt rename effects/{ => dialogparent}/dialogparent.cpp (100%) rename effects/{ => dialogparent}/dialogparent.desktop (100%) rename effects/{ => dialogparent}/dialogparent.h (100%) create mode 100644 effects/diminactive/CMakeLists.txt rename effects/{ => diminactive}/diminactive.cpp (100%) rename effects/{ => diminactive}/diminactive.desktop (100%) rename effects/{ => diminactive}/diminactive.h (100%) rename effects/{ => diminactive}/diminactive_config.cpp (100%) rename effects/{ => diminactive}/diminactive_config.desktop (100%) rename effects/{ => diminactive}/diminactive_config.h (100%) rename effects/{ => diminactive}/diminactive_config.ui (100%) create mode 100644 effects/dimscreen/CMakeLists.txt rename effects/{ => dimscreen}/dimscreen.cpp (100%) rename effects/{ => dimscreen}/dimscreen.desktop (100%) rename effects/{ => dimscreen}/dimscreen.h (100%) create mode 100644 effects/explosion/CMakeLists.txt rename effects/{ => explosion}/data/explosion-end.png (100%) rename effects/{ => explosion}/data/explosion-start.png (100%) rename effects/{ => explosion}/data/explosion.frag (100%) rename effects/{ => explosion}/data/explosion.vert (100%) rename effects/{explosioneffect.cpp => explosion/explosion.cpp} (99%) rename effects/{ => explosion}/explosion.desktop (100%) rename effects/{explosioneffect.h => explosion/explosion.h} (100%) create mode 100644 effects/fade/CMakeLists.txt rename effects/{ => fade}/fade.cpp (100%) rename effects/{ => fade}/fade.desktop (100%) rename effects/{ => fade}/fade.h (100%) create mode 100644 effects/fadedesktop/CMakeLists.txt rename effects/{ => fadedesktop}/fadedesktop.cpp (100%) rename effects/{ => fadedesktop}/fadedesktop.desktop (100%) rename effects/{ => fadedesktop}/fadedesktop.h (100%) create mode 100644 effects/fallapart/CMakeLists.txt rename effects/{ => fallapart}/fallapart.cpp (100%) rename effects/{ => fallapart}/fallapart.desktop (100%) rename effects/{ => fallapart}/fallapart.h (100%) create mode 100644 effects/flipswitch/CMakeLists.txt rename effects/{ => flipswitch}/flipswitch.cpp (100%) rename effects/{ => flipswitch}/flipswitch.desktop (100%) rename effects/{ => flipswitch}/flipswitch.h (100%) rename effects/{ => flipswitch}/flipswitch_config.cpp (99%) rename effects/{ => flipswitch}/flipswitch_config.desktop (100%) rename effects/{ => flipswitch}/flipswitch_config.h (100%) rename effects/{ => flipswitch}/flipswitch_config.ui (100%) create mode 100644 effects/highlightwindow/CMakeLists.txt rename effects/{ => highlightwindow}/highlightwindow.cpp (100%) rename effects/{ => highlightwindow}/highlightwindow.desktop (100%) rename effects/{ => highlightwindow}/highlightwindow.h (100%) create mode 100644 effects/invert/CMakeLists.txt rename effects/{ => invert}/data/invert.frag (100%) rename effects/{ => invert}/data/invert.vert (100%) rename effects/{ => invert}/invert.cpp (100%) rename effects/{ => invert}/invert.desktop (100%) rename effects/{ => invert}/invert.h (100%) rename effects/{ => invert}/invert_config.cpp (98%) rename effects/{ => invert}/invert_config.desktop (100%) rename effects/{ => invert}/invert_config.h (100%) create mode 100644 effects/login/CMakeLists.txt rename effects/{ => login}/login.cpp (100%) rename effects/{ => login}/login.desktop (100%) rename effects/{ => login}/login.h (100%) create mode 100644 effects/logout/CMakeLists.txt rename effects/{ => logout}/logout.cpp (100%) rename effects/{ => logout}/logout.desktop (100%) rename effects/{ => logout}/logout.h (100%) create mode 100644 effects/lookingglass/CMakeLists.txt rename effects/{ => lookingglass}/data/lookingglass.frag (100%) rename effects/{ => lookingglass}/data/lookingglass.vert (100%) rename effects/{ => lookingglass}/lookingglass.cpp (100%) rename effects/{ => lookingglass}/lookingglass.desktop (100%) rename effects/{ => lookingglass}/lookingglass.h (100%) rename effects/{ => lookingglass}/lookingglass_config.cpp (100%) rename effects/{ => lookingglass}/lookingglass_config.desktop (100%) rename effects/{ => lookingglass}/lookingglass_config.h (100%) rename effects/{ => lookingglass}/lookingglass_config.ui (100%) create mode 100644 effects/magiclamp/CMakeLists.txt rename effects/{ => magiclamp}/magiclamp.cpp (100%) rename effects/{ => magiclamp}/magiclamp.desktop (100%) rename effects/{ => magiclamp}/magiclamp.h (100%) rename effects/{ => magiclamp}/magiclamp_config.cpp (98%) rename effects/{ => magiclamp}/magiclamp_config.desktop (100%) rename effects/{ => magiclamp}/magiclamp_config.h (100%) rename effects/{ => magiclamp}/magiclamp_config.ui (100%) create mode 100644 effects/magnifier/CMakeLists.txt rename effects/{ => magnifier}/magnifier.cpp (100%) rename effects/{ => magnifier}/magnifier.desktop (100%) rename effects/{ => magnifier}/magnifier.h (100%) rename effects/{ => magnifier}/magnifier_config.cpp (100%) rename effects/{ => magnifier}/magnifier_config.desktop (100%) rename effects/{ => magnifier}/magnifier_config.h (100%) rename effects/{ => magnifier}/magnifier_config.ui (100%) create mode 100644 effects/minimizeanimation/CMakeLists.txt rename effects/{ => minimizeanimation}/minimizeanimation.cpp (100%) rename effects/{ => minimizeanimation}/minimizeanimation.desktop (100%) rename effects/{ => minimizeanimation}/minimizeanimation.h (100%) create mode 100644 effects/mousemark/CMakeLists.txt rename effects/{ => mousemark}/mousemark.cpp (100%) rename effects/{ => mousemark}/mousemark.desktop (100%) rename effects/{ => mousemark}/mousemark.h (100%) rename effects/{ => mousemark}/mousemark_config.cpp (100%) rename effects/{ => mousemark}/mousemark_config.desktop (100%) rename effects/{ => mousemark}/mousemark_config.h (100%) rename effects/{ => mousemark}/mousemark_config.ui (100%) create mode 100644 effects/presentwindows/CMakeLists.txt rename effects/{ => presentwindows}/presentwindows.cpp (100%) rename effects/{ => presentwindows}/presentwindows.desktop (100%) rename effects/{ => presentwindows}/presentwindows.h (100%) rename effects/{ => presentwindows}/presentwindows_config.cpp (99%) rename effects/{ => presentwindows}/presentwindows_config.desktop (100%) rename effects/{ => presentwindows}/presentwindows_config.h (100%) rename effects/{ => presentwindows}/presentwindows_config.ui (100%) create mode 100644 effects/scalein/CMakeLists.txt rename effects/{ => scalein}/scalein.cpp (100%) rename effects/{ => scalein}/scalein.desktop (100%) rename effects/{ => scalein}/scalein.h (100%) create mode 100644 effects/shadow/CMakeLists.txt rename effects/{ => shadow}/data/shadow-texture.png (100%) rename effects/{ => shadow}/shadow.cpp (100%) rename effects/{ => shadow}/shadow.desktop (100%) rename effects/{ => shadow}/shadow.h (100%) rename effects/{ => shadow}/shadow_config.cpp (99%) rename effects/{ => shadow}/shadow_config.desktop (100%) rename effects/{ => shadow}/shadow_config.h (100%) rename effects/{ => shadow}/shadow_config.ui (100%) rename effects/{ => shadow}/shadow_helper.h (100%) create mode 100644 effects/sharpen/CMakeLists.txt rename effects/{ => sharpen}/data/sharpen.frag (100%) rename effects/{ => sharpen}/data/sharpen.vert (100%) rename effects/{ => sharpen}/sharpen.cpp (100%) rename effects/{ => sharpen}/sharpen.desktop (100%) rename effects/{ => sharpen}/sharpen.h (100%) rename effects/{ => sharpen}/sharpen_config.cpp (98%) rename effects/{ => sharpen}/sharpen_config.desktop (100%) rename effects/{ => sharpen}/sharpen_config.h (100%) create mode 100644 effects/showfps/CMakeLists.txt rename effects/{ => showfps}/showfps.cpp (100%) rename effects/{ => showfps}/showfps.desktop (100%) rename effects/{ => showfps}/showfps.h (100%) rename effects/{ => showfps}/showfps_config.cpp (99%) rename effects/{ => showfps}/showfps_config.desktop (100%) rename effects/{ => showfps}/showfps_config.h (100%) rename effects/{ => showfps}/showfps_config.ui (100%) create mode 100644 effects/showpaint/CMakeLists.txt rename effects/{ => showpaint}/showpaint.cpp (100%) rename effects/{ => showpaint}/showpaint.desktop (100%) rename effects/{ => showpaint}/showpaint.h (100%) create mode 100644 effects/slide/CMakeLists.txt rename effects/{ => slide}/slide.cpp (100%) rename effects/{ => slide}/slide.desktop (100%) rename effects/{ => slide}/slide.h (100%) create mode 100644 effects/snow/CMakeLists.txt rename effects/{ => snow}/data/snow.frag (100%) rename effects/{ => snow}/data/snow.vert (100%) rename effects/{ => snow}/data/snowflake.png (100%) rename effects/{ => snow}/snow.cpp (100%) rename effects/{ => snow}/snow.desktop (100%) rename effects/{ => snow}/snow.h (100%) rename effects/{ => snow}/snow_config.cpp (99%) rename effects/{ => snow}/snow_config.desktop (100%) rename effects/{ => snow}/snow_config.h (100%) rename effects/{ => snow}/snow_config.ui (100%) create mode 100644 effects/taskbarthumbnail/CMakeLists.txt rename effects/{ => taskbarthumbnail}/taskbarthumbnail.cpp (100%) rename effects/{ => taskbarthumbnail}/taskbarthumbnail.desktop (100%) rename effects/{ => taskbarthumbnail}/taskbarthumbnail.h (100%) create mode 100644 effects/thumbnailaside/CMakeLists.txt rename effects/{ => thumbnailaside}/thumbnailaside.cpp (100%) rename effects/{ => thumbnailaside}/thumbnailaside.desktop (100%) rename effects/{ => thumbnailaside}/thumbnailaside.h (100%) rename effects/{ => thumbnailaside}/thumbnailaside_config.cpp (100%) rename effects/{ => thumbnailaside}/thumbnailaside_config.desktop (100%) rename effects/{ => thumbnailaside}/thumbnailaside_config.h (100%) rename effects/{ => thumbnailaside}/thumbnailaside_config.ui (100%) create mode 100644 effects/trackmouse/CMakeLists.txt rename effects/{ => trackmouse}/data/trackmouse.png (100%) rename effects/{ => trackmouse}/trackmouse.cpp (100%) rename effects/{ => trackmouse}/trackmouse.desktop (100%) rename effects/{ => trackmouse}/trackmouse.h (100%) rename effects/{ => trackmouse}/trackmouse_config.cpp (98%) rename effects/{ => trackmouse}/trackmouse_config.desktop (100%) rename effects/{ => trackmouse}/trackmouse_config.h (100%) create mode 100644 effects/translucency/CMakeLists.txt rename effects/{maketransparent.cpp => translucency/translucency.cpp} (91%) rename effects/{maketransparent.desktop => translucency/translucency.desktop} (98%) rename effects/{maketransparent.h => translucency/translucency.h} (94%) rename effects/{maketransparent_config.cpp => translucency/translucency_config.cpp} (86%) rename effects/{maketransparent_config.desktop => translucency/translucency_config.desktop} (96%) rename effects/{maketransparent_config.h => translucency/translucency_config.h} (69%) rename effects/{maketransparent_config.ui => translucency/translucency_config.ui} (99%) create mode 100644 effects/wobblywindows/CMakeLists.txt rename effects/{ => wobblywindows}/wobblywindows.cpp (100%) rename effects/{ => wobblywindows}/wobblywindows.desktop (100%) rename effects/{ => wobblywindows}/wobblywindows.h (100%) rename effects/{ => wobblywindows}/wobblywindows_config.cpp (99%) rename effects/{ => wobblywindows}/wobblywindows_config.desktop (100%) rename effects/{ => wobblywindows}/wobblywindows_config.h (100%) rename effects/{ => wobblywindows}/wobblywindows_config.ui (100%) create mode 100644 effects/zoom/CMakeLists.txt rename effects/{ => zoom}/zoom.cpp (100%) rename effects/{ => zoom}/zoom.desktop (100%) rename effects/{ => zoom}/zoom.h (100%) rename effects/{ => zoom}/zoom_config.cpp (99%) rename effects/{ => zoom}/zoom_config.desktop (100%) rename effects/{ => zoom}/zoom_config.h (100%) diff --git a/effects/CMakeLists.txt b/effects/CMakeLists.txt index 62c4b08d18..5782681013 100644 --- a/effects/CMakeLists.txt +++ b/effects/CMakeLists.txt @@ -1,235 +1,104 @@ -# Uncomment to have the test effects built -#add_subdirectory( test ) - +# Uncomment to have the test effects built as well +#add_subdirectory( _test ) # Adds effect plugin with given name. Sources are given after the name -macro(KWIN4_ADD_EFFECT name) - kde4_add_plugin(kwin4_effect_${name} ${ARGN}) - target_link_libraries(kwin4_effect_${name} kwineffects ${KDE4_KDEUI_LIBS} kephal) - install(TARGETS kwin4_effect_${name} DESTINATION ${PLUGIN_INSTALL_DIR}) -endmacro(KWIN4_ADD_EFFECT) +macro( KWIN4_ADD_EFFECT name ) + kde4_add_plugin( kwin4_effect_${name} ${ARGN} ) + target_link_libraries( kwin4_effect_${name} kwineffects ${KDE4_KDEUI_LIBS} kephal ) + install( TARGETS kwin4_effect_${name} DESTINATION ${PLUGIN_INSTALL_DIR} ) +endmacro( KWIN4_ADD_EFFECT ) -macro(KWIN4_ADD_EFFECT_CONFIG name) - set(kwin4_effect_ui ) #empty - set(kwin4_effect_src ) #empty - foreach(file ${ARGN}) - if(file MATCHES \\.ui) - set(kwin4_effect_ui ${kwin4_effect_ui} ${file}) - else(file MATCHES \\.ui) - set(kwin4_effect_src ${kwin4_effect_src} ${file}) - endif(file MATCHES \\.ui) - endforeach(file) - kde4_add_ui_files(kwin4_effect_src ${kwin4_effect_ui}) - kde4_add_plugin(kcm_kwin4_effect_${name} ${kwin4_effect_src}) - target_link_libraries(kcm_kwin4_effect_${name} kwineffects ${KDE4_KIO_LIBS} ${KDE4_KDEUI_LIBS} kephal) - install(TARGETS kcm_kwin4_effect_${name} DESTINATION ${PLUGIN_INSTALL_DIR}) -endmacro(KWIN4_ADD_EFFECT_CONFIG) +macro( KWIN4_ADD_EFFECT_CONFIG name ) + set( kwin4_effect_ui ) # Initially empty + set( kwin4_effect_src ) # Initially empty + foreach( file ${ARGN} ) + if( file MATCHES \\.ui ) + set( kwin4_effect_ui ${kwin4_effect_ui} ${file} ) + else( file MATCHES \\.ui ) + set( kwin4_effect_src ${kwin4_effect_src} ${file} ) + endif( file MATCHES \\.ui ) + endforeach( file ) + + kde4_add_ui_files( kwin4_effect_src ${kwin4_effect_ui} ) + kde4_add_plugin( kcm_kwin4_effect_${name} ${kwin4_effect_src} ) + target_link_libraries( kcm_kwin4_effect_${name} kwineffects ${KDE4_KIO_LIBS} ${KDE4_KDEUI_LIBS} kephal ) + install( TARGETS kcm_kwin4_effect_${name} DESTINATION ${PLUGIN_INSTALL_DIR} ) +endmacro( KWIN4_ADD_EFFECT_CONFIG ) + +macro( KWIN4_EFFECT_LINK_XRENDER name ) + if( KWIN_HAVE_XRENDER_COMPOSITING ) + target_link_libraries( kwin4_effect_${name} ${X11_Xrender_LIB} ${X11_LIBRARIES} kephal ) + endif( KWIN_HAVE_XRENDER_COMPOSITING ) +endmacro( KWIN4_EFFECT_LINK_XRENDER ) + +# Make sure we can see our libraries include_directories( ${KDEBASE_WORKSPACE_SOURCE_DIR}/kwin/lib ) -install( FILES kwineffect.desktop DESTINATION ${SERVICETYPES_INSTALL_DIR}) +# Install the KWin/Effect service type +install( FILES kwineffect.desktop DESTINATION ${SERVICETYPES_INSTALL_DIR} ) -### builtins - most important, ready-to-use effects -# sources -SET(kwin4_effect_builtins_sources - boxswitch.cpp - desktopgrid.cpp - dialogparent.cpp - diminactive.cpp - dimscreen.cpp - fade.cpp - fadedesktop.cpp - fallapart.cpp - highlightwindow.cpp - login.cpp - logout.cpp - magiclamp.cpp - maketransparent.cpp - minimizeanimation.cpp - presentwindows.cpp - scalein.cpp - shadow.cpp - showfps.cpp - showpaint.cpp - slide.cpp - taskbarthumbnail.cpp - thumbnailaside.cpp - zoom.cpp - ) -# their .desktop files +# Create initial variables +set( kwin4_effect_builtins_sources ) +set( kwin4_effect_builtins_config_sources configs_builtins.cpp ) +set( kwin4_effect_include_directories ) + +############################################################################### +# Built-in effects go here + +# Common effects +include( boxswitch/CMakeLists.txt ) +include( desktopgrid/CMakeLists.txt ) +include( dialogparent/CMakeLists.txt ) +include( diminactive/CMakeLists.txt ) +include( dimscreen/CMakeLists.txt ) +include( fade/CMakeLists.txt ) +include( fadedesktop/CMakeLists.txt ) +include( fallapart/CMakeLists.txt ) +include( highlightwindow/CMakeLists.txt ) +include( login/CMakeLists.txt ) +include( logout/CMakeLists.txt ) +include( magiclamp/CMakeLists.txt ) +include( translucency/CMakeLists.txt ) +include( minimizeanimation/CMakeLists.txt ) +include( presentwindows/CMakeLists.txt ) +include( scalein/CMakeLists.txt ) +include( shadow/CMakeLists.txt ) +include( showfps/CMakeLists.txt ) +include( showpaint/CMakeLists.txt ) +include( slide/CMakeLists.txt ) +include( taskbarthumbnail/CMakeLists.txt ) +include( thumbnailaside/CMakeLists.txt ) +include( zoom/CMakeLists.txt ) + +# OpenGL-specific effects +if( KWIN_HAVE_OPENGL_COMPOSITING ) + include( blur/CMakeLists.txt ) + include( coverswitch/CMakeLists.txt ) + include( cube/CMakeLists.txt ) + include( explosion/CMakeLists.txt ) + include( flipswitch/CMakeLists.txt ) + include( invert/CMakeLists.txt ) + include( lookingglass/CMakeLists.txt ) + include( magnifier/CMakeLists.txt ) + include( mousemark/CMakeLists.txt ) + include( sharpen/CMakeLists.txt ) + include( snow/CMakeLists.txt ) + include( trackmouse/CMakeLists.txt ) + include( wobblywindows/CMakeLists.txt ) +endif( KWIN_HAVE_OPENGL_COMPOSITING ) + +############################################################################### + +# Add the builtins plugin +KWIN4_ADD_EFFECT( builtins ${kwin4_effect_builtins_sources} ) +KWIN4_ADD_EFFECT_CONFIG( builtins ${kwin4_effect_builtins_config_sources} ) +KWIN4_EFFECT_LINK_XRENDER( builtins ) + +# Install global data files install( FILES - boxswitch.desktop - desktopgrid.desktop - dialogparent.desktop - diminactive.desktop - dimscreen.desktop - fade.desktop - fadedesktop.desktop - fallapart.desktop - highlightwindow.desktop - login.desktop - logout.desktop - magiclamp.desktop - maketransparent.desktop - minimizeanimation.desktop - presentwindows.desktop - scalein.desktop - shadow.desktop - showfps.desktop - showpaint.desktop - slide.desktop - taskbarthumbnail.desktop - thumbnailaside.desktop - zoom.desktop - DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) - -# config modules -SET(kwin4_effect_builtins_config_sources - boxswitch_config.cpp - boxswitch_config.ui - desktopgrid_config.cpp - desktopgrid_config.ui - diminactive_config.cpp - diminactive_config.ui - magiclamp_config.cpp - magiclamp_config.ui - maketransparent_config.cpp - maketransparent_config.ui - presentwindows_config.cpp - presentwindows_config.ui - shadow_config.cpp - shadow_config.ui - showfps_config.cpp - showfps_config.ui - thumbnailaside_config.cpp - thumbnailaside_config.ui - zoom_config.cpp - configs_builtins.cpp) -install( FILES - boxswitch_config.desktop - desktopgrid_config.desktop - diminactive_config.desktop - magiclamp_config.desktop - maketransparent_config.desktop - presentwindows_config.desktop - shadow_config.desktop - showfps_config.desktop - thumbnailaside_config.desktop - zoom_config.desktop - DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) - -if(KWIN_HAVE_OPENGL_COMPOSITING) - # opengl-based effects - SET(kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} - blur.cpp - coverswitch.cpp - cube.cpp - cylinder.cpp - explosioneffect.cpp - flipswitch.cpp - invert.cpp - lookingglass.cpp - magnifier.cpp - mousemark.cpp - sharpen.cpp - sphere.cpp - snow.cpp - trackmouse.cpp - wobblywindows.cpp - ) - install( FILES - blur.desktop - coverswitch.desktop - cube.desktop - cylinder.desktop - explosion.desktop - flipswitch.desktop - invert.desktop - lookingglass.desktop - magnifier.desktop - mousemark.desktop - sharpen.desktop - sphere.desktop - snow.desktop - trackmouse.desktop - wobblywindows.desktop - DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) - install( FILES - data/trackmouse.png - data/explosion.frag - data/explosion.vert - data/explosion-start.png - data/explosion-end.png - data/blur.frag - data/blur.vert - data/blur-render.frag - data/blur-render.vert - data/invert.frag - data/invert.vert - data/sharpen.frag - data/sharpen.vert - data/lookingglass.frag - data/lookingglass.vert - data/shadow-texture.png - data/snow.frag - data/snow.vert - data/snowflake.png - data/circle.png - data/circle-edgy.png - data/cubecap.png - data/cylinder.frag - data/cylinder.vert - data/sphere.vert - DESTINATION ${DATA_INSTALL_DIR}/kwin ) - SET(kwin4_effect_builtins_config_sources ${kwin4_effect_builtins_config_sources} - coverswitch_config.cpp - coverswitch_config.ui - cube_config.cpp - cube_config.ui - cylinder_config.cpp - cylinder_config.ui - flipswitch_config.cpp - flipswitch_config.ui - invert_config.cpp - lookingglass_config.cpp - lookingglass_config.ui - magnifier_config.cpp - magnifier_config.ui - mousemark_config.cpp - mousemark_config.ui - sharpen_config.cpp - snow_config.cpp - snow_config.ui - sphere_config.cpp - sphere_config.ui - trackmouse_config.cpp - wobblywindows_config.cpp - wobblywindows_config.ui - ) - install( FILES - coverswitch_config.desktop - cube_config.desktop - cylinder_config.desktop - flipswitch_config.desktop - invert_config.desktop - lookingglass_config.desktop - magnifier_config.desktop - mousemark_config.desktop - sharpen_config.desktop - snow_config.desktop - sphere_config.desktop - trackmouse_config.desktop - wobblywindows_config.desktop - DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) -endif(KWIN_HAVE_OPENGL_COMPOSITING) - -# add the plugin -KWIN4_ADD_EFFECT(builtins ${kwin4_effect_builtins_sources}) -KWIN4_ADD_EFFECT_CONFIG(builtins ${kwin4_effect_builtins_config_sources}) -# link to xrender if necessary -if (KWIN_HAVE_XRENDER_COMPOSITING) - target_link_libraries(kwin4_effect_builtins ${X11_Xrender_LIB} ${X11_LIBRARIES} kephal) -endif (KWIN_HAVE_XRENDER_COMPOSITING) - + _data/circle-edgy.png + _data/circle.png + DESTINATION ${DATA_INSTALL_DIR}/kwin ) diff --git a/effects/data/circle-edgy.png b/effects/_data/circle-edgy.png similarity index 100% rename from effects/data/circle-edgy.png rename to effects/_data/circle-edgy.png diff --git a/effects/data/circle.png b/effects/_data/circle.png similarity index 100% rename from effects/data/circle.png rename to effects/_data/circle.png diff --git a/effects/test/CMakeLists.txt b/effects/_test/CMakeLists.txt similarity index 100% rename from effects/test/CMakeLists.txt rename to effects/_test/CMakeLists.txt diff --git a/effects/test/data/liquid.frag b/effects/_test/data/liquid.frag similarity index 100% rename from effects/test/data/liquid.frag rename to effects/_test/data/liquid.frag diff --git a/effects/test/data/liquid.vert b/effects/_test/data/liquid.vert similarity index 100% rename from effects/test/data/liquid.vert rename to effects/_test/data/liquid.vert diff --git a/effects/test/demo_liquid.cpp b/effects/_test/demo_liquid.cpp similarity index 100% rename from effects/test/demo_liquid.cpp rename to effects/_test/demo_liquid.cpp diff --git a/effects/test/demo_liquid.desktop b/effects/_test/demo_liquid.desktop similarity index 100% rename from effects/test/demo_liquid.desktop rename to effects/_test/demo_liquid.desktop diff --git a/effects/test/demo_liquid.h b/effects/_test/demo_liquid.h similarity index 100% rename from effects/test/demo_liquid.h rename to effects/_test/demo_liquid.h diff --git a/effects/test/demo_shakymove.cpp b/effects/_test/demo_shakymove.cpp similarity index 100% rename from effects/test/demo_shakymove.cpp rename to effects/_test/demo_shakymove.cpp diff --git a/effects/test/demo_shakymove.desktop b/effects/_test/demo_shakymove.desktop similarity index 100% rename from effects/test/demo_shakymove.desktop rename to effects/_test/demo_shakymove.desktop diff --git a/effects/test/demo_shakymove.h b/effects/_test/demo_shakymove.h similarity index 100% rename from effects/test/demo_shakymove.h rename to effects/_test/demo_shakymove.h diff --git a/effects/test/demo_shiftworkspaceup.cpp b/effects/_test/demo_shiftworkspaceup.cpp similarity index 100% rename from effects/test/demo_shiftworkspaceup.cpp rename to effects/_test/demo_shiftworkspaceup.cpp diff --git a/effects/test/demo_shiftworkspaceup.desktop b/effects/_test/demo_shiftworkspaceup.desktop similarity index 100% rename from effects/test/demo_shiftworkspaceup.desktop rename to effects/_test/demo_shiftworkspaceup.desktop diff --git a/effects/test/demo_shiftworkspaceup.h b/effects/_test/demo_shiftworkspaceup.h similarity index 100% rename from effects/test/demo_shiftworkspaceup.h rename to effects/_test/demo_shiftworkspaceup.h diff --git a/effects/test/demo_showpicture.cpp b/effects/_test/demo_showpicture.cpp similarity index 100% rename from effects/test/demo_showpicture.cpp rename to effects/_test/demo_showpicture.cpp diff --git a/effects/test/demo_showpicture.desktop b/effects/_test/demo_showpicture.desktop similarity index 100% rename from effects/test/demo_showpicture.desktop rename to effects/_test/demo_showpicture.desktop diff --git a/effects/test/demo_showpicture.h b/effects/_test/demo_showpicture.h similarity index 100% rename from effects/test/demo_showpicture.h rename to effects/_test/demo_showpicture.h diff --git a/effects/test/demo_wavywindows.cpp b/effects/_test/demo_wavywindows.cpp similarity index 100% rename from effects/test/demo_wavywindows.cpp rename to effects/_test/demo_wavywindows.cpp diff --git a/effects/test/demo_wavywindows.desktop b/effects/_test/demo_wavywindows.desktop similarity index 100% rename from effects/test/demo_wavywindows.desktop rename to effects/_test/demo_wavywindows.desktop diff --git a/effects/test/demo_wavywindows.h b/effects/_test/demo_wavywindows.h similarity index 100% rename from effects/test/demo_wavywindows.h rename to effects/_test/demo_wavywindows.h diff --git a/effects/test/drunken.cpp b/effects/_test/drunken.cpp similarity index 100% rename from effects/test/drunken.cpp rename to effects/_test/drunken.cpp diff --git a/effects/test/drunken.desktop b/effects/_test/drunken.desktop similarity index 100% rename from effects/test/drunken.desktop rename to effects/_test/drunken.desktop diff --git a/effects/test/drunken.h b/effects/_test/drunken.h similarity index 100% rename from effects/test/drunken.h rename to effects/_test/drunken.h diff --git a/effects/test/flame.cpp b/effects/_test/flame.cpp similarity index 100% rename from effects/test/flame.cpp rename to effects/_test/flame.cpp diff --git a/effects/test/flame.desktop b/effects/_test/flame.desktop similarity index 100% rename from effects/test/flame.desktop rename to effects/_test/flame.desktop diff --git a/effects/test/flame.h b/effects/_test/flame.h similarity index 100% rename from effects/test/flame.h rename to effects/_test/flame.h diff --git a/effects/test/howto.cpp b/effects/_test/howto.cpp similarity index 100% rename from effects/test/howto.cpp rename to effects/_test/howto.cpp diff --git a/effects/test/howto.desktop b/effects/_test/howto.desktop similarity index 100% rename from effects/test/howto.desktop rename to effects/_test/howto.desktop diff --git a/effects/test/howto.h b/effects/_test/howto.h similarity index 100% rename from effects/test/howto.h rename to effects/_test/howto.h diff --git a/effects/test/test_fbo.cpp b/effects/_test/test_fbo.cpp similarity index 100% rename from effects/test/test_fbo.cpp rename to effects/_test/test_fbo.cpp diff --git a/effects/test/test_fbo.desktop b/effects/_test/test_fbo.desktop similarity index 100% rename from effects/test/test_fbo.desktop rename to effects/_test/test_fbo.desktop diff --git a/effects/test/test_fbo.h b/effects/_test/test_fbo.h similarity index 100% rename from effects/test/test_fbo.h rename to effects/_test/test_fbo.h diff --git a/effects/test/test_input.cpp b/effects/_test/test_input.cpp similarity index 100% rename from effects/test/test_input.cpp rename to effects/_test/test_input.cpp diff --git a/effects/test/test_input.desktop b/effects/_test/test_input.desktop similarity index 100% rename from effects/test/test_input.desktop rename to effects/_test/test_input.desktop diff --git a/effects/test/test_input.h b/effects/_test/test_input.h similarity index 100% rename from effects/test/test_input.h rename to effects/_test/test_input.h diff --git a/effects/test/test_thumbnail.cpp b/effects/_test/test_thumbnail.cpp similarity index 100% rename from effects/test/test_thumbnail.cpp rename to effects/_test/test_thumbnail.cpp diff --git a/effects/test/test_thumbnail.desktop b/effects/_test/test_thumbnail.desktop similarity index 100% rename from effects/test/test_thumbnail.desktop rename to effects/_test/test_thumbnail.desktop diff --git a/effects/test/test_thumbnail.h b/effects/_test/test_thumbnail.h similarity index 100% rename from effects/test/test_thumbnail.h rename to effects/_test/test_thumbnail.h diff --git a/effects/test/videorecord.cpp b/effects/_test/videorecord.cpp similarity index 100% rename from effects/test/videorecord.cpp rename to effects/_test/videorecord.cpp diff --git a/effects/test/videorecord.desktop b/effects/_test/videorecord.desktop similarity index 100% rename from effects/test/videorecord.desktop rename to effects/_test/videorecord.desktop diff --git a/effects/test/videorecord.h b/effects/_test/videorecord.h similarity index 100% rename from effects/test/videorecord.h rename to effects/_test/videorecord.h diff --git a/effects/test/videorecord_config.cpp b/effects/_test/videorecord_config.cpp similarity index 100% rename from effects/test/videorecord_config.cpp rename to effects/_test/videorecord_config.cpp diff --git a/effects/test/videorecord_config.desktop b/effects/_test/videorecord_config.desktop similarity index 100% rename from effects/test/videorecord_config.desktop rename to effects/_test/videorecord_config.desktop diff --git a/effects/test/videorecord_config.h b/effects/_test/videorecord_config.h similarity index 100% rename from effects/test/videorecord_config.h rename to effects/_test/videorecord_config.h diff --git a/effects/blur/CMakeLists.txt b/effects/blur/CMakeLists.txt new file mode 100644 index 0000000000..2dd7dc6756 --- /dev/null +++ b/effects/blur/CMakeLists.txt @@ -0,0 +1,20 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + blur/blur.cpp + ) + +# .desktop files +install( FILES + blur/blur.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) + +# Data files +install( FILES + blur/data/blur.frag + blur/data/blur.vert + blur/data/blur-render.frag + blur/data/blur-render.vert + DESTINATION ${DATA_INSTALL_DIR}/kwin ) diff --git a/effects/blur.cpp b/effects/blur/blur.cpp similarity index 100% rename from effects/blur.cpp rename to effects/blur/blur.cpp diff --git a/effects/blur.desktop b/effects/blur/blur.desktop similarity index 100% rename from effects/blur.desktop rename to effects/blur/blur.desktop diff --git a/effects/blur.h b/effects/blur/blur.h similarity index 100% rename from effects/blur.h rename to effects/blur/blur.h diff --git a/effects/data/blur-render.frag b/effects/blur/data/blur-render.frag similarity index 100% rename from effects/data/blur-render.frag rename to effects/blur/data/blur-render.frag diff --git a/effects/data/blur-render.vert b/effects/blur/data/blur-render.vert similarity index 100% rename from effects/data/blur-render.vert rename to effects/blur/data/blur-render.vert diff --git a/effects/data/blur.frag b/effects/blur/data/blur.frag similarity index 100% rename from effects/data/blur.frag rename to effects/blur/data/blur.frag diff --git a/effects/data/blur.vert b/effects/blur/data/blur.vert similarity index 100% rename from effects/data/blur.vert rename to effects/blur/data/blur.vert diff --git a/effects/boxswitch/CMakeLists.txt b/effects/boxswitch/CMakeLists.txt new file mode 100644 index 0000000000..5ed180a022 --- /dev/null +++ b/effects/boxswitch/CMakeLists.txt @@ -0,0 +1,26 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + boxswitch/boxswitch.cpp + ) + +# .desktop files +install( FILES + boxswitch/boxswitch.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) + +####################################### +# Config + +# Source files +set( kwin4_effect_builtins_config_sources ${kwin4_effect_builtins_config_sources} + boxswitch/boxswitch_config.cpp + boxswitch/boxswitch_config.ui + ) + +# .desktop files +install( FILES + boxswitch/boxswitch_config.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/boxswitch.cpp b/effects/boxswitch/boxswitch.cpp similarity index 100% rename from effects/boxswitch.cpp rename to effects/boxswitch/boxswitch.cpp diff --git a/effects/boxswitch.desktop b/effects/boxswitch/boxswitch.desktop similarity index 100% rename from effects/boxswitch.desktop rename to effects/boxswitch/boxswitch.desktop diff --git a/effects/boxswitch.h b/effects/boxswitch/boxswitch.h similarity index 100% rename from effects/boxswitch.h rename to effects/boxswitch/boxswitch.h diff --git a/effects/boxswitch_config.cpp b/effects/boxswitch/boxswitch_config.cpp similarity index 99% rename from effects/boxswitch_config.cpp rename to effects/boxswitch/boxswitch_config.cpp index a48ee808e7..ae4c0e15aa 100644 --- a/effects/boxswitch_config.cpp +++ b/effects/boxswitch/boxswitch_config.cpp @@ -24,13 +24,12 @@ along with this program. If not, see . #include #include -#ifndef KDE_USE_FINAL -KWIN_EFFECT_CONFIG_FACTORY -#endif namespace KWin { +KWIN_EFFECT_CONFIG_FACTORY + BoxSwitchEffectConfigForm::BoxSwitchEffectConfigForm(QWidget* parent) : QWidget(parent) { setupUi(this); diff --git a/effects/boxswitch_config.desktop b/effects/boxswitch/boxswitch_config.desktop similarity index 100% rename from effects/boxswitch_config.desktop rename to effects/boxswitch/boxswitch_config.desktop diff --git a/effects/boxswitch_config.h b/effects/boxswitch/boxswitch_config.h similarity index 100% rename from effects/boxswitch_config.h rename to effects/boxswitch/boxswitch_config.h diff --git a/effects/boxswitch_config.ui b/effects/boxswitch/boxswitch_config.ui similarity index 100% rename from effects/boxswitch_config.ui rename to effects/boxswitch/boxswitch_config.ui diff --git a/effects/configs_builtins.cpp b/effects/configs_builtins.cpp index 3a1a9a7846..35b0cdb451 100644 --- a/effects/configs_builtins.cpp +++ b/effects/configs_builtins.cpp @@ -4,6 +4,7 @@ Copyright (C) 2007 Bernhard Loos Copyright (C) 2007 Christian Nitschkowski +Copyright (C) 2009 Lucas Murray This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -21,93 +22,67 @@ along with this program. If not, see . #include -#include "boxswitch_config.h" -#include "desktopgrid_config.h" -#include "diminactive_config.h" -#include "magiclamp_config.h" -#include "maketransparent_config.h" -#include "presentwindows_config.h" -#include "shadow_config.h" -#include "showfps_config.h" -#include "thumbnailaside_config.h" -#include "zoom_config.h" - +#include "boxswitch/boxswitch_config.h" +#include "desktopgrid/desktopgrid_config.h" +#include "diminactive/diminactive_config.h" +#include "magiclamp/magiclamp_config.h" +#include "translucency/translucency_config.h" +#include "presentwindows/presentwindows_config.h" +#include "shadow/shadow_config.h" +#include "showfps/showfps_config.h" +#include "thumbnailaside/thumbnailaside_config.h" +#include "zoom/zoom_config.h" #ifdef KWIN_HAVE_OPENGL_COMPOSITING -#include "coverswitch_config.h" -#include "cube_config.h" -#include "cylinder_config.h" -#include "flipswitch_config.h" -#include "invert_config.h" -#include "lookingglass_config.h" -#include "mousemark_config.h" -#include "magnifier_config.h" -#include "sharpen_config.h" -#include "snow_config.h" -#include "sphere_config.h" -#include "trackmouse_config.h" -#include "wobblywindows_config.h" -#endif -#ifdef KWIN_HAVE_XRENDER_COMPOSITING -// xrender-only here if any -#endif -#ifdef HAVE_CAPTURY -#include "videorecord_config.h" +#include "coverswitch/coverswitch_config.h" +#include "cube/cube_config.h" +#include "cube/cylinder_config.h" +#include "cube/sphere_config.h" +#include "flipswitch/flipswitch_config.h" +#include "invert/invert_config.h" +#include "lookingglass/lookingglass_config.h" +#include "mousemark/mousemark_config.h" +#include "magnifier/magnifier_config.h" +#include "sharpen/sharpen_config.h" +#include "snow/snow_config.h" +#include "trackmouse/trackmouse_config.h" +#include "wobblywindows/wobblywindows_config.h" #endif #include #include -#ifndef KDE_USE_FINAL -KWIN_EFFECT_CONFIG_FACTORY -#endif -#define COMMON_PLUGINS \ - registerPlugin("boxswitch"); \ - registerPlugin("desktopgrid"); \ - registerPlugin("diminactive"); \ - registerPlugin("magiclamp"); \ - registerPlugin("maketransparent"); \ - registerPlugin("presentwindows"); \ - registerPlugin("shadow"); \ - registerPlugin ("showfps"); \ - registerPlugin("thumbnailaside"); \ - registerPlugin("zoom"); +namespace KWin +{ -#define OPENGL_PLUGINS \ - registerPlugin("coverswitch"); \ - registerPlugin("cube"); \ - registerPlugin("cylinder"); \ - registerPlugin("flipswitch"); \ - registerPlugin("invert"); \ - registerPlugin("lookingglass"); \ - registerPlugin("mousemark"); \ - registerPlugin("magnifier"); \ - registerPlugin("sharpen"); \ - registerPlugin("snow"); \ - registerPlugin("sphere"); \ - registerPlugin("trackmouse"); \ - registerPlugin ("wobblywindows"); +KWIN_EFFECT_CONFIG_MULTIPLE( builtins, + KWIN_EFFECT_CONFIG_SINGLE( boxswitch, BoxSwitchEffectConfig ) + KWIN_EFFECT_CONFIG_SINGLE( desktopgrid, DesktopGridEffectConfig ) + KWIN_EFFECT_CONFIG_SINGLE( diminactive, DimInactiveEffectConfig ) + KWIN_EFFECT_CONFIG_SINGLE( magiclamp, MagicLampEffectConfig ) + KWIN_EFFECT_CONFIG_SINGLE( translucency, TranslucencyEffectConfig ) + KWIN_EFFECT_CONFIG_SINGLE( presentwindows, PresentWindowsEffectConfig ) + KWIN_EFFECT_CONFIG_SINGLE( shadow, ShadowEffectConfig ) + KWIN_EFFECT_CONFIG_SINGLE( showfps, ShowFpsEffectConfig ) + KWIN_EFFECT_CONFIG_SINGLE( thumbnailaside, ThumbnailAsideEffectConfig ) + KWIN_EFFECT_CONFIG_SINGLE( zoom, ZoomEffectConfig ) -#define XRENDER_PLUGINS -#define CAPTURY_PLUGINS \ - registerPlugin ("videorecord"); - -K_PLUGIN_FACTORY_DEFINITION(EffectFactory, - COMMON_PLUGINS #ifdef KWIN_HAVE_OPENGL_COMPOSITING - OPENGL_PLUGINS -#endif -#ifdef KWIN_HAVE_XRENDER_COMPOSITING - XRENDER_PLUGINS -#endif -#ifdef HAVE_CAPTURY - CAPTURY_PLUGINS + KWIN_EFFECT_CONFIG_SINGLE( coverswitch, CoverSwitchEffectConfig ) + KWIN_EFFECT_CONFIG_SINGLE( cube, CubeEffectConfig ) + KWIN_EFFECT_CONFIG_SINGLE( cylinder, CylinderEffectConfig ) + KWIN_EFFECT_CONFIG_SINGLE( sphere, SphereEffectConfig ) + KWIN_EFFECT_CONFIG_SINGLE( flipswitch, FlipSwitchEffectConfig ) + KWIN_EFFECT_CONFIG_SINGLE( invert, InvertEffectConfig ) + KWIN_EFFECT_CONFIG_SINGLE( lookingglass, LookingGlassEffectConfig ) + KWIN_EFFECT_CONFIG_SINGLE( mousemark, MouseMarkEffectConfig ) + KWIN_EFFECT_CONFIG_SINGLE( magnifier, MagnifierEffectConfig ) + KWIN_EFFECT_CONFIG_SINGLE( sharpen, SharpenEffectConfig ) + KWIN_EFFECT_CONFIG_SINGLE( snow, SnowEffectConfig ) + KWIN_EFFECT_CONFIG_SINGLE( trackmouse, TrackMouseEffectConfig ) + KWIN_EFFECT_CONFIG_SINGLE( wobblywindows, WobblyWindowsEffectConfig ) #endif ) -K_EXPORT_PLUGIN(EffectFactory("kwin")) -#undef COMMON_PLUGINS -#undef OPENGL_PLUGINS -#undef XRENDER_PLUGINS -#undef CAPTURY_PLUGINS +} // namespace diff --git a/effects/coverswitch/CMakeLists.txt b/effects/coverswitch/CMakeLists.txt new file mode 100644 index 0000000000..cc08dcbe12 --- /dev/null +++ b/effects/coverswitch/CMakeLists.txt @@ -0,0 +1,26 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + coverswitch/coverswitch.cpp + ) + +# .desktop files +install( FILES + coverswitch/coverswitch.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) + +####################################### +# Config + +# Source files +set( kwin4_effect_builtins_config_sources ${kwin4_effect_builtins_config_sources} + coverswitch/coverswitch_config.cpp + coverswitch/coverswitch_config.ui + ) + +# .desktop files +install( FILES + coverswitch/coverswitch_config.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/coverswitch.cpp b/effects/coverswitch/coverswitch.cpp similarity index 100% rename from effects/coverswitch.cpp rename to effects/coverswitch/coverswitch.cpp diff --git a/effects/coverswitch.desktop b/effects/coverswitch/coverswitch.desktop similarity index 100% rename from effects/coverswitch.desktop rename to effects/coverswitch/coverswitch.desktop diff --git a/effects/coverswitch.h b/effects/coverswitch/coverswitch.h similarity index 100% rename from effects/coverswitch.h rename to effects/coverswitch/coverswitch.h diff --git a/effects/coverswitch_config.cpp b/effects/coverswitch/coverswitch_config.cpp similarity index 99% rename from effects/coverswitch_config.cpp rename to effects/coverswitch/coverswitch_config.cpp index b4da1b84c1..a18b9874d1 100644 --- a/effects/coverswitch_config.cpp +++ b/effects/coverswitch/coverswitch_config.cpp @@ -23,13 +23,12 @@ along with this program. If not, see . #include #include -#ifndef KDE_USE_FINAL -KWIN_EFFECT_CONFIG_FACTORY -#endif namespace KWin { +KWIN_EFFECT_CONFIG_FACTORY + CoverSwitchEffectConfigForm::CoverSwitchEffectConfigForm(QWidget* parent) : QWidget(parent) { setupUi(this); diff --git a/effects/coverswitch_config.desktop b/effects/coverswitch/coverswitch_config.desktop similarity index 100% rename from effects/coverswitch_config.desktop rename to effects/coverswitch/coverswitch_config.desktop diff --git a/effects/coverswitch_config.h b/effects/coverswitch/coverswitch_config.h similarity index 100% rename from effects/coverswitch_config.h rename to effects/coverswitch/coverswitch_config.h diff --git a/effects/coverswitch_config.ui b/effects/coverswitch/coverswitch_config.ui similarity index 100% rename from effects/coverswitch_config.ui rename to effects/coverswitch/coverswitch_config.ui diff --git a/effects/cube/CMakeLists.txt b/effects/cube/CMakeLists.txt new file mode 100644 index 0000000000..9829f3c73f --- /dev/null +++ b/effects/cube/CMakeLists.txt @@ -0,0 +1,44 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + cube/cube.cpp + cube/cylinder.cpp + cube/sphere.cpp + ) + +# .desktop files +install( FILES + cube/cube.desktop + cube/cylinder.desktop + cube/sphere.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) + +# Data files +install( FILES + cube/data/cubecap.png + cube/data/cylinder.frag + cube/data/cylinder.vert + cube/data/sphere.vert + DESTINATION ${DATA_INSTALL_DIR}/kwin ) + +####################################### +# Config + +# Source files +set( kwin4_effect_builtins_config_sources ${kwin4_effect_builtins_config_sources} + cube/cube_config.cpp + cube/cube_config.ui + cube/cylinder_config.cpp + cube/cylinder_config.ui + cube/sphere_config.cpp + cube/sphere_config.ui + ) + +# .desktop files +install( FILES + cube/cube_config.desktop + cube/cylinder_config.desktop + cube/sphere_config.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/cube.cpp b/effects/cube/cube.cpp similarity index 100% rename from effects/cube.cpp rename to effects/cube/cube.cpp diff --git a/effects/cube.desktop b/effects/cube/cube.desktop similarity index 100% rename from effects/cube.desktop rename to effects/cube/cube.desktop diff --git a/effects/cube.h b/effects/cube/cube.h similarity index 100% rename from effects/cube.h rename to effects/cube/cube.h diff --git a/effects/cube_config.cpp b/effects/cube/cube_config.cpp similarity index 99% rename from effects/cube_config.cpp rename to effects/cube/cube_config.cpp index 98ea07f8cb..f0283004be 100644 --- a/effects/cube_config.cpp +++ b/effects/cube/cube_config.cpp @@ -29,13 +29,12 @@ along with this program. If not, see . #include #include -#ifndef KDE_USE_FINAL -KWIN_EFFECT_CONFIG_FACTORY -#endif namespace KWin { +KWIN_EFFECT_CONFIG_FACTORY + CubeEffectConfigForm::CubeEffectConfigForm(QWidget* parent) : QWidget(parent) { setupUi(this); diff --git a/effects/cube_config.desktop b/effects/cube/cube_config.desktop similarity index 100% rename from effects/cube_config.desktop rename to effects/cube/cube_config.desktop diff --git a/effects/cube_config.h b/effects/cube/cube_config.h similarity index 100% rename from effects/cube_config.h rename to effects/cube/cube_config.h diff --git a/effects/cube_config.ui b/effects/cube/cube_config.ui similarity index 100% rename from effects/cube_config.ui rename to effects/cube/cube_config.ui diff --git a/effects/cylinder.cpp b/effects/cube/cylinder.cpp similarity index 100% rename from effects/cylinder.cpp rename to effects/cube/cylinder.cpp diff --git a/effects/cylinder.desktop b/effects/cube/cylinder.desktop similarity index 100% rename from effects/cylinder.desktop rename to effects/cube/cylinder.desktop diff --git a/effects/cylinder.h b/effects/cube/cylinder.h similarity index 100% rename from effects/cylinder.h rename to effects/cube/cylinder.h diff --git a/effects/cylinder_config.cpp b/effects/cube/cylinder_config.cpp similarity index 99% rename from effects/cylinder_config.cpp rename to effects/cube/cylinder_config.cpp index 1a90e36eee..e5a82df595 100644 --- a/effects/cylinder_config.cpp +++ b/effects/cube/cylinder_config.cpp @@ -29,13 +29,12 @@ along with this program. If not, see . #include #include -#ifndef KDE_USE_FINAL -KWIN_EFFECT_CONFIG_FACTORY -#endif namespace KWin { +KWIN_EFFECT_CONFIG_FACTORY + CylinderEffectConfigForm::CylinderEffectConfigForm(QWidget* parent) : QWidget(parent) { setupUi(this); diff --git a/effects/cylinder_config.desktop b/effects/cube/cylinder_config.desktop similarity index 100% rename from effects/cylinder_config.desktop rename to effects/cube/cylinder_config.desktop diff --git a/effects/cylinder_config.h b/effects/cube/cylinder_config.h similarity index 100% rename from effects/cylinder_config.h rename to effects/cube/cylinder_config.h diff --git a/effects/cylinder_config.ui b/effects/cube/cylinder_config.ui similarity index 100% rename from effects/cylinder_config.ui rename to effects/cube/cylinder_config.ui diff --git a/effects/data/cubecap.png b/effects/cube/data/cubecap.png similarity index 100% rename from effects/data/cubecap.png rename to effects/cube/data/cubecap.png diff --git a/effects/data/cylinder.frag b/effects/cube/data/cylinder.frag similarity index 100% rename from effects/data/cylinder.frag rename to effects/cube/data/cylinder.frag diff --git a/effects/data/cylinder.vert b/effects/cube/data/cylinder.vert similarity index 100% rename from effects/data/cylinder.vert rename to effects/cube/data/cylinder.vert diff --git a/effects/data/sphere.vert b/effects/cube/data/sphere.vert similarity index 100% rename from effects/data/sphere.vert rename to effects/cube/data/sphere.vert diff --git a/effects/sphere.cpp b/effects/cube/sphere.cpp similarity index 100% rename from effects/sphere.cpp rename to effects/cube/sphere.cpp diff --git a/effects/sphere.desktop b/effects/cube/sphere.desktop similarity index 100% rename from effects/sphere.desktop rename to effects/cube/sphere.desktop diff --git a/effects/sphere.h b/effects/cube/sphere.h similarity index 100% rename from effects/sphere.h rename to effects/cube/sphere.h diff --git a/effects/sphere_config.cpp b/effects/cube/sphere_config.cpp similarity index 99% rename from effects/sphere_config.cpp rename to effects/cube/sphere_config.cpp index a97fcaa8b2..140d5638f3 100644 --- a/effects/sphere_config.cpp +++ b/effects/cube/sphere_config.cpp @@ -29,13 +29,12 @@ along with this program. If not, see . #include #include -#ifndef KDE_USE_FINAL -KWIN_EFFECT_CONFIG_FACTORY -#endif namespace KWin { +KWIN_EFFECT_CONFIG_FACTORY + SphereEffectConfigForm::SphereEffectConfigForm(QWidget* parent) : QWidget(parent) { setupUi(this); diff --git a/effects/sphere_config.desktop b/effects/cube/sphere_config.desktop similarity index 100% rename from effects/sphere_config.desktop rename to effects/cube/sphere_config.desktop diff --git a/effects/sphere_config.h b/effects/cube/sphere_config.h similarity index 100% rename from effects/sphere_config.h rename to effects/cube/sphere_config.h diff --git a/effects/sphere_config.ui b/effects/cube/sphere_config.ui similarity index 100% rename from effects/sphere_config.ui rename to effects/cube/sphere_config.ui diff --git a/effects/desktopgrid/CMakeLists.txt b/effects/desktopgrid/CMakeLists.txt new file mode 100644 index 0000000000..e12f523498 --- /dev/null +++ b/effects/desktopgrid/CMakeLists.txt @@ -0,0 +1,26 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + desktopgrid/desktopgrid.cpp + ) + +# .desktop files +install( FILES + desktopgrid/desktopgrid.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) + +####################################### +# Config + +# Source files +set( kwin4_effect_builtins_config_sources ${kwin4_effect_builtins_config_sources} + desktopgrid/desktopgrid_config.cpp + desktopgrid/desktopgrid_config.ui + ) + +# .desktop files +install( FILES + desktopgrid/desktopgrid_config.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/desktopgrid.cpp b/effects/desktopgrid/desktopgrid.cpp similarity index 100% rename from effects/desktopgrid.cpp rename to effects/desktopgrid/desktopgrid.cpp diff --git a/effects/desktopgrid.desktop b/effects/desktopgrid/desktopgrid.desktop similarity index 100% rename from effects/desktopgrid.desktop rename to effects/desktopgrid/desktopgrid.desktop diff --git a/effects/desktopgrid.h b/effects/desktopgrid/desktopgrid.h similarity index 100% rename from effects/desktopgrid.h rename to effects/desktopgrid/desktopgrid.h diff --git a/effects/desktopgrid_config.cpp b/effects/desktopgrid/desktopgrid_config.cpp similarity index 99% rename from effects/desktopgrid_config.cpp rename to effects/desktopgrid/desktopgrid_config.cpp index e6a33bf255..80be4896c7 100644 --- a/effects/desktopgrid_config.cpp +++ b/effects/desktopgrid/desktopgrid_config.cpp @@ -28,13 +28,12 @@ along with this program. If not, see . #include #include -#ifndef KDE_USE_FINAL -KWIN_EFFECT_CONFIG_FACTORY -#endif namespace KWin { +KWIN_EFFECT_CONFIG_FACTORY + DesktopGridEffectConfigForm::DesktopGridEffectConfigForm(QWidget* parent) : QWidget(parent) { setupUi(this); diff --git a/effects/desktopgrid_config.desktop b/effects/desktopgrid/desktopgrid_config.desktop similarity index 100% rename from effects/desktopgrid_config.desktop rename to effects/desktopgrid/desktopgrid_config.desktop diff --git a/effects/desktopgrid_config.h b/effects/desktopgrid/desktopgrid_config.h similarity index 100% rename from effects/desktopgrid_config.h rename to effects/desktopgrid/desktopgrid_config.h diff --git a/effects/desktopgrid_config.ui b/effects/desktopgrid/desktopgrid_config.ui similarity index 100% rename from effects/desktopgrid_config.ui rename to effects/desktopgrid/desktopgrid_config.ui diff --git a/effects/dialogparent/CMakeLists.txt b/effects/dialogparent/CMakeLists.txt new file mode 100644 index 0000000000..ab626750de --- /dev/null +++ b/effects/dialogparent/CMakeLists.txt @@ -0,0 +1,12 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + dialogparent/dialogparent.cpp + ) + +# .desktop files +install( FILES + dialogparent/dialogparent.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/dialogparent.cpp b/effects/dialogparent/dialogparent.cpp similarity index 100% rename from effects/dialogparent.cpp rename to effects/dialogparent/dialogparent.cpp diff --git a/effects/dialogparent.desktop b/effects/dialogparent/dialogparent.desktop similarity index 100% rename from effects/dialogparent.desktop rename to effects/dialogparent/dialogparent.desktop diff --git a/effects/dialogparent.h b/effects/dialogparent/dialogparent.h similarity index 100% rename from effects/dialogparent.h rename to effects/dialogparent/dialogparent.h diff --git a/effects/diminactive/CMakeLists.txt b/effects/diminactive/CMakeLists.txt new file mode 100644 index 0000000000..2d143e9392 --- /dev/null +++ b/effects/diminactive/CMakeLists.txt @@ -0,0 +1,26 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + diminactive/diminactive.cpp + ) + +# .desktop files +install( FILES + diminactive/diminactive.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) + +####################################### +# Config + +# Source files +set( kwin4_effect_builtins_config_sources ${kwin4_effect_builtins_config_sources} + diminactive/diminactive_config.cpp + diminactive/diminactive_config.ui + ) + +# .desktop files +install( FILES + diminactive/diminactive_config.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/diminactive.cpp b/effects/diminactive/diminactive.cpp similarity index 100% rename from effects/diminactive.cpp rename to effects/diminactive/diminactive.cpp diff --git a/effects/diminactive.desktop b/effects/diminactive/diminactive.desktop similarity index 100% rename from effects/diminactive.desktop rename to effects/diminactive/diminactive.desktop diff --git a/effects/diminactive.h b/effects/diminactive/diminactive.h similarity index 100% rename from effects/diminactive.h rename to effects/diminactive/diminactive.h diff --git a/effects/diminactive_config.cpp b/effects/diminactive/diminactive_config.cpp similarity index 100% rename from effects/diminactive_config.cpp rename to effects/diminactive/diminactive_config.cpp index c766d53aba..e3045ecda5 100644 --- a/effects/diminactive_config.cpp +++ b/effects/diminactive/diminactive_config.cpp @@ -31,11 +31,11 @@ along with this program. If not, see . #include #include -KWIN_EFFECT_CONFIG_FACTORY - namespace KWin { +KWIN_EFFECT_CONFIG_FACTORY + DimInactiveEffectConfigForm::DimInactiveEffectConfigForm(QWidget* parent) : QWidget(parent) { setupUi(this); diff --git a/effects/diminactive_config.desktop b/effects/diminactive/diminactive_config.desktop similarity index 100% rename from effects/diminactive_config.desktop rename to effects/diminactive/diminactive_config.desktop diff --git a/effects/diminactive_config.h b/effects/diminactive/diminactive_config.h similarity index 100% rename from effects/diminactive_config.h rename to effects/diminactive/diminactive_config.h diff --git a/effects/diminactive_config.ui b/effects/diminactive/diminactive_config.ui similarity index 100% rename from effects/diminactive_config.ui rename to effects/diminactive/diminactive_config.ui diff --git a/effects/dimscreen/CMakeLists.txt b/effects/dimscreen/CMakeLists.txt new file mode 100644 index 0000000000..0373e911ce --- /dev/null +++ b/effects/dimscreen/CMakeLists.txt @@ -0,0 +1,12 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + dimscreen/dimscreen.cpp + ) + +# .desktop files +install( FILES + dimscreen/dimscreen.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/dimscreen.cpp b/effects/dimscreen/dimscreen.cpp similarity index 100% rename from effects/dimscreen.cpp rename to effects/dimscreen/dimscreen.cpp diff --git a/effects/dimscreen.desktop b/effects/dimscreen/dimscreen.desktop similarity index 100% rename from effects/dimscreen.desktop rename to effects/dimscreen/dimscreen.desktop diff --git a/effects/dimscreen.h b/effects/dimscreen/dimscreen.h similarity index 100% rename from effects/dimscreen.h rename to effects/dimscreen/dimscreen.h diff --git a/effects/explosion/CMakeLists.txt b/effects/explosion/CMakeLists.txt new file mode 100644 index 0000000000..ba83e60d79 --- /dev/null +++ b/effects/explosion/CMakeLists.txt @@ -0,0 +1,20 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + explosion/explosion.cpp + ) + +# .desktop files +install( FILES + explosion/explosion.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) + +# Data files +install( FILES + explosion/data/explosion-end.png + explosion/data/explosion-start.png + explosion/data/explosion.frag + explosion/data/explosion.vert + DESTINATION ${DATA_INSTALL_DIR}/kwin ) diff --git a/effects/data/explosion-end.png b/effects/explosion/data/explosion-end.png similarity index 100% rename from effects/data/explosion-end.png rename to effects/explosion/data/explosion-end.png diff --git a/effects/data/explosion-start.png b/effects/explosion/data/explosion-start.png similarity index 100% rename from effects/data/explosion-start.png rename to effects/explosion/data/explosion-start.png diff --git a/effects/data/explosion.frag b/effects/explosion/data/explosion.frag similarity index 100% rename from effects/data/explosion.frag rename to effects/explosion/data/explosion.frag diff --git a/effects/data/explosion.vert b/effects/explosion/data/explosion.vert similarity index 100% rename from effects/data/explosion.vert rename to effects/explosion/data/explosion.vert diff --git a/effects/explosioneffect.cpp b/effects/explosion/explosion.cpp similarity index 99% rename from effects/explosioneffect.cpp rename to effects/explosion/explosion.cpp index ca7a8dc8e8..4e3c2570e5 100644 --- a/effects/explosioneffect.cpp +++ b/effects/explosion/explosion.cpp @@ -18,7 +18,7 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . *********************************************************************/ -#include "explosioneffect.h" +#include "explosion.h" #include diff --git a/effects/explosion.desktop b/effects/explosion/explosion.desktop similarity index 100% rename from effects/explosion.desktop rename to effects/explosion/explosion.desktop diff --git a/effects/explosioneffect.h b/effects/explosion/explosion.h similarity index 100% rename from effects/explosioneffect.h rename to effects/explosion/explosion.h diff --git a/effects/fade/CMakeLists.txt b/effects/fade/CMakeLists.txt new file mode 100644 index 0000000000..865afb7560 --- /dev/null +++ b/effects/fade/CMakeLists.txt @@ -0,0 +1,12 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + fade/fade.cpp + ) + +# .desktop files +install( FILES + fade/fade.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/fade.cpp b/effects/fade/fade.cpp similarity index 100% rename from effects/fade.cpp rename to effects/fade/fade.cpp diff --git a/effects/fade.desktop b/effects/fade/fade.desktop similarity index 100% rename from effects/fade.desktop rename to effects/fade/fade.desktop diff --git a/effects/fade.h b/effects/fade/fade.h similarity index 100% rename from effects/fade.h rename to effects/fade/fade.h diff --git a/effects/fadedesktop/CMakeLists.txt b/effects/fadedesktop/CMakeLists.txt new file mode 100644 index 0000000000..61bd4fcacc --- /dev/null +++ b/effects/fadedesktop/CMakeLists.txt @@ -0,0 +1,12 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + fadedesktop/fadedesktop.cpp + ) + +# .desktop files +install( FILES + fadedesktop/fadedesktop.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/fadedesktop.cpp b/effects/fadedesktop/fadedesktop.cpp similarity index 100% rename from effects/fadedesktop.cpp rename to effects/fadedesktop/fadedesktop.cpp diff --git a/effects/fadedesktop.desktop b/effects/fadedesktop/fadedesktop.desktop similarity index 100% rename from effects/fadedesktop.desktop rename to effects/fadedesktop/fadedesktop.desktop diff --git a/effects/fadedesktop.h b/effects/fadedesktop/fadedesktop.h similarity index 100% rename from effects/fadedesktop.h rename to effects/fadedesktop/fadedesktop.h diff --git a/effects/fallapart/CMakeLists.txt b/effects/fallapart/CMakeLists.txt new file mode 100644 index 0000000000..f41fbb401a --- /dev/null +++ b/effects/fallapart/CMakeLists.txt @@ -0,0 +1,12 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + fallapart/fallapart.cpp + ) + +# .desktop files +install( FILES + fallapart/fallapart.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/fallapart.cpp b/effects/fallapart/fallapart.cpp similarity index 100% rename from effects/fallapart.cpp rename to effects/fallapart/fallapart.cpp diff --git a/effects/fallapart.desktop b/effects/fallapart/fallapart.desktop similarity index 100% rename from effects/fallapart.desktop rename to effects/fallapart/fallapart.desktop diff --git a/effects/fallapart.h b/effects/fallapart/fallapart.h similarity index 100% rename from effects/fallapart.h rename to effects/fallapart/fallapart.h diff --git a/effects/flipswitch/CMakeLists.txt b/effects/flipswitch/CMakeLists.txt new file mode 100644 index 0000000000..e838c607be --- /dev/null +++ b/effects/flipswitch/CMakeLists.txt @@ -0,0 +1,26 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + flipswitch/flipswitch.cpp + ) + +# .desktop files +install( FILES + flipswitch/flipswitch.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) + +####################################### +# Config + +# Source files +set( kwin4_effect_builtins_config_sources ${kwin4_effect_builtins_config_sources} + flipswitch/flipswitch_config.cpp + flipswitch/flipswitch_config.ui + ) + +# .desktop files +install( FILES + flipswitch/flipswitch_config.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/flipswitch.cpp b/effects/flipswitch/flipswitch.cpp similarity index 100% rename from effects/flipswitch.cpp rename to effects/flipswitch/flipswitch.cpp diff --git a/effects/flipswitch.desktop b/effects/flipswitch/flipswitch.desktop similarity index 100% rename from effects/flipswitch.desktop rename to effects/flipswitch/flipswitch.desktop diff --git a/effects/flipswitch.h b/effects/flipswitch/flipswitch.h similarity index 100% rename from effects/flipswitch.h rename to effects/flipswitch/flipswitch.h diff --git a/effects/flipswitch_config.cpp b/effects/flipswitch/flipswitch_config.cpp similarity index 99% rename from effects/flipswitch_config.cpp rename to effects/flipswitch/flipswitch_config.cpp index fc63eda2c2..d68d8cd8e5 100644 --- a/effects/flipswitch_config.cpp +++ b/effects/flipswitch/flipswitch_config.cpp @@ -23,13 +23,12 @@ along with this program. If not, see . #include #include -#ifndef KDE_USE_FINAL -KWIN_EFFECT_CONFIG_FACTORY -#endif namespace KWin { +KWIN_EFFECT_CONFIG_FACTORY + FlipSwitchEffectConfigForm::FlipSwitchEffectConfigForm(QWidget* parent) : QWidget(parent) { setupUi(this); diff --git a/effects/flipswitch_config.desktop b/effects/flipswitch/flipswitch_config.desktop similarity index 100% rename from effects/flipswitch_config.desktop rename to effects/flipswitch/flipswitch_config.desktop diff --git a/effects/flipswitch_config.h b/effects/flipswitch/flipswitch_config.h similarity index 100% rename from effects/flipswitch_config.h rename to effects/flipswitch/flipswitch_config.h diff --git a/effects/flipswitch_config.ui b/effects/flipswitch/flipswitch_config.ui similarity index 100% rename from effects/flipswitch_config.ui rename to effects/flipswitch/flipswitch_config.ui diff --git a/effects/highlightwindow/CMakeLists.txt b/effects/highlightwindow/CMakeLists.txt new file mode 100644 index 0000000000..c770e547de --- /dev/null +++ b/effects/highlightwindow/CMakeLists.txt @@ -0,0 +1,12 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + highlightwindow/highlightwindow.cpp + ) + +# .desktop files +install( FILES + highlightwindow/highlightwindow.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/highlightwindow.cpp b/effects/highlightwindow/highlightwindow.cpp similarity index 100% rename from effects/highlightwindow.cpp rename to effects/highlightwindow/highlightwindow.cpp diff --git a/effects/highlightwindow.desktop b/effects/highlightwindow/highlightwindow.desktop similarity index 100% rename from effects/highlightwindow.desktop rename to effects/highlightwindow/highlightwindow.desktop diff --git a/effects/highlightwindow.h b/effects/highlightwindow/highlightwindow.h similarity index 100% rename from effects/highlightwindow.h rename to effects/highlightwindow/highlightwindow.h diff --git a/effects/invert/CMakeLists.txt b/effects/invert/CMakeLists.txt new file mode 100644 index 0000000000..1b014c59d5 --- /dev/null +++ b/effects/invert/CMakeLists.txt @@ -0,0 +1,31 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + invert/invert.cpp + ) + +# .desktop files +install( FILES + invert/invert.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) + +# Data files +install( FILES + invert/data/invert.frag + invert/data/invert.vert + DESTINATION ${DATA_INSTALL_DIR}/kwin ) + +####################################### +# Config + +# Source files +set( kwin4_effect_builtins_config_sources ${kwin4_effect_builtins_config_sources} + invert/invert_config.cpp + ) + +# .desktop files +install( FILES + invert/invert_config.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/data/invert.frag b/effects/invert/data/invert.frag similarity index 100% rename from effects/data/invert.frag rename to effects/invert/data/invert.frag diff --git a/effects/data/invert.vert b/effects/invert/data/invert.vert similarity index 100% rename from effects/data/invert.vert rename to effects/invert/data/invert.vert diff --git a/effects/invert.cpp b/effects/invert/invert.cpp similarity index 100% rename from effects/invert.cpp rename to effects/invert/invert.cpp diff --git a/effects/invert.desktop b/effects/invert/invert.desktop similarity index 100% rename from effects/invert.desktop rename to effects/invert/invert.desktop diff --git a/effects/invert.h b/effects/invert/invert.h similarity index 100% rename from effects/invert.h rename to effects/invert/invert.h diff --git a/effects/invert_config.cpp b/effects/invert/invert_config.cpp similarity index 98% rename from effects/invert_config.cpp rename to effects/invert/invert_config.cpp index fe5312bfc8..ba5e10b865 100644 --- a/effects/invert_config.cpp +++ b/effects/invert/invert_config.cpp @@ -29,12 +29,12 @@ along with this program. If not, see . #include #include -#ifndef KDE_USE_FINAL -KWIN_EFFECT_CONFIG_FACTORY -#endif + namespace KWin { +KWIN_EFFECT_CONFIG_FACTORY + InvertEffectConfig::InvertEffectConfig(QWidget* parent, const QVariantList& args) : KCModule(EffectFactory::componentData(), parent, args) { diff --git a/effects/invert_config.desktop b/effects/invert/invert_config.desktop similarity index 100% rename from effects/invert_config.desktop rename to effects/invert/invert_config.desktop diff --git a/effects/invert_config.h b/effects/invert/invert_config.h similarity index 100% rename from effects/invert_config.h rename to effects/invert/invert_config.h diff --git a/effects/login/CMakeLists.txt b/effects/login/CMakeLists.txt new file mode 100644 index 0000000000..a7cbbf3ce0 --- /dev/null +++ b/effects/login/CMakeLists.txt @@ -0,0 +1,12 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + login/login.cpp + ) + +# .desktop files +install( FILES + login/login.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/login.cpp b/effects/login/login.cpp similarity index 100% rename from effects/login.cpp rename to effects/login/login.cpp diff --git a/effects/login.desktop b/effects/login/login.desktop similarity index 100% rename from effects/login.desktop rename to effects/login/login.desktop diff --git a/effects/login.h b/effects/login/login.h similarity index 100% rename from effects/login.h rename to effects/login/login.h diff --git a/effects/logout/CMakeLists.txt b/effects/logout/CMakeLists.txt new file mode 100644 index 0000000000..67ccff4004 --- /dev/null +++ b/effects/logout/CMakeLists.txt @@ -0,0 +1,12 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + logout/logout.cpp + ) + +# .desktop files +install( FILES + logout/logout.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/logout.cpp b/effects/logout/logout.cpp similarity index 100% rename from effects/logout.cpp rename to effects/logout/logout.cpp diff --git a/effects/logout.desktop b/effects/logout/logout.desktop similarity index 100% rename from effects/logout.desktop rename to effects/logout/logout.desktop diff --git a/effects/logout.h b/effects/logout/logout.h similarity index 100% rename from effects/logout.h rename to effects/logout/logout.h diff --git a/effects/lookingglass/CMakeLists.txt b/effects/lookingglass/CMakeLists.txt new file mode 100644 index 0000000000..5b17c06c06 --- /dev/null +++ b/effects/lookingglass/CMakeLists.txt @@ -0,0 +1,32 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + lookingglass/lookingglass.cpp + ) + +# .desktop files +install( FILES + lookingglass/lookingglass.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) + +# Data files +install( FILES + lookingglass/data/lookingglass.frag + lookingglass/data/lookingglass.vert + DESTINATION ${DATA_INSTALL_DIR}/kwin ) + +####################################### +# Config + +# Source files +set( kwin4_effect_builtins_config_sources ${kwin4_effect_builtins_config_sources} + lookingglass/lookingglass_config.cpp + lookingglass/lookingglass_config.ui + ) + +# .desktop files +install( FILES + lookingglass/lookingglass_config.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/data/lookingglass.frag b/effects/lookingglass/data/lookingglass.frag similarity index 100% rename from effects/data/lookingglass.frag rename to effects/lookingglass/data/lookingglass.frag diff --git a/effects/data/lookingglass.vert b/effects/lookingglass/data/lookingglass.vert similarity index 100% rename from effects/data/lookingglass.vert rename to effects/lookingglass/data/lookingglass.vert diff --git a/effects/lookingglass.cpp b/effects/lookingglass/lookingglass.cpp similarity index 100% rename from effects/lookingglass.cpp rename to effects/lookingglass/lookingglass.cpp diff --git a/effects/lookingglass.desktop b/effects/lookingglass/lookingglass.desktop similarity index 100% rename from effects/lookingglass.desktop rename to effects/lookingglass/lookingglass.desktop diff --git a/effects/lookingglass.h b/effects/lookingglass/lookingglass.h similarity index 100% rename from effects/lookingglass.h rename to effects/lookingglass/lookingglass.h diff --git a/effects/lookingglass_config.cpp b/effects/lookingglass/lookingglass_config.cpp similarity index 100% rename from effects/lookingglass_config.cpp rename to effects/lookingglass/lookingglass_config.cpp index b9cfe07f79..7f77b35d5a 100644 --- a/effects/lookingglass_config.cpp +++ b/effects/lookingglass/lookingglass_config.cpp @@ -32,11 +32,11 @@ along with this program. If not, see . #include #include -KWIN_EFFECT_CONFIG_FACTORY - namespace KWin { +KWIN_EFFECT_CONFIG_FACTORY + LookingGlassEffectConfigForm::LookingGlassEffectConfigForm(QWidget* parent) : QWidget(parent) { setupUi(this); diff --git a/effects/lookingglass_config.desktop b/effects/lookingglass/lookingglass_config.desktop similarity index 100% rename from effects/lookingglass_config.desktop rename to effects/lookingglass/lookingglass_config.desktop diff --git a/effects/lookingglass_config.h b/effects/lookingglass/lookingglass_config.h similarity index 100% rename from effects/lookingglass_config.h rename to effects/lookingglass/lookingglass_config.h diff --git a/effects/lookingglass_config.ui b/effects/lookingglass/lookingglass_config.ui similarity index 100% rename from effects/lookingglass_config.ui rename to effects/lookingglass/lookingglass_config.ui diff --git a/effects/magiclamp/CMakeLists.txt b/effects/magiclamp/CMakeLists.txt new file mode 100644 index 0000000000..81e42fd3c3 --- /dev/null +++ b/effects/magiclamp/CMakeLists.txt @@ -0,0 +1,26 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + magiclamp/magiclamp.cpp + ) + +# .desktop files +install( FILES + magiclamp/magiclamp.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) + +####################################### +# Config + +# Source files +set( kwin4_effect_builtins_config_sources ${kwin4_effect_builtins_config_sources} + magiclamp/magiclamp_config.cpp + magiclamp/magiclamp_config.ui + ) + +# .desktop files +install( FILES + magiclamp/magiclamp_config.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/magiclamp.cpp b/effects/magiclamp/magiclamp.cpp similarity index 100% rename from effects/magiclamp.cpp rename to effects/magiclamp/magiclamp.cpp diff --git a/effects/magiclamp.desktop b/effects/magiclamp/magiclamp.desktop similarity index 100% rename from effects/magiclamp.desktop rename to effects/magiclamp/magiclamp.desktop diff --git a/effects/magiclamp.h b/effects/magiclamp/magiclamp.h similarity index 100% rename from effects/magiclamp.h rename to effects/magiclamp/magiclamp.h diff --git a/effects/magiclamp_config.cpp b/effects/magiclamp/magiclamp_config.cpp similarity index 98% rename from effects/magiclamp_config.cpp rename to effects/magiclamp/magiclamp_config.cpp index b8d51912e8..7765e01881 100644 --- a/effects/magiclamp_config.cpp +++ b/effects/magiclamp/magiclamp_config.cpp @@ -23,13 +23,12 @@ along with this program. If not, see . #include #include -#ifndef KDE_USE_FINAL -KWIN_EFFECT_CONFIG_FACTORY -#endif namespace KWin { +KWIN_EFFECT_CONFIG_FACTORY + MagicLampEffectConfigForm::MagicLampEffectConfigForm(QWidget* parent) : QWidget(parent) { setupUi(this); diff --git a/effects/magiclamp_config.desktop b/effects/magiclamp/magiclamp_config.desktop similarity index 100% rename from effects/magiclamp_config.desktop rename to effects/magiclamp/magiclamp_config.desktop diff --git a/effects/magiclamp_config.h b/effects/magiclamp/magiclamp_config.h similarity index 100% rename from effects/magiclamp_config.h rename to effects/magiclamp/magiclamp_config.h diff --git a/effects/magiclamp_config.ui b/effects/magiclamp/magiclamp_config.ui similarity index 100% rename from effects/magiclamp_config.ui rename to effects/magiclamp/magiclamp_config.ui diff --git a/effects/magnifier/CMakeLists.txt b/effects/magnifier/CMakeLists.txt new file mode 100644 index 0000000000..c0c0050fd3 --- /dev/null +++ b/effects/magnifier/CMakeLists.txt @@ -0,0 +1,26 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + magnifier/magnifier.cpp + ) + +# .desktop files +install( FILES + magnifier/magnifier.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) + +####################################### +# Config + +# Source files +set( kwin4_effect_builtins_config_sources ${kwin4_effect_builtins_config_sources} + magnifier/magnifier_config.cpp + magnifier/magnifier_config.ui + ) + +# .desktop files +install( FILES + magnifier/magnifier_config.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/magnifier.cpp b/effects/magnifier/magnifier.cpp similarity index 100% rename from effects/magnifier.cpp rename to effects/magnifier/magnifier.cpp diff --git a/effects/magnifier.desktop b/effects/magnifier/magnifier.desktop similarity index 100% rename from effects/magnifier.desktop rename to effects/magnifier/magnifier.desktop diff --git a/effects/magnifier.h b/effects/magnifier/magnifier.h similarity index 100% rename from effects/magnifier.h rename to effects/magnifier/magnifier.h diff --git a/effects/magnifier_config.cpp b/effects/magnifier/magnifier_config.cpp similarity index 100% rename from effects/magnifier_config.cpp rename to effects/magnifier/magnifier_config.cpp index fe4eafe114..b3f661a528 100644 --- a/effects/magnifier_config.cpp +++ b/effects/magnifier/magnifier_config.cpp @@ -32,11 +32,11 @@ along with this program. If not, see . #include #include -KWIN_EFFECT_CONFIG_FACTORY - namespace KWin { +KWIN_EFFECT_CONFIG_FACTORY + MagnifierEffectConfigForm::MagnifierEffectConfigForm(QWidget* parent) : QWidget(parent) { setupUi(this); diff --git a/effects/magnifier_config.desktop b/effects/magnifier/magnifier_config.desktop similarity index 100% rename from effects/magnifier_config.desktop rename to effects/magnifier/magnifier_config.desktop diff --git a/effects/magnifier_config.h b/effects/magnifier/magnifier_config.h similarity index 100% rename from effects/magnifier_config.h rename to effects/magnifier/magnifier_config.h diff --git a/effects/magnifier_config.ui b/effects/magnifier/magnifier_config.ui similarity index 100% rename from effects/magnifier_config.ui rename to effects/magnifier/magnifier_config.ui diff --git a/effects/minimizeanimation/CMakeLists.txt b/effects/minimizeanimation/CMakeLists.txt new file mode 100644 index 0000000000..e9535d0723 --- /dev/null +++ b/effects/minimizeanimation/CMakeLists.txt @@ -0,0 +1,12 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + minimizeanimation/minimizeanimation.cpp + ) + +# .desktop files +install( FILES + minimizeanimation/minimizeanimation.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/minimizeanimation.cpp b/effects/minimizeanimation/minimizeanimation.cpp similarity index 100% rename from effects/minimizeanimation.cpp rename to effects/minimizeanimation/minimizeanimation.cpp diff --git a/effects/minimizeanimation.desktop b/effects/minimizeanimation/minimizeanimation.desktop similarity index 100% rename from effects/minimizeanimation.desktop rename to effects/minimizeanimation/minimizeanimation.desktop diff --git a/effects/minimizeanimation.h b/effects/minimizeanimation/minimizeanimation.h similarity index 100% rename from effects/minimizeanimation.h rename to effects/minimizeanimation/minimizeanimation.h diff --git a/effects/mousemark/CMakeLists.txt b/effects/mousemark/CMakeLists.txt new file mode 100644 index 0000000000..37b3ff263e --- /dev/null +++ b/effects/mousemark/CMakeLists.txt @@ -0,0 +1,26 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + mousemark/mousemark.cpp + ) + +# .desktop files +install( FILES + mousemark/mousemark.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) + +####################################### +# Config + +# Source files +set( kwin4_effect_builtins_config_sources ${kwin4_effect_builtins_config_sources} + mousemark/mousemark_config.cpp + mousemark/mousemark_config.ui + ) + +# .desktop files +install( FILES + mousemark/mousemark_config.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/mousemark.cpp b/effects/mousemark/mousemark.cpp similarity index 100% rename from effects/mousemark.cpp rename to effects/mousemark/mousemark.cpp diff --git a/effects/mousemark.desktop b/effects/mousemark/mousemark.desktop similarity index 100% rename from effects/mousemark.desktop rename to effects/mousemark/mousemark.desktop diff --git a/effects/mousemark.h b/effects/mousemark/mousemark.h similarity index 100% rename from effects/mousemark.h rename to effects/mousemark/mousemark.h diff --git a/effects/mousemark_config.cpp b/effects/mousemark/mousemark_config.cpp similarity index 100% rename from effects/mousemark_config.cpp rename to effects/mousemark/mousemark_config.cpp index 9a8b143275..e61ed366c0 100644 --- a/effects/mousemark_config.cpp +++ b/effects/mousemark/mousemark_config.cpp @@ -32,11 +32,11 @@ along with this program. If not, see . #include #include -KWIN_EFFECT_CONFIG_FACTORY - namespace KWin { +KWIN_EFFECT_CONFIG_FACTORY + MouseMarkEffectConfigForm::MouseMarkEffectConfigForm(QWidget* parent) : QWidget(parent) { setupUi(this); diff --git a/effects/mousemark_config.desktop b/effects/mousemark/mousemark_config.desktop similarity index 100% rename from effects/mousemark_config.desktop rename to effects/mousemark/mousemark_config.desktop diff --git a/effects/mousemark_config.h b/effects/mousemark/mousemark_config.h similarity index 100% rename from effects/mousemark_config.h rename to effects/mousemark/mousemark_config.h diff --git a/effects/mousemark_config.ui b/effects/mousemark/mousemark_config.ui similarity index 100% rename from effects/mousemark_config.ui rename to effects/mousemark/mousemark_config.ui diff --git a/effects/presentwindows/CMakeLists.txt b/effects/presentwindows/CMakeLists.txt new file mode 100644 index 0000000000..9b015f44bb --- /dev/null +++ b/effects/presentwindows/CMakeLists.txt @@ -0,0 +1,26 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + presentwindows/presentwindows.cpp + ) + +# .desktop files +install( FILES + presentwindows/presentwindows.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) + +####################################### +# Config + +# Source files +set( kwin4_effect_builtins_config_sources ${kwin4_effect_builtins_config_sources} + presentwindows/presentwindows_config.cpp + presentwindows/presentwindows_config.ui + ) + +# .desktop files +install( FILES + presentwindows/presentwindows_config.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/presentwindows.cpp b/effects/presentwindows/presentwindows.cpp similarity index 100% rename from effects/presentwindows.cpp rename to effects/presentwindows/presentwindows.cpp diff --git a/effects/presentwindows.desktop b/effects/presentwindows/presentwindows.desktop similarity index 100% rename from effects/presentwindows.desktop rename to effects/presentwindows/presentwindows.desktop diff --git a/effects/presentwindows.h b/effects/presentwindows/presentwindows.h similarity index 100% rename from effects/presentwindows.h rename to effects/presentwindows/presentwindows.h diff --git a/effects/presentwindows_config.cpp b/effects/presentwindows/presentwindows_config.cpp similarity index 99% rename from effects/presentwindows_config.cpp rename to effects/presentwindows/presentwindows_config.cpp index d173bd7bc3..183812dd94 100644 --- a/effects/presentwindows_config.cpp +++ b/effects/presentwindows/presentwindows_config.cpp @@ -28,13 +28,12 @@ along with this program. If not, see . #include #include -#ifndef KDE_USE_FINAL -KWIN_EFFECT_CONFIG_FACTORY -#endif namespace KWin { +KWIN_EFFECT_CONFIG_FACTORY + PresentWindowsEffectConfigForm::PresentWindowsEffectConfigForm(QWidget* parent) : QWidget(parent) { setupUi(this); diff --git a/effects/presentwindows_config.desktop b/effects/presentwindows/presentwindows_config.desktop similarity index 100% rename from effects/presentwindows_config.desktop rename to effects/presentwindows/presentwindows_config.desktop diff --git a/effects/presentwindows_config.h b/effects/presentwindows/presentwindows_config.h similarity index 100% rename from effects/presentwindows_config.h rename to effects/presentwindows/presentwindows_config.h diff --git a/effects/presentwindows_config.ui b/effects/presentwindows/presentwindows_config.ui similarity index 100% rename from effects/presentwindows_config.ui rename to effects/presentwindows/presentwindows_config.ui diff --git a/effects/scalein/CMakeLists.txt b/effects/scalein/CMakeLists.txt new file mode 100644 index 0000000000..6a16861531 --- /dev/null +++ b/effects/scalein/CMakeLists.txt @@ -0,0 +1,12 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + scalein/scalein.cpp + ) + +# .desktop files +install( FILES + scalein/scalein.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/scalein.cpp b/effects/scalein/scalein.cpp similarity index 100% rename from effects/scalein.cpp rename to effects/scalein/scalein.cpp diff --git a/effects/scalein.desktop b/effects/scalein/scalein.desktop similarity index 100% rename from effects/scalein.desktop rename to effects/scalein/scalein.desktop diff --git a/effects/scalein.h b/effects/scalein/scalein.h similarity index 100% rename from effects/scalein.h rename to effects/scalein/scalein.h diff --git a/effects/shadow/CMakeLists.txt b/effects/shadow/CMakeLists.txt new file mode 100644 index 0000000000..e7e3413fc5 --- /dev/null +++ b/effects/shadow/CMakeLists.txt @@ -0,0 +1,31 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + shadow/shadow.cpp + ) + +# .desktop files +install( FILES + shadow/shadow.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) + +# Data files +install( FILES + shadow/data/shadow-texture.png + DESTINATION ${DATA_INSTALL_DIR}/kwin ) + +####################################### +# Config + +# Source files +set( kwin4_effect_builtins_config_sources ${kwin4_effect_builtins_config_sources} + shadow/shadow_config.cpp + shadow/shadow_config.ui + ) + +# .desktop files +install( FILES + shadow/shadow_config.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/data/shadow-texture.png b/effects/shadow/data/shadow-texture.png similarity index 100% rename from effects/data/shadow-texture.png rename to effects/shadow/data/shadow-texture.png diff --git a/effects/shadow.cpp b/effects/shadow/shadow.cpp similarity index 100% rename from effects/shadow.cpp rename to effects/shadow/shadow.cpp diff --git a/effects/shadow.desktop b/effects/shadow/shadow.desktop similarity index 100% rename from effects/shadow.desktop rename to effects/shadow/shadow.desktop diff --git a/effects/shadow.h b/effects/shadow/shadow.h similarity index 100% rename from effects/shadow.h rename to effects/shadow/shadow.h diff --git a/effects/shadow_config.cpp b/effects/shadow/shadow_config.cpp similarity index 99% rename from effects/shadow_config.cpp rename to effects/shadow/shadow_config.cpp index a00b15b2a8..b75d2d05e7 100644 --- a/effects/shadow_config.cpp +++ b/effects/shadow/shadow_config.cpp @@ -28,13 +28,12 @@ along with this program. If not, see . #include #include #include -#ifndef KDE_USE_FINAL -KWIN_EFFECT_CONFIG_FACTORY -#endif namespace KWin { +KWIN_EFFECT_CONFIG_FACTORY + ShadowEffectConfigForm::ShadowEffectConfigForm(QWidget* parent) : QWidget(parent) { setupUi(this); diff --git a/effects/shadow_config.desktop b/effects/shadow/shadow_config.desktop similarity index 100% rename from effects/shadow_config.desktop rename to effects/shadow/shadow_config.desktop diff --git a/effects/shadow_config.h b/effects/shadow/shadow_config.h similarity index 100% rename from effects/shadow_config.h rename to effects/shadow/shadow_config.h diff --git a/effects/shadow_config.ui b/effects/shadow/shadow_config.ui similarity index 100% rename from effects/shadow_config.ui rename to effects/shadow/shadow_config.ui diff --git a/effects/shadow_helper.h b/effects/shadow/shadow_helper.h similarity index 100% rename from effects/shadow_helper.h rename to effects/shadow/shadow_helper.h diff --git a/effects/sharpen/CMakeLists.txt b/effects/sharpen/CMakeLists.txt new file mode 100644 index 0000000000..56979a082e --- /dev/null +++ b/effects/sharpen/CMakeLists.txt @@ -0,0 +1,31 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + sharpen/sharpen.cpp + ) + +# .desktop files +install( FILES + sharpen/sharpen.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) + +# Data files +install( FILES + sharpen/data/sharpen.frag + sharpen/data/sharpen.vert + DESTINATION ${DATA_INSTALL_DIR}/kwin ) + +####################################### +# Config + +# Source files +set( kwin4_effect_builtins_config_sources ${kwin4_effect_builtins_config_sources} + sharpen/sharpen_config.cpp + ) + +# .desktop files +install( FILES + sharpen/sharpen_config.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/data/sharpen.frag b/effects/sharpen/data/sharpen.frag similarity index 100% rename from effects/data/sharpen.frag rename to effects/sharpen/data/sharpen.frag diff --git a/effects/data/sharpen.vert b/effects/sharpen/data/sharpen.vert similarity index 100% rename from effects/data/sharpen.vert rename to effects/sharpen/data/sharpen.vert diff --git a/effects/sharpen.cpp b/effects/sharpen/sharpen.cpp similarity index 100% rename from effects/sharpen.cpp rename to effects/sharpen/sharpen.cpp diff --git a/effects/sharpen.desktop b/effects/sharpen/sharpen.desktop similarity index 100% rename from effects/sharpen.desktop rename to effects/sharpen/sharpen.desktop diff --git a/effects/sharpen.h b/effects/sharpen/sharpen.h similarity index 100% rename from effects/sharpen.h rename to effects/sharpen/sharpen.h diff --git a/effects/sharpen_config.cpp b/effects/sharpen/sharpen_config.cpp similarity index 98% rename from effects/sharpen_config.cpp rename to effects/sharpen/sharpen_config.cpp index eeac453609..bbac4087bb 100644 --- a/effects/sharpen_config.cpp +++ b/effects/sharpen/sharpen_config.cpp @@ -29,12 +29,12 @@ along with this program. If not, see . #include #include -#ifndef KDE_USE_FINAL -KWIN_EFFECT_CONFIG_FACTORY -#endif + namespace KWin { +KWIN_EFFECT_CONFIG_FACTORY + SharpenEffectConfig::SharpenEffectConfig(QWidget* parent, const QVariantList& args) : KCModule(EffectFactory::componentData(), parent, args) { diff --git a/effects/sharpen_config.desktop b/effects/sharpen/sharpen_config.desktop similarity index 100% rename from effects/sharpen_config.desktop rename to effects/sharpen/sharpen_config.desktop diff --git a/effects/sharpen_config.h b/effects/sharpen/sharpen_config.h similarity index 100% rename from effects/sharpen_config.h rename to effects/sharpen/sharpen_config.h diff --git a/effects/showfps/CMakeLists.txt b/effects/showfps/CMakeLists.txt new file mode 100644 index 0000000000..5d4f812fc7 --- /dev/null +++ b/effects/showfps/CMakeLists.txt @@ -0,0 +1,26 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + showfps/showfps.cpp + ) + +# .desktop files +install( FILES + showfps/showfps.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) + +####################################### +# Config + +# Source files +set( kwin4_effect_builtins_config_sources ${kwin4_effect_builtins_config_sources} + showfps/showfps_config.cpp + showfps/showfps_config.ui + ) + +# .desktop files +install( FILES + showfps/showfps_config.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/showfps.cpp b/effects/showfps/showfps.cpp similarity index 100% rename from effects/showfps.cpp rename to effects/showfps/showfps.cpp diff --git a/effects/showfps.desktop b/effects/showfps/showfps.desktop similarity index 100% rename from effects/showfps.desktop rename to effects/showfps/showfps.desktop diff --git a/effects/showfps.h b/effects/showfps/showfps.h similarity index 100% rename from effects/showfps.h rename to effects/showfps/showfps.h diff --git a/effects/showfps_config.cpp b/effects/showfps/showfps_config.cpp similarity index 99% rename from effects/showfps_config.cpp rename to effects/showfps/showfps_config.cpp index 26a7e857bd..91161472c7 100644 --- a/effects/showfps_config.cpp +++ b/effects/showfps/showfps_config.cpp @@ -25,13 +25,11 @@ along with this program. If not, see . #include #include -#ifndef KDE_USE_FINAL -KWIN_EFFECT_CONFIG_FACTORY -#endif - namespace KWin { +KWIN_EFFECT_CONFIG_FACTORY + ShowFpsEffectConfig::ShowFpsEffectConfig(QWidget* parent, const QVariantList& args) : KCModule(EffectFactory::componentData(), parent, args) { diff --git a/effects/showfps_config.desktop b/effects/showfps/showfps_config.desktop similarity index 100% rename from effects/showfps_config.desktop rename to effects/showfps/showfps_config.desktop diff --git a/effects/showfps_config.h b/effects/showfps/showfps_config.h similarity index 100% rename from effects/showfps_config.h rename to effects/showfps/showfps_config.h diff --git a/effects/showfps_config.ui b/effects/showfps/showfps_config.ui similarity index 100% rename from effects/showfps_config.ui rename to effects/showfps/showfps_config.ui diff --git a/effects/showpaint/CMakeLists.txt b/effects/showpaint/CMakeLists.txt new file mode 100644 index 0000000000..d0e5734805 --- /dev/null +++ b/effects/showpaint/CMakeLists.txt @@ -0,0 +1,12 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + showpaint/showpaint.cpp + ) + +# .desktop files +install( FILES + showpaint/showpaint.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/showpaint.cpp b/effects/showpaint/showpaint.cpp similarity index 100% rename from effects/showpaint.cpp rename to effects/showpaint/showpaint.cpp diff --git a/effects/showpaint.desktop b/effects/showpaint/showpaint.desktop similarity index 100% rename from effects/showpaint.desktop rename to effects/showpaint/showpaint.desktop diff --git a/effects/showpaint.h b/effects/showpaint/showpaint.h similarity index 100% rename from effects/showpaint.h rename to effects/showpaint/showpaint.h diff --git a/effects/slide/CMakeLists.txt b/effects/slide/CMakeLists.txt new file mode 100644 index 0000000000..1547d0c9de --- /dev/null +++ b/effects/slide/CMakeLists.txt @@ -0,0 +1,12 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + slide/slide.cpp + ) + +# .desktop files +install( FILES + slide/slide.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/slide.cpp b/effects/slide/slide.cpp similarity index 100% rename from effects/slide.cpp rename to effects/slide/slide.cpp diff --git a/effects/slide.desktop b/effects/slide/slide.desktop similarity index 100% rename from effects/slide.desktop rename to effects/slide/slide.desktop diff --git a/effects/slide.h b/effects/slide/slide.h similarity index 100% rename from effects/slide.h rename to effects/slide/slide.h diff --git a/effects/snow/CMakeLists.txt b/effects/snow/CMakeLists.txt new file mode 100644 index 0000000000..f2884ee9bd --- /dev/null +++ b/effects/snow/CMakeLists.txt @@ -0,0 +1,33 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + snow/snow.cpp + ) + +# .desktop files +install( FILES + snow/snow.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) + +# Data files +install( FILES + snow/data/snow.frag + snow/data/snow.vert + snow/data/snowflake.png + DESTINATION ${DATA_INSTALL_DIR}/kwin ) + +####################################### +# Config + +# Source files +set( kwin4_effect_builtins_config_sources ${kwin4_effect_builtins_config_sources} + snow/snow_config.cpp + snow/snow_config.ui + ) + +# .desktop files +install( FILES + snow/snow_config.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/data/snow.frag b/effects/snow/data/snow.frag similarity index 100% rename from effects/data/snow.frag rename to effects/snow/data/snow.frag diff --git a/effects/data/snow.vert b/effects/snow/data/snow.vert similarity index 100% rename from effects/data/snow.vert rename to effects/snow/data/snow.vert diff --git a/effects/data/snowflake.png b/effects/snow/data/snowflake.png similarity index 100% rename from effects/data/snowflake.png rename to effects/snow/data/snowflake.png diff --git a/effects/snow.cpp b/effects/snow/snow.cpp similarity index 100% rename from effects/snow.cpp rename to effects/snow/snow.cpp diff --git a/effects/snow.desktop b/effects/snow/snow.desktop similarity index 100% rename from effects/snow.desktop rename to effects/snow/snow.desktop diff --git a/effects/snow.h b/effects/snow/snow.h similarity index 100% rename from effects/snow.h rename to effects/snow/snow.h diff --git a/effects/snow_config.cpp b/effects/snow/snow_config.cpp similarity index 99% rename from effects/snow_config.cpp rename to effects/snow/snow_config.cpp index 6659b10889..33a4da0ec2 100644 --- a/effects/snow_config.cpp +++ b/effects/snow/snow_config.cpp @@ -28,12 +28,12 @@ along with this program. If not, see . #include #include -#ifndef KDE_USE_FINAL -KWIN_EFFECT_CONFIG_FACTORY -#endif + namespace KWin { +KWIN_EFFECT_CONFIG_FACTORY + SnowEffectConfigForm::SnowEffectConfigForm(QWidget* parent) : QWidget(parent) { setupUi(this); diff --git a/effects/snow_config.desktop b/effects/snow/snow_config.desktop similarity index 100% rename from effects/snow_config.desktop rename to effects/snow/snow_config.desktop diff --git a/effects/snow_config.h b/effects/snow/snow_config.h similarity index 100% rename from effects/snow_config.h rename to effects/snow/snow_config.h diff --git a/effects/snow_config.ui b/effects/snow/snow_config.ui similarity index 100% rename from effects/snow_config.ui rename to effects/snow/snow_config.ui diff --git a/effects/taskbarthumbnail/CMakeLists.txt b/effects/taskbarthumbnail/CMakeLists.txt new file mode 100644 index 0000000000..c502753907 --- /dev/null +++ b/effects/taskbarthumbnail/CMakeLists.txt @@ -0,0 +1,12 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + taskbarthumbnail/taskbarthumbnail.cpp + ) + +# .desktop files +install( FILES + taskbarthumbnail/taskbarthumbnail.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/taskbarthumbnail.cpp b/effects/taskbarthumbnail/taskbarthumbnail.cpp similarity index 100% rename from effects/taskbarthumbnail.cpp rename to effects/taskbarthumbnail/taskbarthumbnail.cpp diff --git a/effects/taskbarthumbnail.desktop b/effects/taskbarthumbnail/taskbarthumbnail.desktop similarity index 100% rename from effects/taskbarthumbnail.desktop rename to effects/taskbarthumbnail/taskbarthumbnail.desktop diff --git a/effects/taskbarthumbnail.h b/effects/taskbarthumbnail/taskbarthumbnail.h similarity index 100% rename from effects/taskbarthumbnail.h rename to effects/taskbarthumbnail/taskbarthumbnail.h diff --git a/effects/thumbnailaside/CMakeLists.txt b/effects/thumbnailaside/CMakeLists.txt new file mode 100644 index 0000000000..ac14c85a62 --- /dev/null +++ b/effects/thumbnailaside/CMakeLists.txt @@ -0,0 +1,26 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + thumbnailaside/thumbnailaside.cpp + ) + +# .desktop files +install( FILES + thumbnailaside/thumbnailaside.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) + +####################################### +# Config + +# Source files +set( kwin4_effect_builtins_config_sources ${kwin4_effect_builtins_config_sources} + thumbnailaside/thumbnailaside_config.cpp + thumbnailaside/thumbnailaside_config.ui + ) + +# .desktop files +install( FILES + thumbnailaside/thumbnailaside_config.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/thumbnailaside.cpp b/effects/thumbnailaside/thumbnailaside.cpp similarity index 100% rename from effects/thumbnailaside.cpp rename to effects/thumbnailaside/thumbnailaside.cpp diff --git a/effects/thumbnailaside.desktop b/effects/thumbnailaside/thumbnailaside.desktop similarity index 100% rename from effects/thumbnailaside.desktop rename to effects/thumbnailaside/thumbnailaside.desktop diff --git a/effects/thumbnailaside.h b/effects/thumbnailaside/thumbnailaside.h similarity index 100% rename from effects/thumbnailaside.h rename to effects/thumbnailaside/thumbnailaside.h diff --git a/effects/thumbnailaside_config.cpp b/effects/thumbnailaside/thumbnailaside_config.cpp similarity index 100% rename from effects/thumbnailaside_config.cpp rename to effects/thumbnailaside/thumbnailaside_config.cpp index 0248ab59ea..8d161f320a 100644 --- a/effects/thumbnailaside_config.cpp +++ b/effects/thumbnailaside/thumbnailaside_config.cpp @@ -32,11 +32,11 @@ along with this program. If not, see . #include #include -KWIN_EFFECT_CONFIG_FACTORY - namespace KWin { +KWIN_EFFECT_CONFIG_FACTORY + ThumbnailAsideEffectConfigForm::ThumbnailAsideEffectConfigForm(QWidget* parent) : QWidget(parent) { setupUi(this); diff --git a/effects/thumbnailaside_config.desktop b/effects/thumbnailaside/thumbnailaside_config.desktop similarity index 100% rename from effects/thumbnailaside_config.desktop rename to effects/thumbnailaside/thumbnailaside_config.desktop diff --git a/effects/thumbnailaside_config.h b/effects/thumbnailaside/thumbnailaside_config.h similarity index 100% rename from effects/thumbnailaside_config.h rename to effects/thumbnailaside/thumbnailaside_config.h diff --git a/effects/thumbnailaside_config.ui b/effects/thumbnailaside/thumbnailaside_config.ui similarity index 100% rename from effects/thumbnailaside_config.ui rename to effects/thumbnailaside/thumbnailaside_config.ui diff --git a/effects/trackmouse/CMakeLists.txt b/effects/trackmouse/CMakeLists.txt new file mode 100644 index 0000000000..552e8adc6c --- /dev/null +++ b/effects/trackmouse/CMakeLists.txt @@ -0,0 +1,30 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + trackmouse/trackmouse.cpp + ) + +# .desktop files +install( FILES + trackmouse/trackmouse.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) + +# Data files +install( FILES + trackmouse/data/trackmouse.png + DESTINATION ${DATA_INSTALL_DIR}/kwin ) + +####################################### +# Config + +# Source files +set( kwin4_effect_builtins_config_sources ${kwin4_effect_builtins_config_sources} + trackmouse/trackmouse_config.cpp + ) + +# .desktop files +install( FILES + trackmouse/trackmouse_config.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/data/trackmouse.png b/effects/trackmouse/data/trackmouse.png similarity index 100% rename from effects/data/trackmouse.png rename to effects/trackmouse/data/trackmouse.png diff --git a/effects/trackmouse.cpp b/effects/trackmouse/trackmouse.cpp similarity index 100% rename from effects/trackmouse.cpp rename to effects/trackmouse/trackmouse.cpp diff --git a/effects/trackmouse.desktop b/effects/trackmouse/trackmouse.desktop similarity index 100% rename from effects/trackmouse.desktop rename to effects/trackmouse/trackmouse.desktop diff --git a/effects/trackmouse.h b/effects/trackmouse/trackmouse.h similarity index 100% rename from effects/trackmouse.h rename to effects/trackmouse/trackmouse.h diff --git a/effects/trackmouse_config.cpp b/effects/trackmouse/trackmouse_config.cpp similarity index 98% rename from effects/trackmouse_config.cpp rename to effects/trackmouse/trackmouse_config.cpp index a3c4af370c..89019c8077 100644 --- a/effects/trackmouse_config.cpp +++ b/effects/trackmouse/trackmouse_config.cpp @@ -29,12 +29,12 @@ along with this program. If not, see . #include #include -#ifndef KDE_USE_FINAL -KWIN_EFFECT_CONFIG_FACTORY -#endif + namespace KWin { +KWIN_EFFECT_CONFIG_FACTORY + TrackMouseEffectConfig::TrackMouseEffectConfig(QWidget* parent, const QVariantList& args) : KCModule(EffectFactory::componentData(), parent, args) { diff --git a/effects/trackmouse_config.desktop b/effects/trackmouse/trackmouse_config.desktop similarity index 100% rename from effects/trackmouse_config.desktop rename to effects/trackmouse/trackmouse_config.desktop diff --git a/effects/trackmouse_config.h b/effects/trackmouse/trackmouse_config.h similarity index 100% rename from effects/trackmouse_config.h rename to effects/trackmouse/trackmouse_config.h diff --git a/effects/translucency/CMakeLists.txt b/effects/translucency/CMakeLists.txt new file mode 100644 index 0000000000..ca65a0e01b --- /dev/null +++ b/effects/translucency/CMakeLists.txt @@ -0,0 +1,26 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + translucency/translucency.cpp + ) + +# .desktop files +install( FILES + translucency/translucency.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) + +####################################### +# Config + +# Source files +set( kwin4_effect_builtins_config_sources ${kwin4_effect_builtins_config_sources} + translucency/translucency_config.cpp + translucency/translucency_config.ui + ) + +# .desktop files +install( FILES + translucency/translucency_config.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/maketransparent.cpp b/effects/translucency/translucency.cpp similarity index 91% rename from effects/maketransparent.cpp rename to effects/translucency/translucency.cpp index dc0a9db583..9687a40943 100644 --- a/effects/maketransparent.cpp +++ b/effects/translucency/translucency.cpp @@ -18,16 +18,16 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . *********************************************************************/ -#include "maketransparent.h" +#include "translucency.h" #include namespace KWin { -KWIN_EFFECT( maketransparent, MakeTransparentEffect ) +KWIN_EFFECT( translucency, TranslucencyEffect ) -MakeTransparentEffect::MakeTransparentEffect() +TranslucencyEffect::TranslucencyEffect() : fadeout( NULL ) , current( NULL ) , previous( NULL ) @@ -36,9 +36,9 @@ MakeTransparentEffect::MakeTransparentEffect() active = effects->activeWindow(); } -void MakeTransparentEffect::reconfigure( ReconfigureFlags ) +void TranslucencyEffect::reconfigure( ReconfigureFlags ) { - KConfigGroup conf = effects->effectConfig("MakeTransparent"); + KConfigGroup conf = effects->effectConfig("Translucency"); decoration = conf.readEntry( "Decoration", 1.0 ); moveresize = conf.readEntry( "MoveResize", 0.8 ); dialogs = conf.readEntry( "Dialogs", 1.0 ); @@ -67,7 +67,7 @@ void MakeTransparentEffect::reconfigure( ReconfigureFlags ) effects->addRepaintFull(); } -void MakeTransparentEffect::prePaintWindow( EffectWindow* w, WindowPrePaintData& data, int time ) +void TranslucencyEffect::prePaintWindow( EffectWindow* w, WindowPrePaintData& data, int time ) { moveresize_timeline.addTime(time); activeinactive_timeline.addTime(time); @@ -96,7 +96,7 @@ void MakeTransparentEffect::prePaintWindow( EffectWindow* w, WindowPrePaintData& effects->prePaintWindow( w, data, time ); } -void MakeTransparentEffect::paintWindow( EffectWindow* w, int mask, QRegion region, WindowPaintData& data ) +void TranslucencyEffect::paintWindow( EffectWindow* w, int mask, QRegion region, WindowPaintData& data ) { // We keep track of the windows that was last active so we know // which one to fade out and which ones to paint as fully inactive @@ -180,7 +180,7 @@ void MakeTransparentEffect::paintWindow( EffectWindow* w, int mask, QRegion regi effects->paintWindow( w, mask, region, data ); } -bool MakeTransparentEffect::isInactive( const EffectWindow* w ) const +bool TranslucencyEffect::isInactive( const EffectWindow* w ) const { if( active == w || w->isDock() || !w->isManaged() ) return false; @@ -192,7 +192,7 @@ bool MakeTransparentEffect::isInactive( const EffectWindow* w ) const return true; } -void MakeTransparentEffect::windowUserMovedResized( EffectWindow* w, bool first, bool last ) +void TranslucencyEffect::windowUserMovedResized( EffectWindow* w, bool first, bool last ) { if( moveresize != 1.0 && ( first || last )) { @@ -201,7 +201,7 @@ void MakeTransparentEffect::windowUserMovedResized( EffectWindow* w, bool first, } } -void MakeTransparentEffect::windowActivated( EffectWindow* w ) +void TranslucencyEffect::windowActivated( EffectWindow* w ) { if( inactive != 1.0 ) { diff --git a/effects/maketransparent.desktop b/effects/translucency/translucency.desktop similarity index 98% rename from effects/maketransparent.desktop rename to effects/translucency/translucency.desktop index cd706f9153..ea2e5048df 100644 --- a/effects/maketransparent.desktop +++ b/effects/translucency/translucency.desktop @@ -71,7 +71,7 @@ Name[wa]=Transparince Name[x-test]=xxTranslucencyxx Name[zh_CN]=半透明 Name[zh_TW]=半透明 -Icon=preferences-system-windows-effect-maketransparent +Icon=preferences-system-windows-effect-translucency Comment=Make windows translucent under different conditions Comment[ar]=تجعل النوافذ شبه شفافة في شروط مختلفة Comment[be@latin]=Robić vokny prazrystymi dla peŭnych umovaŭ @@ -124,7 +124,7 @@ Type=Service X-KDE-ServiceTypes=KWin/Effect X-KDE-PluginInfo-Author=Luboš Luňák X-KDE-PluginInfo-Email=l.lunak@kde.org -X-KDE-PluginInfo-Name=kwin4_effect_maketransparent +X-KDE-PluginInfo-Name=kwin4_effect_translucency X-KDE-PluginInfo-Version=0.1.0 X-KDE-PluginInfo-Category=Appearance X-KDE-PluginInfo-Depends= diff --git a/effects/maketransparent.h b/effects/translucency/translucency.h similarity index 94% rename from effects/maketransparent.h rename to effects/translucency/translucency.h index d57571fbeb..cb17044e6b 100644 --- a/effects/maketransparent.h +++ b/effects/translucency/translucency.h @@ -18,19 +18,19 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . *********************************************************************/ -#ifndef KWIN_MAKETRANSPARENT_H -#define KWIN_MAKETRANSPARENT_H +#ifndef KWIN_TRANSLUCENCY_H +#define KWIN_TRANSLUCENCY_H #include namespace KWin { -class MakeTransparentEffect +class TranslucencyEffect : public Effect { public: - MakeTransparentEffect(); + TranslucencyEffect(); virtual void reconfigure( ReconfigureFlags ); virtual void windowUserMovedResized( EffectWindow* c, bool first, bool last ); virtual void prePaintWindow( EffectWindow* w, WindowPrePaintData& data, int time ); diff --git a/effects/maketransparent_config.cpp b/effects/translucency/translucency_config.cpp similarity index 86% rename from effects/maketransparent_config.cpp rename to effects/translucency/translucency_config.cpp index 82a4005309..c16f6a4552 100644 --- a/effects/maketransparent_config.cpp +++ b/effects/translucency/translucency_config.cpp @@ -18,7 +18,7 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . *********************************************************************/ -#include "maketransparent_config.h" +#include "translucency_config.h" #include @@ -29,21 +29,20 @@ along with this program. If not, see . #include #include -#ifndef KDE_USE_FINAL -KWIN_EFFECT_CONFIG_FACTORY -#endif - namespace KWin { -MakeTransparentEffectConfigForm::MakeTransparentEffectConfigForm(QWidget* parent) : QWidget(parent) + +KWIN_EFFECT_CONFIG_FACTORY + +TranslucencyEffectConfigForm::TranslucencyEffectConfigForm(QWidget* parent) : QWidget(parent) { setupUi(this); } -MakeTransparentEffectConfig::MakeTransparentEffectConfig(QWidget* parent, const QVariantList& args) : +TranslucencyEffectConfig::TranslucencyEffectConfig(QWidget* parent, const QVariantList& args) : KCModule(EffectFactory::componentData(), parent, args) { - m_ui = new MakeTransparentEffectConfigForm(this); + m_ui = new TranslucencyEffectConfigForm(this); QVBoxLayout* layout = new QVBoxLayout(this); layout->addWidget(m_ui); @@ -62,11 +61,11 @@ MakeTransparentEffectConfig::MakeTransparentEffectConfig(QWidget* parent, const load(); } -void MakeTransparentEffectConfig::load() +void TranslucencyEffectConfig::load() { KCModule::load(); - KConfigGroup conf = EffectsHandler::effectConfig("MakeTransparent"); + KConfigGroup conf = EffectsHandler::effectConfig("Translucency"); m_ui->decorations->setValue( (int)( conf.readEntry( "Decoration", 1.0 ) * 100 ) ); m_ui->moveresize->setValue( (int)( conf.readEntry( "MoveResize", 0.8 ) * 100 ) ); m_ui->dialogs->setValue( (int)( conf.readEntry( "Dialogs", 1.0 ) * 100 ) ); @@ -82,11 +81,11 @@ void MakeTransparentEffectConfig::load() emit changed(false); } -void MakeTransparentEffectConfig::save() +void TranslucencyEffectConfig::save() { KCModule::save(); - KConfigGroup conf = EffectsHandler::effectConfig("MakeTransparent"); + KConfigGroup conf = EffectsHandler::effectConfig("Translucency"); conf.writeEntry( "Decoration", m_ui->decorations->value() / 100.0 ); conf.writeEntry( "MoveResize", m_ui->moveresize->value() / 100.0 ); conf.writeEntry( "Dialogs", m_ui->dialogs->value() / 100.0 ); @@ -101,10 +100,10 @@ void MakeTransparentEffectConfig::save() conf.sync(); emit changed(false); - EffectsHandler::sendReloadMessage( "maketransparent" ); + EffectsHandler::sendReloadMessage( "translucency" ); } -void MakeTransparentEffectConfig::defaults() +void TranslucencyEffectConfig::defaults() { m_ui->decorations->setValue( 100 ); m_ui->moveresize->setValue( 80 ); @@ -123,4 +122,4 @@ void MakeTransparentEffectConfig::defaults() } // namespace -#include "maketransparent_config.moc" +#include "translucency_config.moc" diff --git a/effects/maketransparent_config.desktop b/effects/translucency/translucency_config.desktop similarity index 96% rename from effects/maketransparent_config.desktop rename to effects/translucency/translucency_config.desktop index 4cf8349629..09aa5455ab 100644 --- a/effects/maketransparent_config.desktop +++ b/effects/translucency/translucency_config.desktop @@ -3,8 +3,8 @@ Type=Service X-KDE-ServiceTypes=KCModule X-KDE-Library=kcm_kwin4_effect_builtins -X-KDE-ParentComponents=kwin4_effect_maketransparent -X-KDE-PluginKeyword=maketransparent +X-KDE-ParentComponents=kwin4_effect_translucency +X-KDE-PluginKeyword=translucency Name=Translucency Name[af]=Deursigtigheid diff --git a/effects/maketransparent_config.h b/effects/translucency/translucency_config.h similarity index 69% rename from effects/maketransparent_config.h rename to effects/translucency/translucency_config.h index a860b6faf0..bb802d7080 100644 --- a/effects/maketransparent_config.h +++ b/effects/translucency/translucency_config.h @@ -18,35 +18,35 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . *********************************************************************/ -#ifndef KWIN_MAKETRANSPARENT_CONFIG_H -#define KWIN_MAKETRANSPARENT_CONFIG_H +#ifndef KWIN_TRANSLUCENCY_CONFIG_H +#define KWIN_TRANSLUCENCY_CONFIG_H #include -#include "ui_maketransparent_config.h" +#include "ui_translucency_config.h" namespace KWin { -class MakeTransparentEffectConfigForm : public QWidget, public Ui::MakeTransparentEffectConfigForm +class TranslucencyEffectConfigForm : public QWidget, public Ui::TranslucencyEffectConfigForm { Q_OBJECT public: - explicit MakeTransparentEffectConfigForm(QWidget* parent); + explicit TranslucencyEffectConfigForm(QWidget* parent); }; -class MakeTransparentEffectConfig : public KCModule +class TranslucencyEffectConfig : public KCModule { Q_OBJECT public: - explicit MakeTransparentEffectConfig(QWidget* parent = 0, const QVariantList& args = QVariantList()); + explicit TranslucencyEffectConfig(QWidget* parent = 0, const QVariantList& args = QVariantList()); virtual void save(); virtual void load(); virtual void defaults(); private: - MakeTransparentEffectConfigForm* m_ui; + TranslucencyEffectConfigForm* m_ui; }; } // namespace diff --git a/effects/maketransparent_config.ui b/effects/translucency/translucency_config.ui similarity index 99% rename from effects/maketransparent_config.ui rename to effects/translucency/translucency_config.ui index afb47a4b4f..374c7029f5 100644 --- a/effects/maketransparent_config.ui +++ b/effects/translucency/translucency_config.ui @@ -1,6 +1,6 @@ - KWin::MakeTransparentEffectConfigForm - + KWin::TranslucencyEffectConfigForm + 0 diff --git a/effects/wobblywindows/CMakeLists.txt b/effects/wobblywindows/CMakeLists.txt new file mode 100644 index 0000000000..f3cb50b51a --- /dev/null +++ b/effects/wobblywindows/CMakeLists.txt @@ -0,0 +1,26 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + wobblywindows/wobblywindows.cpp + ) + +# .desktop files +install( FILES + wobblywindows/wobblywindows.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) + +####################################### +# Config + +# Source files +set( kwin4_effect_builtins_config_sources ${kwin4_effect_builtins_config_sources} + wobblywindows/wobblywindows_config.cpp + wobblywindows/wobblywindows_config.ui + ) + +# .desktop files +install( FILES + wobblywindows/wobblywindows_config.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/wobblywindows.cpp b/effects/wobblywindows/wobblywindows.cpp similarity index 100% rename from effects/wobblywindows.cpp rename to effects/wobblywindows/wobblywindows.cpp diff --git a/effects/wobblywindows.desktop b/effects/wobblywindows/wobblywindows.desktop similarity index 100% rename from effects/wobblywindows.desktop rename to effects/wobblywindows/wobblywindows.desktop diff --git a/effects/wobblywindows.h b/effects/wobblywindows/wobblywindows.h similarity index 100% rename from effects/wobblywindows.h rename to effects/wobblywindows/wobblywindows.h diff --git a/effects/wobblywindows_config.cpp b/effects/wobblywindows/wobblywindows_config.cpp similarity index 99% rename from effects/wobblywindows_config.cpp rename to effects/wobblywindows/wobblywindows_config.cpp index c1341c1df4..5019b49c5e 100644 --- a/effects/wobblywindows_config.cpp +++ b/effects/wobblywindows/wobblywindows_config.cpp @@ -28,13 +28,11 @@ along with this program. If not, see . #include #include -#ifndef KDE_USE_FINAL -KWIN_EFFECT_CONFIG_FACTORY -#endif - namespace KWin { +KWIN_EFFECT_CONFIG_FACTORY + //----------------------------------------------------------------------------- // WARNING: This is (kinda) copied from wobblywindows.cpp diff --git a/effects/wobblywindows_config.desktop b/effects/wobblywindows/wobblywindows_config.desktop similarity index 100% rename from effects/wobblywindows_config.desktop rename to effects/wobblywindows/wobblywindows_config.desktop diff --git a/effects/wobblywindows_config.h b/effects/wobblywindows/wobblywindows_config.h similarity index 100% rename from effects/wobblywindows_config.h rename to effects/wobblywindows/wobblywindows_config.h diff --git a/effects/wobblywindows_config.ui b/effects/wobblywindows/wobblywindows_config.ui similarity index 100% rename from effects/wobblywindows_config.ui rename to effects/wobblywindows/wobblywindows_config.ui diff --git a/effects/zoom/CMakeLists.txt b/effects/zoom/CMakeLists.txt new file mode 100644 index 0000000000..e3c8876c1b --- /dev/null +++ b/effects/zoom/CMakeLists.txt @@ -0,0 +1,25 @@ +####################################### +# Effect + +# Source files +set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + zoom/zoom.cpp + ) + +# .desktop files +install( FILES + zoom/zoom.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) + +####################################### +# Config + +# Source files +set( kwin4_effect_builtins_config_sources ${kwin4_effect_builtins_config_sources} + zoom/zoom_config.cpp + ) + +# .desktop files +install( FILES + zoom/zoom_config.desktop + DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/zoom.cpp b/effects/zoom/zoom.cpp similarity index 100% rename from effects/zoom.cpp rename to effects/zoom/zoom.cpp diff --git a/effects/zoom.desktop b/effects/zoom/zoom.desktop similarity index 100% rename from effects/zoom.desktop rename to effects/zoom/zoom.desktop diff --git a/effects/zoom.h b/effects/zoom/zoom.h similarity index 100% rename from effects/zoom.h rename to effects/zoom/zoom.h diff --git a/effects/zoom_config.cpp b/effects/zoom/zoom_config.cpp similarity index 99% rename from effects/zoom_config.cpp rename to effects/zoom/zoom_config.cpp index 9b533c3942..e388dec2c6 100644 --- a/effects/zoom_config.cpp +++ b/effects/zoom/zoom_config.cpp @@ -29,12 +29,12 @@ along with this program. If not, see . #include #include -#ifndef KDE_USE_FINAL -KWIN_EFFECT_CONFIG_FACTORY -#endif + namespace KWin { +KWIN_EFFECT_CONFIG_FACTORY + ZoomEffectConfig::ZoomEffectConfig(QWidget* parent, const QVariantList& args) : KCModule(EffectFactory::componentData(), parent, args) { diff --git a/effects/zoom_config.desktop b/effects/zoom/zoom_config.desktop similarity index 100% rename from effects/zoom_config.desktop rename to effects/zoom/zoom_config.desktop diff --git a/effects/zoom_config.h b/effects/zoom/zoom_config.h similarity index 100% rename from effects/zoom_config.h rename to effects/zoom/zoom_config.h diff --git a/lib/kwineffects.h b/lib/kwineffects.h index baa17382c7..b8ccf88cd5 100644 --- a/lib/kwineffects.h +++ b/lib/kwineffects.h @@ -462,12 +462,26 @@ class KWIN_EXPORT Effect * E.g. KWIN_EFFECT_CONFIG( flames, MyFlameEffectConfig ) **/ #define KWIN_EFFECT_CONFIG( name, classname ) \ - K_PLUGIN_FACTORY(name##_factory, registerPlugin();) \ - K_EXPORT_PLUGIN(name##_factory("kcm_kwineffect_" #name)) - + K_PLUGIN_FACTORY(EffectFactory, registerPlugin(#name);) \ + K_EXPORT_PLUGIN(EffectFactory("kcm_kwin4_effect_" #name)) +/** + * Defines the function used to retrieve multiple effects' config widget + * E.g. KWIN_EFFECT_CONFIG_MULTIPLE( flames, + * KWIN_EFFECT_CONFIG_SINGLE( flames, MyFlameEffectConfig ) + * KWIN_EFFECT_CONFIG_SINGLE( fire, MyFireEffectConfig ) + * ) + **/ +#define KWIN_EFFECT_CONFIG_MULTIPLE( name, singles ) \ + K_PLUGIN_FACTORY(EffectFactory, singles) \ + K_EXPORT_PLUGIN(EffectFactory("kcm_kwin4_effect_" #name)) +/** + * @see KWIN_EFFECT_CONFIG_MULTIPLE + */ +#define KWIN_EFFECT_CONFIG_SINGLE( name, classname ) \ + registerPlugin(#name); /** * The declaration of the factory to export the effect - **/ + */ #define KWIN_EFFECT_CONFIG_FACTORY K_PLUGIN_FACTORY_DECLARATION(EffectFactory) From a16aba4b059f1a01e7c18e7c2e669ac478bf033c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Fri, 6 Feb 2009 09:16:30 +0000 Subject: [PATCH 22/60] Merge in the first changes from cube git branch (http://github.com/mgraesslin/kwin/tree/cube): * Code restructuring and clean-up * Use of glLists to store the rotation and painting of the cube. That way things are only calculated when something changed. Painting the cube is still required in each frame as it would break all other effects. * Use face culling to paint the cube in the correct sequence. * Move loading of all settings to cube effect. In preparation of getting rid of cylinder and sphere classes Known regression: cylinder and sphere caps are partly broken. BUG: 171235 svn path=/trunk/KDE/kdebase/workspace/; revision=922023 --- effects/cube/cube.cpp | 330 +++++++++++++++++++++----------------- effects/cube/cube.h | 6 +- effects/cube/cylinder.cpp | 15 +- effects/cube/cylinder.h | 3 +- effects/cube/sphere.cpp | 11 +- 5 files changed, 190 insertions(+), 175 deletions(-) diff --git a/effects/cube/cube.cpp b/effects/cube/cube.cpp index 894bb14fa5..201cd9aaaf 100644 --- a/effects/cube/cube.cpp +++ b/effects/cube/cube.cpp @@ -81,7 +81,8 @@ CubeEffect::CubeEffect() , useForTabBox( false ) , tabBoxMode( false ) , capListCreated( false ) - , capList( 0 ) + , recompileList( true ) + , glList( 0 ) { reconfigure( ReconfigureAll ); @@ -116,12 +117,29 @@ void CubeEffect::loadConfig( QString config ) backgroundColor = conf.readEntry( "BackgroundColor", QColor( Qt::black ) ); animateDesktopChange = conf.readEntry( "AnimateDesktopChange", false ); bigCube = conf.readEntry( "BigCube", false ); + // different settings for cylinder and sphere + if( config == "Cylinder" ) + { + animateDesktopChange = false; + bigCube = true; + } + if( config == "Sphere" ) + { + animateDesktopChange = false; + bigCube = true; + reflection = false; + } capColor = conf.readEntry( "CapColor", KColorScheme( QPalette::Active, KColorScheme::Window ).background().color() ); paintCaps = conf.readEntry( "Caps", true ); closeOnMouseRelease = conf.readEntry( "CloseOnMouseRelease", false ); - zPosition = conf.readEntry( "ZPosition", 100.0 ); + float defaultZPosition = 100.0f; + if( config == "Sphere" ) + defaultZPosition = 450.0f; + zPosition = conf.readEntry( "ZPosition", defaultZPosition ); useForTabBox = conf.readEntry( "TabBox", false ); QString file = conf.readEntry( "Wallpaper", QString("") ); + if( wallpaper ) + wallpaper->discard(); delete wallpaper; wallpaper = NULL; if( !file.isEmpty() ) @@ -196,10 +214,12 @@ void CubeEffect::prePaintScreen( ScreenPrePaintData& data, int time ) if( rotating || start || stop ) { timeLine.addTime( time ); + recompileList = true; } if( verticalRotating ) { verticalTimeLine.addTime( time ); + recompileList = true; } } effects->prePaintScreen( data, time ); @@ -209,6 +229,23 @@ void CubeEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) { if( activated ) { + if( recompileList ) + { + recompileList = false; + glPushMatrix(); + glNewList( glList, GL_COMPILE ); + rotateCube(); + glEndList(); + glPopMatrix(); + } + + // compile List for cube + glNewList( glList + 1, GL_COMPILE ); + glPushMatrix(); + paintCube( mask, region, data ); + glPopMatrix(); + glEndList(); + QRect rect = effects->clientArea( FullScreenArea, activeScreen, effects->currentDesktop()); if( effects->numScreens() > 1 && (slide || bigCube ) ) rect = effects->clientArea( FullArea, activeScreen, effects->currentDesktop() ); @@ -288,6 +325,16 @@ void CubeEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) glTranslatef( xTranslate, yTranslate, 0.0 ); } + // some veriables needed for painting the caps + float cubeAngle = (float)((float)(effects->numberOfDesktops() - 2 )/(float)effects->numberOfDesktops() * 180.0f); + float point = rect.width()/2*tan(cubeAngle*0.5f*M_PI/180.0f); + float zTranslate = zPosition + zoom; + if( start ) + zTranslate *= timeLine.value(); + if( stop ) + zTranslate *= ( 1.0 - timeLine.value() ); + if( slide ) + zTranslate = 0.0; // reflection if( reflection && (!slide) ) { @@ -302,7 +349,51 @@ void CubeEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) glEnable( GL_CLIP_PLANE0 ); reflectionPainting = true; - paintScene( mask, region, data ); + glEnable( GL_CULL_FACE ); + // caps + if( paintCaps && ( effects->numberOfDesktops() >= 2 ) ) + { + glPushMatrix(); + glCallList( glList ); + glTranslatef( rect.width()/2, 0.0, -point-zTranslate ); + glRotatef( (1-frontDesktop)*360.0f / effects->numberOfDesktops(), 0.0, 1.0, 0.0 ); + glTranslatef( 0.0, rect.height(), 0.0 ); + glCullFace( GL_FRONT ); + glCallList( glList + 2 ); + glTranslatef( 0.0, -rect.height(), 0.0 ); + glCullFace( GL_BACK ); + glCallList( glList + 2 ); + glPopMatrix(); + } + + // cube + glCullFace( GL_FRONT ); + glPushMatrix(); + glCallList( glList ); + glCallList( glList + 1 ); + glPopMatrix(); + glCullFace( GL_BACK ); + glPushMatrix(); + glCallList( glList ); + glCallList( glList + 1 ); + glPopMatrix(); + + // cap + if( paintCaps && ( effects->numberOfDesktops() >= 2 ) ) + { + glPushMatrix(); + glCallList( glList ); + glTranslatef( rect.width()/2, 0.0, -point-zTranslate ); + glRotatef( (1-frontDesktop)*360.0f / effects->numberOfDesktops(), 0.0, 1.0, 0.0 ); + glTranslatef( 0.0, rect.height(), 0.0 ); + glCullFace( GL_BACK ); + glCallList( glList + 2 ); + glTranslatef( 0.0, -rect.height(), 0.0 ); + glCullFace( GL_FRONT ); + glCallList( glList + 2 ); + glPopMatrix(); + } + glDisable( GL_CULL_FACE ); reflectionPainting = false; glDisable( GL_CLIP_PLANE0 ); @@ -338,9 +429,51 @@ void CubeEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) glPopMatrix(); PaintClipper::pop( QRegion( rect )); } + glEnable( GL_CULL_FACE ); + // caps + if( paintCaps && ( effects->numberOfDesktops() >= 2 ) && !slide ) + { + glPushMatrix(); + glCallList( glList ); + glTranslatef( rect.width()/2, 0.0, -point-zTranslate ); + glRotatef( (1-frontDesktop)*360.0f / effects->numberOfDesktops(), 0.0, 1.0, 0.0 ); + glTranslatef( 0.0, rect.height(), 0.0 ); + glCullFace( GL_BACK ); + glCallList( glList + 2 ); + glTranslatef( 0.0, -rect.height(), 0.0 ); + glCullFace( GL_FRONT ); + glCallList( glList + 2 ); + glPopMatrix(); + } + + // cube + glCullFace( GL_BACK ); glPushMatrix(); - paintScene( mask, region, data ); + glCallList( glList ); + glCallList( glList + 1 ); glPopMatrix(); + glCullFace( GL_FRONT ); + glPushMatrix(); + glCallList( glList ); + glCallList( glList + 1 ); + glPopMatrix(); + + // cap + if( paintCaps && ( effects->numberOfDesktops() >= 2 ) && !slide ) + { + glPushMatrix(); + glCallList( glList ); + glTranslatef( rect.width()/2, 0.0, -point-zTranslate ); + glRotatef( (1-frontDesktop)*360.0f / effects->numberOfDesktops(), 0.0, 1.0, 0.0 ); + glTranslatef( 0.0, rect.height(), 0.0 ); + glCullFace( GL_FRONT ); + glCallList( glList + 2 ); + glTranslatef( 0.0, -rect.height(), 0.0 ); + glCullFace( GL_BACK ); + glCallList( glList + 2 ); + glPopMatrix(); + } + glDisable( GL_CULL_FACE ); if( effects->numScreens() > 1 && !slide && !bigCube ) { @@ -408,7 +541,7 @@ void CubeEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) } } -void CubeEffect::paintScene( int mask, QRegion region, ScreenPaintData& data ) +void CubeEffect::rotateCube() { QRect rect = effects->clientArea( FullScreenArea, activeScreen, effects->currentDesktop()); if( effects->numScreens() > 1 && (slide || bigCube ) ) @@ -441,13 +574,8 @@ void CubeEffect::paintScene( int mask, QRegion region, ScreenPaintData& data ) glScalef( xScale, yScale, 1.0 ); rect = fullRect; } - int rightSteps = effects->numberOfDesktops()/2; - int leftSteps = rightSteps+1; - int rightSideCounter = 0; - int leftSideCounter = 0; + float internalCubeAngle = 360.0f / effects->numberOfDesktops(); - cube_painting = true; - int desktopIndex = 0; float zTranslate = zPosition + zoom; if( start ) zTranslate *= timeLine.value(); @@ -455,14 +583,9 @@ void CubeEffect::paintScene( int mask, QRegion region, ScreenPaintData& data ) zTranslate *= ( 1.0 - timeLine.value() ); if( slide ) zTranslate = 0.0; - - bool topCapAfter = false; - bool topCapBefore = false; - // Rotation of the cube float cubeAngle = (float)((float)(effects->numberOfDesktops() - 2 )/(float)effects->numberOfDesktops() * 180.0f); float point = rect.width()/2*tan(cubeAngle*0.5f*M_PI/180.0f); - float zTexture = rect.width()/2*tan(45.0f*M_PI/180.0f); if( verticalRotating || verticalPosition != Normal || manualVerticalAngle != 0.0 ) { // change the verticalPosition if manualVerticalAngle > 90 or < -90 degrees @@ -523,71 +646,6 @@ void CubeEffect::paintScene( int mask, QRegion region, ScreenPaintData& data ) glTranslatef( rect.width()/2, rect.height()/2, -point-zTranslate ); glRotatef( angle, 1.0, 0.0, 0.0 ); glTranslatef( -rect.width()/2, -rect.height()/2, point+zTranslate ); - - // calculate if the caps have to be painted before/after or during desktop painting - if( paintCaps ) - { - float M[16]; - float P[16]; - float V[4]; - glGetFloatv( GL_PROJECTION_MATRIX, P ); - glGetFloatv( GL_MODELVIEW_MATRIX, M ); - glGetFloatv( GL_VIEWPORT, V ); - - // calculate y coordinate of the top of front desktop - float X = M[0]*0.0 + M[4]*0.0 + M[8]*(-zTranslate) + M[12]*1; - float Y = M[1]*0.0 + M[5]*0.0 + M[9]*(-zTranslate) + M[13]*1; - float Z = M[2]*0.0 + M[6]*0.0 + M[10]*(-zTranslate) + M[14]*1; - float W = M[3]*0.0 + M[7]*0.0 + M[11]*(-zTranslate) + M[15]*1; - float clipY = P[1]*X + P[5]*Y + P[9]*Z + P[13]*W; - float clipW = P[3]*X + P[7]*Y + P[11]*Z + P[15]*W; - float normY = clipY/clipW; - float yFront = (V[3]/2)*normY+(V[3]-V[1])/2; - - // calculate y coordinate of the bottom of front desktop - X = M[0]*0.0 + M[4]*rect.height() + M[8]*(-zTranslate) + M[12]*1; - Y = M[1]*0.0 + M[5]*rect.height() + M[9]*(-zTranslate) + M[13]*1; - Z = M[2]*0.0 + M[6]*rect.height() + M[10]*(-zTranslate) + M[14]*1; - W = M[3]*0.0 + M[7]*rect.height() + M[11]*(-zTranslate) + M[15]*1; - clipY = P[1]*X + P[5]*Y + P[9]*Z + P[13]*W; - clipW = P[3]*X + P[7]*Y + P[11]*Z + P[15]*W; - normY = clipY/clipW; - float yFrontBottom = (V[3]/2)*normY+(V[3]-V[1])/2; - - // change matrix to a rear position - glPushMatrix(); - glTranslatef( 0.0, 0.0, -point-zTranslate ); - float desktops = (effects->numberOfDesktops()/2.0); - glRotatef( desktops*internalCubeAngle, 1.0, 0.0, 0.0 ); - glTranslatef( 0.0, 0.0, point ); - glGetFloatv(GL_MODELVIEW_MATRIX, M); - // calculate y coordinate of the top of rear desktop - X = M[0]*0.0 + M[4]*0.0 + M[8]*0.0 + M[12]*1; - Y = M[1]*0.0 + M[5]*0.0 + M[9]*0.0 + M[13]*1; - Z = M[2]*0.0 + M[6]*0.0 + M[10]*0.0 + M[14]*1; - W = M[3]*0.0 + M[7]*0.0 + M[11]*0.0 + M[15]*1; - clipY = P[1]*X + P[5]*Y + P[9]*Z + P[13]*W; - clipW = P[3]*X + P[7]*Y + P[11]*Z + P[15]*W; - normY = clipY/clipW; - float yBack = (V[3]/2)*normY+(V[3]-V[1])/2; - - // calculate y coordniate of the bottom of rear desktop - glTranslatef( 0.0, -rect.height(), 0.0 ); - glGetFloatv(GL_MODELVIEW_MATRIX, M); - X = M[0]*0.0 + M[4]*0.0 + M[8]*0.0 + M[12]*1; - Y = M[1]*0.0 + M[5]*0.0 + M[9]*0.0 + M[13]*1; - Z = M[2]*0.0 + M[6]*0.0 + M[10]*0.0 + M[14]*1; - W = M[3]*0.0 + M[7]*0.0 + M[11]*0.0 + M[15]*1; - clipY = P[1]*X + P[5]*Y + P[9]*Z + P[13]*W; - clipW = P[3]*X + P[7]*Y + P[11]*Z + P[15]*W; - normY = clipY/clipW; - float yBackBottom = (V[3]/2)*normY+(V[3]-V[1])/2; - glPopMatrix(); - if( yBack >= yFront ) - topCapAfter = true; - if( yBackBottom <= yFrontBottom ) - topCapBefore = true; - } } if( rotating || (manualAngle != 0.0) ) { @@ -642,53 +700,31 @@ void CubeEffect::paintScene( int mask, QRegion region, ScreenPaintData& data ) glRotatef( rotationAngle, 0.0, 1.0, 0.0 ); glTranslatef( -rect.width()/2, -rect.height()/2, point+zTranslate ); } + } - if( topCapBefore || topCapAfter ) - { - if( (topCapAfter && !reflectionPainting) || (topCapBefore && reflectionPainting) ) - { - // paint the bottom cap - bottomCap = true; - glTranslatef( 0.0, rect.height(), 0.0 ); - paintCap( point, zTexture ); - glTranslatef( 0.0, -rect.height(), 0.0 ); - bottomCap = false; - } - if( (topCapBefore && !reflectionPainting) || (topCapAfter && reflectionPainting) ) - { - // paint the top cap - paintCap( point, zTexture ); - } - } +void CubeEffect::paintCube( int mask, QRegion region, ScreenPaintData& data ) + { + QRect rect = effects->clientArea( FullScreenArea, activeScreen, effects->currentDesktop()); + if( effects->numScreens() > 1 && (slide || bigCube ) ) + rect = effects->clientArea( FullArea, activeScreen, effects->currentDesktop() ); + float internalCubeAngle = 360.0f / effects->numberOfDesktops(); + cube_painting = true; + float zTranslate = zPosition + zoom; + if( start ) + zTranslate *= timeLine.value(); + if( stop ) + zTranslate *= ( 1.0 - timeLine.value() ); + if( slide ) + zTranslate = 0.0; + + // Rotation of the cube + float cubeAngle = (float)((float)(effects->numberOfDesktops() - 2 )/(float)effects->numberOfDesktops() * 180.0f); + float point = rect.width()/2*tan(cubeAngle*0.5f*M_PI/180.0f); for( int i=0; inumberOfDesktops(); i++ ) { - if( !topCapAfter && !topCapBefore && i == effects->numberOfDesktops()/2 -1 && !slide ) - { - // paint the bottom cap - bottomCap = true; - glTranslatef( 0.0, rect.height(), 0.0 ); - paintCap( point, zTexture ); - glTranslatef( 0.0, -rect.height(), 0.0 ); - bottomCap = false; - // paint the top cap - paintCap( point, zTexture ); - } - if( i%2 == 0 && i != effects->numberOfDesktops() -1) - { - // desktops on the right (including back) - desktopIndex = rightSteps - rightSideCounter; - rightSideCounter++; - } - else - { - // desktops on the left (including front) - desktopIndex = leftSteps + leftSideCounter; - leftSideCounter++; - } - // start painting the cube - painting_desktop = (desktopIndex + frontDesktop )%effects->numberOfDesktops(); + painting_desktop = (i + frontDesktop )%effects->numberOfDesktops(); if( painting_desktop == 0 ) { painting_desktop = effects->numberOfDesktops(); @@ -725,30 +761,13 @@ void CubeEffect::paintScene( int mask, QRegion region, ScreenPaintData& data ) ScreenPaintData newData = data; RotationData rot = RotationData(); rot.axis = RotationData::YAxis; - rot.angle = internalCubeAngle * desktopIndex; + rot.angle = internalCubeAngle * i; rot.xRotationPoint = rect.width()/2; rot.zRotationPoint = -point; newData.rotation = &rot; newData.zTranslate = -zTranslate; effects->paintScreen( mask, region, newData ); } - if( topCapBefore || topCapAfter ) - { - if( (topCapAfter && !reflectionPainting) || (topCapBefore && reflectionPainting) ) - { - // paint the top cap - paintCap( point, zTexture ); - } - if( (topCapBefore && !reflectionPainting) || (topCapAfter && reflectionPainting) ) - { - // paint the bottom cap - bottomCap = true; - glTranslatef( 0.0, rect.height(), 0.0 ); - paintCap( point, zTexture ); - glTranslatef( 0.0, -rect.height(), 0.0 ); - bottomCap = false; - } - } cube_painting = false; painting_desktop = effects->currentDesktop(); } @@ -777,11 +796,9 @@ void CubeEffect::paintCap( float z, float zTexture ) if( !capListCreated ) { capListCreated = true; - glNewList( capList, GL_COMPILE_AND_EXECUTE ); - bool texture = false; + glNewList( glList + 2, GL_COMPILE ); if( texturedCaps && effects->numberOfDesktops() > 3 && capTexture ) { - texture = true; paintCapStep( z, zTexture, true ); } else @@ -789,7 +806,7 @@ void CubeEffect::paintCap( float z, float zTexture ) glEndList(); } else - glCallList( capList ); + glCallList( glList + 2 ); glPopMatrix(); } @@ -965,7 +982,7 @@ void CubeEffect::postPaintScreen() effects->setActiveFullScreenEffect( 0 ); // delete the GL lists - glDeleteLists( capList, 1 ); + glDeleteLists( glList, 3 ); } effects->addRepaintFull(); } @@ -1328,7 +1345,7 @@ bool CubeEffect::borderActivated( ElectricBorder border ) void CubeEffect::toggle() { - if( effects->activeFullScreenEffect() && effects->activeFullScreenEffect() != this || + if( ( effects->activeFullScreenEffect() && effects->activeFullScreenEffect() != this ) || effects->numberOfDesktops() < 2 ) return; if( !activated ) @@ -1568,8 +1585,20 @@ void CubeEffect::setActive( bool active ) glPopMatrix(); } // create the needed GL lists - capList = glGenLists(1); + glList = glGenLists(3); capListCreated = false; + recompileList = true; + // create the capList + if( paintCaps ) + { + QRect rect = effects->clientArea( FullScreenArea, activeScreen, effects->currentDesktop()); + if( effects->numScreens() > 1 && (slide || bigCube ) ) + rect = effects->clientArea( FullArea, activeScreen, effects->currentDesktop() ); + float cubeAngle = (float)((float)(effects->numberOfDesktops() - 2 )/(float)effects->numberOfDesktops() * 180.0f); + float point = rect.width()/2*tan(cubeAngle*0.5f*M_PI/180.0f); + float zTexture = rect.width()/2*tan(45.0f*M_PI/180.0f); + paintCap( point, zTexture ); + } effects->addRepaintFull(); } @@ -1583,7 +1612,7 @@ void CubeEffect::setActive( bool active ) } void CubeEffect::mouseChanged( const QPoint& pos, const QPoint& oldpos, Qt::MouseButtons buttons, - Qt::MouseButtons oldbuttons, Qt::KeyboardModifiers modifiers, Qt::KeyboardModifiers oldmodifiers ) + Qt::MouseButtons oldbuttons, Qt::KeyboardModifiers, Qt::KeyboardModifiers ) { if( !activated ) return; @@ -1618,7 +1647,10 @@ void CubeEffect::mouseChanged( const QPoint& pos, const QPoint& oldpos, Qt::Mous repaint = true; } if( repaint ) + { + recompileList = true; effects->addRepaintFull(); + } } if( !oldbuttons.testFlag( Qt::LeftButton ) && buttons.testFlag( Qt::LeftButton ) ) { diff --git a/effects/cube/cube.h b/effects/cube/cube.h index eb4b72a32d..3ae771c785 100644 --- a/effects/cube/cube.h +++ b/effects/cube/cube.h @@ -68,10 +68,11 @@ class CubeEffect Normal, Down }; - virtual void paintScene( int mask, QRegion region, ScreenPaintData& data ); + virtual void paintCube( int mask, QRegion region, ScreenPaintData& data ); virtual void paintCap( float z, float zTexture ); virtual void paintCapStep( float z, float zTexture, bool texture ); void loadConfig( QString config ); + void rotateCube(); void rotateToDesktop( int desktop ); void setActive( bool active ); bool activated; @@ -123,7 +124,8 @@ class CubeEffect // GL lists bool capListCreated; - GLuint capList; + bool recompileList; + GLuint glList; }; } // namespace diff --git a/effects/cube/cylinder.cpp b/effects/cube/cylinder.cpp index 7393c21f9c..5735290d3e 100644 --- a/effects/cube/cylinder.cpp +++ b/effects/cube/cylinder.cpp @@ -39,8 +39,6 @@ CylinderEffect::CylinderEffect() , mValid( true ) , mShader( 0 ) { - if( wallpaper ) - wallpaper->discard(); reconfigure( ReconfigureAll ); } @@ -52,8 +50,6 @@ CylinderEffect::~CylinderEffect() void CylinderEffect::reconfigure( ReconfigureFlags ) { loadConfig( "Cylinder" ); - animateDesktopChange = false; - bigCube = true; } bool CylinderEffect::supported() @@ -93,7 +89,7 @@ bool CylinderEffect::loadData() return true; } -void CylinderEffect::paintScene( int mask, QRegion region, ScreenPaintData& data ) +void CylinderEffect::paintCube( int mask, QRegion region, ScreenPaintData& data ) { glPushMatrix(); QRect rect = effects->clientArea( FullArea, activeScreen, effects->currentDesktop()); @@ -105,7 +101,7 @@ void CylinderEffect::paintScene( int mask, QRegion region, ScreenPaintData& data // radius of the circle float radius = (rect.width()*0.5)/cos(radian); glTranslatef( 0.0, 0.0, midpoint - radius ); - CubeEffect::paintScene( mask, region, data ); + CubeEffect::paintCube( mask, region, data ); glPopMatrix(); } @@ -158,17 +154,12 @@ void CylinderEffect::paintWindow( EffectWindow* w, int mask, QRegion region, Win effects->paintWindow( w, mask, region, data ); } -void CylinderEffect::desktopChanged( int old ) - { - // cylinder effect is not useful to slide - } - void CylinderEffect::paintCap( float z, float zTexture ) { if( ( !paintCaps ) || effects->numberOfDesktops() <= 2 ) return; CubeEffect::paintCap( z, zTexture ); - QRect rect = effects->clientArea( FullArea, activeScreen, painting_desktop ); + QRect rect = effects->clientArea( FullArea, activeScreen, effects->currentDesktop() ); float cubeAngle = (effects->numberOfDesktops() - 2 )/(float)effects->numberOfDesktops() * 180.0f; float radian = (cubeAngle*0.5)*M_PI/180; diff --git a/effects/cube/cylinder.h b/effects/cube/cylinder.h index 372671fe5e..bb37a53338 100644 --- a/effects/cube/cylinder.h +++ b/effects/cube/cylinder.h @@ -36,11 +36,10 @@ class CylinderEffect virtual void reconfigure( ReconfigureFlags ); virtual void prePaintWindow( EffectWindow* w, WindowPrePaintData& data, int time ); virtual void paintWindow( EffectWindow* w, int mask, QRegion region, WindowPaintData& data ); - virtual void desktopChanged( int old ); static bool supported(); protected: - virtual void paintScene( int mask, QRegion region, ScreenPaintData& data ); + virtual void paintCube( int mask, QRegion region, ScreenPaintData& data ); virtual void paintCap( float z, float zTexture ); private: bool loadData(); diff --git a/effects/cube/sphere.cpp b/effects/cube/sphere.cpp index 25c5af6e96..7ef348cc30 100644 --- a/effects/cube/sphere.cpp +++ b/effects/cube/sphere.cpp @@ -22,7 +22,6 @@ along with this program. If not, see . #include #include -#include #include @@ -40,8 +39,6 @@ SphereEffect::SphereEffect() , mValid( true ) , mShader( 0 ) { - if( wallpaper ) - wallpaper->discard(); reconfigure( ReconfigureAll ); } @@ -53,12 +50,6 @@ SphereEffect::~SphereEffect() void SphereEffect::reconfigure( ReconfigureFlags ) { loadConfig( "Sphere" ); - reflection = false; - animateDesktopChange = false; - KConfigGroup conf = effects->effectConfig( "Sphere" ); - zPosition = conf.readEntry( "ZPosition", 450.0 ); - capDeformationFactor = conf.readEntry( "CapDeformation", 0 )/100.0f; - bigCube = true; } bool SphereEffect::supported() @@ -163,7 +154,7 @@ void SphereEffect::paintCap( float z, float zTexture ) void SphereEffect::paintCapStep( float z, float zTexture, bool texture ) { - QRect rect = effects->clientArea( FullArea, activeScreen, painting_desktop ); + QRect rect = effects->clientArea( FullArea, activeScreen, effects->currentDesktop() ); float cubeAngle = (effects->numberOfDesktops() - 2 )/(float)effects->numberOfDesktops() * 180.0f; float radius = (rect.width()*0.5)/cos(cubeAngle*0.5*M_PI/180.0); float angle = acos( (rect.height()*0.5)/radius )*180.0/M_PI; From b81bf26c77cddb89c2f222ee2ca3cd7eeadabd18 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Fri, 6 Feb 2009 09:20:34 +0000 Subject: [PATCH 23/60] Fill empty spaces in multi screen setup with cube cap color if caps are used. FEATURE: 169371 svn path=/trunk/KDE/kdebase/workspace/; revision=922024 --- effects/cube/cube.cpp | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/effects/cube/cube.cpp b/effects/cube/cube.cpp index 201cd9aaaf..68b990f388 100644 --- a/effects/cube/cube.cpp +++ b/effects/cube/cube.cpp @@ -1326,6 +1326,36 @@ void CubeEffect::paintWindow( EffectWindow* w, int mask, QRegion region, WindowP } data.quads = new_quads; } + if( w->isDesktop() && effects->numScreens() > 1 && paintCaps && !slide ) + { + QRegion paint = QRegion( rect ); + for( int i=0; inumScreens(); i++ ) + { + if( i == w->screen() ) + continue; + paint = paint.subtracted( QRegion( effects->clientArea( ScreenArea, i, painting_desktop ))); + } + paint = paint.subtracted( QRegion( w->geometry())); + // in case of free area in multiscreen setup fill it with cap color + if( !paint.isEmpty() ) + { + glColor4f( capColor.redF(), capColor.greenF(), capColor.blueF(), cubeOpacity ); + glPushAttrib( GL_CURRENT_BIT | GL_ENABLE_BIT ); + glEnable( GL_BLEND ); + glBlendFunc( GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA ); + glBegin( GL_QUADS ); + foreach( QRect paintRect, paint.rects() ) + { + glVertex2f( paintRect.x(), paintRect.y() ); + glVertex2f( paintRect.x()+paintRect.width(), paintRect.y() ); + glVertex2f( paintRect.x()+paintRect.width(), paintRect.y() + paintRect.height() ); + glVertex2f( paintRect.x(), paintRect.y() + paintRect.height() ); + } + glEnd(); + glDisable( GL_BLEND ); + glPopAttrib(); + } + } } effects->paintWindow( w, mask, region, data ); } From 59208e430a306029994549f6399769cd3490cdb4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Fri, 6 Feb 2009 09:24:12 +0000 Subject: [PATCH 24/60] Option to invert mouse and cursor keys in cube mode. FEATURE: 178398 svn path=/trunk/KDE/kdebase/workspace/; revision=922025 --- effects/cube/cube.cpp | 160 +++++++++++++++++++++++-------- effects/cube/cube.h | 2 + effects/cube/cube_config.cpp | 10 ++ effects/cube/cube_config.ui | 31 +++++- effects/cube/cylinder_config.cpp | 14 +++ effects/cube/cylinder_config.ui | 39 +++++--- effects/cube/sphere_config.cpp | 12 ++- effects/cube/sphere_config.ui | 37 ++++--- 8 files changed, 240 insertions(+), 65 deletions(-) diff --git a/effects/cube/cube.cpp b/effects/cube/cube.cpp index 68b990f388..dbeba8680c 100644 --- a/effects/cube/cube.cpp +++ b/effects/cube/cube.cpp @@ -137,6 +137,8 @@ void CubeEffect::loadConfig( QString config ) defaultZPosition = 450.0f; zPosition = conf.readEntry( "ZPosition", defaultZPosition ); useForTabBox = conf.readEntry( "TabBox", false ); + invertKeys = conf.readEntry( "InvertKeys", false ); + invertMouse = conf.readEntry( "InvertMouse", false ); QString file = conf.readEntry( "Wallpaper", QString("") ); if( wallpaper ) wallpaper->discard(); @@ -1420,12 +1422,20 @@ void CubeEffect::grabbedKeyboardEvent( QKeyEvent* e ) if( !rotating && !start ) { rotating = true; - rotationDirection = Left; + if( invertKeys ) + rotationDirection = Right; + else + rotationDirection = Left; } else { if( rotations.count() < effects->numberOfDesktops() ) - rotations.enqueue( Left ); + { + if( invertKeys ) + rotations.enqueue( Right ); + else + rotations.enqueue( Left ); + } } break; case Qt::Key_Right: @@ -1434,66 +1444,134 @@ void CubeEffect::grabbedKeyboardEvent( QKeyEvent* e ) if( !rotating && !start ) { rotating = true; - rotationDirection = Right; + if( invertKeys ) + rotationDirection = Left; + else + rotationDirection = Right; } else { if( rotations.count() < effects->numberOfDesktops() ) - rotations.enqueue( Right ); + { + if( invertKeys ) + rotations.enqueue( Left ); + else + rotations.enqueue( Right ); + } } break; case Qt::Key_Up: kDebug(1212) << "up"; - if( verticalPosition != Up ) + if( invertKeys ) { - if( !verticalRotating ) + if( verticalPosition != Down ) { - verticalRotating = true; - verticalRotationDirection = Upwards; - if( verticalPosition == Normal ) - verticalPosition = Up; - if( verticalPosition == Down ) - verticalPosition = Normal; + if( !verticalRotating ) + { + verticalRotating = true; + verticalRotationDirection = Downwards; + if( verticalPosition == Normal ) + verticalPosition = Down; + if( verticalPosition == Up ) + verticalPosition = Normal; + } + else + { + verticalRotations.enqueue( Downwards ); + } } - else + else if( manualVerticalAngle > 0.0 && !verticalRotating ) { - verticalRotations.enqueue( Upwards ); + // rotate to down position from the manual position + verticalRotating = true; + verticalRotationDirection = Downwards; + verticalPosition = Down; + manualVerticalAngle -= 90.0; } } - else if( manualVerticalAngle < 0.0 && !verticalRotating ) + else { - // rotate to up position from the manual position - verticalRotating = true; - verticalRotationDirection = Upwards; - verticalPosition = Up; - manualVerticalAngle += 90.0; + if( verticalPosition != Up ) + { + if( !verticalRotating ) + { + verticalRotating = true; + verticalRotationDirection = Upwards; + if( verticalPosition == Normal ) + verticalPosition = Up; + if( verticalPosition == Down ) + verticalPosition = Normal; + } + else + { + verticalRotations.enqueue( Upwards ); + } + } + else if( manualVerticalAngle < 0.0 && !verticalRotating ) + { + // rotate to up position from the manual position + verticalRotating = true; + verticalRotationDirection = Upwards; + verticalPosition = Up; + manualVerticalAngle += 90.0; + } } break; case Qt::Key_Down: kDebug(1212) << "down"; - if( verticalPosition != Down ) + if( invertKeys ) { - if( !verticalRotating ) + if( verticalPosition != Up ) { - verticalRotating = true; - verticalRotationDirection = Downwards; - if( verticalPosition == Normal ) - verticalPosition = Down; - if( verticalPosition == Up ) - verticalPosition = Normal; + if( !verticalRotating ) + { + verticalRotating = true; + verticalRotationDirection = Upwards; + if( verticalPosition == Normal ) + verticalPosition = Up; + if( verticalPosition == Down ) + verticalPosition = Normal; + } + else + { + verticalRotations.enqueue( Upwards ); + } } - else + else if( manualVerticalAngle < 0.0 && !verticalRotating ) { - verticalRotations.enqueue( Downwards ); + // rotate to up position from the manual position + verticalRotating = true; + verticalRotationDirection = Upwards; + verticalPosition = Up; + manualVerticalAngle += 90.0; } } - else if( manualVerticalAngle > 0.0 && !verticalRotating ) + else { - // rotate to down position from the manual position - verticalRotating = true; - verticalRotationDirection = Downwards; - verticalPosition = Down; - manualVerticalAngle -= 90.0; + if( verticalPosition != Down ) + { + if( !verticalRotating ) + { + verticalRotating = true; + verticalRotationDirection = Downwards; + if( verticalPosition == Normal ) + verticalPosition = Down; + if( verticalPosition == Up ) + verticalPosition = Normal; + } + else + { + verticalRotations.enqueue( Downwards ); + } + } + else if( manualVerticalAngle > 0.0 && !verticalRotating ) + { + // rotate to down position from the manual position + verticalRotating = true; + verticalRotationDirection = Downwards; + verticalPosition = Down; + manualVerticalAngle -= 90.0; + } } break; case Qt::Key_Escape: @@ -1662,7 +1740,10 @@ void CubeEffect::mouseChanged( const QPoint& pos, const QPoint& oldpos, Qt::Mous // display height corresponds to 180* int deltaY = pos.y() - oldpos.y(); float deltaVerticalDegrees = (float)deltaY/rect.height()*180.0f; - manualVerticalAngle -= deltaVerticalDegrees; + if( invertMouse ) + manualVerticalAngle += deltaVerticalDegrees; + else + manualVerticalAngle -= deltaVerticalDegrees; if( deltaVerticalDegrees != 0.0 ) repaint = true; } @@ -1672,7 +1753,10 @@ void CubeEffect::mouseChanged( const QPoint& pos, const QPoint& oldpos, Qt::Mous // display width corresponds to sum of angles of the polyhedron int deltaX = oldpos.x() - pos.x(); float deltaDegrees = (float)deltaX/rect.width() * 360.0f; - manualAngle -= deltaDegrees; + if( invertMouse ) + manualAngle += deltaDegrees; + else + manualAngle -= deltaDegrees; if( deltaDegrees != 0.0 ) repaint = true; } diff --git a/effects/cube/cube.h b/effects/cube/cube.h index 3ae771c785..1120f9dd2e 100644 --- a/effects/cube/cube.h +++ b/effects/cube/cube.h @@ -120,6 +120,8 @@ class CubeEffect float zoom; float zPosition; bool useForTabBox; + bool invertKeys; + bool invertMouse; bool tabBoxMode; // GL lists diff --git a/effects/cube/cube_config.cpp b/effects/cube/cube_config.cpp index f0283004be..2dc3ec39c9 100644 --- a/effects/cube/cube_config.cpp +++ b/effects/cube/cube_config.cpp @@ -81,6 +81,8 @@ CubeEffectConfig::CubeEffectConfig(QWidget* parent, const QVariantList& args) : connect(m_ui->closeOnMouseReleaseBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); connect(m_ui->zPositionSlider, SIGNAL(valueChanged(int)), this, SLOT(changed())); connect(m_ui->walkThroughDesktopBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); + connect(m_ui->invertKeysBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); + connect(m_ui->invertMouseBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); load(); } @@ -105,6 +107,8 @@ void CubeEffectConfig::load() bool walkThroughDesktop = conf.readEntry( "TabBox", false ); m_ui->zPositionSlider->setValue( conf.readEntry( "ZPosition", 100 ) ); m_ui->wallpaperRequester->setPath( conf.readEntry( "Wallpaper", "" ) ); + bool invertKeys = conf.readEntry( "InvertKeys", false ); + bool invertMouse = conf.readEntry( "InvertMouse", false ); m_ui->rotationDurationSpin->setValue( duration ); m_ui->cubeOpacitySlider->setValue( opacity ); @@ -175,6 +179,8 @@ void CubeEffectConfig::load() } m_ui->backgroundColorButton->setColor( background ); m_ui->capColorButton->setColor( capColor ); + m_ui->invertKeysBox->setChecked( invertKeys ); + m_ui->invertMouseBox->setChecked( invertMouse ); capsSelectionChanged(); emit changed(false); @@ -198,6 +204,8 @@ void CubeEffectConfig::save() conf.writeEntry( "Wallpaper", m_ui->wallpaperRequester->url().path() ); conf.writeEntry( "ZPosition", m_ui->zPositionSlider->value() ); conf.writeEntry( "TabBox", m_ui->walkThroughDesktopBox->checkState() == Qt::Checked ? true : false ); + conf.writeEntry( "InvertKeys", m_ui->invertKeysBox->isChecked() ); + conf.writeEntry( "InvertMouse", m_ui->invertMouseBox->isChecked() ); m_ui->editor->save(); @@ -224,6 +232,8 @@ void CubeEffectConfig::defaults() m_ui->wallpaperRequester->setPath( "" ); m_ui->zPositionSlider->setValue( 100 ); m_ui->walkThroughDesktopBox->setCheckState( Qt::Unchecked ); + m_ui->invertKeysBox->setChecked( false ); + m_ui->invertMouseBox->setChecked( false ); m_ui->editor->allDefault(); emit changed(true); } diff --git a/effects/cube/cube_config.ui b/effects/cube/cube_config.ui index 36bacd0d28..3a6318ae17 100644 --- a/effects/cube/cube_config.ui +++ b/effects/cube/cube_config.ui @@ -142,7 +142,7 @@ - Default + Default msec @@ -307,6 +307,19 @@ + + + + Qt::Vertical + + + + 20 + 40 + + + + @@ -419,6 +432,20 @@ otherwise it will remain active + + + + Invert courser keys + + + + + + + Invert mouse + + + @@ -463,6 +490,8 @@ otherwise it will remain active bigCubeBox closeOnMouseReleaseBox walkThroughDesktopBox + invertKeysBox + invertMouseBox zPositionSlider diff --git a/effects/cube/cylinder_config.cpp b/effects/cube/cylinder_config.cpp index e5a82df595..861b053c88 100644 --- a/effects/cube/cylinder_config.cpp +++ b/effects/cube/cylinder_config.cpp @@ -77,6 +77,9 @@ CylinderEffectConfig::CylinderEffectConfig(QWidget* parent, const QVariantList& connect(m_ui->closeOnMouseReleaseBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); connect(m_ui->zPositionSlider, SIGNAL(valueChanged(int)), this, SLOT(changed())); connect(m_ui->walkThroughDesktopBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); + connect(m_ui->invertKeysBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); + connect(m_ui->invertMouseBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); + load(); } @@ -99,6 +102,9 @@ void CylinderEffectConfig::load() bool walkThroughDesktop = conf.readEntry( "TabBox", false ); m_ui->zPositionSlider->setValue( conf.readEntry( "ZPosition", 100 ) ); m_ui->wallpaperRequester->setPath( conf.readEntry( "Wallpaper", "" ) ); + bool invertKeys = conf.readEntry( "InvertKeys", false ); + bool invertMouse = conf.readEntry( "InvertMouse", false ); + m_ui->rotationDurationSpin->setValue( duration ); m_ui->cubeOpacitySlider->setValue( opacity ); @@ -153,6 +159,9 @@ void CylinderEffectConfig::load() } m_ui->backgroundColorButton->setColor( background ); m_ui->capColorButton->setColor( capColor ); + m_ui->invertKeysBox->setChecked( invertKeys ); + m_ui->invertMouseBox->setChecked( invertMouse ); + capsSelectionChanged(); emit changed(false); @@ -174,6 +183,9 @@ void CylinderEffectConfig::save() conf.writeEntry( "Wallpaper", m_ui->wallpaperRequester->url().path() ); conf.writeEntry( "ZPosition", m_ui->zPositionSlider->value() ); conf.writeEntry( "TabBox", m_ui->walkThroughDesktopBox->checkState() == Qt::Checked ? true : false ); + conf.writeEntry( "InvertKeys", m_ui->invertKeysBox->isChecked() ); + conf.writeEntry( "InvertMouse", m_ui->invertMouseBox->isChecked() ); + m_ui->editor->save(); @@ -198,6 +210,8 @@ void CylinderEffectConfig::defaults() m_ui->wallpaperRequester->setPath( "" ); m_ui->zPositionSlider->setValue( 100 ); m_ui->walkThroughDesktopBox->setCheckState( Qt::Unchecked ); + m_ui->invertKeysBox->setChecked( false ); + m_ui->invertMouseBox->setChecked( false ); m_ui->editor->allDefault(); emit changed(true); } diff --git a/effects/cube/cylinder_config.ui b/effects/cube/cylinder_config.ui index dfbff8f373..057fd7fe62 100644 --- a/effects/cube/cylinder_config.ui +++ b/effects/cube/cylinder_config.ui @@ -142,7 +142,7 @@ - Default + Default msec @@ -307,6 +307,19 @@ + + + + Qt::Vertical + + + + 20 + 40 + + + + @@ -399,20 +412,18 @@ otherwise it will remain active. - - - Qt::Vertical + + + Invert courser keys - - QSizePolicy::Preferred + + + + + + Invert mouse - - - 20 - 0 - - - + @@ -456,6 +467,8 @@ otherwise it will remain active. capsImageBox closeOnMouseReleaseBox walkThroughDesktopBox + invertMouseBox + invertKeysBox zPositionSlider diff --git a/effects/cube/sphere_config.cpp b/effects/cube/sphere_config.cpp index 140d5638f3..cf5eb5e662 100644 --- a/effects/cube/sphere_config.cpp +++ b/effects/cube/sphere_config.cpp @@ -76,7 +76,9 @@ SphereEffectConfig::SphereEffectConfig(QWidget* parent, const QVariantList& args connect(m_ui->closeOnMouseReleaseBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); connect(m_ui->zPositionSlider, SIGNAL(valueChanged(int)), this, SLOT(changed())); connect(m_ui->capDeformationSlider, SIGNAL(valueChanged(int)), this, SLOT(changed())); - connect(m_ui->walkThroughDesktopBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); + connect(m_ui->walkThroughDesktopBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); + connect(m_ui->invertKeysBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); + connect(m_ui->invertMouseBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); load(); } @@ -99,6 +101,8 @@ void SphereEffectConfig::load() m_ui->zPositionSlider->setValue( conf.readEntry( "ZPosition", 450 ) ); m_ui->capDeformationSlider->setValue( conf.readEntry( "CapDeformation", 0 ) ); m_ui->wallpaperRequester->setPath( conf.readEntry( "Wallpaper", "" ) ); + bool invertKeys = conf.readEntry( "InvertKeys", false ); + bool invertMouse = conf.readEntry( "InvertMouse", false ); m_ui->rotationDurationSpin->setValue( duration ); m_ui->cubeOpacitySlider->setValue( opacity ); @@ -145,6 +149,8 @@ void SphereEffectConfig::load() } m_ui->backgroundColorButton->setColor( background ); m_ui->capColorButton->setColor( capColor ); + m_ui->invertKeysBox->setChecked( invertKeys ); + m_ui->invertMouseBox->setChecked( invertMouse ); capsSelectionChanged(); emit changed(false); @@ -166,6 +172,8 @@ void SphereEffectConfig::save() conf.writeEntry( "ZPosition", m_ui->zPositionSlider->value() ); conf.writeEntry( "CapDeformation", m_ui->capDeformationSlider->value() ); conf.writeEntry( "TabBox", m_ui->walkThroughDesktopBox->checkState() == Qt::Checked ? true : false ); + conf.writeEntry( "InvertKeys", m_ui->invertKeysBox->isChecked() ); + conf.writeEntry( "InvertMouse", m_ui->invertMouseBox->isChecked() ); m_ui->editor->save(); @@ -190,6 +198,8 @@ void SphereEffectConfig::defaults() m_ui->zPositionSlider->setValue( 450 ); m_ui->capDeformationSlider->setValue( 0 ); m_ui->walkThroughDesktopBox->setCheckState( Qt::Unchecked ); + m_ui->invertKeysBox->setChecked( false ); + m_ui->invertMouseBox->setChecked( false ); m_ui->editor->allDefault(); emit changed(true); } diff --git a/effects/cube/sphere_config.ui b/effects/cube/sphere_config.ui index 56d60d654a..bef6d65a1a 100644 --- a/effects/cube/sphere_config.ui +++ b/effects/cube/sphere_config.ui @@ -307,6 +307,19 @@ + + + + Qt::Vertical + + + + 20 + 40 + + + + @@ -399,20 +412,18 @@ otherwise it will remain active - - - Qt::Vertical + + + Invert courser keys - - QSizePolicy::Preferred + + + + + + Invert mouse - - - 20 - 0 - - - + @@ -498,6 +509,8 @@ otherwise it will remain active capsImageBox closeOnMouseReleaseBox walkThroughDesktopBox + invertMouseBox + invertKeysBox capDeformationSlider zPositionSlider From 026c90a983f01232d5c0bb6395c5d990c28be95a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Fri, 6 Feb 2009 09:27:40 +0000 Subject: [PATCH 25/60] Option to not animate the panels during desktop switching animation. FEATURE: 177730 svn path=/trunk/KDE/kdebase/workspace/; revision=922026 --- effects/cube/cube.cpp | 19 +++++++++++++++++++ effects/cube/cube.h | 3 +++ effects/cube/cube_config.cpp | 5 +++++ effects/cube/cube_config.ui | 8 ++++++++ 4 files changed, 35 insertions(+) diff --git a/effects/cube/cube.cpp b/effects/cube/cube.cpp index dbeba8680c..05f70ec610 100644 --- a/effects/cube/cube.cpp +++ b/effects/cube/cube.cpp @@ -139,6 +139,7 @@ void CubeEffect::loadConfig( QString config ) useForTabBox = conf.readEntry( "TabBox", false ); invertKeys = conf.readEntry( "InvertKeys", false ); invertMouse = conf.readEntry( "InvertMouse", false ); + dontSlidePanels = conf.readEntry( "DontSlidePanels", false ); QString file = conf.readEntry( "Wallpaper", QString("") ); if( wallpaper ) wallpaper->discard(); @@ -223,6 +224,8 @@ void CubeEffect::prePaintScreen( ScreenPrePaintData& data, int time ) verticalTimeLine.addTime( time ); recompileList = true; } + if( slide && dontSlidePanels ) + panels.clear(); } effects->prePaintScreen( data, time ); } @@ -536,6 +539,14 @@ void CubeEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) effects->paintWindow( w, 0, QRegion( w->x(), w->y(), w->width(), w->height() ), wData ); } } + if( slide && dontSlidePanels ) + { + foreach( EffectWindow* w, panels ) + { + WindowPaintData wData( w ); + effects->paintWindow( w, 0, QRegion( w->x(), w->y(), w->width(), w->height() ), wData ); + } + } } else { @@ -980,6 +991,8 @@ void CubeEffect::postPaintScreen() effects->ungrabKeyboard(); keyboard_grab = false; effects->destroyInputWindow( input ); + windowsOnOtherScreens.clear(); + panels.clear(); effects->setActiveFullScreenEffect( 0 ); @@ -1172,6 +1185,10 @@ void CubeEffect::prePaintWindow( EffectWindow* w, WindowPrePaintData& data, int } w->disablePainting( EffectWindow::PAINT_DISABLED_BY_DESKTOP ); } + if( slide && dontSlidePanels && w->isDock() && painting_desktop == effects->currentDesktop() ) + { + panels.append( w ); + } } } effects->prePaintWindow( w, data, time ); @@ -1181,6 +1198,8 @@ void CubeEffect::paintWindow( EffectWindow* w, int mask, QRegion region, WindowP { if( activated && cube_painting ) { + if( slide && dontSlidePanels && w->isDock() ) + return; //kDebug(1212) << w->caption(); float opacity = cubeOpacity; if( slide ) diff --git a/effects/cube/cube.h b/effects/cube/cube.h index 1120f9dd2e..7c0feda6e6 100644 --- a/effects/cube/cube.h +++ b/effects/cube/cube.h @@ -112,6 +112,7 @@ class CubeEffect int oldDesktop; int rotationDuration; QList windowsOnOtherScreens; + QList panels; int activeScreen; bool animateDesktopChange; bool bigCube; @@ -123,6 +124,8 @@ class CubeEffect bool invertKeys; bool invertMouse; bool tabBoxMode; + bool dontSlidePanels; + bool shortcutsRegistered; // GL lists bool capListCreated; diff --git a/effects/cube/cube_config.cpp b/effects/cube/cube_config.cpp index 2dc3ec39c9..d9ca3b0c0d 100644 --- a/effects/cube/cube_config.cpp +++ b/effects/cube/cube_config.cpp @@ -83,6 +83,7 @@ CubeEffectConfig::CubeEffectConfig(QWidget* parent, const QVariantList& args) : connect(m_ui->walkThroughDesktopBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); connect(m_ui->invertKeysBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); connect(m_ui->invertMouseBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); + connect(m_ui->dontSlidePanelsBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); load(); } @@ -109,6 +110,7 @@ void CubeEffectConfig::load() m_ui->wallpaperRequester->setPath( conf.readEntry( "Wallpaper", "" ) ); bool invertKeys = conf.readEntry( "InvertKeys", false ); bool invertMouse = conf.readEntry( "InvertMouse", false ); + bool dontSlidePanels = conf.readEntry( "DontSlidePanels", false ); m_ui->rotationDurationSpin->setValue( duration ); m_ui->cubeOpacitySlider->setValue( opacity ); @@ -181,6 +183,7 @@ void CubeEffectConfig::load() m_ui->capColorButton->setColor( capColor ); m_ui->invertKeysBox->setChecked( invertKeys ); m_ui->invertMouseBox->setChecked( invertMouse ); + m_ui->dontSlidePanelsBox->setChecked( dontSlidePanels ); capsSelectionChanged(); emit changed(false); @@ -206,6 +209,7 @@ void CubeEffectConfig::save() conf.writeEntry( "TabBox", m_ui->walkThroughDesktopBox->checkState() == Qt::Checked ? true : false ); conf.writeEntry( "InvertKeys", m_ui->invertKeysBox->isChecked() ); conf.writeEntry( "InvertMouse", m_ui->invertMouseBox->isChecked() ); + conf.writeEntry( "DontSlidePanels", m_ui->dontSlidePanelsBox->isChecked() ); m_ui->editor->save(); @@ -234,6 +238,7 @@ void CubeEffectConfig::defaults() m_ui->walkThroughDesktopBox->setCheckState( Qt::Unchecked ); m_ui->invertKeysBox->setChecked( false ); m_ui->invertMouseBox->setChecked( false ); + m_ui->dontSlidePanelsBox->setChecked( false ); m_ui->editor->allDefault(); emit changed(true); } diff --git a/effects/cube/cube_config.ui b/effects/cube/cube_config.ui index 3a6318ae17..16eb979ca3 100644 --- a/effects/cube/cube_config.ui +++ b/effects/cube/cube_config.ui @@ -403,6 +403,13 @@ + + + + Fix panels while switching desktops + + + @@ -487,6 +494,7 @@ otherwise it will remain active capColorButton capsImageBox animateDesktopChangeBox + dontSlidePanelsBox bigCubeBox closeOnMouseReleaseBox walkThroughDesktopBox From 642ae708b50ff9f1dd0b8000491e121defc3a45f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Fri, 6 Feb 2009 09:32:16 +0000 Subject: [PATCH 26/60] Cube uses the pager layout to animate desktop switching (not the cube mode). This requires some more work including an option to use the old way (ignoring pager layout). FEATURE: 167752 svn path=/trunk/KDE/kdebase/workspace/; revision=922028 --- effects/cube/cube.cpp | 237 +++++++++++++++++++++++++++++++++--------- effects/cube/cube.h | 3 + 2 files changed, 188 insertions(+), 52 deletions(-) diff --git a/effects/cube/cube.cpp b/effects/cube/cube.cpp index 05f70ec610..f6ed78533a 100644 --- a/effects/cube/cube.cpp +++ b/effects/cube/cube.cpp @@ -199,6 +199,8 @@ void CubeEffect::loadConfig( QString config ) verticalTimeLine.setCurveShape( TimeLine::EaseInOutCurve ); verticalTimeLine.setDuration( rotationDuration ); + slideTimeLine.setCurveShape( TimeLine::EaseInOutCurve ); + slideTimeLine.setDuration( rotationDuration ); } CubeEffect::~CubeEffect() @@ -224,8 +226,13 @@ void CubeEffect::prePaintScreen( ScreenPrePaintData& data, int time ) verticalTimeLine.addTime( time ); recompileList = true; } - if( slide && dontSlidePanels ) - panels.clear(); + if( slide && !slideRotations.empty() ) + { + slideTimeLine.addTime( time ); + recompileList = true; + if( dontSlidePanels ) + panels.clear(); + } } effects->prePaintScreen( data, time ); } @@ -239,7 +246,8 @@ void CubeEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) recompileList = false; glPushMatrix(); glNewList( glList, GL_COMPILE ); - rotateCube(); + if( !slide ) + rotateCube(); glEndList(); glPopMatrix(); } @@ -247,7 +255,10 @@ void CubeEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) // compile List for cube glNewList( glList + 1, GL_COMPILE ); glPushMatrix(); - paintCube( mask, region, data ); + if( slide ) + paintSlideCube( mask, region, data ); + else + paintCube( mask, region, data ); glPopMatrix(); glEndList(); @@ -338,8 +349,6 @@ void CubeEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) zTranslate *= timeLine.value(); if( stop ) zTranslate *= ( 1.0 - timeLine.value() ); - if( slide ) - zTranslate = 0.0; // reflection if( reflection && (!slide) ) { @@ -557,11 +566,11 @@ void CubeEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) void CubeEffect::rotateCube() { QRect rect = effects->clientArea( FullScreenArea, activeScreen, effects->currentDesktop()); - if( effects->numScreens() > 1 && (slide || bigCube ) ) + if( effects->numScreens() > 1 && bigCube ) rect = effects->clientArea( FullArea, activeScreen, effects->currentDesktop() ); float xScale = 1.0; float yScale = 1.0; - if( effects->numScreens() > 1 && !slide && !bigCube ) + if( effects->numScreens() > 1 && !bigCube ) { QRect fullRect = effects->clientArea( FullArea, activeScreen, effects->currentDesktop() ); xScale = (float)rect.width()/(float)fullRect.width(); @@ -594,8 +603,6 @@ void CubeEffect::rotateCube() zTranslate *= timeLine.value(); if( stop ) zTranslate *= ( 1.0 - timeLine.value() ); - if( slide ) - zTranslate = 0.0; // Rotation of the cube float cubeAngle = (float)((float)(effects->numberOfDesktops() - 2 )/(float)effects->numberOfDesktops() * 180.0f); float point = rect.width()/2*tan(cubeAngle*0.5f*M_PI/180.0f); @@ -718,7 +725,7 @@ void CubeEffect::rotateCube() void CubeEffect::paintCube( int mask, QRegion region, ScreenPaintData& data ) { QRect rect = effects->clientArea( FullScreenArea, activeScreen, effects->currentDesktop()); - if( effects->numScreens() > 1 && (slide || bigCube ) ) + if( effects->numScreens() > 1 && bigCube ) rect = effects->clientArea( FullArea, activeScreen, effects->currentDesktop() ); float internalCubeAngle = 360.0f / effects->numberOfDesktops(); cube_painting = true; @@ -727,8 +734,6 @@ void CubeEffect::paintCube( int mask, QRegion region, ScreenPaintData& data ) zTranslate *= timeLine.value(); if( stop ) zTranslate *= ( 1.0 - timeLine.value() ); - if( slide ) - zTranslate = 0.0; // Rotation of the cube float cubeAngle = (float)((float)(effects->numberOfDesktops() - 2 )/(float)effects->numberOfDesktops() * 180.0f); @@ -742,35 +747,6 @@ void CubeEffect::paintCube( int mask, QRegion region, ScreenPaintData& data ) { painting_desktop = effects->numberOfDesktops(); } - if( slide ) - { - // only paint required desktops during slide phase - if( painting_desktop != frontDesktop ) - { - int leftDesktop = frontDesktop - 1; - int rightDesktop = frontDesktop + 1; - if( leftDesktop == 0 ) - leftDesktop = effects->numberOfDesktops(); - if( rightDesktop > effects->numberOfDesktops() ) - rightDesktop = 1; - if( !desktopChangedWhileRotating && rotationDirection == Left && painting_desktop != rightDesktop ) - { - continue; - } - if( desktopChangedWhileRotating && rotationDirection == Left && painting_desktop != leftDesktop ) - { - continue; - } - if( !desktopChangedWhileRotating && rotationDirection == Right && painting_desktop != leftDesktop ) - { - continue; - } - if( desktopChangedWhileRotating && rotationDirection == Right && painting_desktop != rightDesktop ) - { - continue; - } - } - } ScreenPaintData newData = data; RotationData rot = RotationData(); rot.axis = RotationData::YAxis; @@ -785,6 +761,75 @@ void CubeEffect::paintCube( int mask, QRegion region, ScreenPaintData& data ) painting_desktop = effects->currentDesktop(); } +void CubeEffect::paintSlideCube(int mask, QRegion region, KWin::ScreenPaintData& data) + { + // slide cube only paints to desktops at a time + // first the horizontal rotations followed by vertical rotations + QRect rect = effects->clientArea( FullArea, activeScreen, effects->currentDesktop() ); + float point = rect.width()/2*tan(45.0f*M_PI/180.0f); + cube_painting = true; + painting_desktop = frontDesktop; + + ScreenPaintData firstFaceData = data; + ScreenPaintData secondFaceData = data; + RotationData firstFaceRot = RotationData(); + RotationData secondFaceRot = RotationData(); + RotationDirection direction = slideRotations.head(); + int secondDesktop; + switch ( direction ) + { + case Left: + firstFaceRot.axis = RotationData::YAxis; + secondFaceRot.axis = RotationData::YAxis; + secondDesktop = effects->desktopToLeft( frontDesktop, true ); + firstFaceRot.angle = 90.0f*slideTimeLine.value(); + secondFaceRot.angle = -90.0f*(1.0f - slideTimeLine.value()); + break; + case Right: + firstFaceRot.axis = RotationData::YAxis; + secondFaceRot.axis = RotationData::YAxis; + secondDesktop = effects->desktopToRight( frontDesktop, true ); + firstFaceRot.angle = -90.0f*slideTimeLine.value(); + secondFaceRot.angle = 90.0f*(1.0f - slideTimeLine.value()); + break; + case Upwards: + firstFaceRot.axis = RotationData::XAxis; + secondFaceRot.axis = RotationData::XAxis; + secondDesktop = effects->desktopUp( frontDesktop, true); + firstFaceRot.angle = -90.0f*slideTimeLine.value(); + secondFaceRot.angle = 90.0f*(1.0f - slideTimeLine.value()); + point = rect.height()/2*tan(45.0f*M_PI/180.0f); + break; + case Downwards: + firstFaceRot.axis = RotationData::XAxis; + secondFaceRot.axis = RotationData::XAxis; + secondDesktop = effects->desktopDown( frontDesktop, true ); + firstFaceRot.angle = 90.0f*slideTimeLine.value(); + secondFaceRot.angle = -90.0f*(1.0f - slideTimeLine.value()); + point = rect.height()/2*tan(45.0f*M_PI/180.0f); + break; + default: + // totally impossible + return; + } + // front desktop + firstFaceRot.xRotationPoint = rect.width()/2; + firstFaceRot.yRotationPoint = rect.height()/2; + firstFaceRot.zRotationPoint = -point; + firstFaceData.rotation = &firstFaceRot; + effects->paintScreen( mask, region, firstFaceData ); + // second desktop + painting_desktop = secondDesktop; + secondFaceRot.xRotationPoint = rect.width()/2; + secondFaceRot.yRotationPoint = rect.height()/2; + secondFaceRot.zRotationPoint = -point; + secondFaceData.rotation = &secondFaceRot; + effects->paintScreen( mask, region, secondFaceData ); + cube_painting = false; + painting_desktop = effects->currentDesktop(); + } + + void CubeEffect::paintCap( float z, float zTexture ) { QRect rect = effects->clientArea( FullArea, activeScreen, effects->currentDesktop()); @@ -1078,6 +1123,39 @@ void CubeEffect::postPaintScreen() effects->addRepaintFull(); return; // rotation has to end before cube is closed } + if( slide ) + { + if( slideTimeLine.value() == 1.0 ) + { + RotationDirection direction = slideRotations.dequeue(); + switch (direction) + { + case Left: + frontDesktop = effects->desktopToLeft( frontDesktop, true ); + break; + case Right: + frontDesktop = effects->desktopToRight( frontDesktop, true ); + break; + case Upwards: + frontDesktop = effects->desktopUp( frontDesktop, true ); + break; + case Downwards: + frontDesktop = effects->desktopDown( frontDesktop, true ); + break; + } + slideTimeLine.setProgress( 0.0 ); + if( !slideRotations.empty() ) + { + effects->addRepaintFull(); + return; + } + } + else + { + effects->addRepaintFull(); + return; + } + } if( schedule_close ) { schedule_close = false; @@ -1089,7 +1167,6 @@ void CubeEffect::postPaintScreen() { activated = false; slide = false; - timeLine.setDuration( rotationDuration ); effects->setActiveFullScreenEffect( 0 ); } effects->addRepaintFull(); @@ -1671,9 +1748,6 @@ void CubeEffect::rotateToDesktop( int desktop ) { currentShape = TimeLine::EaseInCurve; timeLine.setCurveShape( currentShape ); - // change timeline duration in slide mode - if( slide ) - timeLine.setDuration( rotationDuration / (rotations.count()+1) ); } } @@ -1716,7 +1790,7 @@ void CubeEffect::setActive( bool active ) capListCreated = false; recompileList = true; // create the capList - if( paintCaps ) + if( paintCaps && !slide ) { QRect rect = effects->clientArea( FullScreenArea, activeScreen, effects->currentDesktop()); if( effects->numScreens() > 1 && (slide || bigCube ) ) @@ -1806,16 +1880,75 @@ void CubeEffect::desktopChanged( int old ) { if( effects->activeFullScreenEffect() && effects->activeFullScreenEffect() != this ) return; - if( activated ) + if( activated && !slide ) return; if( !animateDesktopChange ) return; slide = true; + bool activate = true; + if( !slideRotations.empty() ) + { + // last slide still in progress + activate = false; + old = frontDesktop; + RotationDirection direction = slideRotations.dequeue(); + slideRotations.clear(); + slideRotations.enqueue( direction ); + } oldDesktop = old; - setActive( true ); - frontDesktop = old; - rotateToDesktop( effects->currentDesktop() ); - setActive( false ); + // calculate distance in respect to pager + int x, y; + Qt::Orientation orientation; + effects->calcDesktopLayout( &x, &y, &orientation ); + int x_distance = (( effects->currentDesktop() - 1 ) % x ) - (( old - 1 ) % x ); + if( qAbs( x_distance ) > x/2 ) + { + int sign = -1 * (x_distance/qAbs( x_distance )); + x_distance = sign * ( x - qAbs( x_distance )); + } + if( x_distance > 0 ) + { + for( int i=0; icurrentDesktop() -1 ) / x ) - (( old - 1 ) / x ); + if( qAbs( y_distance ) > y/2 ) + { + int sign = -1 * (y_distance/qAbs( y_distance )); + y_distance = sign * ( y - qAbs( y_distance )); + } + if( y_distance > 0 ) + { + for( int i=0; i rotations; QQueue verticalRotations; + QQueue slideRotations; QColor backgroundColor; QColor capColor; GLTexture* wallpaper; From 7b5a71d2dd1b7d440c5d65de5c9feb52f0ec25f4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Fri, 6 Feb 2009 09:37:18 +0000 Subject: [PATCH 27/60] Option to not change the opacity of windows in cube mode. That way only the cube (that is the desktops) will be painted in a transparent way. FEATURE: 182195 svn path=/trunk/KDE/kdebase/workspace/; revision=922029 --- effects/cube/cube.cpp | 6 +++++- effects/cube/cube.h | 1 + effects/cube/cube_config.cpp | 5 +++++ effects/cube/cube_config.ui | 10 +++++++++- effects/cube/cylinder_config.cpp | 5 +++++ effects/cube/cylinder_config.ui | 10 +++++++++- effects/cube/sphere_config.cpp | 5 +++++ effects/cube/sphere_config.ui | 10 +++++++++- 8 files changed, 48 insertions(+), 4 deletions(-) diff --git a/effects/cube/cube.cpp b/effects/cube/cube.cpp index f6ed78533a..b7c7dbfd0e 100644 --- a/effects/cube/cube.cpp +++ b/effects/cube/cube.cpp @@ -52,7 +52,8 @@ CubeEffect::CubeEffect() , borderActivate( ElectricNone ) , frontDesktop( 0 ) , cubeOpacity( 1.0 ) - , displayDesktopName( true ) + , opacityDesktopOnly( true ) + , displayDesktopName( false ) , reflection( true ) , rotating( false ) , desktopChangedWhileRotating( false ) @@ -111,6 +112,7 @@ void CubeEffect::loadConfig( QString config ) effects->reserveElectricBorder( borderActivate ); cubeOpacity = (float)conf.readEntry( "Opacity", 80 )/100.0f; + opacityDesktopOnly = conf.readEntry( "OpacityDesktopOnly", false ); displayDesktopName = conf.readEntry( "DisplayDesktopName", true ); reflection = conf.readEntry( "Reflection", true ); rotationDuration = animationTime( conf, "RotationDuration", 500 ); @@ -1373,6 +1375,8 @@ void CubeEffect::paintWindow( EffectWindow* w, int mask, QRegion region, WindowP // bug #173214 if( opacity > 0.99f ) opacity = 0.99f; + if( opacityDesktopOnly && !w->isDesktop() ) + opacity = 0.99f; data.opacity *= opacity; } diff --git a/effects/cube/cube.h b/effects/cube/cube.h index 3c56088b85..50e9f5d4bc 100644 --- a/effects/cube/cube.h +++ b/effects/cube/cube.h @@ -85,6 +85,7 @@ class CubeEffect Window input; int frontDesktop; float cubeOpacity; + bool opacityDesktopOnly; bool displayDesktopName; bool reflection; bool rotating; diff --git a/effects/cube/cube_config.cpp b/effects/cube/cube_config.cpp index d9ca3b0c0d..f28504af16 100644 --- a/effects/cube/cube_config.cpp +++ b/effects/cube/cube_config.cpp @@ -68,6 +68,7 @@ CubeEffectConfig::CubeEffectConfig(QWidget* parent, const QVariantList& args) : connect(m_ui->rotationDurationSpin, SIGNAL(valueChanged(int)), this, SLOT(changed())); connect(m_ui->cubeOpacitySlider, SIGNAL(valueChanged(int)), this, SLOT(changed())); connect(m_ui->cubeOpacitySpin, SIGNAL(valueChanged(int)), this, SLOT(changed())); + connect(m_ui->desktopOpacityOnlyBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); connect(m_ui->displayDesktopNameBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); connect(m_ui->reflectionBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); connect(m_ui->backgroundColorButton, SIGNAL(changed(QColor)), this, SLOT(changed())); @@ -96,6 +97,7 @@ void CubeEffectConfig::load() int duration = conf.readEntry( "RotationDuration", 0 ); float opacity = conf.readEntry( "Opacity", 80 ); + bool desktopOpacityOnly = conf.readEntry( "OpacityDesktopOnly", false ); bool desktopName = conf.readEntry( "DisplayDesktopName", true ); bool reflection = conf.readEntry( "Reflection", true ); QColor background = conf.readEntry( "BackgroundColor", QColor( Qt::black ) ); @@ -115,6 +117,7 @@ void CubeEffectConfig::load() m_ui->rotationDurationSpin->setValue( duration ); m_ui->cubeOpacitySlider->setValue( opacity ); m_ui->cubeOpacitySpin->setValue( opacity ); + m_ui->desktopOpacityOnlyBox->setChecked( desktopOpacityOnly ); if( desktopName ) { m_ui->displayDesktopNameBox->setCheckState( Qt::Checked ); @@ -197,6 +200,7 @@ void CubeEffectConfig::save() conf.writeEntry( "DisplayDesktopName", m_ui->displayDesktopNameBox->checkState() == Qt::Checked ? true : false ); conf.writeEntry( "Reflection", m_ui->reflectionBox->checkState() == Qt::Checked ? true : false ); conf.writeEntry( "Opacity", m_ui->cubeOpacitySpin->value() ); + conf.writeEntry( "OpacityDesktopOnly", m_ui->desktopOpacityOnlyBox->isChecked() ); conf.writeEntry( "BackgroundColor", m_ui->backgroundColorButton->color() ); conf.writeEntry( "Caps", m_ui->cubeCapsBox->checkState() == Qt::Checked ? true : false ); conf.writeEntry( "CapColor", m_ui->capColorButton->color() ); @@ -226,6 +230,7 @@ void CubeEffectConfig::defaults() m_ui->reflectionBox->setCheckState( Qt::Checked ); m_ui->cubeOpacitySpin->setValue( 80 ); m_ui->cubeOpacitySlider->setValue( 80 ); + m_ui->desktopOpacityOnlyBox->setChecked( false ); m_ui->backgroundColorButton->setColor( QColor( Qt::black ) ); m_ui->cubeCapsBox->setCheckState( Qt::Checked ); m_ui->capColorButton->setColor( KColorScheme( QPalette::Active, KColorScheme::Window ).background().color() ); diff --git a/effects/cube/cube_config.ui b/effects/cube/cube_config.ui index 16eb979ca3..8ecbfa7b4a 100644 --- a/effects/cube/cube_config.ui +++ b/effects/cube/cube_config.ui @@ -5,7 +5,7 @@ 0 0 - 610 + 700 566 @@ -241,6 +241,13 @@ + + + + Do not change opacity of windows + + + @@ -488,6 +495,7 @@ otherwise it will remain active rotationDurationSpin cubeOpacitySlider cubeOpacitySpin + desktopOpacityOnlyBox backgroundColorButton wallpaperRequester cubeCapsBox diff --git a/effects/cube/cylinder_config.cpp b/effects/cube/cylinder_config.cpp index 861b053c88..4971996953 100644 --- a/effects/cube/cylinder_config.cpp +++ b/effects/cube/cylinder_config.cpp @@ -66,6 +66,7 @@ CylinderEffectConfig::CylinderEffectConfig(QWidget* parent, const QVariantList& connect(m_ui->rotationDurationSpin, SIGNAL(valueChanged(int)), this, SLOT(changed())); connect(m_ui->cubeOpacitySlider, SIGNAL(valueChanged(int)), this, SLOT(changed())); connect(m_ui->cubeOpacitySpin, SIGNAL(valueChanged(int)), this, SLOT(changed())); + connect(m_ui->desktopOpacityOnlyBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); connect(m_ui->displayDesktopNameBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); connect(m_ui->reflectionBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); connect(m_ui->backgroundColorButton, SIGNAL(changed(QColor)), this, SLOT(changed())); @@ -92,6 +93,7 @@ void CylinderEffectConfig::load() int duration = conf.readEntry( "RotationDuration", 0 ); float opacity = conf.readEntry( "Opacity", 80 ); + bool desktopOpacityOnly = conf.readEntry( "OpacityDesktopOnly", false ); bool desktopName = conf.readEntry( "DisplayDesktopName", true ); bool reflection = conf.readEntry( "Reflection", true ); QColor background = conf.readEntry( "BackgroundColor", QColor( Qt::black ) ); @@ -109,6 +111,7 @@ void CylinderEffectConfig::load() m_ui->rotationDurationSpin->setValue( duration ); m_ui->cubeOpacitySlider->setValue( opacity ); m_ui->cubeOpacitySpin->setValue( opacity ); + m_ui->desktopOpacityOnlyBox->setChecked( desktopOpacityOnly ); if( desktopName ) { m_ui->displayDesktopNameBox->setCheckState( Qt::Checked ); @@ -175,6 +178,7 @@ void CylinderEffectConfig::save() conf.writeEntry( "DisplayDesktopName", m_ui->displayDesktopNameBox->checkState() == Qt::Checked ? true : false ); conf.writeEntry( "Reflection", m_ui->reflectionBox->checkState() == Qt::Checked ? true : false ); conf.writeEntry( "Opacity", m_ui->cubeOpacitySpin->value() ); + conf.writeEntry( "OpacityDesktopOnly", m_ui->desktopOpacityOnlyBox->isChecked() ); conf.writeEntry( "BackgroundColor", m_ui->backgroundColorButton->color() ); conf.writeEntry( "Caps", m_ui->cubeCapsBox->checkState() == Qt::Checked ? true : false ); conf.writeEntry( "CapColor", m_ui->capColorButton->color() ); @@ -202,6 +206,7 @@ void CylinderEffectConfig::defaults() m_ui->reflectionBox->setCheckState( Qt::Checked ); m_ui->cubeOpacitySpin->setValue( 80 ); m_ui->cubeOpacitySlider->setValue( 80 ); + m_ui->desktopOpacityOnlyBox->setChecked( false ); m_ui->backgroundColorButton->setColor( QColor( Qt::black ) ); m_ui->cubeCapsBox->setCheckState( Qt::Checked ); m_ui->capColorButton->setColor( KColorScheme( QPalette::Active, KColorScheme::Window ).background().color() ); diff --git a/effects/cube/cylinder_config.ui b/effects/cube/cylinder_config.ui index 057fd7fe62..433db2d8f9 100644 --- a/effects/cube/cylinder_config.ui +++ b/effects/cube/cylinder_config.ui @@ -5,7 +5,7 @@ 0 0 - 610 + 729 542 @@ -241,6 +241,13 @@ + + + + Do not change opacity of windows + + + @@ -460,6 +467,7 @@ otherwise it will remain active. rotationDurationSpin cubeOpacitySlider cubeOpacitySpin + desktopOpacityOnlyBox backgroundColorButton wallpaperRequester cubeCapsBox diff --git a/effects/cube/sphere_config.cpp b/effects/cube/sphere_config.cpp index cf5eb5e662..9e0df2d548 100644 --- a/effects/cube/sphere_config.cpp +++ b/effects/cube/sphere_config.cpp @@ -66,6 +66,7 @@ SphereEffectConfig::SphereEffectConfig(QWidget* parent, const QVariantList& args connect(m_ui->rotationDurationSpin, SIGNAL(valueChanged(int)), this, SLOT(changed())); connect(m_ui->cubeOpacitySlider, SIGNAL(valueChanged(int)), this, SLOT(changed())); connect(m_ui->cubeOpacitySpin, SIGNAL(valueChanged(int)), this, SLOT(changed())); + connect(m_ui->desktopOpacityOnlyBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); connect(m_ui->displayDesktopNameBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); connect(m_ui->backgroundColorButton, SIGNAL(changed(QColor)), this, SLOT(changed())); connect(m_ui->cubeCapsBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); @@ -91,6 +92,7 @@ void SphereEffectConfig::load() int duration = conf.readEntry( "RotationDuration", 0 ); float opacity = conf.readEntry( "Opacity", 80 ); + bool desktopOpacityOnly = conf.readEntry( "OpacityDesktopOnly", false ); bool desktopName = conf.readEntry( "DisplayDesktopName", true ); QColor background = conf.readEntry( "BackgroundColor", QColor( Qt::black ) ); QColor capColor = conf.readEntry( "CapColor", KColorScheme( QPalette::Active, KColorScheme::Window ).background().color() ); @@ -107,6 +109,7 @@ void SphereEffectConfig::load() m_ui->rotationDurationSpin->setValue( duration ); m_ui->cubeOpacitySlider->setValue( opacity ); m_ui->cubeOpacitySpin->setValue( opacity ); + m_ui->desktopOpacityOnlyBox->setChecked( desktopOpacityOnly ); if( desktopName ) { m_ui->displayDesktopNameBox->setCheckState( Qt::Checked ); @@ -163,6 +166,7 @@ void SphereEffectConfig::save() conf.writeEntry( "RotationDuration", m_ui->rotationDurationSpin->value() ); conf.writeEntry( "DisplayDesktopName", m_ui->displayDesktopNameBox->checkState() == Qt::Checked ? true : false ); conf.writeEntry( "Opacity", m_ui->cubeOpacitySpin->value() ); + conf.writeEntry( "OpacityDesktopOnly", m_ui->desktopOpacityOnlyBox->isChecked() ); conf.writeEntry( "BackgroundColor", m_ui->backgroundColorButton->color() ); conf.writeEntry( "Caps", m_ui->cubeCapsBox->checkState() == Qt::Checked ? true : false ); conf.writeEntry( "CapColor", m_ui->capColorButton->color() ); @@ -189,6 +193,7 @@ void SphereEffectConfig::defaults() m_ui->displayDesktopNameBox->setCheckState( Qt::Checked ); m_ui->cubeOpacitySpin->setValue( 80 ); m_ui->cubeOpacitySlider->setValue( 80 ); + m_ui->desktopOpacityOnlyBox->setChecked( false ); m_ui->backgroundColorButton->setColor( QColor( Qt::black ) ); m_ui->cubeCapsBox->setCheckState( Qt::Checked ); m_ui->capColorButton->setColor( KColorScheme( QPalette::Active, KColorScheme::Window ).background().color() ); diff --git a/effects/cube/sphere_config.ui b/effects/cube/sphere_config.ui index bef6d65a1a..406cf3a13c 100644 --- a/effects/cube/sphere_config.ui +++ b/effects/cube/sphere_config.ui @@ -5,7 +5,7 @@ 0 0 - 610 + 700 542 @@ -241,6 +241,13 @@ + + + + Do not change opacity of windows + + + @@ -502,6 +509,7 @@ otherwise it will remain active rotationDurationSpin cubeOpacitySlider cubeOpacitySpin + desktopOpacityOnlyBox backgroundColorButton wallpaperRequester cubeCapsBox From a3c57fcab032be324f6581125ec763ddd06ca881 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Fri, 6 Feb 2009 09:39:57 +0000 Subject: [PATCH 28/60] Option to not animate windows shown on all desktops during desktop switching animation. svn path=/trunk/KDE/kdebase/workspace/; revision=922030 --- effects/cube/cube.cpp | 26 ++++++- effects/cube/cube.h | 5 +- effects/cube/cube_config.cpp | 9 ++- effects/cube/cube_config.ui | 143 ++++++++++++++++++++++++----------- 4 files changed, 133 insertions(+), 50 deletions(-) diff --git a/effects/cube/cube.cpp b/effects/cube/cube.cpp index b7c7dbfd0e..53890e68a4 100644 --- a/effects/cube/cube.cpp +++ b/effects/cube/cube.cpp @@ -141,7 +141,8 @@ void CubeEffect::loadConfig( QString config ) useForTabBox = conf.readEntry( "TabBox", false ); invertKeys = conf.readEntry( "InvertKeys", false ); invertMouse = conf.readEntry( "InvertMouse", false ); - dontSlidePanels = conf.readEntry( "DontSlidePanels", false ); + dontSlidePanels = conf.readEntry( "DontSlidePanels", true ); + dontSlideStickyWindows = conf.readEntry( "DontSlideStickyWindows", true ); QString file = conf.readEntry( "Wallpaper", QString("") ); if( wallpaper ) wallpaper->discard(); @@ -234,6 +235,8 @@ void CubeEffect::prePaintScreen( ScreenPrePaintData& data, int time ) recompileList = true; if( dontSlidePanels ) panels.clear(); + if( dontSlideStickyWindows ) + stickyWindows.clear(); } } effects->prePaintScreen( data, time ); @@ -558,6 +561,14 @@ void CubeEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) effects->paintWindow( w, 0, QRegion( w->x(), w->y(), w->width(), w->height() ), wData ); } } + if( slide && dontSlideStickyWindows ) + { + foreach( EffectWindow* w, stickyWindows ) + { + WindowPaintData wData( w ); + effects->paintWindow( w, 0, QRegion( w->x(), w->y(), w->width(), w->height() ), wData ); + } + } } else { @@ -1040,6 +1051,7 @@ void CubeEffect::postPaintScreen() effects->destroyInputWindow( input ); windowsOnOtherScreens.clear(); panels.clear(); + stickyWindows.clear(); effects->setActiveFullScreenEffect( 0 ); @@ -1264,9 +1276,14 @@ void CubeEffect::prePaintWindow( EffectWindow* w, WindowPrePaintData& data, int } w->disablePainting( EffectWindow::PAINT_DISABLED_BY_DESKTOP ); } - if( slide && dontSlidePanels && w->isDock() && painting_desktop == effects->currentDesktop() ) + if( slide && dontSlidePanels && w->isDock()) { - panels.append( w ); + panels.insert( w ); + } + if( slide && dontSlideStickyWindows && !w->isDock() && + !w->isDesktop() && w->isOnAllDesktops()) + { + stickyWindows.insert( w ); } } } @@ -1279,6 +1296,9 @@ void CubeEffect::paintWindow( EffectWindow* w, int mask, QRegion region, WindowP { if( slide && dontSlidePanels && w->isDock() ) return; + if( slide && dontSlideStickyWindows && + w->isOnAllDesktops() && !w->isDock() && !w->isDesktop() ) + return; //kDebug(1212) << w->caption(); float opacity = cubeOpacity; if( slide ) diff --git a/effects/cube/cube.h b/effects/cube/cube.h index 50e9f5d4bc..0e67a71781 100644 --- a/effects/cube/cube.h +++ b/effects/cube/cube.h @@ -25,6 +25,7 @@ along with this program. If not, see . #include #include #include +#include namespace KWin { @@ -116,7 +117,8 @@ class CubeEffect int oldDesktop; int rotationDuration; QList windowsOnOtherScreens; - QList panels; + QSet panels; + QSet stickyWindows; int activeScreen; bool animateDesktopChange; bool bigCube; @@ -129,6 +131,7 @@ class CubeEffect bool invertMouse; bool tabBoxMode; bool dontSlidePanels; + bool dontSlideStickyWindows; bool shortcutsRegistered; // GL lists diff --git a/effects/cube/cube_config.cpp b/effects/cube/cube_config.cpp index f28504af16..643e60ecfb 100644 --- a/effects/cube/cube_config.cpp +++ b/effects/cube/cube_config.cpp @@ -85,6 +85,7 @@ CubeEffectConfig::CubeEffectConfig(QWidget* parent, const QVariantList& args) : connect(m_ui->invertKeysBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); connect(m_ui->invertMouseBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); connect(m_ui->dontSlidePanelsBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); + connect(m_ui->dontSlideStickyWindowsBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); load(); } @@ -112,7 +113,8 @@ void CubeEffectConfig::load() m_ui->wallpaperRequester->setPath( conf.readEntry( "Wallpaper", "" ) ); bool invertKeys = conf.readEntry( "InvertKeys", false ); bool invertMouse = conf.readEntry( "InvertMouse", false ); - bool dontSlidePanels = conf.readEntry( "DontSlidePanels", false ); + bool dontSlidePanels = conf.readEntry( "DontSlidePanels", true ); + bool dontSlideStickyWindows = conf.readEntry( "DontSlideStickyWindows", true ); m_ui->rotationDurationSpin->setValue( duration ); m_ui->cubeOpacitySlider->setValue( opacity ); @@ -187,6 +189,7 @@ void CubeEffectConfig::load() m_ui->invertKeysBox->setChecked( invertKeys ); m_ui->invertMouseBox->setChecked( invertMouse ); m_ui->dontSlidePanelsBox->setChecked( dontSlidePanels ); + m_ui->dontSlideStickyWindowsBox->setChecked( dontSlideStickyWindows ); capsSelectionChanged(); emit changed(false); @@ -214,6 +217,7 @@ void CubeEffectConfig::save() conf.writeEntry( "InvertKeys", m_ui->invertKeysBox->isChecked() ); conf.writeEntry( "InvertMouse", m_ui->invertMouseBox->isChecked() ); conf.writeEntry( "DontSlidePanels", m_ui->dontSlidePanelsBox->isChecked() ); + conf.writeEntry( "DontSlideStickyWindows", m_ui->dontSlideStickyWindowsBox->isChecked() ); m_ui->editor->save(); @@ -243,7 +247,8 @@ void CubeEffectConfig::defaults() m_ui->walkThroughDesktopBox->setCheckState( Qt::Unchecked ); m_ui->invertKeysBox->setChecked( false ); m_ui->invertMouseBox->setChecked( false ); - m_ui->dontSlidePanelsBox->setChecked( false ); + m_ui->dontSlidePanelsBox->setChecked( true ); + m_ui->dontSlideStickyWindowsBox->setChecked( true ); m_ui->editor->allDefault(); emit changed(true); } diff --git a/effects/cube/cube_config.ui b/effects/cube/cube_config.ui index 8ecbfa7b4a..fd180f0367 100644 --- a/effects/cube/cube_config.ui +++ b/effects/cube/cube_config.ui @@ -5,7 +5,7 @@ 0 0 - 700 + 747 566 @@ -314,23 +314,10 @@ - - - - Qt::Vertical - - - - 20 - 40 - - - - - + Zoom @@ -381,7 +368,7 @@ - + Qt::Vertical @@ -394,29 +381,12 @@ - + Additional Options - - - - - - - Display the cube when switching desktops - - - - - - - Fix panels while switching desktops - - - @@ -460,6 +430,58 @@ otherwise it will remain active + + + + Qt::Vertical + + + + 20 + 40 + + + + + + + + + + + Animate Desktop Change + + + + + + + + + Display the cube when switching desktops + + + + + + + false + + + Do not animate panels + + + + + + + false + + + Do not animate windows on all desktops + + + @@ -501,13 +523,14 @@ otherwise it will remain active cubeCapsBox capColorButton capsImageBox - animateDesktopChangeBox - dontSlidePanelsBox bigCubeBox closeOnMouseReleaseBox walkThroughDesktopBox invertKeysBox invertMouseBox + animateDesktopChangeBox + dontSlidePanelsBox + dontSlideStickyWindowsBox zPositionSlider @@ -519,12 +542,12 @@ otherwise it will remain active setValue(int) - 386 - 175 + 725 + 102 - 235 - 162 + 568 + 101 @@ -535,12 +558,44 @@ otherwise it will remain active setValue(int) - 133 - 162 + 466 + 101 - 386 - 175 + 725 + 102 + + + + + animateDesktopChangeBox + toggled(bool) + dontSlidePanelsBox + setEnabled(bool) + + + 147 + 209 + + + 147 + 232 + + + + + animateDesktopChangeBox + toggled(bool) + dontSlideStickyWindowsBox + setEnabled(bool) + + + 53 + 209 + + + 27 + 261 From daa32a53fb7fdd619596097d96f9d07719b1bcea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Fri, 6 Feb 2009 09:45:34 +0000 Subject: [PATCH 29/60] Adding mouse wheel support to effects. First one to use is cube effect. CCMAIL: marco.gulino@gmail.com svn path=/trunk/KDE/kdebase/workspace/; revision=922031 --- effects/cube/cube.cpp | 53 +++++++++++++++++++++++++++++++++++++++++++ effects/cube/cube.h | 1 + utils.cpp | 8 +++++++ 3 files changed, 62 insertions(+) diff --git a/effects/cube/cube.cpp b/effects/cube/cube.cpp index 53890e68a4..caa918b35c 100644 --- a/effects/cube/cube.cpp +++ b/effects/cube/cube.cpp @@ -1900,6 +1900,59 @@ void CubeEffect::mouseChanged( const QPoint& pos, const QPoint& oldpos, Qt::Mous } } +void CubeEffect::windowInputMouseEvent( Window w, QEvent* e ) + { + assert( w == input ); + QMouseEvent *mouse = dynamic_cast< QMouseEvent* >( e ); + if( mouse && mouse->type() == QEvent::MouseButtonRelease ) + { + if( mouse->button() == Qt::XButton1 ) + { + if( !rotating && !start ) + { + rotating = true; + if( invertMouse ) + rotationDirection = Right; + else + rotationDirection = Left; + } + else + { + if( rotations.count() < effects->numberOfDesktops() ) + { + if( invertMouse ) + rotations.enqueue( Right ); + else + rotations.enqueue( Left ); + } + } + effects->addRepaintFull(); + } + if( mouse->button() == Qt::XButton2 ) + { + if( !rotating && !start ) + { + rotating = true; + if( invertMouse ) + rotationDirection = Left; + else + rotationDirection = Right; + } + else + { + if( rotations.count() < effects->numberOfDesktops() ) + { + if( invertMouse ) + rotations.enqueue( Left ); + else + rotations.enqueue( Right ); + } + } + effects->addRepaintFull(); + } + } + } + void CubeEffect::desktopChanged( int old ) { if( effects->activeFullScreenEffect() && effects->activeFullScreenEffect() != this ) diff --git a/effects/cube/cube.h b/effects/cube/cube.h index 0e67a71781..0e61ba55ce 100644 --- a/effects/cube/cube.h +++ b/effects/cube/cube.h @@ -47,6 +47,7 @@ class CubeEffect virtual void grabbedKeyboardEvent( QKeyEvent* e ); virtual void mouseChanged( const QPoint& pos, const QPoint& oldpos, Qt::MouseButtons buttons, Qt::MouseButtons oldbuttons, Qt::KeyboardModifiers modifiers, Qt::KeyboardModifiers oldmodifiers ); + virtual void windowInputMouseEvent( Window w, QEvent* e ); virtual void desktopChanged( int old ); virtual void tabBoxAdded( int mode ); virtual void tabBoxUpdated(); diff --git a/utils.cpp b/utils.cpp index e9dc085941..a1d0ca80c9 100644 --- a/utils.cpp +++ b/utils.cpp @@ -334,6 +334,10 @@ Qt::MouseButton x11ToQtMouseButton( int button ) return Qt::MidButton; if( button == Button3 ) return Qt::RightButton; + if( button == Button4 ) + return Qt::XButton1; + if( button == Button5 ) + return Qt::XButton2; return Qt::NoButton; } @@ -366,6 +370,10 @@ Qt::MouseButtons x11ToQtMouseButtons( int state ) ret |= Qt::MidButton; if( state & Button3Mask ) ret |= Qt::RightButton; + if( state & Button4Mask ) + ret |= Qt::XButton1; + if( state & Button5Mask ) + ret |= Qt::XButton2; return ret; } From 502fdbb751f27ef35bfed0ac173dc95b439e74a3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Fri, 6 Feb 2009 09:51:04 +0000 Subject: [PATCH 30/60] Cylinder and Sphere effect have their own shortcut. Nevertheless it's still not possible to use cube and cylinder or sphere. That'll be fixed when the effects are merged into cube. BUG: 175788 svn path=/trunk/KDE/kdebase/workspace/; revision=922033 --- effects/cube/cube.cpp | 34 ++++++++++++++++++++++++++------ effects/cube/cylinder.cpp | 1 + effects/cube/cylinder_config.cpp | 8 ++++---- effects/cube/sphere.cpp | 1 + effects/cube/sphere_config.cpp | 8 ++++---- 5 files changed, 38 insertions(+), 14 deletions(-) diff --git a/effects/cube/cube.cpp b/effects/cube/cube.cpp index caa918b35c..589ab8615c 100644 --- a/effects/cube/cube.cpp +++ b/effects/cube/cube.cpp @@ -81,17 +81,12 @@ CubeEffect::CubeEffect() , zPosition( 0.0 ) , useForTabBox( false ) , tabBoxMode( false ) + , shortcutsRegistered( false ) , capListCreated( false ) , recompileList( true ) , glList( 0 ) { reconfigure( ReconfigureAll ); - - KActionCollection* actionCollection = new KActionCollection( this ); - KAction* a = static_cast< KAction* >( actionCollection->addAction( "Cube" )); - a->setText( i18n("Desktop Cube" )); - a->setGlobalShortcut( KShortcut( Qt::CTRL + Qt::Key_F11 )); - connect( a, SIGNAL( triggered( bool )), this, SLOT( toggle())); } bool CubeEffect::supported() @@ -204,6 +199,33 @@ void CubeEffect::loadConfig( QString config ) verticalTimeLine.setDuration( rotationDuration ); slideTimeLine.setCurveShape( TimeLine::EaseInOutCurve ); slideTimeLine.setDuration( rotationDuration ); + + // do not connect the shortcut if we use cylinder or sphere + KActionCollection* actionCollection = new KActionCollection( this ); + if( config == "Cube" && !shortcutsRegistered ) + { + KAction* a = static_cast< KAction* >( actionCollection->addAction( "Cube" )); + a->setText( i18n("Desktop Cube" )); + a->setGlobalShortcut( KShortcut( Qt::CTRL + Qt::Key_F11 )); + connect( a, SIGNAL( triggered( bool )), this, SLOT( toggle())); + shortcutsRegistered = true; + } + if( config == "Cylinder" && !shortcutsRegistered ) + { + KAction* a = static_cast< KAction* >( actionCollection->addAction( "Cylinder" )); + a->setText( i18n("Desktop Cylinder" )); + a->setGlobalShortcut( KShortcut( Qt::CTRL + Qt::SHIFT + Qt::Key_F11 )); + connect( a, SIGNAL( triggered( bool )), this, SLOT( toggle())); + shortcutsRegistered = true; + } + if( config == "Sphere" && !shortcutsRegistered ) + { + KAction* a = static_cast< KAction* >( actionCollection->addAction( "Sphere" )); + a->setText( i18n("Desktop Sphere" )); + a->setGlobalShortcut( KShortcut( Qt::CTRL + Qt::META + Qt::Key_F11 )); + connect( a, SIGNAL( triggered( bool )), this, SLOT( toggle())); + shortcutsRegistered = true; + } } CubeEffect::~CubeEffect() diff --git a/effects/cube/cylinder.cpp b/effects/cube/cylinder.cpp index 5735290d3e..e5dfe8ca5b 100644 --- a/effects/cube/cylinder.cpp +++ b/effects/cube/cylinder.cpp @@ -39,6 +39,7 @@ CylinderEffect::CylinderEffect() , mValid( true ) , mShader( 0 ) { + shortcutsRegistered = false; reconfigure( ReconfigureAll ); } diff --git a/effects/cube/cylinder_config.cpp b/effects/cube/cylinder_config.cpp index 4971996953..4a3068e5bf 100644 --- a/effects/cube/cylinder_config.cpp +++ b/effects/cube/cylinder_config.cpp @@ -53,13 +53,13 @@ CylinderEffectConfig::CylinderEffectConfig(QWidget* parent, const QVariantList& m_ui->tabWidget->setTabText( 1, i18nc("@title:tab Advanced Settings", "Advanced") ); m_actionCollection = new KActionCollection( this, componentData() ); - m_actionCollection->setConfigGroup( "Cube" ); + m_actionCollection->setConfigGroup( "Cylinder" ); m_actionCollection->setConfigGlobal(true); - KAction* a = (KAction*) m_actionCollection->addAction( "Cube" ); - a->setText( i18n("Desktop Cube" )); + KAction* a = (KAction*) m_actionCollection->addAction( "Cylinder" ); + a->setText( i18n("Desktop Cylinder" )); a->setProperty("isConfigurationAction", true); - a->setGlobalShortcut( KShortcut( Qt::CTRL + Qt::Key_F11 )); + a->setGlobalShortcut( KShortcut( Qt::CTRL + Qt::SHIFT + Qt::Key_F11 )); m_ui->editor->addCollection(m_actionCollection); diff --git a/effects/cube/sphere.cpp b/effects/cube/sphere.cpp index 7ef348cc30..2b63ccb1d4 100644 --- a/effects/cube/sphere.cpp +++ b/effects/cube/sphere.cpp @@ -39,6 +39,7 @@ SphereEffect::SphereEffect() , mValid( true ) , mShader( 0 ) { + shortcutsRegistered = false; reconfigure( ReconfigureAll ); } diff --git a/effects/cube/sphere_config.cpp b/effects/cube/sphere_config.cpp index 9e0df2d548..eb22b7714d 100644 --- a/effects/cube/sphere_config.cpp +++ b/effects/cube/sphere_config.cpp @@ -53,13 +53,13 @@ SphereEffectConfig::SphereEffectConfig(QWidget* parent, const QVariantList& args m_ui->tabWidget->setTabText( 1, i18nc("@title:tab Advanced Settings", "Advanced") ); m_actionCollection = new KActionCollection( this, componentData() ); - m_actionCollection->setConfigGroup( "Cube" ); + m_actionCollection->setConfigGroup( "Sphere" ); m_actionCollection->setConfigGlobal(true); - KAction* a = (KAction*) m_actionCollection->addAction( "Cube" ); - a->setText( i18n("Desktop Cube" )); + KAction* a = (KAction*) m_actionCollection->addAction( "Sphere" ); + a->setText( i18n("Desktop Sphere" )); a->setProperty("isConfigurationAction", true); - a->setGlobalShortcut( KShortcut( Qt::CTRL + Qt::Key_F11 )); + a->setGlobalShortcut( KShortcut( Qt::CTRL + Qt::META + Qt::Key_F11 )); m_ui->editor->addCollection(m_actionCollection); From a1c82cd52bc835a3d4078976c61b703e41647db8 Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Fri, 6 Feb 2009 10:15:06 +0000 Subject: [PATCH 31/60] Added support for inter-effect communication through the use of proxy classes. Example code has been added to present windows and desktop grid, if this code is not to be used by KDE 4.3 it should be removed and added to a test effect instead. svn path=/trunk/KDE/kdebase/workspace/; revision=922039 --- effects.cpp | 12 +++++ effects.h | 1 + effects/desktopgrid/desktopgrid.cpp | 11 +++++ effects/presentwindows/CMakeLists.txt | 1 + effects/presentwindows/presentwindows.cpp | 8 +++- effects/presentwindows/presentwindows.h | 7 +++ .../presentwindows/presentwindows_proxy.cpp | 41 +++++++++++++++++ effects/presentwindows/presentwindows_proxy.h | 44 +++++++++++++++++++ lib/kwineffects.cpp | 5 +++ lib/kwineffects.h | 11 +++++ 10 files changed, 140 insertions(+), 1 deletion(-) create mode 100644 effects/presentwindows/presentwindows_proxy.cpp create mode 100644 effects/presentwindows/presentwindows_proxy.h diff --git a/effects.cpp b/effects.cpp index e0ebb6a755..b39d2a6661 100644 --- a/effects.cpp +++ b/effects.cpp @@ -355,6 +355,18 @@ void EffectsHandlerImpl::grabbedKeyboardEvent( QKeyEvent* e ) keyboard_grab_effect->grabbedKeyboardEvent( e ); } +const void* EffectsHandlerImpl::getProxy( QString name ) + { + // All effects start with "kwin4_effect_", prepend it to the name + name.prepend( "kwin4_effect_" ); + + for( QVector< EffectPair >::iterator it = loaded_effects.begin(); it != loaded_effects.end(); ++it) + if ( (*it).first == name ) + return (*it).second->proxy(); + + return NULL; + } + void EffectsHandlerImpl::startMousePolling() { if( !mouse_poll_ref_count ) // Start timer if required diff --git a/effects.h b/effects.h index 4bd7412976..e78eb7057e 100644 --- a/effects.h +++ b/effects.h @@ -65,6 +65,7 @@ class EffectsHandlerImpl : public EffectsHandler virtual QPoint cursorPos() const; virtual bool grabKeyboard( Effect* effect ); virtual void ungrabKeyboard(); + virtual const void* getProxy( QString name ); virtual void startMousePolling(); virtual void stopMousePolling(); virtual EffectWindow* findWindow( WId id ) const; diff --git a/effects/desktopgrid/desktopgrid.cpp b/effects/desktopgrid/desktopgrid.cpp index 25b6a57ba9..15ea3aaef0 100644 --- a/effects/desktopgrid/desktopgrid.cpp +++ b/effects/desktopgrid/desktopgrid.cpp @@ -21,6 +21,8 @@ along with this program. If not, see . #include "desktopgrid.h" +#include "../presentwindows/presentwindows_proxy.h" + #include #include @@ -712,6 +714,15 @@ void DesktopGridEffect::setActive( bool active ) if( activated == active ) return; // Already in that state + // Example proxy code, TODO: Use or remove + //const PresentWindowsEffectProxy* proxy = + // static_cast( effects->getProxy( "presentwindows" )); + //if( proxy ) + // kDebug() << "Retrieved PresentWindowsEffectProxy, is present windows activate?" + // << proxy->isActive(); + //else + // kDebug() << "Failed to retrieve PresentWindowsEffectProxy. Maybe present windows isn't enabled?"; + activated = active; if( activated && timeline.value() == 0 ) setup(); diff --git a/effects/presentwindows/CMakeLists.txt b/effects/presentwindows/CMakeLists.txt index 9b015f44bb..964b0fe333 100644 --- a/effects/presentwindows/CMakeLists.txt +++ b/effects/presentwindows/CMakeLists.txt @@ -4,6 +4,7 @@ # Source files set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} presentwindows/presentwindows.cpp + presentwindows/presentwindows_proxy.cpp ) # .desktop files diff --git a/effects/presentwindows/presentwindows.cpp b/effects/presentwindows/presentwindows.cpp index c47c851150..cb653d6985 100644 --- a/effects/presentwindows/presentwindows.cpp +++ b/effects/presentwindows/presentwindows.cpp @@ -41,7 +41,8 @@ namespace KWin KWIN_EFFECT( presentwindows, PresentWindowsEffect ) PresentWindowsEffect::PresentWindowsEffect() - : m_borderActivate( ElectricNone ) + : m_proxy( this ) + , m_borderActivate( ElectricNone ) , m_borderActivateAll( ElectricNone ) , m_activated( false ) , m_allDesktops( false ) @@ -100,6 +101,11 @@ void PresentWindowsEffect::reconfigure( ReconfigureFlags ) m_showPanel = conf.readEntry( "ShowPanel", false ); } +const void* PresentWindowsEffect::proxy() const + { + return &m_proxy; + } + //----------------------------------------------------------------------------- // Screen painting diff --git a/effects/presentwindows/presentwindows.h b/effects/presentwindows/presentwindows.h index 34bd16ffdb..19a9db5eac 100644 --- a/effects/presentwindows/presentwindows.h +++ b/effects/presentwindows/presentwindows.h @@ -22,6 +22,8 @@ along with this program. If not, see . #ifndef KWIN_PRESENTWINDOWS_H #define KWIN_PRESENTWINDOWS_H +#include "presentwindows_proxy.h" + // Include with base class for effects. #include #include @@ -69,6 +71,8 @@ class PresentWindowsEffect virtual ~PresentWindowsEffect(); virtual void reconfigure( ReconfigureFlags ); + virtual const void* proxy() const; + // Screen painting virtual void prePaintScreen( ScreenPrePaintData &data, int time ); virtual void paintScreen( int mask, QRegion region, ScreenPaintData &data ); @@ -129,6 +133,9 @@ class PresentWindowsEffect void paintWindowIcon( EffectWindow *w, WindowPaintData &data ); // TODO: Do we need this? private: + PresentWindowsEffectProxy m_proxy; + friend class PresentWindowsEffectProxy; + // User configuration settings ElectricBorder m_borderActivate; ElectricBorder m_borderActivateAll; diff --git a/effects/presentwindows/presentwindows_proxy.cpp b/effects/presentwindows/presentwindows_proxy.cpp new file mode 100644 index 0000000000..adbceda74b --- /dev/null +++ b/effects/presentwindows/presentwindows_proxy.cpp @@ -0,0 +1,41 @@ +/******************************************************************** + KWin - the KDE window manager + This file is part of the KDE project. + +Copyright (C) 2009 Lucas Murray + +This program is free software; you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation; either version 2 of the License, or +(at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program. If not, see . +*********************************************************************/ + +#include "presentwindows_proxy.h" +#include "presentwindows.h" + +namespace KWin +{ + +PresentWindowsEffectProxy::PresentWindowsEffectProxy( PresentWindowsEffect* effect ) + : m_effect( effect ) + { + } + +PresentWindowsEffectProxy::~PresentWindowsEffectProxy() + { + } + +bool PresentWindowsEffectProxy::isActive() const + { + return m_effect->m_activated; + } + +} // namespace diff --git a/effects/presentwindows/presentwindows_proxy.h b/effects/presentwindows/presentwindows_proxy.h new file mode 100644 index 0000000000..8ee56a764e --- /dev/null +++ b/effects/presentwindows/presentwindows_proxy.h @@ -0,0 +1,44 @@ +/******************************************************************** + KWin - the KDE window manager + This file is part of the KDE project. + +Copyright (C) 2009 Lucas Murray + +This program is free software; you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation; either version 2 of the License, or +(at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program. If not, see . +*********************************************************************/ + +#ifndef KWIN_PRESENTWINDOWS_PROXY_H +#define KWIN_PRESENTWINDOWS_PROXY_H + +namespace KWin +{ + +class PresentWindowsEffect; + +// Example proxy code, TODO: Use or remove +class PresentWindowsEffectProxy + { + public: + PresentWindowsEffectProxy( PresentWindowsEffect* effect ); + ~PresentWindowsEffectProxy(); + + bool isActive() const; + + private: + PresentWindowsEffect* m_effect; + }; + +} // namespace + +#endif diff --git a/lib/kwineffects.cpp b/lib/kwineffects.cpp index 342cdbf744..72300adade 100644 --- a/lib/kwineffects.cpp +++ b/lib/kwineffects.cpp @@ -112,6 +112,11 @@ void Effect::reconfigure( ReconfigureFlags ) { } +const void* Effect::proxy() const + { + return NULL; + } + void Effect::windowUserMovedResized( EffectWindow* , bool, bool ) { } diff --git a/lib/kwineffects.h b/lib/kwineffects.h index b8ccf88cd5..206a618df4 100644 --- a/lib/kwineffects.h +++ b/lib/kwineffects.h @@ -296,6 +296,11 @@ class KWIN_EXPORT Effect */ virtual void reconfigure( ReconfigureFlags flags ); + /** + * Called when another effect requests the proxy for this effect. + */ + virtual const void* proxy() const; + /** * Called before starting to paint the screen. * In this method you can: @@ -522,6 +527,12 @@ class KWIN_EXPORT EffectsHandler virtual bool grabKeyboard( Effect* effect ) = 0; virtual void ungrabKeyboard() = 0; + /** + * Retrieve the proxy class for an effect if it has one. Will return NULL if + * the effect isn't loaded or doesn't have a proxy class. + */ + virtual const void* getProxy( QString name ) = 0; + // Mouse polling virtual void startMousePolling() = 0; virtual void stopMousePolling() = 0; From 81ffa5aec9b4af5393cf0cc4680f307d3db2b0dc Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Fri, 6 Feb 2009 14:21:20 +0000 Subject: [PATCH 32/60] Raise electric border windows when an effect mouse input window is created to allow effects to be toggled by active screen edges. svn path=/trunk/KDE/kdebase/workspace/; revision=922121 --- effects.cpp | 8 ++++++++ effects/cube/cube.cpp | 12 +++++------- effects/desktopgrid/desktopgrid.cpp | 10 ++++------ effects/presentwindows/presentwindows.cpp | 16 ++++++---------- layers.cpp | 20 +++++++++++++++++++- workspace.h | 2 ++ 6 files changed, 44 insertions(+), 24 deletions(-) diff --git a/effects.cpp b/effects.cpp index b39d2a6661..949ecd96b1 100644 --- a/effects.cpp +++ b/effects.cpp @@ -665,6 +665,11 @@ Window EffectsHandlerImpl::createInputWindow( Effect* e, int x, int y, int w, in XDefineCursor( display(), win, cursor.handle()); XMapWindow( display(), win ); input_windows.append( qMakePair( e, win )); + + // Raise electric border windows above the input windows + // so they can still be triggered. + Workspace::self()->raiseElectricBorderWindows(); + return win; } @@ -740,6 +745,9 @@ void EffectsHandlerImpl::checkInputWindowStacking() XRaiseWindow( display(), wins[ 0 ] ); XRestackWindows( display(), wins, pos ); delete[] wins; + // Raise electric border windows above the input windows + // so they can still be triggered. TODO: Do both at once. + Workspace::self()->raiseElectricBorderWindows(); } QPoint EffectsHandlerImpl::cursorPos() const diff --git a/effects/cube/cube.cpp b/effects/cube/cube.cpp index 589ab8615c..acecd4279c 100644 --- a/effects/cube/cube.cpp +++ b/effects/cube/cube.cpp @@ -1506,15 +1506,13 @@ void CubeEffect::paintWindow( EffectWindow* w, int mask, QRegion region, WindowP bool CubeEffect::borderActivated( ElectricBorder border ) { - if( effects->activeFullScreenEffect() && effects->activeFullScreenEffect() != this ) + if( border != borderActivate ) return false; - if( border == borderActivate && !activated ) - { - kDebug(1212) << "border activated"; - toggle(); + if( effects->activeFullScreenEffect() && effects->activeFullScreenEffect() != this ) return true; - } - return false; + kDebug(1212) << "border activated"; + toggle(); + return true; } void CubeEffect::toggle() diff --git a/effects/desktopgrid/desktopgrid.cpp b/effects/desktopgrid/desktopgrid.cpp index 15ea3aaef0..7ddd39e547 100644 --- a/effects/desktopgrid/desktopgrid.cpp +++ b/effects/desktopgrid/desktopgrid.cpp @@ -406,14 +406,12 @@ void DesktopGridEffect::grabbedKeyboardEvent( QKeyEvent* e ) bool DesktopGridEffect::borderActivated( ElectricBorder border ) { - if( effects->activeFullScreenEffect() && effects->activeFullScreenEffect() != this ) + if( border != borderActivate ) return false; - if( border == borderActivate && !activated ) - { - toggle(); + if( effects->activeFullScreenEffect() && effects->activeFullScreenEffect() != this ) return true; - } - return false; + toggle(); + return true; } //----------------------------------------------------------------------------- diff --git a/effects/presentwindows/presentwindows.cpp b/effects/presentwindows/presentwindows.cpp index cb653d6985..4f7a6d8d2c 100644 --- a/effects/presentwindows/presentwindows.cpp +++ b/effects/presentwindows/presentwindows.cpp @@ -290,19 +290,15 @@ void PresentWindowsEffect::windowDeleted( EffectWindow *w ) bool PresentWindowsEffect::borderActivated( ElectricBorder border ) { - if( effects->activeFullScreenEffect() && effects->activeFullScreenEffect() != this ) + if( border != m_borderActivate && border != m_borderActivateAll ) return false; - if( border == m_borderActivate && !m_activated ) - { + if( effects->activeFullScreenEffect() && effects->activeFullScreenEffect() != this ) + return true; + if( border == m_borderActivate ) toggleActive(); - return true; - } - if( border == m_borderActivateAll && !m_activated ) - { + else toggleActiveAllDesktops(); - return true; - } - return false; + return true; } void PresentWindowsEffect::windowInputMouseEvent( Window w, QEvent *e ) diff --git a/layers.cpp b/layers.cpp index 7d85d73c8f..9a8e1850ce 100644 --- a/layers.cpp +++ b/layers.cpp @@ -219,7 +219,25 @@ void Workspace::propagateClients( bool propagate_new_clients ) // Make the cached stacking order invalid here, in case we need the new stacking order before we get // the matching event, due to X being asynchronous. - x_stacking_dirty = true; + x_stacking_dirty = true; + } + +/** + * Raise electric border windows to the real top of the screen. We only need + * to do this if an effect input window is active. + */ +void Workspace::raiseElectricBorderWindows() + { + Window* windows = new Window[ 8 ]; // There are up to 8 borders + int pos = 0; + for( int i = 0; i < ELECTRIC_COUNT; ++i ) + if( electric_windows[ i ] != None ) + windows[ pos++ ] = electric_windows[ i ]; + if( !pos ) + return; // No borders at all + XRaiseWindow( display(), windows[ 0 ] ); + XRestackWindows( display(), windows, pos ); + delete [] windows; } diff --git a/workspace.h b/workspace.h index b3835c9d6c..a798b00777 100644 --- a/workspace.h +++ b/workspace.h @@ -361,6 +361,8 @@ class Workspace : public QObject, public KDecorationDefines void startMousePolling(); void stopMousePolling(); + void raiseElectricBorderWindows(); + public slots: void addRepaintFull(); void refresh(); From fef063cf46c36c1ae240debf90e26447b57c3f2c Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Fri, 6 Feb 2009 14:31:54 +0000 Subject: [PATCH 33/60] Ensure to highlight the correct desktop back in if the desktop grid was deactivated by pressing ESC or by using an electric border. svn path=/trunk/KDE/kdebase/workspace/; revision=922144 --- effects/desktopgrid/desktopgrid.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/effects/desktopgrid/desktopgrid.cpp b/effects/desktopgrid/desktopgrid.cpp index 7ddd39e547..0839374842 100644 --- a/effects/desktopgrid/desktopgrid.cpp +++ b/effects/desktopgrid/desktopgrid.cpp @@ -724,6 +724,8 @@ void DesktopGridEffect::setActive( bool active ) activated = active; if( activated && timeline.value() == 0 ) setup(); + if( !activated ) + setHighlightedDesktop( effects->currentDesktop() ); // Ensure selected desktop is highlighted effects->addRepaintFull(); } @@ -739,7 +741,7 @@ void DesktopGridEffect::setup() hoverTimeline.clear(); for( int i = 0; i < effects->numberOfDesktops(); i++ ) { - TimeLine newTimeline( animationTime( 250 )); + TimeLine newTimeline( animationTime( zoomDuration )); newTimeline.setCurveShape( TimeLine::EaseInOutCurve ); hoverTimeline.append( newTimeline ); } From 00a50d882f8698e8890fbb6c964dedd94f0af767 Mon Sep 17 00:00:00 2001 From: Script Kiddy Date: Fri, 6 Feb 2009 15:34:47 +0000 Subject: [PATCH 34/60] SVN_SILENT made messages (.desktop file) svn path=/trunk/KDE/kdebase/workspace/; revision=922231 --- effects/fadedesktop/fadedesktop.desktop | 4 ++++ effects/highlightwindow/highlightwindow.desktop | 6 ++++++ 2 files changed, 10 insertions(+) diff --git a/effects/fadedesktop/fadedesktop.desktop b/effects/fadedesktop/fadedesktop.desktop index 3b9941d8f1..0738a7fa01 100644 --- a/effects/fadedesktop/fadedesktop.desktop +++ b/effects/fadedesktop/fadedesktop.desktop @@ -1,5 +1,7 @@ [Desktop Entry] Name=Fade Desktop +Name[ca]=Esvair l'escriptori +Name[ca@valencia]=Esvair l'escriptori Name[et]=Töölaua hääbumine Name[gl]=Esvair o escritorio Name[nds]=Schriefdisch överblennen @@ -11,6 +13,8 @@ Name[x-test]=xxFade Desktopxx Name[zh_TW]=淡出淡入桌面 Icon=preferences-system-windows-effect-fadedesktop Comment=Fade between virtual desktops when switching between them +Comment[ca]=Esvaeix entre els escriptoris virtuals quan es commuta entre ells +Comment[ca@valencia]=Esvaeix entre els escriptoris virtuals quan es commuta entre ells Comment[et]=Hääbumisefekt ühelt virtuaalselt töölaualt teisele lülitudes Comment[gl]=Emprega un efeito de esvaemento ao trocar de escritorio Comment[nds]=Bi't Wesseln de Schriefdischen överenanner blennen diff --git a/effects/highlightwindow/highlightwindow.desktop b/effects/highlightwindow/highlightwindow.desktop index c429f10d48..c131279dc6 100644 --- a/effects/highlightwindow/highlightwindow.desktop +++ b/effects/highlightwindow/highlightwindow.desktop @@ -1,21 +1,27 @@ [Desktop Entry] Name=Highlight Window +Name[ca]=Realça la finestra +Name[ca@valencia]=Realça la finestra Name[et]=Akna esiletõstmine Name[eu]=Leihoa nabarmendu Name[ga]=Aibhsigh Fuinneog Name[nds]=Finster rutheven Name[pt]=Realçar a Janela Name[pt_BR]=Janela realçada +Name[sv]=Markera fönster Name[uk]=Підсвітити вікно Name[x-test]=xxHighlight Windowxx Name[zh_TW]=突顯視窗 Icon=preferences-system-windows-effect-highlightwindow Comment=Highlight the appropriate window when hovering over taskbar entries +Comment[ca]=Realça la finestra apropiada em passar el cursor sobre les entrades de la barra de tasques +Comment[ca@valencia]=Realça la finestra apropiada em passar el cursor sobre les entrades de la barra de tasques Comment[et]=Akende esiletõstmine, kui kursor on nende tegumiriba kirje kohal Comment[ga]=Aibhsigh an fhuinneog chuí nuair atá an cúrsóir os cionn iontrála sa tascbharra Comment[nds]=Bi't Wiesen op Programmbalken-Indrääg de tohören Finstern rutheven Comment[pt]=Realçar a janela apropriada ao passar o rato sobre os itens da barra de tarefas Comment[pt_BR]=Realçar a janela apropriada ao passar o ponteiro do mouse sobre as entradas da barra de tarefas +Comment[sv]=Markera motsvarande fönster när pekaren hålls över poster i aktivitetsfältet Comment[uk]=Підсвітити відповідне вікно, коли курсор знаходиться над елементом панелі задач Comment[x-test]=xxHighlight the appropriate window when hovering over taskbar entriesxx Comment[zh_TW]=當游標停在工作列的按鈕上面時,突顯視窗 From f7f5bc8326b630211410e6350e42433803741269 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Fri, 6 Feb 2009 18:53:16 +0000 Subject: [PATCH 35/60] Split cube mode and animation of desktop switching in separate effects: say hello to CubeSlide effect. svn path=/trunk/KDE/kdebase/workspace/; revision=922342 --- effects/configs_builtins.cpp | 2 + effects/cube/CMakeLists.txt | 5 + effects/cube/cube.cpp | 329 +++----------------------- effects/cube/cube.h | 11 - effects/cube/cube_config.cpp | 22 -- effects/cube/cube_config.ui | 102 ++------ effects/cube/cubeslide.cpp | 323 +++++++++++++++++++++++++ effects/cube/cubeslide.desktop | 17 ++ effects/cube/cubeslide.h | 68 ++++++ effects/cube/cubeslide_config.cpp | 94 ++++++++ effects/cube/cubeslide_config.desktop | 9 + effects/cube/cubeslide_config.h | 56 +++++ effects/cube/cubeslide_config.ui | 97 ++++++++ effects/cube/cylinder.cpp | 2 +- effects/cube/sphere.cpp | 2 +- kcmkwin/kwincompositing/main.cpp | 14 +- 16 files changed, 726 insertions(+), 427 deletions(-) create mode 100644 effects/cube/cubeslide.cpp create mode 100644 effects/cube/cubeslide.desktop create mode 100644 effects/cube/cubeslide.h create mode 100644 effects/cube/cubeslide_config.cpp create mode 100644 effects/cube/cubeslide_config.desktop create mode 100644 effects/cube/cubeslide_config.h create mode 100644 effects/cube/cubeslide_config.ui diff --git a/effects/configs_builtins.cpp b/effects/configs_builtins.cpp index 35b0cdb451..2489dd618f 100644 --- a/effects/configs_builtins.cpp +++ b/effects/configs_builtins.cpp @@ -36,6 +36,7 @@ along with this program. If not, see . #ifdef KWIN_HAVE_OPENGL_COMPOSITING #include "coverswitch/coverswitch_config.h" #include "cube/cube_config.h" +#include "cube/cubeslide_config.h" #include "cube/cylinder_config.h" #include "cube/sphere_config.h" #include "flipswitch/flipswitch_config.h" @@ -71,6 +72,7 @@ KWIN_EFFECT_CONFIG_MULTIPLE( builtins, #ifdef KWIN_HAVE_OPENGL_COMPOSITING KWIN_EFFECT_CONFIG_SINGLE( coverswitch, CoverSwitchEffectConfig ) KWIN_EFFECT_CONFIG_SINGLE( cube, CubeEffectConfig ) + KWIN_EFFECT_CONFIG_SINGLE( cubeslide, CubeSlideEffectConfig ) KWIN_EFFECT_CONFIG_SINGLE( cylinder, CylinderEffectConfig ) KWIN_EFFECT_CONFIG_SINGLE( sphere, SphereEffectConfig ) KWIN_EFFECT_CONFIG_SINGLE( flipswitch, FlipSwitchEffectConfig ) diff --git a/effects/cube/CMakeLists.txt b/effects/cube/CMakeLists.txt index 9829f3c73f..2fb887cf20 100644 --- a/effects/cube/CMakeLists.txt +++ b/effects/cube/CMakeLists.txt @@ -4,6 +4,7 @@ # Source files set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} cube/cube.cpp + cube/cubeslide.cpp cube/cylinder.cpp cube/sphere.cpp ) @@ -11,6 +12,7 @@ set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} # .desktop files install( FILES cube/cube.desktop + cube/cubeslide.desktop cube/cylinder.desktop cube/sphere.desktop DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) @@ -30,6 +32,8 @@ install( FILES set( kwin4_effect_builtins_config_sources ${kwin4_effect_builtins_config_sources} cube/cube_config.cpp cube/cube_config.ui + cube/cubeslide_config.cpp + cube/cubeslide_config.ui cube/cylinder_config.cpp cube/cylinder_config.ui cube/sphere_config.cpp @@ -39,6 +43,7 @@ set( kwin4_effect_builtins_config_sources ${kwin4_effect_builtins_config_sources # .desktop files install( FILES cube/cube_config.desktop + cube/cubeslide_config.desktop cube/cylinder_config.desktop cube/sphere_config.desktop DESTINATION ${SERVICES_INSTALL_DIR}/kwin ) diff --git a/effects/cube/cube.cpp b/effects/cube/cube.cpp index acecd4279c..e173a50dd6 100644 --- a/effects/cube/cube.cpp +++ b/effects/cube/cube.cpp @@ -70,10 +70,7 @@ CubeEffect::CubeEffect() , start( false ) , stop( false ) , reflectionPainting( false ) - , slide( false ) - , oldDesktop( 0 ) , activeScreen( 0 ) - , animateDesktopChange( false ) , bigCube( false ) , bottomCap( false ) , closeOnMouseRelease( false ) @@ -112,17 +109,14 @@ void CubeEffect::loadConfig( QString config ) reflection = conf.readEntry( "Reflection", true ); rotationDuration = animationTime( conf, "RotationDuration", 500 ); backgroundColor = conf.readEntry( "BackgroundColor", QColor( Qt::black ) ); - animateDesktopChange = conf.readEntry( "AnimateDesktopChange", false ); bigCube = conf.readEntry( "BigCube", false ); // different settings for cylinder and sphere if( config == "Cylinder" ) { - animateDesktopChange = false; bigCube = true; } if( config == "Sphere" ) { - animateDesktopChange = false; bigCube = true; reflection = false; } @@ -136,8 +130,6 @@ void CubeEffect::loadConfig( QString config ) useForTabBox = conf.readEntry( "TabBox", false ); invertKeys = conf.readEntry( "InvertKeys", false ); invertMouse = conf.readEntry( "InvertMouse", false ); - dontSlidePanels = conf.readEntry( "DontSlidePanels", true ); - dontSlideStickyWindows = conf.readEntry( "DontSlideStickyWindows", true ); QString file = conf.readEntry( "Wallpaper", QString("") ); if( wallpaper ) wallpaper->discard(); @@ -197,8 +189,6 @@ void CubeEffect::loadConfig( QString config ) verticalTimeLine.setCurveShape( TimeLine::EaseInOutCurve ); verticalTimeLine.setDuration( rotationDuration ); - slideTimeLine.setCurveShape( TimeLine::EaseInOutCurve ); - slideTimeLine.setDuration( rotationDuration ); // do not connect the shortcut if we use cylinder or sphere KActionCollection* actionCollection = new KActionCollection( this ); @@ -251,15 +241,6 @@ void CubeEffect::prePaintScreen( ScreenPrePaintData& data, int time ) verticalTimeLine.addTime( time ); recompileList = true; } - if( slide && !slideRotations.empty() ) - { - slideTimeLine.addTime( time ); - recompileList = true; - if( dontSlidePanels ) - panels.clear(); - if( dontSlideStickyWindows ) - stickyWindows.clear(); - } } effects->prePaintScreen( data, time ); } @@ -273,8 +254,7 @@ void CubeEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) recompileList = false; glPushMatrix(); glNewList( glList, GL_COMPILE ); - if( !slide ) - rotateCube(); + rotateCube(); glEndList(); glPopMatrix(); } @@ -282,15 +262,12 @@ void CubeEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) // compile List for cube glNewList( glList + 1, GL_COMPILE ); glPushMatrix(); - if( slide ) - paintSlideCube( mask, region, data ); - else - paintCube( mask, region, data ); + paintCube( mask, region, data ); glPopMatrix(); glEndList(); QRect rect = effects->clientArea( FullScreenArea, activeScreen, effects->currentDesktop()); - if( effects->numScreens() > 1 && (slide || bigCube ) ) + if( effects->numScreens() > 1 && bigCube ) rect = effects->clientArea( FullArea, activeScreen, effects->currentDesktop() ); QRect fullRect = effects->clientArea( FullArea, activeScreen, effects->currentDesktop() ); @@ -302,8 +279,8 @@ void CubeEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) glClearColor( clearColor[0], clearColor[1], clearColor[2], clearColor[3] ); // wallpaper - if( wallpaper && !slide ) - { + if( wallpaper ) + { wallpaper->bind(); wallpaper->render( region, rect ); wallpaper->unbind(); @@ -313,7 +290,7 @@ void CubeEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) glEnable( GL_BLEND ); glBlendFunc( GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA ); - if( effects->numScreens() > 1 && !slide && !bigCube ) + if( effects->numScreens() > 1 && !bigCube ) { windowsOnOtherScreens.clear(); // unfortunatelly we have to change the projection matrix in dual screen mode @@ -377,7 +354,7 @@ void CubeEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) if( stop ) zTranslate *= ( 1.0 - timeLine.value() ); // reflection - if( reflection && (!slide) ) + if( reflection ) { // restrict painting the reflections to the current screen PaintClipper::push( QRegion( rect )); @@ -440,7 +417,7 @@ void CubeEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) glPopMatrix(); glPushMatrix(); - if( effects->numScreens() > 1 && rect.x() != fullRect.x() && !slide && !bigCube ) + if( effects->numScreens() > 1 && rect.x() != fullRect.x() && !bigCube ) { // have to change the reflection area in horizontal layout and right screen glTranslatef( -rect.x(), 0.0, 0.0 ); @@ -472,7 +449,7 @@ void CubeEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) } glEnable( GL_CULL_FACE ); // caps - if( paintCaps && ( effects->numberOfDesktops() >= 2 ) && !slide ) + if( paintCaps && ( effects->numberOfDesktops() >= 2 )) { glPushMatrix(); glCallList( glList ); @@ -500,7 +477,7 @@ void CubeEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) glPopMatrix(); // cap - if( paintCaps && ( effects->numberOfDesktops() >= 2 ) && !slide ) + if( paintCaps && ( effects->numberOfDesktops() >= 2 )) { glPushMatrix(); glCallList( glList ); @@ -516,7 +493,7 @@ void CubeEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) } glDisable( GL_CULL_FACE ); - if( effects->numScreens() > 1 && !slide && !bigCube ) + if( effects->numScreens() > 1 && !bigCube ) { glPopMatrix(); // revert change of projection matrix @@ -529,7 +506,7 @@ void CubeEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) glPopAttrib(); // desktop name box - inspired from coverswitch - if( displayDesktopName && (!slide) ) + if( displayDesktopName ) { QColor color_frame; QColor color_text; @@ -563,7 +540,7 @@ void CubeEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) text_font ); glPopAttrib(); } - if( effects->numScreens() > 1 && !slide && !bigCube ) + if( effects->numScreens() > 1 && !bigCube ) { foreach( EffectWindow* w, windowsOnOtherScreens ) { @@ -575,22 +552,6 @@ void CubeEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) effects->paintWindow( w, 0, QRegion( w->x(), w->y(), w->width(), w->height() ), wData ); } } - if( slide && dontSlidePanels ) - { - foreach( EffectWindow* w, panels ) - { - WindowPaintData wData( w ); - effects->paintWindow( w, 0, QRegion( w->x(), w->y(), w->width(), w->height() ), wData ); - } - } - if( slide && dontSlideStickyWindows ) - { - foreach( EffectWindow* w, stickyWindows ) - { - WindowPaintData wData( w ); - effects->paintWindow( w, 0, QRegion( w->x(), w->y(), w->width(), w->height() ), wData ); - } - } } else { @@ -796,75 +757,6 @@ void CubeEffect::paintCube( int mask, QRegion region, ScreenPaintData& data ) painting_desktop = effects->currentDesktop(); } -void CubeEffect::paintSlideCube(int mask, QRegion region, KWin::ScreenPaintData& data) - { - // slide cube only paints to desktops at a time - // first the horizontal rotations followed by vertical rotations - QRect rect = effects->clientArea( FullArea, activeScreen, effects->currentDesktop() ); - float point = rect.width()/2*tan(45.0f*M_PI/180.0f); - cube_painting = true; - painting_desktop = frontDesktop; - - ScreenPaintData firstFaceData = data; - ScreenPaintData secondFaceData = data; - RotationData firstFaceRot = RotationData(); - RotationData secondFaceRot = RotationData(); - RotationDirection direction = slideRotations.head(); - int secondDesktop; - switch ( direction ) - { - case Left: - firstFaceRot.axis = RotationData::YAxis; - secondFaceRot.axis = RotationData::YAxis; - secondDesktop = effects->desktopToLeft( frontDesktop, true ); - firstFaceRot.angle = 90.0f*slideTimeLine.value(); - secondFaceRot.angle = -90.0f*(1.0f - slideTimeLine.value()); - break; - case Right: - firstFaceRot.axis = RotationData::YAxis; - secondFaceRot.axis = RotationData::YAxis; - secondDesktop = effects->desktopToRight( frontDesktop, true ); - firstFaceRot.angle = -90.0f*slideTimeLine.value(); - secondFaceRot.angle = 90.0f*(1.0f - slideTimeLine.value()); - break; - case Upwards: - firstFaceRot.axis = RotationData::XAxis; - secondFaceRot.axis = RotationData::XAxis; - secondDesktop = effects->desktopUp( frontDesktop, true); - firstFaceRot.angle = -90.0f*slideTimeLine.value(); - secondFaceRot.angle = 90.0f*(1.0f - slideTimeLine.value()); - point = rect.height()/2*tan(45.0f*M_PI/180.0f); - break; - case Downwards: - firstFaceRot.axis = RotationData::XAxis; - secondFaceRot.axis = RotationData::XAxis; - secondDesktop = effects->desktopDown( frontDesktop, true ); - firstFaceRot.angle = 90.0f*slideTimeLine.value(); - secondFaceRot.angle = -90.0f*(1.0f - slideTimeLine.value()); - point = rect.height()/2*tan(45.0f*M_PI/180.0f); - break; - default: - // totally impossible - return; - } - // front desktop - firstFaceRot.xRotationPoint = rect.width()/2; - firstFaceRot.yRotationPoint = rect.height()/2; - firstFaceRot.zRotationPoint = -point; - firstFaceData.rotation = &firstFaceRot; - effects->paintScreen( mask, region, firstFaceData ); - // second desktop - painting_desktop = secondDesktop; - secondFaceRot.xRotationPoint = rect.width()/2; - secondFaceRot.yRotationPoint = rect.height()/2; - secondFaceRot.zRotationPoint = -point; - secondFaceData.rotation = &secondFaceRot; - effects->paintScreen( mask, region, secondFaceData ); - cube_painting = false; - painting_desktop = effects->currentDesktop(); - } - - void CubeEffect::paintCap( float z, float zTexture ) { QRect rect = effects->clientArea( FullArea, activeScreen, effects->currentDesktop()); @@ -1072,8 +964,6 @@ void CubeEffect::postPaintScreen() keyboard_grab = false; effects->destroyInputWindow( input ); windowsOnOtherScreens.clear(); - panels.clear(); - stickyWindows.clear(); effects->setActiveFullScreenEffect( 0 ); @@ -1159,52 +1049,10 @@ void CubeEffect::postPaintScreen() effects->addRepaintFull(); return; // rotation has to end before cube is closed } - if( slide ) - { - if( slideTimeLine.value() == 1.0 ) - { - RotationDirection direction = slideRotations.dequeue(); - switch (direction) - { - case Left: - frontDesktop = effects->desktopToLeft( frontDesktop, true ); - break; - case Right: - frontDesktop = effects->desktopToRight( frontDesktop, true ); - break; - case Upwards: - frontDesktop = effects->desktopUp( frontDesktop, true ); - break; - case Downwards: - frontDesktop = effects->desktopDown( frontDesktop, true ); - break; - } - slideTimeLine.setProgress( 0.0 ); - if( !slideRotations.empty() ) - { - effects->addRepaintFull(); - return; - } - } - else - { - effects->addRepaintFull(); - return; - } - } if( schedule_close ) { schedule_close = false; - if( !slide ) - { - stop = true; - } - else - { - activated = false; - slide = false; - effects->setActiveFullScreenEffect( 0 ); - } + stop = true; effects->addRepaintFull(); } } @@ -1298,15 +1146,6 @@ void CubeEffect::prePaintWindow( EffectWindow* w, WindowPrePaintData& data, int } w->disablePainting( EffectWindow::PAINT_DISABLED_BY_DESKTOP ); } - if( slide && dontSlidePanels && w->isDock()) - { - panels.insert( w ); - } - if( slide && dontSlideStickyWindows && !w->isDock() && - !w->isDesktop() && w->isOnAllDesktops()) - { - stickyWindows.insert( w ); - } } } effects->prePaintWindow( w, data, time ); @@ -1316,15 +1155,8 @@ void CubeEffect::paintWindow( EffectWindow* w, int mask, QRegion region, WindowP { if( activated && cube_painting ) { - if( slide && dontSlidePanels && w->isDock() ) - return; - if( slide && dontSlideStickyWindows && - w->isOnAllDesktops() && !w->isDock() && !w->isDesktop() ) - return; //kDebug(1212) << w->caption(); float opacity = cubeOpacity; - if( slide ) - opacity = 1.0f; if( start ) { opacity = 1.0 - (1.0 - opacity)*timeLine.value(); @@ -1343,19 +1175,6 @@ void CubeEffect::paintWindow( EffectWindow* w, int mask, QRegion region, WindowP if( painting_desktop == effects->currentDesktop() && (!w->isOnDesktop( painting_desktop )) ) opacity = cubeOpacity * (1.0 - timeLine.value()); } - bool slideOpacity = false; - // fade in windows from different desktops in first slide step - if( slide && painting_desktop == oldDesktop && (!w->isOnDesktop( painting_desktop )) ) - { - opacity = timeLine.value(); - slideOpacity = true; - } - // fade out windows from different desktops in last slide step - if( slide && rotations.empty() && painting_desktop == effects->currentDesktop() && (!w->isOnDesktop( painting_desktop )) ) - { - opacity = 1.0 - timeLine.value(); - slideOpacity = true; - } // check for windows belonging to the previous desktop int prev_desktop = painting_desktop -1; if( prev_desktop == 0 ) @@ -1411,16 +1230,13 @@ void CubeEffect::paintWindow( EffectWindow* w, int mask, QRegion region, WindowP opacity = cubeOpacity * (1.0 - timeLine.value()); } } - if( !slide || (slide && !w->isDesktop()) || slideOpacity ) - { - // HACK set opacity to 0.99 in case of fully opaque to ensure that windows are painted in correct sequence - // bug #173214 - if( opacity > 0.99f ) - opacity = 0.99f; - if( opacityDesktopOnly && !w->isDesktop() ) - opacity = 0.99f; - data.opacity *= opacity; - } + // HACK set opacity to 0.99 in case of fully opaque to ensure that windows are painted in correct sequence + // bug #173214 + if( opacity > 0.99f ) + opacity = 0.99f; + if( opacityDesktopOnly && !w->isDesktop() ) + opacity = 0.99f; + data.opacity *= opacity; if( w->isOnDesktop(painting_desktop) && w->x() < rect.x() ) { @@ -1470,7 +1286,7 @@ void CubeEffect::paintWindow( EffectWindow* w, int mask, QRegion region, WindowP } data.quads = new_quads; } - if( w->isDesktop() && effects->numScreens() > 1 && paintCaps && !slide ) + if( w->isDesktop() && effects->numScreens() > 1 && paintCaps ) { QRegion paint = QRegion( rect ); for( int i=0; inumScreens(); i++ ) @@ -1802,22 +1618,19 @@ void CubeEffect::setActive( bool active ) effects->startMousePolling(); activated = true; activeScreen = effects->activeScreen(); - if( !slide ) - { - keyboard_grab = effects->grabKeyboard( this ); - input = effects->createInputWindow( this, 0, 0, displayWidth(), displayHeight(), - Qt::OpenHandCursor ); - frontDesktop = effects->currentDesktop(); - zoom = 0.0; - start = true; - } + keyboard_grab = effects->grabKeyboard( this ); + input = effects->createInputWindow( this, 0, 0, displayWidth(), displayHeight(), + Qt::OpenHandCursor ); + frontDesktop = effects->currentDesktop(); + zoom = 0.0; + start = true; effects->setActiveFullScreenEffect( this ); kDebug(1212) << "Cube is activated"; verticalPosition = Normal; verticalRotating = false; manualAngle = 0.0; manualVerticalAngle = 0.0; - if( reflection && !slide ) + if( reflection ) { // clip parts above the reflection area double eqn[4] = {0.0, 1.0, 0.0, 0.0}; @@ -1834,10 +1647,10 @@ void CubeEffect::setActive( bool active ) capListCreated = false; recompileList = true; // create the capList - if( paintCaps && !slide ) + if( paintCaps ) { QRect rect = effects->clientArea( FullScreenArea, activeScreen, effects->currentDesktop()); - if( effects->numScreens() > 1 && (slide || bigCube ) ) + if( effects->numScreens() > 1 && bigCube ) rect = effects->clientArea( FullArea, activeScreen, effects->currentDesktop() ); float cubeAngle = (float)((float)(effects->numberOfDesktops() - 2 )/(float)effects->numberOfDesktops() * 180.0f); float point = rect.width()/2*tan(cubeAngle*0.5f*M_PI/180.0f); @@ -1863,10 +1676,10 @@ void CubeEffect::mouseChanged( const QPoint& pos, const QPoint& oldpos, Qt::Mous return; if( tabBoxMode ) return; - if( stop || slide ) + if( stop ) return; QRect rect = effects->clientArea( FullScreenArea, activeScreen, effects->currentDesktop()); - if( effects->numScreens() > 1 && (slide || bigCube ) ) + if( effects->numScreens() > 1 && bigCube ) rect = effects->clientArea( FullArea, activeScreen, effects->currentDesktop() ); if( buttons.testFlag( Qt::LeftButton ) ) { @@ -1973,82 +1786,6 @@ void CubeEffect::windowInputMouseEvent( Window w, QEvent* e ) } } -void CubeEffect::desktopChanged( int old ) - { - if( effects->activeFullScreenEffect() && effects->activeFullScreenEffect() != this ) - return; - if( activated && !slide ) - return; - if( !animateDesktopChange ) - return; - slide = true; - bool activate = true; - if( !slideRotations.empty() ) - { - // last slide still in progress - activate = false; - old = frontDesktop; - RotationDirection direction = slideRotations.dequeue(); - slideRotations.clear(); - slideRotations.enqueue( direction ); - } - oldDesktop = old; - // calculate distance in respect to pager - int x, y; - Qt::Orientation orientation; - effects->calcDesktopLayout( &x, &y, &orientation ); - int x_distance = (( effects->currentDesktop() - 1 ) % x ) - (( old - 1 ) % x ); - if( qAbs( x_distance ) > x/2 ) - { - int sign = -1 * (x_distance/qAbs( x_distance )); - x_distance = sign * ( x - qAbs( x_distance )); - } - if( x_distance > 0 ) - { - for( int i=0; icurrentDesktop() -1 ) / x ) - (( old - 1 ) / x ); - if( qAbs( y_distance ) > y/2 ) - { - int sign = -1 * (y_distance/qAbs( y_distance )); - y_distance = sign * ( y - qAbs( y_distance )); - } - if( y_distance > 0 ) - { - for( int i=0; i rotations; QQueue verticalRotations; - QQueue slideRotations; QColor backgroundColor; QColor capColor; GLTexture* wallpaper; @@ -114,14 +110,9 @@ class CubeEffect bool start; bool stop; bool reflectionPainting; - bool slide; - int oldDesktop; int rotationDuration; QList windowsOnOtherScreens; - QSet panels; - QSet stickyWindows; int activeScreen; - bool animateDesktopChange; bool bigCube; bool bottomCap; bool closeOnMouseRelease; @@ -131,8 +122,6 @@ class CubeEffect bool invertKeys; bool invertMouse; bool tabBoxMode; - bool dontSlidePanels; - bool dontSlideStickyWindows; bool shortcutsRegistered; // GL lists diff --git a/effects/cube/cube_config.cpp b/effects/cube/cube_config.cpp index 643e60ecfb..c5c903e476 100644 --- a/effects/cube/cube_config.cpp +++ b/effects/cube/cube_config.cpp @@ -72,7 +72,6 @@ CubeEffectConfig::CubeEffectConfig(QWidget* parent, const QVariantList& args) : connect(m_ui->displayDesktopNameBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); connect(m_ui->reflectionBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); connect(m_ui->backgroundColorButton, SIGNAL(changed(QColor)), this, SLOT(changed())); - connect(m_ui->animateDesktopChangeBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); connect(m_ui->bigCubeBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); connect(m_ui->cubeCapsBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); connect(m_ui->cubeCapsBox, SIGNAL(stateChanged(int)), this, SLOT(capsSelectionChanged())); @@ -84,8 +83,6 @@ CubeEffectConfig::CubeEffectConfig(QWidget* parent, const QVariantList& args) : connect(m_ui->walkThroughDesktopBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); connect(m_ui->invertKeysBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); connect(m_ui->invertMouseBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); - connect(m_ui->dontSlidePanelsBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); - connect(m_ui->dontSlideStickyWindowsBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); load(); } @@ -105,7 +102,6 @@ void CubeEffectConfig::load() QColor capColor = conf.readEntry( "CapColor", KColorScheme( QPalette::Active, KColorScheme::Window ).background().color() ); bool texturedCaps = conf.readEntry( "TexturedCaps", true ); bool caps = conf.readEntry( "Caps", true ); - bool animateChange = conf.readEntry( "AnimateDesktopChange", false ); bool bigCube = conf.readEntry( "BigCube", false ); bool closeOnMouseRelease = conf.readEntry( "CloseOnMouseRelease", false ); bool walkThroughDesktop = conf.readEntry( "TabBox", false ); @@ -113,8 +109,6 @@ void CubeEffectConfig::load() m_ui->wallpaperRequester->setPath( conf.readEntry( "Wallpaper", "" ) ); bool invertKeys = conf.readEntry( "InvertKeys", false ); bool invertMouse = conf.readEntry( "InvertMouse", false ); - bool dontSlidePanels = conf.readEntry( "DontSlidePanels", true ); - bool dontSlideStickyWindows = conf.readEntry( "DontSlideStickyWindows", true ); m_ui->rotationDurationSpin->setValue( duration ); m_ui->cubeOpacitySlider->setValue( opacity ); @@ -152,14 +146,6 @@ void CubeEffectConfig::load() { m_ui->capsImageBox->setCheckState( Qt::Unchecked ); } - if( animateChange ) - { - m_ui->animateDesktopChangeBox->setCheckState( Qt::Checked ); - } - else - { - m_ui->animateDesktopChangeBox->setCheckState( Qt::Unchecked ); - } if( bigCube ) { m_ui->bigCubeBox->setCheckState( Qt::Checked ); @@ -188,8 +174,6 @@ void CubeEffectConfig::load() m_ui->capColorButton->setColor( capColor ); m_ui->invertKeysBox->setChecked( invertKeys ); m_ui->invertMouseBox->setChecked( invertMouse ); - m_ui->dontSlidePanelsBox->setChecked( dontSlidePanels ); - m_ui->dontSlideStickyWindowsBox->setChecked( dontSlideStickyWindows ); capsSelectionChanged(); emit changed(false); @@ -208,7 +192,6 @@ void CubeEffectConfig::save() conf.writeEntry( "Caps", m_ui->cubeCapsBox->checkState() == Qt::Checked ? true : false ); conf.writeEntry( "CapColor", m_ui->capColorButton->color() ); conf.writeEntry( "TexturedCaps", m_ui->capsImageBox->checkState() == Qt::Checked ? true : false ); - conf.writeEntry( "AnimateDesktopChange", m_ui->animateDesktopChangeBox->checkState() == Qt::Checked ? true : false ); conf.writeEntry( "BigCube", m_ui->bigCubeBox->checkState() == Qt::Checked ? true : false ); conf.writeEntry( "CloseOnMouseRelease", m_ui->closeOnMouseReleaseBox->checkState() == Qt::Checked ? true : false ); conf.writeEntry( "Wallpaper", m_ui->wallpaperRequester->url().path() ); @@ -216,8 +199,6 @@ void CubeEffectConfig::save() conf.writeEntry( "TabBox", m_ui->walkThroughDesktopBox->checkState() == Qt::Checked ? true : false ); conf.writeEntry( "InvertKeys", m_ui->invertKeysBox->isChecked() ); conf.writeEntry( "InvertMouse", m_ui->invertMouseBox->isChecked() ); - conf.writeEntry( "DontSlidePanels", m_ui->dontSlidePanelsBox->isChecked() ); - conf.writeEntry( "DontSlideStickyWindows", m_ui->dontSlideStickyWindowsBox->isChecked() ); m_ui->editor->save(); @@ -239,7 +220,6 @@ void CubeEffectConfig::defaults() m_ui->cubeCapsBox->setCheckState( Qt::Checked ); m_ui->capColorButton->setColor( KColorScheme( QPalette::Active, KColorScheme::Window ).background().color() ); m_ui->capsImageBox->setCheckState( Qt::Checked ); - m_ui->animateDesktopChangeBox->setCheckState( Qt::Unchecked ); m_ui->bigCubeBox->setCheckState( Qt::Unchecked ); m_ui->closeOnMouseReleaseBox->setCheckState( Qt::Unchecked ); m_ui->wallpaperRequester->setPath( "" ); @@ -247,8 +227,6 @@ void CubeEffectConfig::defaults() m_ui->walkThroughDesktopBox->setCheckState( Qt::Unchecked ); m_ui->invertKeysBox->setChecked( false ); m_ui->invertMouseBox->setChecked( false ); - m_ui->dontSlidePanelsBox->setChecked( true ); - m_ui->dontSlideStickyWindowsBox->setChecked( true ); m_ui->editor->allDefault(); emit changed(true); } diff --git a/effects/cube/cube_config.ui b/effects/cube/cube_config.ui index fd180f0367..4e72d7edc7 100644 --- a/effects/cube/cube_config.ui +++ b/effects/cube/cube_config.ui @@ -271,7 +271,7 @@ Tab 2 - + Caps @@ -314,6 +314,19 @@ + + + + Qt::Vertical + + + + 20 + 40 + + + + @@ -430,58 +443,6 @@ otherwise it will remain active - - - - Qt::Vertical - - - - 20 - 40 - - - - - - - - - - - Animate Desktop Change - - - - - - - - - Display the cube when switching desktops - - - - - - - false - - - Do not animate panels - - - - - - - false - - - Do not animate windows on all desktops - - - @@ -528,9 +489,6 @@ otherwise it will remain active walkThroughDesktopBox invertKeysBox invertMouseBox - animateDesktopChangeBox - dontSlidePanelsBox - dontSlideStickyWindowsBox zPositionSlider @@ -567,37 +525,5 @@ otherwise it will remain active - - animateDesktopChangeBox - toggled(bool) - dontSlidePanelsBox - setEnabled(bool) - - - 147 - 209 - - - 147 - 232 - - - - - animateDesktopChangeBox - toggled(bool) - dontSlideStickyWindowsBox - setEnabled(bool) - - - 53 - 209 - - - 27 - 261 - - - diff --git a/effects/cube/cubeslide.cpp b/effects/cube/cubeslide.cpp new file mode 100644 index 0000000000..dd0d5557b1 --- /dev/null +++ b/effects/cube/cubeslide.cpp @@ -0,0 +1,323 @@ +/******************************************************************** + KWin - the KDE window manager + This file is part of the KDE project. + + Copyright (C) 2009 Martin Gräßlin + +This program is free software; you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation; either version 2 of the License, or +(at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program. If not, see . +*********************************************************************/ + +#include "cubeslide.h" + +#include +#include + +#include + +#include + +namespace KWin +{ + +KWIN_EFFECT( cubeslide, CubeSlideEffect ) +KWIN_EFFECT_SUPPORTED( cubeslide, CubeSlideEffect::supported() ) + +CubeSlideEffect::CubeSlideEffect() + { + reconfigure( ReconfigureAll ); + } + +CubeSlideEffect::~CubeSlideEffect() + { + } + +bool CubeSlideEffect::supported() + { + return effects->compositingType() == OpenGLCompositing; + } + +void CubeSlideEffect::reconfigure( ReconfigureFlags ) + { + KConfigGroup conf = effects->effectConfig( "CubeSlide" ); + int rotationDuration = animationTime( conf, "RotationDuration", 500 ); + timeLine.setCurveShape( TimeLine::EaseInOutCurve ); + timeLine.setDuration( rotationDuration ); + dontSlidePanels = conf.readEntry( "DontSlidePanels", true ); + dontSlideStickyWindows = conf.readEntry( "DontSlideStickyWindows", true ); + } + +void CubeSlideEffect::prePaintScreen( ScreenPrePaintData& data, int time) + { + if( !slideRotations.empty() ) + { + data.mask |= PAINT_SCREEN_TRANSFORMED | Effect::PAINT_SCREEN_WITH_TRANSFORMED_WINDOWS | PAINT_SCREEN_BACKGROUND_FIRST; + timeLine.addTime( time ); + if( dontSlidePanels ) + panels.clear(); + if( dontSlideStickyWindows ) + stickyWindows.clear(); + } + effects->prePaintScreen( data, time ); + } + +void CubeSlideEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data) + { + if( !slideRotations.empty() ) + { + glPushMatrix(); + glNewList( glList, GL_COMPILE ); + paintSlideCube( mask, region, data ); + glEndList(); + glPopMatrix(); + + glPushAttrib( GL_CURRENT_BIT | GL_ENABLE_BIT ); + glEnable( GL_CULL_FACE ); + glCullFace( GL_BACK ); + glPushMatrix(); + glCallList( glList ); + glPopMatrix(); + glCullFace( GL_FRONT ); + glPushMatrix(); + glCallList( glList ); + glPopMatrix(); + glDisable( GL_CULL_FACE ); + glPopAttrib(); + if( dontSlidePanels ) + { + foreach( EffectWindow* w, panels ) + { + WindowPaintData wData( w ); + effects->paintWindow( w, 0, QRegion( w->x(), w->y(), w->width(), w->height() ), wData ); + } + } + if( dontSlideStickyWindows ) + { + foreach( EffectWindow* w, stickyWindows ) + { + WindowPaintData wData( w ); + effects->paintWindow( w, 0, QRegion( w->x(), w->y(), w->width(), w->height() ), wData ); + } + } + } + else + effects->paintScreen( mask, region, data ); + } + +void CubeSlideEffect::paintSlideCube(int mask, QRegion region, ScreenPaintData& data) + { + // slide cube only paints to desktops at a time + // first the horizontal rotations followed by vertical rotations + QRect rect = effects->clientArea( FullArea, effects->activeScreen(), effects->currentDesktop() ); + float point = rect.width()/2*tan(45.0f*M_PI/180.0f); + cube_painting = true; + painting_desktop = front_desktop; + + ScreenPaintData firstFaceData = data; + ScreenPaintData secondFaceData = data; + RotationData firstFaceRot = RotationData(); + RotationData secondFaceRot = RotationData(); + RotationDirection direction = slideRotations.head(); + int secondDesktop; + switch ( direction ) + { + case Left: + firstFaceRot.axis = RotationData::YAxis; + secondFaceRot.axis = RotationData::YAxis; + secondDesktop = effects->desktopToLeft( front_desktop, true ); + firstFaceRot.angle = 90.0f*timeLine.value(); + secondFaceRot.angle = -90.0f*(1.0f - timeLine.value()); + break; + case Right: + firstFaceRot.axis = RotationData::YAxis; + secondFaceRot.axis = RotationData::YAxis; + secondDesktop = effects->desktopToRight( front_desktop, true ); + firstFaceRot.angle = -90.0f*timeLine.value(); + secondFaceRot.angle = 90.0f*(1.0f - timeLine.value()); + break; + case Upwards: + firstFaceRot.axis = RotationData::XAxis; + secondFaceRot.axis = RotationData::XAxis; + secondDesktop = effects->desktopUp( front_desktop, true); + firstFaceRot.angle = -90.0f*timeLine.value(); + secondFaceRot.angle = 90.0f*(1.0f - timeLine.value()); + point = rect.height()/2*tan(45.0f*M_PI/180.0f); + break; + case Downwards: + firstFaceRot.axis = RotationData::XAxis; + secondFaceRot.axis = RotationData::XAxis; + secondDesktop = effects->desktopDown( front_desktop, true ); + firstFaceRot.angle = 90.0f*timeLine.value(); + secondFaceRot.angle = -90.0f*(1.0f - timeLine.value()); + point = rect.height()/2*tan(45.0f*M_PI/180.0f); + break; + default: + // totally impossible + return; + } + // front desktop + firstFaceRot.xRotationPoint = rect.width()/2; + firstFaceRot.yRotationPoint = rect.height()/2; + firstFaceRot.zRotationPoint = -point; + firstFaceData.rotation = &firstFaceRot; + effects->paintScreen( mask, region, firstFaceData ); + // second desktop + painting_desktop = secondDesktop; + secondFaceRot.xRotationPoint = rect.width()/2; + secondFaceRot.yRotationPoint = rect.height()/2; + secondFaceRot.zRotationPoint = -point; + secondFaceData.rotation = &secondFaceRot; + effects->paintScreen( mask, region, secondFaceData ); + cube_painting = false; + painting_desktop = effects->currentDesktop(); + } + +void CubeSlideEffect::prePaintWindow( EffectWindow* w, WindowPrePaintData& data, int time) + { + if( !slideRotations.empty() && cube_painting ) + { + if( dontSlidePanels && w->isDock()) + { + panels.insert( w ); + } + if( dontSlideStickyWindows && !w->isDock() && + !w->isDesktop() && w->isOnAllDesktops()) + { + stickyWindows.insert( w ); + } + if( w->isOnDesktop( painting_desktop ) ) + w->enablePainting( EffectWindow::PAINT_DISABLED_BY_DESKTOP ); + else + w->disablePainting( EffectWindow::PAINT_DISABLED_BY_DESKTOP ); + } + effects->prePaintWindow( w, data, time ); + } + +void CubeSlideEffect::paintWindow( EffectWindow* w, int mask, QRegion region, WindowPaintData& data) + { + if( !slideRotations.empty() && cube_painting ) + { + if( dontSlidePanels && w->isDock() ) + return; + if( dontSlideStickyWindows && + w->isOnAllDesktops() && !w->isDock() && !w->isDesktop() ) + return; + } + effects->paintWindow( w, mask, region, data ); + } + +void CubeSlideEffect::postPaintScreen() + { + effects->postPaintScreen(); + if( !slideRotations.empty() ) + { + if( timeLine.value() == 1.0 ) + { + RotationDirection direction = slideRotations.dequeue(); + switch (direction) + { + case Left: + front_desktop = effects->desktopToLeft( front_desktop, true ); + break; + case Right: + front_desktop = effects->desktopToRight( front_desktop, true ); + break; + case Upwards: + front_desktop = effects->desktopUp( front_desktop, true ); + break; + case Downwards: + front_desktop = effects->desktopDown( front_desktop, true ); + break; + } + timeLine.setProgress( 0.0 ); + if( slideRotations.empty() ) + { + effects->setActiveFullScreenEffect( 0 ); + glDeleteLists( glList, 1 ); + } + } + effects->addRepaintFull(); + } + } + +void CubeSlideEffect::desktopChanged( int old ) + { + if( effects->activeFullScreenEffect() && effects->activeFullScreenEffect() != this ) + return; + bool activate = true; + if( !slideRotations.empty() ) + { + // last slide still in progress + activate = false; + old = front_desktop; + RotationDirection direction = slideRotations.dequeue(); + slideRotations.clear(); + slideRotations.enqueue( direction ); + } + // calculate distance in respect to pager + int x, y; + Qt::Orientation orientation; + effects->calcDesktopLayout( &x, &y, &orientation ); + int x_distance = (( effects->currentDesktop() - 1 ) % x ) - (( old - 1 ) % x ); + if( qAbs( x_distance ) > x/2 ) + { + int sign = -1 * (x_distance/qAbs( x_distance )); + x_distance = sign * ( x - qAbs( x_distance )); + } + if( x_distance > 0 ) + { + for( int i=0; icurrentDesktop() -1 ) / x ) - (( old - 1 ) / x ); + if( qAbs( y_distance ) > y/2 ) + { + int sign = -1 * (y_distance/qAbs( y_distance )); + y_distance = sign * ( y - qAbs( y_distance )); + } + if( y_distance > 0 ) + { + for( int i=0; isetActiveFullScreenEffect( this ); + glList = glGenLists( 1 ); + timeLine.setProgress( 0.0 ); + front_desktop = old; + effects->addRepaintFull(); + } + } + +} // namespace diff --git a/effects/cube/cubeslide.desktop b/effects/cube/cubeslide.desktop new file mode 100644 index 0000000000..83dcedf2b3 --- /dev/null +++ b/effects/cube/cubeslide.desktop @@ -0,0 +1,17 @@ +[Desktop Entry] +Name=Desktop Cube Animation +Icon=preferences-system-windows-effect-cube +Comment=Animate desktop switching with a cube + +Type=Service +X-KDE-ServiceTypes=KWin/Effect +X-KDE-PluginInfo-Author=Martin Gräßlin +X-KDE-PluginInfo-Email=kde@martin-graesslin.com +X-KDE-PluginInfo-Name=kwin4_effect_cubeslide +X-KDE-PluginInfo-Version=0.1.0 +X-KDE-PluginInfo-Category=Window Management +X-KDE-PluginInfo-Depends= +X-KDE-PluginInfo-License=GPL +X-KDE-PluginInfo-EnabledByDefault=false +X-KDE-Library=kwin4_effect_builtins +X-KDE-Ordering=50 diff --git a/effects/cube/cubeslide.h b/effects/cube/cubeslide.h new file mode 100644 index 0000000000..5f2f5a5b23 --- /dev/null +++ b/effects/cube/cubeslide.h @@ -0,0 +1,68 @@ +/******************************************************************** + KWin - the KDE window manager + This file is part of the KDE project. + + Copyright (C) 2009 Martin Gräßlin + +This program is free software; you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation; either version 2 of the License, or +(at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program. If not, see . +*********************************************************************/ + +#ifndef KWIN_CUBESLIDE_H +#define KWIN_CUBESLIDE_H + +#include +#include +#include +#include + +namespace KWin +{ +class CubeSlideEffect + : public Effect + { + public: + CubeSlideEffect(); + ~CubeSlideEffect(); + virtual void reconfigure( ReconfigureFlags ); + virtual void prePaintScreen( ScreenPrePaintData& data, int time ); + virtual void paintScreen( int mask, QRegion region, ScreenPaintData& data ); + virtual void postPaintScreen(); + virtual void prePaintWindow( EffectWindow* w, WindowPrePaintData& data, int time ); + virtual void paintWindow( EffectWindow* w, int mask, QRegion region, WindowPaintData& data ); + virtual void desktopChanged( int old ); + + static bool supported(); + private: + enum RotationDirection + { + Left, + Right, + Upwards, + Downwards + }; + void paintSlideCube( int mask, QRegion region, ScreenPaintData& data ); + bool cube_painting; + int front_desktop; + int painting_desktop; + TimeLine timeLine; + QQueue slideRotations; + QSet panels; + QSet stickyWindows; + bool dontSlidePanels; + bool dontSlideStickyWindows; + GLuint glList; + }; +} + +#endif diff --git a/effects/cube/cubeslide_config.cpp b/effects/cube/cubeslide_config.cpp new file mode 100644 index 0000000000..78e6a4180a --- /dev/null +++ b/effects/cube/cubeslide_config.cpp @@ -0,0 +1,94 @@ +/******************************************************************** + KWin - the KDE window manager + This file is part of the KDE project. + + Copyright (C) 2009 Martin Gräßlin + +This program is free software; you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation; either version 2 of the License, or +(at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program. If not, see . +*********************************************************************/ +#include "cubeslide_config.h" +#include + +#include +#include +#include + +namespace KWin +{ + +KWIN_EFFECT_CONFIG_FACTORY + +CubeSlideEffectConfigForm::CubeSlideEffectConfigForm(QWidget* parent) : QWidget(parent) +{ + setupUi(this); +} + +CubeSlideEffectConfig::CubeSlideEffectConfig(QWidget* parent, const QVariantList& args) : + KCModule(EffectFactory::componentData(), parent, args) + { + m_ui = new CubeSlideEffectConfigForm(this); + + QVBoxLayout* layout = new QVBoxLayout(this); + + layout->addWidget(m_ui); + + connect(m_ui->rotationDurationSpin, SIGNAL(valueChanged(int)), this, SLOT(changed())); + connect(m_ui->dontSlidePanelsBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); + connect(m_ui->dontSlideStickyWindowsBox, SIGNAL(stateChanged(int)), this, SLOT(changed())); + + load(); + } + +void CubeSlideEffectConfig::load() + { + KCModule::load(); + + KConfigGroup conf = EffectsHandler::effectConfig( "CubeSlide" ); + + int duration = conf.readEntry( "RotationDuration", 0 ); + bool dontSlidePanels = conf.readEntry( "DontSlidePanels", true ); + bool dontSlideStickyWindows = conf.readEntry( "DontSlideStickyWindows", true ); + + m_ui->rotationDurationSpin->setValue( duration ); + m_ui->dontSlidePanelsBox->setChecked( dontSlidePanels ); + m_ui->dontSlideStickyWindowsBox->setChecked( dontSlideStickyWindows ); + + emit changed(false); + } + +void CubeSlideEffectConfig::save() + { + KConfigGroup conf = EffectsHandler::effectConfig( "CubeSlide" ); + + conf.writeEntry( "RotationDuration", m_ui->rotationDurationSpin->value() ); + conf.writeEntry( "DontSlidePanels", m_ui->dontSlidePanelsBox->isChecked() ); + conf.writeEntry( "DontSlideStickyWindows", m_ui->dontSlideStickyWindowsBox->isChecked() ); + + conf.sync(); + + emit changed(false); + EffectsHandler::sendReloadMessage( "cubeslide" ); + } + +void CubeSlideEffectConfig::defaults() + { + m_ui->rotationDurationSpin->setValue( 0 ); + m_ui->dontSlidePanelsBox->setChecked( true ); + m_ui->dontSlideStickyWindowsBox->setChecked( true ); + emit changed(true); + } + +} // namespace + +#include "cubeslide_config.moc" diff --git a/effects/cube/cubeslide_config.desktop b/effects/cube/cubeslide_config.desktop new file mode 100644 index 0000000000..3720328ee5 --- /dev/null +++ b/effects/cube/cubeslide_config.desktop @@ -0,0 +1,9 @@ +[Desktop Entry] +Type=Service +X-KDE-ServiceTypes=KCModule + +X-KDE-Library=kcm_kwin4_effect_builtins +X-KDE-ParentComponents=kwin4_effect_cubeslide +X-KDE-PluginKeyword=cubeslide + +Name=Desktop Cube Animation diff --git a/effects/cube/cubeslide_config.h b/effects/cube/cubeslide_config.h new file mode 100644 index 0000000000..6ebfde7435 --- /dev/null +++ b/effects/cube/cubeslide_config.h @@ -0,0 +1,56 @@ +/******************************************************************** + KWin - the KDE window manager + This file is part of the KDE project. + + Copyright (C) 2009 Martin Gräßlin + +This program is free software; you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation; either version 2 of the License, or +(at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program. If not, see . +*********************************************************************/ + +#ifndef KWIN_CUBESLIDE_CONFIG_H +#define KWIN_CUBESLIDE_CONFIG_H + +#include + +#include "ui_cubeslide_config.h" + +class KFileDialog; + +namespace KWin +{ + +class CubeSlideEffectConfigForm : public QWidget, public Ui::CubeSlideEffectConfigForm +{ + Q_OBJECT + public: + explicit CubeSlideEffectConfigForm(QWidget* parent); +}; + +class CubeSlideEffectConfig : public KCModule + { + Q_OBJECT + public: + explicit CubeSlideEffectConfig(QWidget* parent = 0, const QVariantList& args = QVariantList()); + + public slots: + virtual void save(); + virtual void load(); + virtual void defaults(); + private: + CubeSlideEffectConfigForm* m_ui; + }; + +} // namespace + +#endif diff --git a/effects/cube/cubeslide_config.ui b/effects/cube/cubeslide_config.ui new file mode 100644 index 0000000000..dc3ab67c6a --- /dev/null +++ b/effects/cube/cubeslide_config.ui @@ -0,0 +1,97 @@ + + KWin::CubeSlideEffectConfigForm + + + + 0 + 0 + 342 + 126 + + + + + + + + 0 + 0 + + + + + 100 + 0 + + + + Default + + + msec + + + 5000 + + + 10 + + + + + + + Do not animate panels + + + + + + + Do not animate windows on all desktops + + + + + + + Qt::Vertical + + + + 20 + 40 + + + + + + + + Rotation duration: + + + Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter + + + rotationDurationSpin + + + + + tabWidget + groupBox + dontSlideStickyWindowsBox + verticalSpacer + rotationDurationSpin + dontSlidePanelsBox + label + + + rotationDurationSpin + dontSlidePanelsBox + dontSlideStickyWindowsBox + + + + diff --git a/effects/cube/cylinder.cpp b/effects/cube/cylinder.cpp index e5dfe8ca5b..2cfec92a7d 100644 --- a/effects/cube/cylinder.cpp +++ b/effects/cube/cylinder.cpp @@ -82,7 +82,7 @@ bool CylinderEffect::loadData() mShader->setUniform( "winTexture", 0 ); mShader->setUniform( "opacity", cubeOpacity ); QRect rect = effects->clientArea( FullScreenArea, activeScreen, effects->currentDesktop()); - if( effects->numScreens() > 1 && (slide || bigCube ) ) + if( effects->numScreens() > 1 && bigCube ) rect = effects->clientArea( FullArea, activeScreen, effects->currentDesktop() ); mShader->setUniform( "width", (float)rect.width() ); mShader->unbind(); diff --git a/effects/cube/sphere.cpp b/effects/cube/sphere.cpp index 2b63ccb1d4..674d69d2a7 100644 --- a/effects/cube/sphere.cpp +++ b/effects/cube/sphere.cpp @@ -82,7 +82,7 @@ bool SphereEffect::loadData() mShader->setUniform( "winTexture", 0 ); mShader->setUniform( "opacity", cubeOpacity ); QRect rect = effects->clientArea( FullScreenArea, activeScreen, effects->currentDesktop()); - if( effects->numScreens() > 1 && (slide || bigCube ) ) + if( effects->numScreens() > 1 && bigCube ) rect = effects->clientArea( FullArea, activeScreen, effects->currentDesktop() ); mShader->setUniform( "width", (float)rect.width() ); mShader->setUniform( "height", (float)rect.height() ); diff --git a/kcmkwin/kwincompositing/main.cpp b/kcmkwin/kwincompositing/main.cpp index 27ff713016..af16574f48 100644 --- a/kcmkwin/kwincompositing/main.cpp +++ b/kcmkwin/kwincompositing/main.cpp @@ -181,7 +181,7 @@ KWinCompositingConfig::KWinCompositingConfig(QWidget *parent, const QVariantList services = trader->query("KWin/Effect", "[X-KDE-PluginInfo-Name] == 'kwin4_effect_slide'"); if( !services.isEmpty() ) slide = services.first()->name(); - services = trader->query("KWin/Effect", "[X-KDE-PluginInfo-Name] == 'kwin4_effect_cube'"); + services = trader->query("KWin/Effect", "[X-KDE-PluginInfo-Name] == 'kwin4_effect_cubeslide'"); if( !services.isEmpty() ) cube = services.first()->name(); services = trader->query("KWin/Effect", "[X-KDE-PluginInfo-Name] == 'kwin4_effect_fadedesktop'"); @@ -339,8 +339,7 @@ void KWinCompositingConfig::loadGeneralTab() ui.desktopSwitchingCombo->setCurrentIndex( 0 ); if( effectEnabled( "slide", effectconfig )) ui.desktopSwitchingCombo->setCurrentIndex( 1 ); - KConfigGroup cubeconfig(mKWinConfig, "Effect-Cube"); - if( effectEnabled( "cube", effectconfig ) && cubeconfig.readEntry("AnimateDesktopChange", false)) + if( effectEnabled( "cubeslide", effectconfig )) ui.desktopSwitchingCombo->setCurrentIndex( 2 ); if( effectEnabled( "fadedesktop", effectconfig )) ui.desktopSwitchingCombo->setCurrentIndex( 3 ); @@ -472,34 +471,33 @@ void KWinCompositingConfig::saveGeneralTab() presentwindowsconfig.writeEntry("TabBox", presentWindowSwitching); int desktopSwitcher = ui.desktopSwitchingCombo->currentIndex(); - bool cubeDesktopSwitching = false; switch( desktopSwitcher ) { case 0: // no effect effectconfig.writeEntry("kwin4_effect_slideEnabled", false); + effectconfig.writeEntry("kwin4_effect_cubeslideEnabled", false); effectconfig.writeEntry("kwin4_effect_fadedesktopEnabled", false); break; case 1: // slide effectconfig.writeEntry("kwin4_effect_slideEnabled", true); + effectconfig.writeEntry("kwin4_effect_cubeslideEnabled", false); effectconfig.writeEntry("kwin4_effect_fadedesktopEnabled", false); break; case 2: // cube - cubeDesktopSwitching = true; effectconfig.writeEntry("kwin4_effect_slideEnabled", false); - effectconfig.writeEntry("kwin4_effect_cubeEnabled", true); + effectconfig.writeEntry("kwin4_effect_cubeslideEnabled", true); effectconfig.writeEntry("kwin4_effect_fadedesktopEnabled", false); break; case 3: // fadedesktop effectconfig.writeEntry("kwin4_effect_slideEnabled", false); + effectconfig.writeEntry("kwin4_effect_cubeslideEnabled", false); effectconfig.writeEntry("kwin4_effect_fadedesktopEnabled", true); break; } - KConfigGroup cubeconfig(mKWinConfig, "Effect-Cube"); - cubeconfig.writeEntry("AnimateDesktopChange", cubeDesktopSwitching); } void KWinCompositingConfig::saveEffectsTab() From 5b89fb86ed902383ddf60e11b8a0e5acd2582feb Mon Sep 17 00:00:00 2001 From: Albert Astals Cid Date: Fri, 6 Feb 2009 21:23:57 +0000 Subject: [PATCH 36/60] Typo found by Yuri Chornoivan svn path=/trunk/KDE/kdebase/workspace/; revision=922388 --- effects/cube/cube_config.ui | 2 +- effects/cube/cylinder_config.ui | 2 +- effects/cube/sphere_config.ui | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/effects/cube/cube_config.ui b/effects/cube/cube_config.ui index 4e72d7edc7..d1b5918143 100644 --- a/effects/cube/cube_config.ui +++ b/effects/cube/cube_config.ui @@ -432,7 +432,7 @@ otherwise it will remain active - Invert courser keys + Invert cursor keys diff --git a/effects/cube/cylinder_config.ui b/effects/cube/cylinder_config.ui index 433db2d8f9..c92ad63ea8 100644 --- a/effects/cube/cylinder_config.ui +++ b/effects/cube/cylinder_config.ui @@ -421,7 +421,7 @@ otherwise it will remain active. - Invert courser keys + Invert cursor keys diff --git a/effects/cube/sphere_config.ui b/effects/cube/sphere_config.ui index 406cf3a13c..d0f6bf5c64 100644 --- a/effects/cube/sphere_config.ui +++ b/effects/cube/sphere_config.ui @@ -421,7 +421,7 @@ otherwise it will remain active - Invert courser keys + Invert cursor keys From a604e4a60d614e9a2fdd92a370909d1450a54a2d Mon Sep 17 00:00:00 2001 From: Frederik Schwarzer Date: Sat, 7 Feb 2009 01:12:28 +0000 Subject: [PATCH 37/60] global typo fix svn path=/trunk/KDE/kdebase/workspace/; revision=922431 --- activation.cpp | 2 +- events.cpp | 2 +- geometry.cpp | 2 +- group.cpp | 2 +- kcmkwin/kwincompositing/main.cpp | 2 +- workspace.cpp | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/activation.cpp b/activation.cpp index a92cd36db3..a1eddf6dd9 100644 --- a/activation.cpp +++ b/activation.cpp @@ -116,7 +116,7 @@ namespace KWin Since at this time it's known that the new window doesn't belong to any existing application (better said, the application doesn't have any other window mapped), it is either the very first window - of the application, or its the only window of the application + of the application, or it is the only window of the application that was hidden before. The latter case is handled by removing the property from windows before withdrawing them, making the timestamp empty for next mapping of the window. In the sooner diff --git a/events.cpp b/events.cpp index a6cc98fac3..a8764df70d 100644 --- a/events.cpp +++ b/events.cpp @@ -744,7 +744,7 @@ bool Client::mapRequestEvent( XMapRequestEvent* e ) { // Special support for the save-set feature, which is a bit broken. // If there's a window from one client embedded in another one, - // e.g. using XEMBED, and the embedder suddenly looses its X connection, + // e.g. using XEMBED, and the embedder suddenly loses its X connection, // save-set will reparent the embedded window to its closest ancestor // that will remains. Unfortunately, with reparenting window managers, // this is not the root window, but the frame (or in KWin's case, diff --git a/geometry.cpp b/geometry.cpp index a8d9222995..6c8b554876 100644 --- a/geometry.cpp +++ b/geometry.cpp @@ -2267,7 +2267,7 @@ bool Client::isFullScreenable( bool fullscreen_hack ) const return isNormalWindow(); if( rules()->checkStrictGeometry( false )) { - // the app wouldn't fit exactly fullscreen geometry due its strict geometry requirements + // the app wouldn't fit exactly fullscreen geometry due to its strict geometry requirements QRect fsarea = workspace()->clientArea( FullScreenArea, this ); if( sizeForClientSize( fsarea.size(), SizemodeAny, true ) != fsarea.size()) return false; diff --git a/group.cpp b/group.cpp index 0b90b2ca5b..1d68db47f7 100644 --- a/group.cpp +++ b/group.cpp @@ -1050,7 +1050,7 @@ void Client::checkGroup( Group* set_group, bool force ) } else // Not transient without a group, put it in its client leader group. { // This might be stupid if grouping was used for e.g. taskbar grouping - // or minimizing together the whole group, but as long as its used + // or minimizing together the whole group, but as long as it is used // only for dialogs it's better to keep windows from one app in one group. Group* new_group = workspace()->findClientLeaderGroup( this ); if( in_group != NULL && in_group != new_group ) diff --git a/kcmkwin/kwincompositing/main.cpp b/kcmkwin/kwincompositing/main.cpp index af16574f48..6b2fa1b0bd 100644 --- a/kcmkwin/kwincompositing/main.cpp +++ b/kcmkwin/kwincompositing/main.cpp @@ -549,7 +549,7 @@ void KWinCompositingConfig::save() mPreviousConfig = config.entryMap(); // bah; tab content being dependent on the other is really bad; and - // deprecated in the HIG for a reason. Its confusing! + // deprecated in the HIG for a reason. It is confusing! // Make sure we only call save on each tab once; as they are stateful due to the revert concept if ( ui.tabWidget->currentIndex() == 0 ) // "General" tab was active { diff --git a/workspace.cpp b/workspace.cpp index e5a9e0142e..132dcd2828 100644 --- a/workspace.cpp +++ b/workspace.cpp @@ -2433,7 +2433,7 @@ void Workspace::setupTopMenuHandling() int Workspace::topMenuHeight() const { if( topmenu_height == 0 ) - { // Simply create a dummy menubar and use its preffered height as the menu height + { // Simply create a dummy menubar and use its preferred height as the menu height KMenuBar tmpmenu; tmpmenu.addAction( "dummy" ); topmenu_height = tmpmenu.sizeHint().height(); From 1db192a11da7505f83f26e7ca0c354ccff48a17e Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Sat, 7 Feb 2009 05:52:25 +0000 Subject: [PATCH 38/60] Fixed cube from crashing due to mouse polling if it was activated and deactivated too quickly. svn path=/trunk/KDE/kdebase/workspace/; revision=922457 --- effects/cube/cube.cpp | 13 +++++++++++-- effects/cube/cube.h | 1 + 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/effects/cube/cube.cpp b/effects/cube/cube.cpp index e173a50dd6..c1ceb5218c 100644 --- a/effects/cube/cube.cpp +++ b/effects/cube/cube.cpp @@ -46,6 +46,7 @@ KWIN_EFFECT_SUPPORTED( cube, CubeEffect::supported() ) CubeEffect::CubeEffect() : activated( false ) + , mousePolling( false ) , cube_painting( false ) , keyboard_grab( false ) , schedule_close( false ) @@ -1615,7 +1616,11 @@ void CubeEffect::setActive( bool active ) { if( active ) { - effects->startMousePolling(); + if( !mousePolling ) + { + effects->startMousePolling(); + mousePolling = true; + } activated = true; activeScreen = effects->activeScreen(); keyboard_grab = effects->grabKeyboard( this ); @@ -1662,7 +1667,11 @@ void CubeEffect::setActive( bool active ) } else { - effects->stopMousePolling(); + if( mousePolling ) + { + effects->stopMousePolling(); + mousePolling = false; + } schedule_close = true; // we have to add a repaint, to start the deactivating effects->addRepaintFull(); diff --git a/effects/cube/cube.h b/effects/cube/cube.h index bf98cd73f4..1f4a62c2ca 100644 --- a/effects/cube/cube.h +++ b/effects/cube/cube.h @@ -77,6 +77,7 @@ class CubeEffect void rotateToDesktop( int desktop ); void setActive( bool active ); bool activated; + bool mousePolling; bool cube_painting; bool keyboard_grab; bool schedule_close; From 681cda92b552b8d3874bae9dca6a6fc0e134a6ef Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Sat, 7 Feb 2009 09:48:20 +0000 Subject: [PATCH 39/60] Add slight animations to the dim inactive effect. Also don't dim windows when a fullscreen effect is active, fixes dimmed windows during coverswitch. BUG: 165295 svn path=/trunk/KDE/kdebase/workspace/; revision=922574 --- effects/diminactive/diminactive.cpp | 34 ++++++++++++++++++++++++++--- effects/diminactive/diminactive.h | 4 ++++ 2 files changed, 35 insertions(+), 3 deletions(-) diff --git a/effects/diminactive/diminactive.cpp b/effects/diminactive/diminactive.cpp index 5f6daac1d2..244fdb2ec7 100644 --- a/effects/diminactive/diminactive.cpp +++ b/effects/diminactive/diminactive.cpp @@ -31,7 +31,10 @@ KWIN_EFFECT( diminactive, DimInactiveEffect ) DimInactiveEffect::DimInactiveEffect() { reconfigure( ReconfigureAll ); + timeline.setDuration( 250 ); + previousActiveTimeline.setDuration( 250 ); active = effects->activeWindow(); + previousActive = NULL; } void DimInactiveEffect::reconfigure( ReconfigureFlags ) @@ -43,12 +46,34 @@ void DimInactiveEffect::reconfigure( ReconfigureFlags ) dim_strength = conf.readEntry("Strength", 25); } +void DimInactiveEffect::prePaintScreen( ScreenPrePaintData& data, int time ) + { + double oldValue = timeline.value(); + if( effects->activeFullScreenEffect() ) + timeline.removeTime( time ); + else + timeline.addTime( time ); + if( oldValue != timeline.value() ) + effects->addRepaintFull(); + if( previousActive ) + { // We are fading out the previous window + previousActive->addRepaintFull(); + previousActiveTimeline.addTime( time ); + } + effects->prePaintScreen( data, time ); + } + void DimInactiveEffect::paintWindow( EffectWindow* w, int mask, QRegion region, WindowPaintData& data ) { - if( dimWindow( w )) + if( dimWindow( w ) || w == previousActive ) { - data.brightness *= (1.0 - (dim_strength / 100.0)); - data.saturation *= (1.0 - (dim_strength / 100.0)); + double previous = 1.0; + if( w == previousActive ) + previous = previousActiveTimeline.value(); + if( previousActiveTimeline.value() == 1.0 ) + previousActive = NULL; + data.brightness *= (1.0 - (dim_strength / 100.0) * timeline.value() * previous ); + data.saturation *= (1.0 - (dim_strength / 100.0) * timeline.value() * previous ); } effects->paintWindow( w, mask, region, data ); } @@ -76,6 +101,9 @@ void DimInactiveEffect::windowActivated( EffectWindow* w ) { if( active != NULL ) { + previousActive = active; + previousActiveTimeline.setProgress( 0.0 ); + if( dim_by_group ) { if(( w == NULL || w->group() != active->group()) && active->group() != NULL ) diff --git a/effects/diminactive/diminactive.h b/effects/diminactive/diminactive.h index 1c58b86bd1..9111254c38 100644 --- a/effects/diminactive/diminactive.h +++ b/effects/diminactive/diminactive.h @@ -35,11 +35,15 @@ class DimInactiveEffect public: DimInactiveEffect(); virtual void reconfigure( ReconfigureFlags ); + virtual void prePaintScreen( ScreenPrePaintData& data, int time ); virtual void paintWindow( EffectWindow* w, int mask, QRegion region, WindowPaintData& data ); virtual void windowActivated( EffectWindow* c ); private: bool dimWindow( const EffectWindow* w ) const; + TimeLine timeline; EffectWindow* active; + EffectWindow* previousActive; + TimeLine previousActiveTimeline; int dim_strength; // reduce saturation and brightness by this percentage bool dim_panels; // do/don't dim also all panels bool dim_desktop; // do/don't dim the desktop From c028835466c9ba969efe00ccb40c986d5407def8 Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Sat, 7 Feb 2009 09:53:17 +0000 Subject: [PATCH 40/60] SVN_SILENT Make dim inactive effect animation obey the user's animation speed settings. svn path=/trunk/KDE/kdebase/workspace/; revision=922576 --- effects/diminactive/diminactive.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/effects/diminactive/diminactive.cpp b/effects/diminactive/diminactive.cpp index 244fdb2ec7..9cfe990978 100644 --- a/effects/diminactive/diminactive.cpp +++ b/effects/diminactive/diminactive.cpp @@ -31,8 +31,8 @@ KWIN_EFFECT( diminactive, DimInactiveEffect ) DimInactiveEffect::DimInactiveEffect() { reconfigure( ReconfigureAll ); - timeline.setDuration( 250 ); - previousActiveTimeline.setDuration( 250 ); + timeline.setDuration( animationTime( 250 )); + previousActiveTimeline.setDuration( animationTime( 250 )); active = effects->activeWindow(); previousActive = NULL; } From fd233d1482c6b361960b55c509f1f8dc2fea4dd7 Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Sat, 7 Feb 2009 15:40:31 +0000 Subject: [PATCH 41/60] SVN_SILENT Started writing code that would display a thumbnail of a window in the middle of the screen if it was offscreen when the highlight window effect was activated. After getting half way through it however I determined that it was a useless feature so instead of deleting the code that was already written I am just commenting it out. If anyone can find a purpose for this please let me know your ideas. svn path=/trunk/KDE/kdebase/workspace/; revision=922795 --- effects/highlightwindow/highlightwindow.cpp | 76 +++++++++++++++++++++ effects/highlightwindow/highlightwindow.h | 14 ++++ 2 files changed, 90 insertions(+) diff --git a/effects/highlightwindow/highlightwindow.cpp b/effects/highlightwindow/highlightwindow.cpp index 8623f7c61a..9a23599832 100644 --- a/effects/highlightwindow/highlightwindow.cpp +++ b/effects/highlightwindow/highlightwindow.cpp @@ -130,6 +130,82 @@ void HighlightWindowEffect::propertyNotify( EffectWindow* w, long a ) } prepareHighlighting(); m_windowOpacity[w] = 1.0; // Because it's not in stackingOrder() yet + + /* TODO: Finish thumbnails of offscreen windows, not sure if it's worth it though + if( !m_highlightedWindow->isOnCurrentDesktop() ) + { // Window is offscreen, determine thumbnail position + QRect screenArea = effects->clientArea( MaximizeArea ); // Workable area of the active screen + QRect outerArea = outerArea.adjusted( outerArea.width() / 10, outerArea.height() / 10, + -outerArea.width() / 10, -outerArea.height() / 10 ); // Add 10% margin around the edge + QRect innerArea = outerArea.adjusted( outerArea.width() / 40, outerArea.height() / 40, + -outerArea.width() / 40, -outerArea.height() / 40 ); // Outer edge of the thumbnail border (2.5%) + QRect thumbArea = outerArea.adjusted( 20, 20, -20, -20 ); // Outer edge of the thumbnail (20px) + + // Determine the maximum size that we can make the thumbnail within the innerArea + double areaAspect = double( thumbArea.width() ) / double( thumbArea.height() ); + double windowAspect = aspectRatio( m_highlightedWindow ); + QRect thumbRect; // Position doesn't matter right now, but it will later + if( windowAspect > areaAspect ) + // Top/bottom will touch first + thumbRect = QRect( 0, 0, widthForHeight( thumbArea.height() ), thumbArea.height() ); + else // Left/right will touch first + thumbRect = QRect( 0, 0, thumbArea.width(), heightForWidth( thumbArea.width() )); + if( thumbRect.width() >= m_highlightedWindow->width() ) + // Area is larger than the window, just use the window's size + thumbRect = m_highlightedWindow->geometry(); + + // Determine position of desktop relative to the current one + QSize grid; + Qt::Orientation orientation; + effects->calcDesktopLayout( &grid.rwidth(), &grid.rheight(), &orientation ); + QPoint currentDesktop; + QPoint targetDesktop; + if( orientation == Qt::Horizontal ) + { + currentDesktop.setX(( effects->currentDesktop() - 1 ) % grid.width() + 1 ); + currentDesktop.setY(( effects->currentDesktop() - 1 ) / grid.width() + 1 ); + targetDesktop.setX(( m_highlightedWindow->desktop() - 1 ) % grid.width() + 1 ); + targetDesktop.setY(( m_highlightedWindow->desktop() - 1 ) / grid.width() + 1 ); + } + else + { + currentDesktop.setX(( effects->currentDesktop() - 1 ) / grid.height() + 1 ); + currentDesktop.setY(( effects->currentDesktop() - 1 ) % grid.height() + 1 ); + targetDesktop.setX(( m_highlightedWindow->desktop() - 1 ) / grid.height() + 1 ); + targetDesktop.setY(( m_highlightedWindow->desktop() - 1 ) % grid.height() + 1 ); + } + QPoint direction = targetDesktop - currentDesktop; + + // Draw a line from the center of the current desktop to the center of the target desktop. + QPointF desktopLine( 0, 0, direction.x() * screenArea.width(), direction.y() * screenArea.height() ); + desktopLeft.translate( screenArea.width() / 2, screenArea.height() / 2 ); // Move to the screen center + + // Take the point where the line crosses the outerArea, this will be the tip of our arrow + QPointF arrowTip; + QLineF testLine( // Top + outerArea.x(), outerArea.y(), + outerArea.x() + outerArea.width(), outerArea.y() ); + if( desktopLine.intersect( testLine, &arrowTip ) != QLineF::BoundedIntersection ) + { + testLine = QLineF( // Right + outerArea.x() + outerArea.width(), outerArea.y(), + outerArea.x() + outerArea.width(), outerArea.y() + outerArea.height() ); + if( desktopLine.intersect( testLine, &arrowTip ) != QLineF::BoundedIntersection ) + { + testLine = QLineF( // Bottom + outerArea.x() + outerArea.width(), outerArea.y() + outerArea.height(), + outerArea.x(), outerArea.y() + outerArea.height() ); + if( desktopLine.intersect( testLine, &arrowTip ) != QLineF::BoundedIntersection ) + { + testLine = QLineF( // Left + outerArea.x(), outerArea.y() + outerArea.height(), + outerArea.x(), outerArea.y() ); + desktopLine.intersect( testLine, &arrowTip ); // Should never fail + } + } + } + m_arrowTip = arrowTip.toPoint(); + } */ } void HighlightWindowEffect::prepareHighlighting() diff --git a/effects/highlightwindow/highlightwindow.h b/effects/highlightwindow/highlightwindow.h index 414d880555..c7982210f6 100644 --- a/effects/highlightwindow/highlightwindow.h +++ b/effects/highlightwindow/highlightwindow.h @@ -53,6 +53,20 @@ class HighlightWindowEffect long m_atom; EffectWindow* m_highlightedWindow; EffectWindow* m_monitorWindow; + + // Offscreen position cache + /*QRect m_thumbArea; // Thumbnail area + QPoint m_arrowTip; // Position of the arrow's tip + QPoint m_arrowA; // Arrow vertex position at the base (First) + QPoint m_arrowB; // Arrow vertex position at the base (Second) + + // Helper functions + inline double aspectRatio( EffectWindow *w ) + { return w->width() / double( w->height() ); } + inline int widthForHeight( EffectWindow *w, int height ) + { return int(( height / double( w->height() )) * w->width() ); } + inline int heightForWidth( EffectWindow *w, int width ) + { return int(( width / double( w->width() )) * w->height() ); }*/ }; } // namespace From b4151d2103a26f3e4c122240dc20bfbbbc6afd56 Mon Sep 17 00:00:00 2001 From: Script Kiddy Date: Sat, 7 Feb 2009 16:03:24 +0000 Subject: [PATCH 42/60] SVN_SILENT made messages (.desktop file) svn path=/trunk/KDE/kdebase/workspace/; revision=922806 --- effects/coverswitch/coverswitch.desktop | 1 + effects/coverswitch/coverswitch_config.desktop | 1 + effects/fadedesktop/fadedesktop.desktop | 1 + effects/flipswitch/flipswitch.desktop | 2 +- effects/flipswitch/flipswitch_config.desktop | 2 +- 5 files changed, 5 insertions(+), 2 deletions(-) diff --git a/effects/coverswitch/coverswitch.desktop b/effects/coverswitch/coverswitch.desktop index 732c45374a..3273764d7d 100644 --- a/effects/coverswitch/coverswitch.desktop +++ b/effects/coverswitch/coverswitch.desktop @@ -8,6 +8,7 @@ Name[ca]=Canvi de capa Name[ca@valencia]=Canvi de capa Name[da]=Cover-skifter Name[de]=3D-Fenstergalerie +Name[el]=Εναλλαγή εξωφύλλου Name[eo]=Kovra ŝanĝilo Name[es]=Selección de ventana en modo carátula Name[et]=Aknalülitaja diff --git a/effects/coverswitch/coverswitch_config.desktop b/effects/coverswitch/coverswitch_config.desktop index 78faf79107..bea5a42fb7 100644 --- a/effects/coverswitch/coverswitch_config.desktop +++ b/effects/coverswitch/coverswitch_config.desktop @@ -15,6 +15,7 @@ Name[ca]=Canvi de capa Name[ca@valencia]=Canvi de capa Name[da]=Cover-skifter Name[de]=3D-Fenstergalerie +Name[el]=Εναλλαγή εξωφύλλου Name[eo]=Kovra ŝanĝilo Name[es]=Selección de ventana en modo carátula Name[et]=Aknalülitaja diff --git a/effects/fadedesktop/fadedesktop.desktop b/effects/fadedesktop/fadedesktop.desktop index 0738a7fa01..1c96013882 100644 --- a/effects/fadedesktop/fadedesktop.desktop +++ b/effects/fadedesktop/fadedesktop.desktop @@ -2,6 +2,7 @@ Name=Fade Desktop Name[ca]=Esvair l'escriptori Name[ca@valencia]=Esvair l'escriptori +Name[el]=Ομαλή εμφάνιση επιφάνειας εργασίας Name[et]=Töölaua hääbumine Name[gl]=Esvair o escritorio Name[nds]=Schriefdisch överblennen diff --git a/effects/flipswitch/flipswitch.desktop b/effects/flipswitch/flipswitch.desktop index 49500ffdb3..b194c08b09 100644 --- a/effects/flipswitch/flipswitch.desktop +++ b/effects/flipswitch/flipswitch.desktop @@ -6,7 +6,7 @@ Name[ca]=Canvi en roda Name[ca@valencia]=Canvi en roda Name[da]=Vippeskifter Name[de]=3D-Fensterstapel -Name[el]=Εναλλαγή πλαισίου +Name[el]=Εναλλαγή στοίβας Name[eo]=Turna ŝanĝilo Name[es]=Selección de ventana en modo cascada Name[et]=Aknalehitseja diff --git a/effects/flipswitch/flipswitch_config.desktop b/effects/flipswitch/flipswitch_config.desktop index f1debbe3d0..6ccafa7c32 100644 --- a/effects/flipswitch/flipswitch_config.desktop +++ b/effects/flipswitch/flipswitch_config.desktop @@ -13,7 +13,7 @@ Name[ca]=Canvi en roda Name[ca@valencia]=Canvi en roda Name[da]=Vippeskifter Name[de]=3D-Fensterstapel -Name[el]=Εναλλαγή πλαισίου +Name[el]=Εναλλαγή στοίβας Name[eo]=Turna ŝanĝilo Name[es]=Selección de ventana en modo cascada Name[et]=Aknalehitseja From 13c2f21e9dd5707004c470fb1f9e8136620497c1 Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Sun, 8 Feb 2009 08:45:21 +0000 Subject: [PATCH 43/60] Added EffectWindow::acceptsFocus(). Prevent present windows from displaying windows that cannot be focused anyway (Such as conky). svn path=/trunk/KDE/kdebase/workspace/; revision=923091 --- effects.cpp | 8 ++++++++ effects.h | 1 + effects/presentwindows/presentwindows.cpp | 2 ++ lib/kwineffects.h | 6 +++++- 4 files changed, 16 insertions(+), 1 deletion(-) diff --git a/effects.cpp b/effects.cpp index 949ecd96b1..52dda8e9f5 100644 --- a/effects.cpp +++ b/effects.cpp @@ -1343,6 +1343,14 @@ bool EffectWindowImpl::isManaged() const return dynamic_cast< const Client* >( toplevel ) != NULL; } +bool EffectWindowImpl::acceptsFocus() const + { + const Client* client = dynamic_cast< const Client* >( toplevel ); + if( !client ) + return true; // We don't actually know... + return client->wantsInput(); + } + bool EffectWindowImpl::isModal() const { if( Client* c = dynamic_cast< Client* >( toplevel )) diff --git a/effects.h b/effects.h index e78eb7057e..d4416b1a52 100644 --- a/effects.h +++ b/effects.h @@ -237,6 +237,7 @@ class EffectWindowImpl : public EffectWindow virtual bool isComboBox() const; virtual bool isDNDIcon() const; virtual bool isManaged() const; // managed or override-redirect + virtual bool acceptsFocus() const; virtual bool isModal() const; virtual EffectWindow* findModal(); diff --git a/effects/presentwindows/presentwindows.cpp b/effects/presentwindows/presentwindows.cpp index 4f7a6d8d2c..b7d0d7988b 100644 --- a/effects/presentwindows/presentwindows.cpp +++ b/effects/presentwindows/presentwindows.cpp @@ -1268,6 +1268,8 @@ bool PresentWindowsEffect::isSelectableWindow( EffectWindow *w ) return false; if( w->isDeleted() ) return false; + if( !w->acceptsFocus() ) + return false; if( !m_allDesktops && !w->isOnCurrentDesktop() ) return false; if( !m_tabBoxEnabled && m_ignoreMinimized && w->isMinimized() ) diff --git a/lib/kwineffects.h b/lib/kwineffects.h index 206a618df4..89ccf1ec7b 100644 --- a/lib/kwineffects.h +++ b/lib/kwineffects.h @@ -164,7 +164,7 @@ X-KDE-Library=kwin4_effect_cooleffect #define KWIN_EFFECT_API_MAKE_VERSION( major, minor ) (( major ) << 8 | ( minor )) #define KWIN_EFFECT_API_VERSION_MAJOR 0 -#define KWIN_EFFECT_API_VERSION_MINOR 58 +#define KWIN_EFFECT_API_VERSION_MINOR 59 #define KWIN_EFFECT_API_VERSION KWIN_EFFECT_API_MAKE_VERSION( \ KWIN_EFFECT_API_VERSION_MAJOR, KWIN_EFFECT_API_VERSION_MINOR ) @@ -843,6 +843,10 @@ class KWIN_EXPORT EffectWindow * aspects, as opposed to override-redirect windows that are entirely handled by the application). */ virtual bool isManaged() const = 0; // whether it's managed or override-redirect + /** + * Returns whether or not the window can accept keyboard focus. + */ + virtual bool acceptsFocus() const = 0; virtual bool isModal() const = 0; virtual EffectWindow* findModal() = 0; From 8f8c1d31ba9f8a3f32a49b9911e514b2c0d5c52e Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Sun, 8 Feb 2009 14:07:00 +0000 Subject: [PATCH 44/60] Added blurring during the logout effect. As this is done entirely using mipmaps the quality isn't the best. Might add a shader later that will generate the final image so it uses mipmaps for realtime blurring while using a high quality blur at the end. svn path=/trunk/KDE/kdebase/workspace/; revision=923246 --- effects/logout/logout.cpp | 85 +++++++++++++++++++++++++++++++++++++++ effects/logout/logout.h | 12 ++++++ 2 files changed, 97 insertions(+) diff --git a/effects/logout/logout.cpp b/effects/logout/logout.cpp index 7d0c3e4228..6fe089b9db 100644 --- a/effects/logout/logout.cpp +++ b/effects/logout/logout.cpp @@ -3,6 +3,7 @@ This file is part of the KDE project. Copyright (C) 2007 Lubos Lunak +Copyright (C) 2009 Lucas Murray This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -40,6 +41,38 @@ LogoutEffect::LogoutEffect() Atom hack = XInternAtom( display(), "_KWIN_LOGOUT_EFFECT", False ); XChangeProperty( display(), sel, hack, hack, 8, PropModeReplace, (unsigned char*)&hack, 1 ); // the atom is not removed when effect is destroyed, this is temporary anyway + +#ifdef KWIN_HAVE_OPENGL_COMPOSITING + blurSupported = false; + + // If NPOT textures are not supported use the nearest power-of-two sized + // texture. It wastes memory, but it's possible to support systems without + // NPOT textures this way. + int texw = displayWidth(); + int texh = displayHeight(); + if( !GLTexture::NPOTTextureSupported() ) + { + kWarning( 1212 ) << "NPOT textures not supported, wasting some memory"; + texw = nearestPowerOfTwo( texw ); + texh = nearestPowerOfTwo( texh ); + } + // Create texture and render target + blurTexture = new GLTexture( texw, texh ); + blurTexture->setFilter( GL_LINEAR_MIPMAP_LINEAR ); + blurTexture->setWrapMode( GL_CLAMP_TO_EDGE ); + + blurTarget = new GLRenderTarget( blurTexture ); + if( blurTarget->valid() ) + blurSupported = true; +#endif + } + +LogoutEffect::~LogoutEffect() + { +#ifdef KWIN_HAVE_OPENGL_COMPOSITING + delete blurTexture; + delete blurTarget; +#endif } void LogoutEffect::prePaintScreen( ScreenPrePaintData& data, int time ) @@ -48,9 +81,27 @@ void LogoutEffect::prePaintScreen( ScreenPrePaintData& data, int time ) progress = qBound( 0., progress + time / animationTime( 2000. ), 1. ); else if( progress != 0 ) progress = qBound( 0., progress - time / animationTime( 500. ), 1. ); + +#ifdef KWIN_HAVE_OPENGL_COMPOSITING + if( blurSupported && progress > 0.0 ) + { + data.mask |= PAINT_SCREEN_WITH_TRANSFORMED_WINDOWS; + effects->pushRenderTarget( blurTarget ); + } +#endif + effects->prePaintScreen( data, time ); } +void LogoutEffect::prePaintWindow( EffectWindow* w, WindowPrePaintData& data, int time ) + { +#ifdef KWIN_HAVE_OPENGL_COMPOSITING + if( blurSupported && progress > 0.0 && w == logout_window ) + w->disablePainting( EffectWindow::PAINT_DISABLED ); +#endif + effects->prePaintWindow( w, data, time ); + } + void LogoutEffect::paintWindow( EffectWindow* w, int mask, QRegion region, WindowPaintData& data ) { if( w != logout_window && progress != 0 ) @@ -73,6 +124,40 @@ void LogoutEffect::postPaintScreen() if( progress != 0 && progress != 1 ) effects->addRepaintFull(); effects->postPaintScreen(); + +#ifdef KWIN_HAVE_OPENGL_COMPOSITING + if( blurSupported && progress > 0.0 ) + { + assert( effects->popRenderTarget() == blurTarget ); + + // Render the blurred scene + blurTexture->bind(); + GLfloat bias[1]; + glGetTexEnvfv( GL_TEXTURE_FILTER_CONTROL, GL_TEXTURE_LOD_BIAS, bias ); + glTexEnvf( GL_TEXTURE_FILTER_CONTROL, GL_TEXTURE_LOD_BIAS, progress * 2.75 ); + glBegin(GL_QUADS); + glTexCoord2f( 0.0, 0.0 ); + glVertex2f( 0.0, displayHeight() ); + glTexCoord2f( 1.0, 0.0 ); + glVertex2f( displayWidth(), displayHeight() ); + glTexCoord2f( 1.0, 1.0 ); + glVertex2f( displayWidth(), 0.0 ); + glTexCoord2f( 0.0, 1.0 ); + glVertex2f( 0.0, 0.0 ); + glEnd(); + glTexEnvf( GL_TEXTURE_FILTER_CONTROL, GL_TEXTURE_LOD_BIAS, bias[0] ); + blurTexture->unbind(); + + // Render the logout window + if( logout_window ) + { + int mask = PAINT_WINDOW_OPAQUE; // TODO: Can we have a translucent logout window? + QRect region = infiniteRegion(); + WindowPaintData data( logout_window ); + effects->drawWindow( logout_window, mask, region, data ); + } + } +#endif } void LogoutEffect::windowAdded( EffectWindow* w ) diff --git a/effects/logout/logout.h b/effects/logout/logout.h index 0179942568..d71b529806 100644 --- a/effects/logout/logout.h +++ b/effects/logout/logout.h @@ -3,6 +3,7 @@ This file is part of the KDE project. Copyright (C) 2007 Lubos Lunak +Copyright (C) 2009 Lucas Murray This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -27,13 +28,18 @@ along with this program. If not, see . namespace KWin { +class GLRenderTarget; +class GLTexture; + class LogoutEffect : public Effect { public: LogoutEffect(); + ~LogoutEffect(); virtual void prePaintScreen( ScreenPrePaintData& data, int time ); virtual void postPaintScreen(); + virtual void prePaintWindow( EffectWindow* w, WindowPrePaintData& data, int time ); virtual void paintWindow( EffectWindow* w, int mask, QRegion region, WindowPaintData& data ); virtual void windowAdded( EffectWindow* w ); virtual void windowClosed( EffectWindow* w ); @@ -41,6 +47,12 @@ class LogoutEffect bool isLogoutDialog( EffectWindow* w ); double progress; // 0-1 EffectWindow* logout_window; + +#ifdef KWIN_HAVE_OPENGL_COMPOSITING + bool blurSupported; + GLTexture* blurTexture; + GLRenderTarget* blurTarget; +#endif }; } // namespace From bcb561c83906c2a33815b46ff236b042e4433e95 Mon Sep 17 00:00:00 2001 From: Script Kiddy Date: Sun, 8 Feb 2009 14:11:41 +0000 Subject: [PATCH 45/60] SVN_SILENT made messages (.desktop file) svn path=/trunk/KDE/kdebase/workspace/; revision=923249 --- effects/cube/cubeslide.desktop | 6 ++++++ effects/cube/cubeslide_config.desktop | 3 +++ 2 files changed, 9 insertions(+) diff --git a/effects/cube/cubeslide.desktop b/effects/cube/cubeslide.desktop index 83dcedf2b3..db3838100e 100644 --- a/effects/cube/cubeslide.desktop +++ b/effects/cube/cubeslide.desktop @@ -1,7 +1,13 @@ [Desktop Entry] Name=Desktop Cube Animation +Name[pt_BR]=Animação do cubo da área de trabalho +Name[sv]=Animering med skrivbordskub +Name[uk]=Анімація куба стільниць Icon=preferences-system-windows-effect-cube Comment=Animate desktop switching with a cube +Comment[pt_BR]=Anima a alternação da área de trabalho com um cubo +Comment[sv]=Animera skrivbordsbyte med en kub +Comment[uk]=Створювати анімацію перемикання стільниць куба Type=Service X-KDE-ServiceTypes=KWin/Effect diff --git a/effects/cube/cubeslide_config.desktop b/effects/cube/cubeslide_config.desktop index 3720328ee5..becf737643 100644 --- a/effects/cube/cubeslide_config.desktop +++ b/effects/cube/cubeslide_config.desktop @@ -7,3 +7,6 @@ X-KDE-ParentComponents=kwin4_effect_cubeslide X-KDE-PluginKeyword=cubeslide Name=Desktop Cube Animation +Name[pt_BR]=Animação do cubo da área de trabalho +Name[sv]=Animering med skrivbordskub +Name[uk]=Анімація куба стільниць From 57f57adaa4231db9aab1b34cdc0ec29b423f59db Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Sun, 8 Feb 2009 15:47:37 +0000 Subject: [PATCH 46/60] Export method hasAlpha() from Toplevel to EffectWindow. svn path=/trunk/KDE/kdebase/workspace/; revision=923320 --- effects.cpp | 6 ++++++ effects.h | 1 + lib/kwineffects.h | 3 ++- 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/effects.cpp b/effects.cpp index 52dda8e9f5..2abbe5c8e8 100644 --- a/effects.cpp +++ b/effects.cpp @@ -1094,6 +1094,12 @@ double EffectWindowImpl::opacity() const return toplevel->opacity(); } +bool EffectWindowImpl::hasAlpha() const + { + return toplevel->hasAlpha(); + } + + bool EffectWindowImpl::isDeleted() const { return (dynamic_cast( toplevel ) != 0); diff --git a/effects.h b/effects.h index d4416b1a52..b54138ed52 100644 --- a/effects.h +++ b/effects.h @@ -195,6 +195,7 @@ class EffectWindowImpl : public EffectWindow virtual int desktop() const; // prefer isOnXXX() virtual bool isMinimized() const; virtual double opacity() const; + virtual bool hasAlpha() const; virtual QString caption() const; virtual QPixmap icon() const; virtual QString windowClass() const; diff --git a/lib/kwineffects.h b/lib/kwineffects.h index 89ccf1ec7b..d6da04389d 100644 --- a/lib/kwineffects.h +++ b/lib/kwineffects.h @@ -164,7 +164,7 @@ X-KDE-Library=kwin4_effect_cooleffect #define KWIN_EFFECT_API_MAKE_VERSION( major, minor ) (( major ) << 8 | ( minor )) #define KWIN_EFFECT_API_VERSION_MAJOR 0 -#define KWIN_EFFECT_API_VERSION_MINOR 59 +#define KWIN_EFFECT_API_VERSION_MINOR 60 #define KWIN_EFFECT_API_VERSION KWIN_EFFECT_API_MAKE_VERSION( \ KWIN_EFFECT_API_VERSION_MAJOR, KWIN_EFFECT_API_VERSION_MINOR ) @@ -718,6 +718,7 @@ class KWIN_EXPORT EffectWindow virtual bool isMinimized() const = 0; virtual double opacity() const = 0; + virtual bool hasAlpha() const = 0; virtual bool isOnDesktop( int d ) const; virtual bool isOnCurrentDesktop() const; From b11d8630333e6caf7e9125aad2d9c4b149acbb3d Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Sun, 8 Feb 2009 16:04:02 +0000 Subject: [PATCH 47/60] Cleaned up the logout effect and fixed a whole pile of bugs that I introduced when adding the blur animation. svn path=/trunk/KDE/kdebase/workspace/; revision=923329 --- effects/logout/logout.cpp | 111 +++++++++++++++++----------------- effects/logout/logout.desktop | 8 +-- effects/logout/logout.h | 8 ++- 3 files changed, 67 insertions(+), 60 deletions(-) diff --git a/effects/logout/logout.cpp b/effects/logout/logout.cpp index 6fe089b9db..5fc474a7c5 100644 --- a/effects/logout/logout.cpp +++ b/effects/logout/logout.cpp @@ -3,6 +3,7 @@ This file is part of the KDE project. Copyright (C) 2007 Lubos Lunak +Copyright (C) 2009 Martin Gräßlin Copyright (C) 2009 Lucas Murray This program is free software; you can redistribute it and/or modify @@ -31,8 +32,9 @@ namespace KWin KWIN_EFFECT( logout, LogoutEffect ) LogoutEffect::LogoutEffect() - : progress( 0 ) - , logout_window( NULL ) + : progress( 0.0 ) + , logoutWindow( NULL ) + , logoutWindowClosed( true ) { char net_wm_cm_name[ 100 ]; sprintf( net_wm_cm_name, "_NET_WM_CM_S%d", DefaultScreen( display())); @@ -44,26 +46,18 @@ LogoutEffect::LogoutEffect() #ifdef KWIN_HAVE_OPENGL_COMPOSITING blurSupported = false; + if( effects->compositingType() == OpenGLCompositing && GLTexture::NPOTTextureSupported() ) + { // TODO: It seems that it is not possible to create a GLRenderTarget that has + // a different size than the display right now. Most likely a KWin core bug. + // Create texture and render target + blurTexture = new GLTexture( displayWidth(), displayHeight() ); + blurTexture->setFilter( GL_LINEAR_MIPMAP_LINEAR ); + blurTexture->setWrapMode( GL_CLAMP_TO_EDGE ); - // If NPOT textures are not supported use the nearest power-of-two sized - // texture. It wastes memory, but it's possible to support systems without - // NPOT textures this way. - int texw = displayWidth(); - int texh = displayHeight(); - if( !GLTexture::NPOTTextureSupported() ) - { - kWarning( 1212 ) << "NPOT textures not supported, wasting some memory"; - texw = nearestPowerOfTwo( texw ); - texh = nearestPowerOfTwo( texh ); + blurTarget = new GLRenderTarget( blurTexture ); + if( blurTarget->valid() ) + blurSupported = true; } - // Create texture and render target - blurTexture = new GLTexture( texw, texh ); - blurTexture->setFilter( GL_LINEAR_MIPMAP_LINEAR ); - blurTexture->setWrapMode( GL_CLAMP_TO_EDGE ); - - blurTarget = new GLRenderTarget( blurTexture ); - if( blurTarget->valid() ) - blurSupported = true; #endif } @@ -77,10 +71,10 @@ LogoutEffect::~LogoutEffect() void LogoutEffect::prePaintScreen( ScreenPrePaintData& data, int time ) { - if( logout_window != NULL ) - progress = qBound( 0., progress + time / animationTime( 2000. ), 1. ); - else if( progress != 0 ) - progress = qBound( 0., progress - time / animationTime( 500. ), 1. ); + if( logoutWindow != NULL && !logoutWindowClosed ) + progress = qMin( 1.0, progress + time / animationTime( 2000.0 )); + else if( progress > 0.0 ) + progress = qMax( 0.0, progress - time / animationTime( 500.0 )); #ifdef KWIN_HAVE_OPENGL_COMPOSITING if( blurSupported && progress > 0.0 ) @@ -93,37 +87,32 @@ void LogoutEffect::prePaintScreen( ScreenPrePaintData& data, int time ) effects->prePaintScreen( data, time ); } -void LogoutEffect::prePaintWindow( EffectWindow* w, WindowPrePaintData& data, int time ) - { -#ifdef KWIN_HAVE_OPENGL_COMPOSITING - if( blurSupported && progress > 0.0 && w == logout_window ) - w->disablePainting( EffectWindow::PAINT_DISABLED ); -#endif - effects->prePaintWindow( w, data, time ); - } - void LogoutEffect::paintWindow( EffectWindow* w, int mask, QRegion region, WindowPaintData& data ) { - if( w != logout_window && progress != 0 ) + if( progress > 0.0 ) { - if( effects->saturationSupported() ) + if( w == logoutWindow ) { - data.saturation *= ( 1 - progress * 0.8 ); - data.brightness *= ( 1 - progress * 0.3 ); + windowOpacity = data.opacity; + data.opacity = 0.0; // Cheat, we need the opacity for later but don't want to blur it } - else // When saturation isn't supported then reduce brightness a bit more - { - data.brightness *= ( 1 - progress * 0.6 ); + else + { + if( effects->saturationSupported() ) + { + data.saturation *= ( 1.0 - progress * 0.8 ); + data.brightness *= ( 1.0 - progress * 0.3 ); + } + else // When saturation isn't supported then reduce brightness a bit more + data.brightness *= ( 1.0 - progress * 0.6 ); } } effects->paintWindow( w, mask, region, data ); } -void LogoutEffect::postPaintScreen() +void LogoutEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) { - if( progress != 0 && progress != 1 ) - effects->addRepaintFull(); - effects->postPaintScreen(); + effects->paintScreen( mask, region, data ); #ifdef KWIN_HAVE_OPENGL_COMPOSITING if( blurSupported && progress > 0.0 ) @@ -135,7 +124,7 @@ void LogoutEffect::postPaintScreen() GLfloat bias[1]; glGetTexEnvfv( GL_TEXTURE_FILTER_CONTROL, GL_TEXTURE_LOD_BIAS, bias ); glTexEnvf( GL_TEXTURE_FILTER_CONTROL, GL_TEXTURE_LOD_BIAS, progress * 2.75 ); - glBegin(GL_QUADS); + glBegin( GL_QUADS ); glTexCoord2f( 0.0, 0.0 ); glVertex2f( 0.0, displayHeight() ); glTexCoord2f( 1.0, 0.0 ); @@ -149,36 +138,50 @@ void LogoutEffect::postPaintScreen() blurTexture->unbind(); // Render the logout window - if( logout_window ) + if( logoutWindow ) { - int mask = PAINT_WINDOW_OPAQUE; // TODO: Can we have a translucent logout window? - QRect region = infiniteRegion(); - WindowPaintData data( logout_window ); - effects->drawWindow( logout_window, mask, region, data ); + int winMask = logoutWindow->hasAlpha() ? PAINT_WINDOW_TRANSLUCENT : PAINT_WINDOW_OPAQUE; + WindowPaintData winData( logoutWindow ); + winData.opacity = windowOpacity; + effects->drawWindow( logoutWindow, winMask, region, winData ); } } #endif } +void LogoutEffect::postPaintScreen() + { + if( progress != 0.0 && progress != 1.0 ) + effects->addRepaintFull(); + effects->postPaintScreen(); + } + void LogoutEffect::windowAdded( EffectWindow* w ) { if( isLogoutDialog( w )) { - logout_window = w; - progress = 0; + logoutWindow = w; + logoutWindowClosed = false; // So we don't blur the window on close + progress = 0.0; effects->addRepaintFull(); } } void LogoutEffect::windowClosed( EffectWindow* w ) { - if( w == logout_window ) + if( w == logoutWindow ) { - logout_window = NULL; + logoutWindowClosed = true; effects->addRepaintFull(); } } +void LogoutEffect::windowDeleted( EffectWindow* w ) + { + if( w == logoutWindow ) + logoutWindow = NULL; + } + bool LogoutEffect::isLogoutDialog( EffectWindow* w ) { // TODO there should be probably a better way (window type?) if( w->windowClass() == "ksmserver ksmserver" diff --git a/effects/logout/logout.desktop b/effects/logout/logout.desktop index 7162d837e4..077be0aa0b 100644 --- a/effects/logout/logout.desktop +++ b/effects/logout/logout.desktop @@ -122,13 +122,13 @@ Comment[zh_TW]=顯示登出視窗時將桌面淡化 Type=Service X-KDE-ServiceTypes=KWin/Effect -X-KDE-PluginInfo-Author=Lubos Lunak -X-KDE-PluginInfo-Email=l.lunak@kde.org +X-KDE-PluginInfo-Author=Lubos Lunak & Lucas Murray +X-KDE-PluginInfo-Email=l.lunak@kde.org & lmurray@undefinedfire.com X-KDE-PluginInfo-Name=kwin4_effect_logout -X-KDE-PluginInfo-Version=0.1.0 +X-KDE-PluginInfo-Version=0.2.0 X-KDE-PluginInfo-Category=Appearance X-KDE-PluginInfo-Depends= X-KDE-PluginInfo-License=GPL X-KDE-PluginInfo-EnabledByDefault=true X-KDE-Library=kwin4_effect_builtins -X-KDE-Ordering=40 +X-KDE-Ordering=85 diff --git a/effects/logout/logout.h b/effects/logout/logout.h index d71b529806..2c5700bc4c 100644 --- a/effects/logout/logout.h +++ b/effects/logout/logout.h @@ -3,6 +3,7 @@ This file is part of the KDE project. Copyright (C) 2007 Lubos Lunak +Copyright (C) 2009 Martin Gräßlin Copyright (C) 2009 Lucas Murray This program is free software; you can redistribute it and/or modify @@ -38,20 +39,23 @@ class LogoutEffect LogoutEffect(); ~LogoutEffect(); virtual void prePaintScreen( ScreenPrePaintData& data, int time ); + virtual void paintScreen( int mask, QRegion region, ScreenPaintData& data ); virtual void postPaintScreen(); - virtual void prePaintWindow( EffectWindow* w, WindowPrePaintData& data, int time ); virtual void paintWindow( EffectWindow* w, int mask, QRegion region, WindowPaintData& data ); virtual void windowAdded( EffectWindow* w ); virtual void windowClosed( EffectWindow* w ); + virtual void windowDeleted( EffectWindow* w ); private: bool isLogoutDialog( EffectWindow* w ); double progress; // 0-1 - EffectWindow* logout_window; + EffectWindow* logoutWindow; + bool logoutWindowClosed; #ifdef KWIN_HAVE_OPENGL_COMPOSITING bool blurSupported; GLTexture* blurTexture; GLRenderTarget* blurTarget; + double windowOpacity; #endif }; From 298586b6ee2434dcbaf5a5dbc75a8b605d7dc516 Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Sun, 8 Feb 2009 17:27:50 +0000 Subject: [PATCH 48/60] configure in the right config group ... svn path=/trunk/KDE/kdebase/workspace/; revision=923375 --- clients/kde2/config/config.cpp | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/clients/kde2/config/config.cpp b/clients/kde2/config/config.cpp index 011d524d0a..83ecc02501 100644 --- a/clients/kde2/config/config.cpp +++ b/clients/kde2/config/config.cpp @@ -45,9 +45,10 @@ extern "C" // Configure tab in kwindecoration KDE2Config::KDE2Config( KConfig* conf, QWidget* parent ) - : QObject( parent ), c(conf) + : QObject( parent ) { KGlobal::locale()->insertCatalog("kwin_clients"); + c = new KConfig("kwinKDE2rc"); highcolor = QPixmap::defaultDepth() > 8; gb = new KVBox( parent ); gb->setSpacing( KDialog::spacingHint() ); @@ -72,11 +73,6 @@ KDE2Config::KDE2Config( KConfig* conf, QWidget* parent ) "for high-color displays; otherwise, no gradients are drawn.") ); } - // Load configuration options - c = new KConfig("kwinKDE2rc"); - KConfigGroup cg(c, "General"); - load( cg ); - // Ensure we track user changes properly connect( cbShowStipple, SIGNAL(clicked()), this, SLOT(slotSelectionChanged()) ); @@ -86,6 +82,9 @@ KDE2Config::KDE2Config( KConfig* conf, QWidget* parent ) connect( cbUseGradients, SIGNAL(clicked()), this, SLOT(slotSelectionChanged()) ); + // Load configuration options + load( KConfigGroup() ); + // Make the widgets visible in kwindecoration gb->show(); } @@ -94,6 +93,7 @@ KDE2Config::KDE2Config( KConfig* conf, QWidget* parent ) KDE2Config::~KDE2Config() { delete gb; + delete c; } @@ -107,7 +107,7 @@ void KDE2Config::slotSelectionChanged() // It is passed the open config from kwindecoration to improve efficiency void KDE2Config::load( const KConfigGroup& ) { - KConfigGroup cg(c, "KDE2"); + KConfigGroup cg(c, "General"); bool override = cg.readEntry( "ShowTitleBarStipple", true); cbShowStipple->setChecked( override ); @@ -124,7 +124,7 @@ void KDE2Config::load( const KConfigGroup& ) // Saves the configurable options to the kwinrc config file void KDE2Config::save( KConfigGroup& ) { - KConfigGroup cg(c, "KDE2"); + KConfigGroup cg(c, "General"); cg.writeEntry( "ShowTitleBarStipple", cbShowStipple->isChecked() ); cg.writeEntry( "ShowGrabBar", cbShowGrabBar->isChecked() ); From 56f36bec7f354e33aba5d859bae22f81d1065eed Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Mon, 9 Feb 2009 12:37:59 +0000 Subject: [PATCH 49/60] Deactivate window highlight immediately after the window is closed or if the X window property is deleted. svn path=/trunk/KDE/kdebase/workspace/; revision=923779 --- effects/highlightwindow/highlightwindow.cpp | 15 +++++++++++---- effects/highlightwindow/highlightwindow.h | 1 + 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/effects/highlightwindow/highlightwindow.cpp b/effects/highlightwindow/highlightwindow.cpp index 9a23599832..d535227bc3 100644 --- a/effects/highlightwindow/highlightwindow.cpp +++ b/effects/highlightwindow/highlightwindow.cpp @@ -99,11 +99,15 @@ void HighlightWindowEffect::windowAdded( EffectWindow* w ) propertyNotify( w, m_atom ); // Check initial value } +void HighlightWindowEffect::windowClosed( EffectWindow* w ) + { + if( m_monitorWindow == w ) // The monitoring window was destroyed + finishHighlighting(); + } + void HighlightWindowEffect::windowDeleted( EffectWindow* w ) { m_windowOpacity.remove( w ); - if( m_monitorWindow == w ) // The monitoring window was destroyed - finishHighlighting(); } void HighlightWindowEffect::propertyNotify( EffectWindow* w, long a ) @@ -113,11 +117,14 @@ void HighlightWindowEffect::propertyNotify( EffectWindow* w, long a ) QByteArray byteData = w->readProperty( m_atom, m_atom, 32 ); if( byteData.length() < 1 ) - return; // Invalid length + { // Property was removed, clearing highlight + finishHighlighting(); + return; + } long* data = reinterpret_cast( byteData.data() ); if( !data[0] ) - { // Purposely clearing highlight + { // Purposely clearing highlight by issuing a NULL target finishHighlighting(); return; } diff --git a/effects/highlightwindow/highlightwindow.h b/effects/highlightwindow/highlightwindow.h index c7982210f6..8ad853a794 100644 --- a/effects/highlightwindow/highlightwindow.h +++ b/effects/highlightwindow/highlightwindow.h @@ -37,6 +37,7 @@ class HighlightWindowEffect virtual void paintWindow( EffectWindow* w, int mask, QRegion region, WindowPaintData& data ); virtual void windowAdded( EffectWindow* w ); + virtual void windowClosed( EffectWindow* w ); virtual void windowDeleted( EffectWindow* w ); virtual void propertyNotify( EffectWindow* w, long atom ); From 657288d7b6af87009d8313b776635091840473e2 Mon Sep 17 00:00:00 2001 From: Script Kiddy Date: Mon, 9 Feb 2009 13:37:07 +0000 Subject: [PATCH 50/60] SVN_SILENT made messages (.desktop file) svn path=/trunk/KDE/kdebase/workspace/; revision=923793 --- effects/cube/cubeslide.desktop | 2 ++ effects/cube/cubeslide_config.desktop | 1 + 2 files changed, 3 insertions(+) diff --git a/effects/cube/cubeslide.desktop b/effects/cube/cubeslide.desktop index db3838100e..3f4709c6db 100644 --- a/effects/cube/cubeslide.desktop +++ b/effects/cube/cubeslide.desktop @@ -1,10 +1,12 @@ [Desktop Entry] Name=Desktop Cube Animation +Name[pt]=Animação do Cubo de Ecrãs Name[pt_BR]=Animação do cubo da área de trabalho Name[sv]=Animering med skrivbordskub Name[uk]=Анімація куба стільниць Icon=preferences-system-windows-effect-cube Comment=Animate desktop switching with a cube +Comment[pt]=Animar a mudança de ecrãs com um cubo Comment[pt_BR]=Anima a alternação da área de trabalho com um cubo Comment[sv]=Animera skrivbordsbyte med en kub Comment[uk]=Створювати анімацію перемикання стільниць куба diff --git a/effects/cube/cubeslide_config.desktop b/effects/cube/cubeslide_config.desktop index becf737643..8ad7e547e1 100644 --- a/effects/cube/cubeslide_config.desktop +++ b/effects/cube/cubeslide_config.desktop @@ -7,6 +7,7 @@ X-KDE-ParentComponents=kwin4_effect_cubeslide X-KDE-PluginKeyword=cubeslide Name=Desktop Cube Animation +Name[pt]=Animação do Cubo de Ecrãs Name[pt_BR]=Animação do cubo da área de trabalho Name[sv]=Animering med skrivbordskub Name[uk]=Анімація куба стільниць From 4d82d2291e72c346d48585a59c7ba7612f7c53c2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lubo=C5=A1=20Lu=C5=88=C3=A1k?= Date: Mon, 9 Feb 2009 14:31:42 +0000 Subject: [PATCH 51/60] Don't needlessly setup compositing twice during startup. Xrandr seems to like to send events about "changes" right after application startup. svn path=/trunk/KDE/kdebase/workspace/; revision=923829 --- composite.cpp | 6 ++---- events.cpp | 12 +++++++++--- workspace.cpp | 1 + workspace.h | 1 + 4 files changed, 13 insertions(+), 7 deletions(-) diff --git a/composite.cpp b/composite.cpp index 36a3b3fe76..9aaeb60e66 100644 --- a/composite.cpp +++ b/composite.cpp @@ -175,10 +175,8 @@ void Workspace::setupCompositing() { // autoconfigure refresh rate based on XRandR info if( Extensions::randrAvailable() ) { - XRRScreenConfiguration *config; - - config = XRRGetScreenInfo( display(), rootWindow() ); - rate = XRRConfigCurrentRate( config ); + XRRScreenConfiguration *config = XRRGetScreenInfo( display(), rootWindow() ); + rate = xrrRefreshRate = XRRConfigCurrentRate( config ); XRRFreeScreenConfigInfo( config ); } } diff --git a/events.cpp b/events.cpp index a8764df70d..c8e99288a7 100644 --- a/events.cpp +++ b/events.cpp @@ -501,15 +501,21 @@ bool Workspace::workspaceEvent( XEvent * e ) { #ifdef HAVE_XRANDR XRRUpdateConfiguration( e ); -#endif if( compositing() ) { // desktopResized() should take care of when the size or // shape of the desktop has changed, but we also want to // catch refresh rate changes - finishCompositing(); - QTimer::singleShot( 0, this, SLOT( setupCompositing() ) ); + XRRScreenConfiguration *config = XRRGetScreenInfo( display(), rootWindow() ); + bool changed = ( xrrRefreshRate != XRRConfigCurrentRate( config )); + XRRFreeScreenConfigInfo( config ); + if( changed ) + { + finishCompositing(); + QTimer::singleShot( 0, this, SLOT( setupCompositing() ) ); + } } +#endif } else if( e->type == Extensions::syncAlarmNotifyEvent() && Extensions::syncAvailable()) { diff --git a/workspace.cpp b/workspace.cpp index 132dcd2828..b40cddab5d 100644 --- a/workspace.cpp +++ b/workspace.cpp @@ -139,6 +139,7 @@ Workspace::Workspace( bool restore ) , cm_selection( NULL ) , compositingSuspended( false ) , compositeRate( 0 ) + , xrrRefreshRate( 0 ) , overlay( None ) , overlay_visible( true ) , overlay_shown( false ) diff --git a/workspace.h b/workspace.h index a798b00777..396b92a1c0 100644 --- a/workspace.h +++ b/workspace.h @@ -774,6 +774,7 @@ class Workspace : public QObject, public KDecorationDefines QTime nextPaintReference; QTimer mousePollingTimer; int compositeRate; + int xrrRefreshRate; // used only for compositing QRegion repaints_region; Window overlay; // XComposite overlay window bool overlay_visible; From 1bc2f456d9b074447272158063eb66e7e795ad32 Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Mon, 9 Feb 2009 14:36:47 +0000 Subject: [PATCH 52/60] Prevent dim inactive from crashing whenever the previous active window is closed. svn path=/trunk/KDE/kdebase/workspace/; revision=923835 --- effects/diminactive/diminactive.cpp | 6 ++++++ effects/diminactive/diminactive.h | 1 + 2 files changed, 7 insertions(+) diff --git a/effects/diminactive/diminactive.cpp b/effects/diminactive/diminactive.cpp index 9cfe990978..2e5b6f8375 100644 --- a/effects/diminactive/diminactive.cpp +++ b/effects/diminactive/diminactive.cpp @@ -97,6 +97,12 @@ bool DimInactiveEffect::dimWindow( const EffectWindow* w ) const return true; // dim the rest } +void DimInactiveEffect::windowDeleted( EffectWindow* w ) + { + if( w == previousActive ) + previousActive = NULL; + } + void DimInactiveEffect::windowActivated( EffectWindow* w ) { if( active != NULL ) diff --git a/effects/diminactive/diminactive.h b/effects/diminactive/diminactive.h index 9111254c38..ff3915c451 100644 --- a/effects/diminactive/diminactive.h +++ b/effects/diminactive/diminactive.h @@ -37,6 +37,7 @@ class DimInactiveEffect virtual void reconfigure( ReconfigureFlags ); virtual void prePaintScreen( ScreenPrePaintData& data, int time ); virtual void paintWindow( EffectWindow* w, int mask, QRegion region, WindowPaintData& data ); + virtual void windowDeleted( EffectWindow* w ); virtual void windowActivated( EffectWindow* c ); private: bool dimWindow( const EffectWindow* w ) const; From b50a8d352a50a2a5ec5890d0c7e811db78fc6619 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lubo=C5=A1=20Lu=C5=88=C3=A1k?= Date: Mon, 9 Feb 2009 14:37:07 +0000 Subject: [PATCH 53/60] Compress possible several reasons for resetting compositing. svn path=/trunk/KDE/kdebase/workspace/; revision=923836 --- events.cpp | 5 +---- geometry.cpp | 5 +---- workspace.cpp | 2 ++ workspace.h | 1 + 4 files changed, 5 insertions(+), 8 deletions(-) diff --git a/events.cpp b/events.cpp index c8e99288a7..d419dbc684 100644 --- a/events.cpp +++ b/events.cpp @@ -510,10 +510,7 @@ bool Workspace::workspaceEvent( XEvent * e ) bool changed = ( xrrRefreshRate != XRRConfigCurrentRate( config )); XRRFreeScreenConfigInfo( config ); if( changed ) - { - finishCompositing(); - QTimer::singleShot( 0, this, SLOT( setupCompositing() ) ); - } + compositeResetTimer.start( 0 ); } #endif } diff --git a/geometry.cpp b/geometry.cpp index 6c8b554876..ad5ac12a58 100644 --- a/geometry.cpp +++ b/geometry.cpp @@ -65,10 +65,7 @@ void Workspace::desktopResized() destroyElectricBorders(); updateElectricBorders(); if( compositing() ) - { - finishCompositing(); - QTimer::singleShot( 0, this, SLOT( setupCompositing() ) ); - } + compositeResetTimer.start( 0 ); } /*! diff --git a/workspace.cpp b/workspace.cpp index b40cddab5d..1ec5ca2eff 100644 --- a/workspace.cpp +++ b/workspace.cpp @@ -172,7 +172,9 @@ Workspace::Workspace( bool restore ) this, SLOT( gotTemporaryRulesMessage(const QString&) )); connect( &rulesUpdatedTimer, SIGNAL( timeout() ), this, SLOT( writeWindowRules() )); connect( &unredirectTimer, SIGNAL( timeout() ), this, SLOT( delayedCheckUnredirect() )); + connect( &compositeResetTimer, SIGNAL( timeout()), this, SLOT( resetCompositing())); unredirectTimer.setSingleShot( true ); + compositeResetTimer.setSingleShot( true ); updateXTime(); // Needed for proper initialization of user_time in Client ctor diff --git a/workspace.h b/workspace.h index 396b92a1c0..d6c474eb30 100644 --- a/workspace.h +++ b/workspace.h @@ -785,6 +785,7 @@ class Workspace : public QObject, public KDecorationDefines QTimer unredirectTimer; bool forceUnredirectCheck; QList< int > composite_paint_times; + QTimer compositeResetTimer; // for compressing composite resets private: friend bool performTransiencyCheck(); From 14a5fb8026137d26698eb151bcb2f9d2ef1149f4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lubo=C5=A1=20Lu=C5=88=C3=A1k?= Date: Mon, 9 Feb 2009 14:39:52 +0000 Subject: [PATCH 54/60] Try to have initting set during Workspace setup again, will be also needed for the following commit. If there will be any problems during KWin startup because of this please yell. svn path=/trunk/KDE/kdebase/workspace/; revision=923838 --- main.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main.cpp b/main.cpp index 9833345429..b9db78f700 100644 --- a/main.cpp +++ b/main.cpp @@ -311,7 +311,7 @@ Application::Application() atoms = new Atoms; - initting = false; // TODO +// initting = false; // TODO // This tries to detect compositing options and can use GLX. GLX problems // (X errors) shouldn't cause kwin to abort, so this is out of the From 7249ca2cfb8d86d6b4c8781f740fcb69d9e18812 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lubo=C5=A1=20Lu=C5=88=C3=A1k?= Date: Mon, 9 Feb 2009 14:51:11 +0000 Subject: [PATCH 55/60] Do self-check immediatelly during compositing setup only when it's not KWin startup at the same time (in other words, only when activating compositing using the kcm). Currently selfcheck causes bad flicker (due to X mapping the overlay window for too long?) which looks bad during KDE startup. With this patch, KDE startup is without any flicker. svn path=/trunk/KDE/kdebase/workspace/; revision=923842 --- main.cpp | 4 +-- scene.cpp | 13 ++++++-- scene.h | 17 ++++++++++ scene_opengl.cpp | 81 +++++++++++++++++++++++++++++++++-------------- scene_opengl.h | 3 ++ scene_xrender.cpp | 72 ++++++++++++++++++++++++++++------------- scene_xrender.h | 2 ++ utils.h | 1 + workspace.h | 2 +- 9 files changed, 144 insertions(+), 51 deletions(-) diff --git a/main.cpp b/main.cpp index b9db78f700..7b70502a56 100644 --- a/main.cpp +++ b/main.cpp @@ -68,7 +68,7 @@ Atoms* atoms; int screen_number = -1; -static bool initting = false; +bool initting = false; /** * Whether to run Xlib in synchronous mode and print backtraces for X errors. @@ -180,7 +180,7 @@ static int x11ErrorHandler( Display* d, XErrorEvent* e ) fprintf( stderr, "kwin: X Error (%s)\n", errorMessage( *e, d ).data() ); if( kwin_sync ) - fprintf( stderr, "%s\n", kBacktrace().toLocal8Bit().data() ); + fprintf( stderr, "%s\n", kBacktrace().toLocal8Bit().data() ); if( initting ) { diff --git a/scene.cpp b/scene.cpp index 3acf357b99..6642ea7530 100644 --- a/scene.cpp +++ b/scene.cpp @@ -89,8 +89,9 @@ namespace KWin Scene* scene; Scene::Scene( Workspace* ws ) - : wspace( ws ), - has_waitSync( false ) + : wspace( ws ) + , has_waitSync( false ) + , selfCheckDone( false ) { } @@ -337,6 +338,14 @@ QList< QPoint > Scene::selfCheckPoints() const return ret; } +QRegion Scene::selfCheckRegion() const + { + QRegion reg; + foreach( const QPoint& p, selfCheckPoints()) + reg |= QRect( p, QSize( selfCheckWidth(), selfCheckHeight())); + return reg; + } + //**************************************** // Scene::Window //**************************************** diff --git a/scene.h b/scene.h index 680e3433a8..8c326f2ea7 100644 --- a/scene.h +++ b/scene.h @@ -108,6 +108,10 @@ class Scene // compute time since the last repaint void updateTimeDiff(); QList< QPoint > selfCheckPoints() const; + QRegion selfCheckRegion() const; + // dimensions of the test pixmap for selfcheck + int selfCheckWidth() const; + int selfCheckHeight() const; // saved data for 2nd pass of optimized screen painting struct Phase2Data { @@ -133,6 +137,7 @@ class Scene QTime last_time; Workspace* wspace; bool has_waitSync; + bool selfCheckDone; }; // The base class for windows representations in composite backends @@ -198,6 +203,18 @@ class Scene::Window extern Scene* scene; +inline +int Scene::selfCheckWidth() const + { + return 3; + } + +inline +int Scene::selfCheckHeight() const + { + return 2; + } + inline int Scene::Window::x() const { diff --git a/scene_opengl.cpp b/scene_opengl.cpp index 6fb8f9cf65..4b34a1b69d 100644 --- a/scene_opengl.cpp +++ b/scene_opengl.cpp @@ -183,8 +183,16 @@ SceneOpenGL::SceneOpenGL( Workspace* ws ) kError( 1212 ) << "OpenGL compositing setup failed"; return; // error } - if( !selfCheck()) - return; + // Do self-check immediatelly during compositing setup only when it's not KWin startup + // at the same time (in other words, only when activating compositing using the kcm). + // Currently selfcheck causes bad flicker (due to X mapping the overlay window + // for too long?) which looks bad during KDE startup. + if( !initting ) + { + if( !selfCheck()) + return; + selfCheckDone = true; + } kDebug( 1212 ) << "DB:" << db << ", TFP:" << tfp_mode << ", SHM:" << shm_mode << ", Direct:" << bool( glXIsDirect( display(), ctxbuffer )) << endl; init_ok = true; @@ -624,10 +632,28 @@ bool SceneOpenGL::initDrawableConfigs() // Test if compositing actually _really_ works, by creating a texture from a testing // window, drawing it on the screen, reading the contents back and comparing. This // should test whether compositing really works. -// It would be still nice to check somehow if compositing is not awfully slow. +// This function does the whole selfcheck, it can be done also in two parts +// during actual drawing (to avoid flicker, see selfCheck() call from the ctor). bool SceneOpenGL::selfCheck() { - QImage img( 3, 2, QImage::Format_RGB32 ); + QRegion reg = selfCheckRegion(); + if( wspace->overlayWindow()) + { // avoid covering the whole screen too soon + wspace->setOverlayShape( reg ); + wspace->showOverlay(); + } + selfCheckSetup(); + flushBuffer( PAINT_SCREEN_REGION, reg ); + bool ok = selfCheckFinish(); + if( wspace->overlayWindow()) + wspace->hideOverlay(); + return ok; + } + +void SceneOpenGL::selfCheckSetup() + { + KXErrorHandler err; + QImage img( selfCheckWidth(), selfCheckHeight(), QImage::Format_RGB32 ); img.setPixel( 0, 0, QColor( Qt::red ).rgb()); img.setPixel( 1, 0, QColor( Qt::green ).rgb()); img.setPixel( 2, 0, QColor( Qt::blue ).rgb()); @@ -635,46 +661,42 @@ bool SceneOpenGL::selfCheck() img.setPixel( 1, 1, QColor( Qt::black ).rgb()); img.setPixel( 2, 1, QColor( Qt::white ).rgb()); QPixmap pix = QPixmap::fromImage( img ); - QList< QPoint > points = selfCheckPoints(); - QRegion reg; - foreach( const QPoint& p, points ) - reg |= QRect( p, pix.size()); - if( wspace->overlayWindow()) - { // avoid covering the whole screen too soon - wspace->setOverlayShape( reg ); - wspace->showOverlay(); - } - foreach( const QPoint& p, points ) + foreach( const QPoint& p, selfCheckPoints()) { XSetWindowAttributes wa; wa.override_redirect = True; - ::Window window = XCreateWindow( display(), rootWindow(), 0, 0, 3, 2, 0, QX11Info::appDepth(), - CopyFromParent, CopyFromParent, CWOverrideRedirect, &wa ); + ::Window window = XCreateWindow( display(), rootWindow(), 0, 0, selfCheckWidth(), selfCheckHeight(), + 0, QX11Info::appDepth(), CopyFromParent, CopyFromParent, CWOverrideRedirect, &wa ); XSetWindowBackgroundPixmap( display(), window, pix.handle()); XClearWindow( display(), window ); XMapWindow( display(), window ); // move the window one down to where the result will be rendered too, just in case // the render would fail completely and eventual check would try to read this window's contents XMoveWindow( display(), window, p.x() + 1, p.y()); - XCompositeRedirectWindow( display(), window, CompositeRedirectManual ); + XCompositeRedirectWindow( display(), window, CompositeRedirectAutomatic ); Pixmap wpix = XCompositeNameWindowPixmap( display(), window ); glXWaitX(); Texture texture; - texture.load( wpix, QSize( 3, 2 ), QX11Info::appDepth()); + texture.load( wpix, QSize( selfCheckWidth(), selfCheckHeight()), QX11Info::appDepth()); texture.bind(); - QRect rect( p.x(), p.y(), 3, 2 ); + QRect rect( p.x(), p.y(), selfCheckWidth(), selfCheckHeight()); texture.render( infiniteRegion(), rect ); texture.unbind(); glXWaitGL(); XFreePixmap( display(), wpix ); XDestroyWindow( display(), window ); } - flushBuffer( PAINT_SCREEN_REGION, reg ); + err.error( true ); // just sync and discard + } + +bool SceneOpenGL::selfCheckFinish() + { glXWaitGL(); + KXErrorHandler err; bool ok = true; - foreach( const QPoint& p, points ) + foreach( const QPoint& p, selfCheckPoints()) { - QPixmap pix = QPixmap::grabWindow( rootWindow(), p.x(), p.y(), 3, 2 ); + QPixmap pix = QPixmap::grabWindow( rootWindow(), p.x(), p.y(), selfCheckWidth(), selfCheckHeight()); QImage img = pix.toImage(); // kDebug(1212) << "P:" << QColor( img.pixel( 0, 0 )).name(); // kDebug(1212) << "P:" << QColor( img.pixel( 1, 0 )).name(); @@ -694,8 +716,8 @@ bool SceneOpenGL::selfCheck() break; } } - if( wspace->overlayWindow()) - wspace->hideOverlay(); + if( err.error( true )) + ok = false; if( ok ) kDebug( 1212 ) << "Compositing self-check passed."; if( !ok && options->disableCompositingChecks ) @@ -729,7 +751,18 @@ void SceneOpenGL::paint( QRegion damage, ToplevelList toplevels ) ungrabXServer(); // ungrab before flushBuffer(), it may wait for vsync if( wspace->overlayWindow()) // show the window only after the first pass, since wspace->showOverlay(); // that pass may take long + if( !selfCheckDone ) + { + selfCheckSetup(); + damage |= selfCheckRegion(); + } flushBuffer( mask, damage ); + if( !selfCheckDone ) + { + if( !selfCheckFinish()) + QTimer::singleShot( 0, Workspace::self(), SLOT( finishCompositing())); + selfCheckDone = true; + } // do cleanup stacking_order.clear(); checkGLError( "PostPaint" ); diff --git a/scene_opengl.h b/scene_opengl.h index 6be75c6ea6..3e7c636b64 100644 --- a/scene_opengl.h +++ b/scene_opengl.h @@ -65,6 +65,8 @@ class SceneOpenGL void waitSync(); void flushBuffer( int mask, QRegion damage ); bool selfCheck(); + void selfCheckSetup(); + bool selfCheckFinish(); GC gcroot; class FBConfigInfo { @@ -91,6 +93,7 @@ class SceneOpenGL static XShmSegmentInfo shm; #endif bool init_ok; + bool selfCheckDone; }; class SceneOpenGL::Texture diff --git a/scene_xrender.cpp b/scene_xrender.cpp index 33b827de13..35a7e5ffc5 100644 --- a/scene_xrender.cpp +++ b/scene_xrender.cpp @@ -131,8 +131,12 @@ SceneXrender::SceneXrender( Workspace* ws ) kError( 1212 ) << "XRender compositing setup failed"; return; } - if( !selfCheck()) - return; + if( !initting ) // see comment for opengl version + { + if( !selfCheck()) + return; + selfCheckDone = true; + } init_ok = true; } @@ -169,7 +173,24 @@ void SceneXrender::createBuffer() // Just like SceneOpenGL::selfCheck() bool SceneXrender::selfCheck() { - QImage img( 3, 2, QImage::Format_RGB32 ); + QRegion reg = selfCheckRegion(); + if( wspace->overlayWindow()) + { // avoid covering the whole screen too soon + wspace->setOverlayShape( reg ); + wspace->showOverlay(); + } + selfCheckSetup(); + flushBuffer( PAINT_SCREEN_REGION, reg ); + bool ok = selfCheckFinish(); + if( wspace->overlayWindow()) + wspace->hideOverlay(); + return ok; + } + +void SceneXrender::selfCheckSetup() + { + KXErrorHandler err; + QImage img( selfCheckWidth(), selfCheckHeight(), QImage::Format_RGB32 ); img.setPixel( 0, 0, QColor( Qt::red ).rgb()); img.setPixel( 1, 0, QColor( Qt::green ).rgb()); img.setPixel( 2, 0, QColor( Qt::blue ).rgb()); @@ -177,44 +198,40 @@ bool SceneXrender::selfCheck() img.setPixel( 1, 1, QColor( Qt::black ).rgb()); img.setPixel( 2, 1, QColor( Qt::white ).rgb()); QPixmap pix = QPixmap::fromImage( img ); - QList< QPoint > points = selfCheckPoints(); - QRegion reg; - foreach( const QPoint& p, points ) - reg |= QRect( p, pix.size()); - if( wspace->overlayWindow()) - { // avoid covering the whole screen too soon - wspace->setOverlayShape( reg ); - wspace->showOverlay(); - } - foreach( const QPoint& p, points ) + foreach( const QPoint& p, selfCheckPoints()) { XSetWindowAttributes wa; wa.override_redirect = True; - ::Window window = XCreateWindow( display(), rootWindow(), 0, 0, 3, 2, 0, QX11Info::appDepth(), - CopyFromParent, CopyFromParent, CWOverrideRedirect, &wa ); + ::Window window = XCreateWindow( display(), rootWindow(), 0, 0, selfCheckWidth(), selfCheckHeight(), + 0, QX11Info::appDepth(), CopyFromParent, CopyFromParent, CWOverrideRedirect, &wa ); XSetWindowBackgroundPixmap( display(), window, pix.handle()); XClearWindow( display(), window ); XMapWindow( display(), window ); // move the window one down to where the result will be rendered too, just in case // the render would fail completely and eventual check would try to read this window's contents XMoveWindow( display(), window, p.x() + 1, p.y()); - XCompositeRedirectWindow( display(), window, CompositeRedirectManual ); + XCompositeRedirectWindow( display(), window, CompositeRedirectAutomatic ); Pixmap wpix = XCompositeNameWindowPixmap( display(), window ); XWindowAttributes attrs; XGetWindowAttributes( display(), window, &attrs ); XRenderPictFormat* format = XRenderFindVisualFormat( display(), attrs.visual ); Picture pic = XRenderCreatePicture( display(), wpix, format, 0, 0 ); - QRect rect( p.x(), p.y(), 3, 2 ); + QRect rect( p.x(), p.y(), selfCheckWidth(), selfCheckHeight()); XRenderComposite( display(), PictOpSrc, pic, None, buffer, 0, 0, 0, 0, rect.x(), rect.y(), rect.width(), rect.height()); XFreePixmap( display(), wpix ); XDestroyWindow( display(), window ); } - flushBuffer( PAINT_SCREEN_REGION, reg ); + err.error( true ); // just sync and discard + } + +bool SceneXrender::selfCheckFinish() + { + KXErrorHandler err; bool ok = true; - foreach( const QPoint& p, points ) + foreach( const QPoint& p, selfCheckPoints()) { - QPixmap pix = QPixmap::grabWindow( rootWindow(), p.x(), p.y(), 3, 2 ); + QPixmap pix = QPixmap::grabWindow( rootWindow(), p.x(), p.y(), selfCheckWidth(), selfCheckHeight()); QImage img = pix.toImage(); // kDebug(1212) << "P:" << QColor( img.pixel( 0, 0 )).name(); // kDebug(1212) << "P:" << QColor( img.pixel( 1, 0 )).name(); @@ -234,8 +251,8 @@ bool SceneXrender::selfCheck() break; } } - if( wspace->overlayWindow()) - wspace->hideOverlay(); + if( err.error( true )) + ok = false; if( ok ) kDebug( 1212 ) << "Compositing self-check passed."; if( !ok && options->disableCompositingChecks ) @@ -259,7 +276,18 @@ void SceneXrender::paint( QRegion damage, ToplevelList toplevels ) paintScreen( &mask, &damage ); if( wspace->overlayWindow()) // show the window only after the first pass, since wspace->showOverlay(); // that pass may take long + if( !selfCheckDone ) + { + selfCheckSetup(); + damage |= selfCheckRegion(); + } flushBuffer( mask, damage ); + if( !selfCheckDone ) + { + if( !selfCheckFinish()) + QTimer::singleShot( 0, Workspace::self(), SLOT( finishCompositing())); + selfCheckDone = true; + } // do cleanup stacking_order.clear(); } diff --git a/scene_xrender.h b/scene_xrender.h index 2b800de434..a4fa392660 100644 --- a/scene_xrender.h +++ b/scene_xrender.h @@ -56,6 +56,8 @@ class SceneXrender void createBuffer(); void flushBuffer( int mask, QRegion damage ); bool selfCheck(); + void selfCheckSetup(); + bool selfCheckFinish(); XRenderPictFormat* format; Picture front; static Picture buffer; diff --git a/utils.h b/utils.h index 8e0cdd9a8e..880af40093 100644 --- a/utils.h +++ b/utils.h @@ -98,6 +98,7 @@ typedef QList< Group* > GroupList; typedef QList< const Group* > ConstGroupList; extern Options* options; +extern bool initting; // whether kwin is starting up enum Layer { diff --git a/workspace.h b/workspace.h index d6c474eb30..79889c966a 100644 --- a/workspace.h +++ b/workspace.h @@ -522,6 +522,7 @@ class Workspace : public QObject, public KDecorationDefines void slotReloadConfig(); void setPopupClientOpacity( QAction* action ); void setupCompositing(); + void finishCompositing(); void performCompositing(); void performMousePoll(); void lostCMSelection(); @@ -606,7 +607,6 @@ class Workspace : public QObject, public KDecorationDefines void updateClientArea( bool force ); - void finishCompositing(); bool windowRepaintsPending() const; void setCompositeTimer(); void checkCompositePaintTime( int msec ); From 5d54cf94458bbe30c3cd0c6be710f42292ab26e2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Mon, 9 Feb 2009 14:59:14 +0000 Subject: [PATCH 56/60] Rework of dim screen for administration mode effect. Now it changes brightness and saturation of all windows instead of painting a semi-transparent area on the screen. And it works nicely with fullscreen effects. So the windows are not dimmed in e.g. coverswitch. BUG: 183046 svn path=/trunk/KDE/kdebase/workspace/; revision=923844 --- effects/dimscreen/dimscreen.cpp | 131 +++++++++----------------------- effects/dimscreen/dimscreen.h | 21 ++--- 2 files changed, 42 insertions(+), 110 deletions(-) diff --git a/effects/dimscreen/dimscreen.cpp b/effects/dimscreen/dimscreen.cpp index cee4df31b7..7d53b67dfa 100644 --- a/effects/dimscreen/dimscreen.cpp +++ b/effects/dimscreen/dimscreen.cpp @@ -2,7 +2,7 @@ KWin - the KDE window manager This file is part of the KDE project. - Copyright (C) 2008 Martin Gräßlin This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -21,10 +21,6 @@ along with this program. If not, see . #include -#ifdef KWIN_HAVE_OPENGL_COMPOSITING -#include -#endif - namespace KWin { @@ -32,13 +28,10 @@ KWIN_EFFECT( dimscreen, DimScreenEffect ) DimScreenEffect::DimScreenEffect() : mActivated( false ) - , animation( false ) - , deactivate( false ) + , activateAnimation( false ) + , deactivateAnimation( false ) { reconfigure( ReconfigureAll ); -#ifdef KWIN_HAVE_XRENDER_COMPOSITING - alphaFormat = XRenderFindStandardFormat( display(), PictStandardARGB32 ); -#endif } DimScreenEffect::~DimScreenEffect() @@ -47,99 +40,51 @@ DimScreenEffect::~DimScreenEffect() void DimScreenEffect::reconfigure( ReconfigureFlags ) { - animationDuration = Effect::animationTime( 300 ); + timeline.setDuration( animationTime( 250 )); } void DimScreenEffect::prePaintScreen( ScreenPrePaintData& data, int time ) { + if( mActivated && activateAnimation && !effects->activeFullScreenEffect() ) + timeline.addTime( time ); + if( mActivated && deactivateAnimation ) + timeline.removeTime( time ); + if( mActivated && effects->activeFullScreenEffect() ) + timeline.removeTime( time ); + if( mActivated && !activateAnimation && !deactivateAnimation && !effects->activeFullScreenEffect() && timeline.value() != 1.0 ) + timeline.addTime( time ); effects->prePaintScreen( data, time ); } -void DimScreenEffect::paintScreen( int mask, QRegion region, ScreenPaintData& data ) - { - effects->paintScreen( mask, region, data ); - if( mActivated || deactivate ) - { - float opacity = 0.4; - int height = Effect::displayHeight(); - if( animation ) - { - int elapsed = animationTime.elapsed(); - float timeFactor = (float)((float)elapsed/(float)animationDuration); - if( timeFactor > 1.0 ) - timeFactor = 1.0; - if( deactivate ) - { - opacity = opacity - opacity * timeFactor; - } - else - { - opacity = opacity * timeFactor; - } - } -#ifdef KWIN_HAVE_OPENGL_COMPOSITING - if( effects->compositingType() == OpenGLCompositing ) - { - glPushAttrib( GL_CURRENT_BIT | GL_ENABLE_BIT ); - glEnable( GL_BLEND ); - glBlendFunc( GL_SRC_ALPHA,GL_ONE_MINUS_SRC_ALPHA ); - glPolygonMode( GL_FRONT, GL_FILL ); - glColor4f( 0.0, 0.0, 0.0, opacity ); - float vertices[] = { 0.0, 0.0, 0.0, height, Effect::displayWidth(), height, Effect::displayWidth(), 0.0 }; - renderGLGeometry( 4, vertices ); - glDisable( GL_BLEND ); - glPopAttrib(); - } -#endif -#ifdef KWIN_HAVE_XRENDER_COMPOSITING - if( effects->compositingType() == XRenderCompositing ) - { - Pixmap pixmap = XCreatePixmap( display(), rootWindow(), - Effect::displayWidth(), Effect::displayHeight(), 32 ); - Picture pic = XRenderCreatePicture( display(), pixmap, alphaFormat, 0, NULL ); - XFreePixmap( display(), pixmap ); - XRenderColor col; - col.alpha = int( opacity * 0xffff ); - col.red = int( 0.0 * opacity * 0xffff ); - col.green = int( 0.0 * opacity * 0xffff ); - col.blue = int( 0.0 * opacity * 0xffff ); - XRenderFillRectangle( display(), PictOpSrc, pic, &col, 0, 0, - Effect::displayWidth(), height ); - XRenderComposite( display(), PictOpOver, - pic, None, effects->xrenderBufferPicture(), - 0, 0, 0, 0, 0, 0, Effect::displayWidth(), height ); - XRenderFreePicture( display(), pic ); - } -#endif - // re-paint active window - EffectWindow* activeWindow = effects->activeWindow(); - if( activeWindow ) - { - WindowPaintData data( activeWindow ); - effects->drawWindow( activeWindow, 0, activeWindow->geometry(), data ); - } - } - } - void DimScreenEffect::postPaintScreen() { - if( animation ) + if( mActivated ) { - if( animationTime.elapsed() >= animationDuration ) + if( activateAnimation && timeline.value() == 1.0 ) { - animation = false; - deactivate = false; + activateAnimation = false; + effects->addRepaintFull(); } - effects->addRepaintFull(); + if( deactivateAnimation && timeline.value() == 0.0 ) + { + deactivateAnimation = false; + mActivated = false; + effects->addRepaintFull(); + } + // still animating + if( timeline.value() > 0.0 && timeline.value() < 1.0 ) + effects->addRepaintFull(); } effects->postPaintScreen(); } void DimScreenEffect::paintWindow( EffectWindow *w, int mask, QRegion region, WindowPaintData &data ) { - if( mActivated && ( w == effects->activeWindow() ) ) + if( mActivated && ( w != window ) && + !( w->isComboBox() || w->isDropdownMenu() || w->isTooltip() ) ) { - return; + data.brightness *= (1.0 - 0.33 * timeline.value() ); + data.saturation *= (1.0 - 0.33 * timeline.value() ); } effects->paintWindow( w, mask, region, data ); } @@ -151,24 +96,22 @@ void DimScreenEffect::windowActivated( EffectWindow *w ) check << "kdesu kdesu"; check << "kdesudo kdesudo"; check << "polkit-kde-manager polkit-kde-manager"; - bool before = mActivated; if( check.contains( w->windowClass() ) ) { mActivated = true; + activateAnimation = true; + deactivateAnimation = false; + window = w; + effects->addRepaintFull(); } else { - mActivated = false; - } - if( before != mActivated ) - { - if( !mActivated ) + if( mActivated) { - deactivate = true; + activateAnimation = false; + deactivateAnimation = true; + effects->addRepaintFull(); } - animation = true; - animationTime.restart(); - effects->addRepaintFull(); } } } // namespace diff --git a/effects/dimscreen/dimscreen.h b/effects/dimscreen/dimscreen.h index d5f7de1f43..310fa6a09a 100644 --- a/effects/dimscreen/dimscreen.h +++ b/effects/dimscreen/dimscreen.h @@ -2,7 +2,7 @@ KWin - the KDE window manager This file is part of the KDE project. - Copyright (C) 2008 Martin Gräßlin This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -23,12 +23,6 @@ along with this program. If not, see . #include -#include - -#ifdef KWIN_HAVE_XRENDER_COMPOSITING -#include -#endif - namespace KWin { @@ -41,21 +35,16 @@ class DimScreenEffect virtual void reconfigure( ReconfigureFlags ); virtual void prePaintScreen( ScreenPrePaintData& data, int time ); - virtual void paintScreen( int mask, QRegion region, ScreenPaintData& data ); virtual void postPaintScreen(); virtual void paintWindow( EffectWindow *w, int mask, QRegion region, WindowPaintData &data ); virtual void windowActivated( EffectWindow *w ); private: bool mActivated; - QTime animationTime; - int animationDuration; - bool animation; - bool deactivate; - -#ifdef KWIN_HAVE_XRENDER_COMPOSITING - XRenderPictFormat* alphaFormat; -#endif + bool activateAnimation; + bool deactivateAnimation; + TimeLine timeline; + EffectWindow* window; }; } // namespace From 5945dd113184c020938c9dc1e63ee11b96ff8106 Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Tue, 10 Feb 2009 06:22:04 +0000 Subject: [PATCH 57/60] If an effect is triggered by an electric border "push" the cursor back out of the triggering area and disallow a retrigger for 350ms. Prevents accidental deactivation of effect when leaving the cursor in the hotspot. svn path=/trunk/KDE/kdebase/workspace/; revision=924111 --- workspace.cpp | 8 +++++++- workspace.h | 1 + 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/workspace.cpp b/workspace.cpp index 1ec5ca2eff..f6972e2f29 100644 --- a/workspace.cpp +++ b/workspace.cpp @@ -2128,6 +2128,7 @@ void Workspace::updateElectricBorders() { electric_time_first = xTime(); electric_time_last = xTime(); + electric_time_last_trigger = xTime(); electric_current_border = ElectricNone; QRect r = Kephal::ScreenUtils::desktopGeometry(); electricTop = r.top(); @@ -2226,6 +2227,7 @@ void Workspace::checkElectricBorder(const QPoint& pos, Time now) Time treshold_set = options->electricBorderDelay(); // Set timeout Time treshold_reset = 250; // Reset timeout + Time treshold_trigger = 350; // Minimum time between triggers int distance_reset = 30; // Mouse should not move more than this many pixels ElectricBorder border; @@ -2253,6 +2255,7 @@ void Workspace::checkElectricBorder(const QPoint& pos, Time now) if(( electric_current_border == border ) && ( timestampDiff( electric_time_last, now ) < treshold_reset ) && + ( timestampDiff( electric_time_last_trigger, now ) > treshold_trigger ) && (( pos-electric_push_point ).manhattanLength() < distance_reset )) { electric_time_last = now; @@ -2260,11 +2263,14 @@ void Workspace::checkElectricBorder(const QPoint& pos, Time now) if( timestampDiff( electric_time_first, now ) > treshold_set ) { electric_current_border = ElectricNone; + electric_time_last_trigger = now; if( effects && static_cast( effects )->borderActivated( border )) {} // Handled by effects else + { electricBorderSwitchDesktop( border, pos ); - return; + return; + } } } else diff --git a/workspace.h b/workspace.h index 79889c966a..7e12a2514b 100644 --- a/workspace.h +++ b/workspace.h @@ -741,6 +741,7 @@ class Workspace : public QObject, public KDecorationDefines int electricBottom; Time electric_time_first; Time electric_time_last; + Time electric_time_last_trigger; QPoint electric_push_point; int electric_reserved[ELECTRIC_COUNT]; // Corners/edges used by something From c493623f7a9557e93c90a59c4b21311e6b1dc5c0 Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Tue, 10 Feb 2009 07:02:19 +0000 Subject: [PATCH 58/60] Only activate windows in desktop grid if the user moves them and prevent moving of minimized windows. Also fixes activating of minimized windows in desktop grid by clicking where they were when they were visible. BUG: 179938 svn path=/trunk/KDE/kdebase/workspace/; revision=924118 --- effects/desktopgrid/desktopgrid.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/effects/desktopgrid/desktopgrid.cpp b/effects/desktopgrid/desktopgrid.cpp index 0839374842..491c4c1c76 100644 --- a/effects/desktopgrid/desktopgrid.cpp +++ b/effects/desktopgrid/desktopgrid.cpp @@ -347,7 +347,8 @@ void DesktopGridEffect::windowInputMouseEvent( Window, QEvent* e ) } if( windowMove ) { - effects->activateWindow( windowMove ); // Just in case it was deactivated + if( wasWindowMove ) + effects->activateWindow( windowMove ); // Just in case it was deactivated effects->setElevatedWindow( windowMove, false ); windowMove = NULL; } @@ -550,7 +551,7 @@ EffectWindow* DesktopGridEffect::windowAt( QPoint pos ) const int desktop; pos = unscalePos( pos, &desktop ); foreach( EffectWindow* w, windows ) - if( w->isOnDesktop( desktop ) && w->geometry().contains( pos )) + if( w->isOnDesktop( desktop ) && !w->isMinimized() && w->geometry().contains( pos )) return w; return NULL; } From 9894be083cd50995be87562648dd687e7935fe72 Mon Sep 17 00:00:00 2001 From: Script Kiddy Date: Tue, 10 Feb 2009 14:33:53 +0000 Subject: [PATCH 59/60] SVN_SILENT made messages (.desktop file) svn path=/trunk/KDE/kdebase/workspace/; revision=924329 --- effects/cube/cubeslide.desktop | 6 ++++++ effects/cube/cubeslide_config.desktop | 3 +++ 2 files changed, 9 insertions(+) diff --git a/effects/cube/cubeslide.desktop b/effects/cube/cubeslide.desktop index 3f4709c6db..0e31f36038 100644 --- a/effects/cube/cubeslide.desktop +++ b/effects/cube/cubeslide.desktop @@ -1,15 +1,21 @@ [Desktop Entry] Name=Desktop Cube Animation +Name[et]=Töölauakuubiku animeerimine +Name[nds]=Animeert Wörpel-Schriefdisch Name[pt]=Animação do Cubo de Ecrãs Name[pt_BR]=Animação do cubo da área de trabalho Name[sv]=Animering med skrivbordskub Name[uk]=Анімація куба стільниць +Name[zh_TW]=桌面立方體動畫 Icon=preferences-system-windows-effect-cube Comment=Animate desktop switching with a cube +Comment[et]=Töölaua vahetamise animeerimine kuubikul +Comment[nds]=Schriefdischwesseln mit en Wörpel animeren Comment[pt]=Animar a mudança de ecrãs com um cubo Comment[pt_BR]=Anima a alternação da área de trabalho com um cubo Comment[sv]=Animera skrivbordsbyte med en kub Comment[uk]=Створювати анімацію перемикання стільниць куба +Comment[zh_TW]=切換桌面時模擬立方體的動畫 Type=Service X-KDE-ServiceTypes=KWin/Effect diff --git a/effects/cube/cubeslide_config.desktop b/effects/cube/cubeslide_config.desktop index 8ad7e547e1..e63d1fc4e0 100644 --- a/effects/cube/cubeslide_config.desktop +++ b/effects/cube/cubeslide_config.desktop @@ -7,7 +7,10 @@ X-KDE-ParentComponents=kwin4_effect_cubeslide X-KDE-PluginKeyword=cubeslide Name=Desktop Cube Animation +Name[et]=Töölauakuubiku animeerimine +Name[nds]=Animeert Wörpel-Schriefdisch Name[pt]=Animação do Cubo de Ecrãs Name[pt_BR]=Animação do cubo da área de trabalho Name[sv]=Animering med skrivbordskub Name[uk]=Анімація куба стільниць +Name[zh_TW]=桌面立方體動畫 From 366488f20cc5b5e0872637c27b6cd45b046aa3b5 Mon Sep 17 00:00:00 2001 From: Michael Jansen Date: Wed, 11 Feb 2009 00:34:09 +0000 Subject: [PATCH 60/60] Commit 921749 changed the component name for kwin effects configuration kcms from kwin to kcm_kwin4_effect_xyz . That broke global shortcuts configuration. CCMAIL: kwin@kde.org CCMAIL: lmurray@undefinedfire.com svn path=/trunk/KDE/kdebase/workspace/; revision=924534 --- effects/_test/videorecord_config.cpp | 4 +++- effects/cube/cube_config.cpp | 4 +++- effects/cube/cylinder_config.cpp | 4 +++- effects/cube/sphere_config.cpp | 4 +++- effects/desktopgrid/desktopgrid_config.cpp | 4 +++- effects/invert/invert_config.cpp | 4 +++- effects/lookingglass/lookingglass_config.cpp | 5 +++-- effects/magnifier/magnifier_config.cpp | 5 +++-- effects/mousemark/mousemark_config.cpp | 4 ++-- effects/presentwindows/presentwindows_config.cpp | 4 +++- effects/sharpen/sharpen_config.cpp | 5 ++++- effects/snow/snow_config.cpp | 4 +++- effects/thumbnailaside/thumbnailaside_config.cpp | 5 +++-- effects/zoom/zoom_config.cpp | 5 ++++- 14 files changed, 43 insertions(+), 18 deletions(-) diff --git a/effects/_test/videorecord_config.cpp b/effects/_test/videorecord_config.cpp index c9b5364263..6742b3c816 100644 --- a/effects/_test/videorecord_config.cpp +++ b/effects/_test/videorecord_config.cpp @@ -57,7 +57,9 @@ VideoRecordEffectConfig::VideoRecordEffectConfig(QWidget* parent, const QVariant hlayout->addWidget( saveVideo ); layout->addLayout( hlayout ); - KActionCollection* actionCollection = new KActionCollection( this, componentData() ); + // Shortcut config. The shortcut belongs to the component "kwin"! + KActionCollection* actionCollection = new KActionCollection( this, KComponentData("kwin") ); + KAction* a = static_cast(actionCollection->addAction( "VideoRecord" )); a->setText( i18n("Toggle Video Recording" )); a->setProperty("isConfigurationAction", true); diff --git a/effects/cube/cube_config.cpp b/effects/cube/cube_config.cpp index c5c903e476..88a726a70c 100644 --- a/effects/cube/cube_config.cpp +++ b/effects/cube/cube_config.cpp @@ -52,7 +52,9 @@ CubeEffectConfig::CubeEffectConfig(QWidget* parent, const QVariantList& args) : m_ui->tabWidget->setTabText( 0, i18nc("@title:tab Basic Settings", "Basic") ); m_ui->tabWidget->setTabText( 1, i18nc("@title:tab Advanced Settings", "Advanced") ); - m_actionCollection = new KActionCollection( this, componentData() ); + // Shortcut config. The shortcut belongs to the component "kwin"! + m_actionCollection = new KActionCollection( this, KComponentData("kwin") ); + m_actionCollection->setConfigGroup( "Cube" ); m_actionCollection->setConfigGlobal(true); diff --git a/effects/cube/cylinder_config.cpp b/effects/cube/cylinder_config.cpp index 4a3068e5bf..7f617576fa 100644 --- a/effects/cube/cylinder_config.cpp +++ b/effects/cube/cylinder_config.cpp @@ -52,7 +52,9 @@ CylinderEffectConfig::CylinderEffectConfig(QWidget* parent, const QVariantList& m_ui->tabWidget->setTabText( 0, i18nc("@title:tab Basic Settings", "Basic") ); m_ui->tabWidget->setTabText( 1, i18nc("@title:tab Advanced Settings", "Advanced") ); - m_actionCollection = new KActionCollection( this, componentData() ); + // Shortcut config. The shortcut belongs to the component "kwin"! + m_actionCollection = new KActionCollection( this, KComponentData("kwin") ); + m_actionCollection->setConfigGroup( "Cylinder" ); m_actionCollection->setConfigGlobal(true); diff --git a/effects/cube/sphere_config.cpp b/effects/cube/sphere_config.cpp index eb22b7714d..9f4f56a348 100644 --- a/effects/cube/sphere_config.cpp +++ b/effects/cube/sphere_config.cpp @@ -52,7 +52,9 @@ SphereEffectConfig::SphereEffectConfig(QWidget* parent, const QVariantList& args m_ui->tabWidget->setTabText( 0, i18nc("@title:tab Basic Settings", "Basic") ); m_ui->tabWidget->setTabText( 1, i18nc("@title:tab Advanced Settings", "Advanced") ); - m_actionCollection = new KActionCollection( this, componentData() ); + // Shortcut config. The shortcut belongs to the component "kwin"! + m_actionCollection = new KActionCollection( this, KComponentData("kwin") ); + m_actionCollection->setConfigGroup( "Sphere" ); m_actionCollection->setConfigGlobal(true); diff --git a/effects/desktopgrid/desktopgrid_config.cpp b/effects/desktopgrid/desktopgrid_config.cpp index 80be4896c7..f0cff3b2d5 100644 --- a/effects/desktopgrid/desktopgrid_config.cpp +++ b/effects/desktopgrid/desktopgrid_config.cpp @@ -48,7 +48,9 @@ DesktopGridEffectConfig::DesktopGridEffectConfig(QWidget* parent, const QVariant layout->addWidget( m_ui ); - m_actionCollection = new KActionCollection( this, componentData() ); + // Shortcut config. The shortcut belongs to the component "kwin"! + m_actionCollection = new KActionCollection( this, KComponentData("kwin") ); + m_actionCollection->setConfigGroup( "DesktopGrid" ); m_actionCollection->setConfigGlobal( true ); diff --git a/effects/invert/invert_config.cpp b/effects/invert/invert_config.cpp index ba5e10b865..d4671cdba0 100644 --- a/effects/invert/invert_config.cpp +++ b/effects/invert/invert_config.cpp @@ -39,7 +39,9 @@ InvertEffectConfig::InvertEffectConfig(QWidget* parent, const QVariantList& args KCModule(EffectFactory::componentData(), parent, args) { QVBoxLayout* layout = new QVBoxLayout(this); - KActionCollection* actionCollection = new KActionCollection( this, componentData() ); + + // Shortcut config. The shortcut belongs to the component "kwin"! + KActionCollection *actionCollection = new KActionCollection( this, KComponentData("kwin") ); KAction* a = static_cast(actionCollection->addAction( "Invert" )); a->setText( i18n("Toggle Invert Effect" )); diff --git a/effects/lookingglass/lookingglass_config.cpp b/effects/lookingglass/lookingglass_config.cpp index 7f77b35d5a..9d698550e5 100644 --- a/effects/lookingglass/lookingglass_config.cpp +++ b/effects/lookingglass/lookingglass_config.cpp @@ -54,8 +54,9 @@ LookingGlassEffectConfig::LookingGlassEffectConfig(QWidget* parent, const QVaria connect(m_ui->editor, SIGNAL(keyChange()), this, SLOT(changed())); connect(m_ui->radiusSpin, SIGNAL(valueChanged(int)), this, SLOT(changed())); - // Shortcut config - m_actionCollection = new KActionCollection( this, componentData() ); + // Shortcut config. The shortcut belongs to the component "kwin"! + m_actionCollection = new KActionCollection( this, KComponentData("kwin") ); + m_actionCollection->setConfigGroup("LookingGlass"); m_actionCollection->setConfigGlobal(true); diff --git a/effects/magnifier/magnifier_config.cpp b/effects/magnifier/magnifier_config.cpp index b3f661a528..ee1e668891 100644 --- a/effects/magnifier/magnifier_config.cpp +++ b/effects/magnifier/magnifier_config.cpp @@ -54,8 +54,9 @@ MagnifierEffectConfig::MagnifierEffectConfig(QWidget* parent, const QVariantList connect(m_ui->editor, SIGNAL(keyChange()), this, SLOT(changed())); connect(m_ui->spinWidth, SIGNAL(valueChanged(int)), this, SLOT(changed())); - // Shortcut config - m_actionCollection = new KActionCollection( this, componentData() ); + // Shortcut config. The shortcut belongs to the component "kwin"! + m_actionCollection = new KActionCollection( this, KComponentData("kwin") ); + m_actionCollection->setConfigGroup("Magnifier"); m_actionCollection->setConfigGlobal(true); diff --git a/effects/mousemark/mousemark_config.cpp b/effects/mousemark/mousemark_config.cpp index e61ed366c0..4909fb468c 100644 --- a/effects/mousemark/mousemark_config.cpp +++ b/effects/mousemark/mousemark_config.cpp @@ -55,8 +55,8 @@ MouseMarkEffectConfig::MouseMarkEffectConfig(QWidget* parent, const QVariantList connect(m_ui->spinWidth, SIGNAL(valueChanged(int)), this, SLOT(changed())); connect(m_ui->comboColors, SIGNAL(currentIndexChanged(int)), this, SLOT(changed())); - // Shortcut config - m_actionCollection = new KActionCollection( this, componentData() ); + // Shortcut config. The shortcut belongs to the component "kwin"! + m_actionCollection = new KActionCollection( this, KComponentData("kwin") ); KAction* a = static_cast< KAction* >( m_actionCollection->addAction( "ClearMouseMarks" )); a->setText( i18n( "Clear Mouse Marks" )); diff --git a/effects/presentwindows/presentwindows_config.cpp b/effects/presentwindows/presentwindows_config.cpp index 183812dd94..b4d40ed68f 100644 --- a/effects/presentwindows/presentwindows_config.cpp +++ b/effects/presentwindows/presentwindows_config.cpp @@ -48,7 +48,9 @@ PresentWindowsEffectConfig::PresentWindowsEffectConfig(QWidget* parent, const QV layout->addWidget( m_ui ); - m_actionCollection = new KActionCollection( this, componentData() ); + // Shortcut config. The shortcut belongs to the component "kwin"! + m_actionCollection = new KActionCollection( this, KComponentData("kwin") ); + m_actionCollection->setConfigGroup( "PresentWindows" ); m_actionCollection->setConfigGlobal( true ); diff --git a/effects/sharpen/sharpen_config.cpp b/effects/sharpen/sharpen_config.cpp index bbac4087bb..5241ee45bf 100644 --- a/effects/sharpen/sharpen_config.cpp +++ b/effects/sharpen/sharpen_config.cpp @@ -39,7 +39,10 @@ SharpenEffectConfig::SharpenEffectConfig(QWidget* parent, const QVariantList& ar KCModule(EffectFactory::componentData(), parent, args) { QVBoxLayout* layout = new QVBoxLayout(this); - KActionCollection* actionCollection = new KActionCollection( this, componentData() ); + + // Shortcut config. The shortcut belongs to the component "kwin"! + KActionCollection *actionCollection = new KActionCollection( this, KComponentData("kwin") ); + KAction* a = static_cast(actionCollection->addAction( "Sharpen" )); a->setText( i18nc("@action Enables/Disables an effect that makes windows more sharp", "Toggle Sharpen Effect" )); a->setProperty("isConfigurationAction", true); diff --git a/effects/snow/snow_config.cpp b/effects/snow/snow_config.cpp index 33a4da0ec2..50550999b1 100644 --- a/effects/snow/snow_config.cpp +++ b/effects/snow/snow_config.cpp @@ -56,7 +56,9 @@ SnowEffectConfig::SnowEffectConfig(QWidget* parent, const QVariantList& args) : connect(m_ui->maxHSpeed, SIGNAL(valueChanged(int)), this, SLOT(changed())); connect(m_ui->snowBehindWindows, SIGNAL(stateChanged(int)), this, SLOT(changed())); - m_actionCollection = new KActionCollection( this, componentData() ); + // Shortcut config. The shortcut belongs to the component "kwin"! + m_actionCollection = new KActionCollection( this, KComponentData("kwin") ); + m_actionCollection->setConfigGroup("Snow"); m_actionCollection->setConfigGlobal(true); diff --git a/effects/thumbnailaside/thumbnailaside_config.cpp b/effects/thumbnailaside/thumbnailaside_config.cpp index 8d161f320a..8feffdb4a4 100644 --- a/effects/thumbnailaside/thumbnailaside_config.cpp +++ b/effects/thumbnailaside/thumbnailaside_config.cpp @@ -56,8 +56,9 @@ ThumbnailAsideEffectConfig::ThumbnailAsideEffectConfig(QWidget* parent, const QV connect(m_ui->spinSpacing, SIGNAL(valueChanged(int)), this, SLOT(changed())); connect(m_ui->spinOpacity, SIGNAL(valueChanged(int)), this, SLOT(changed())); - // Shortcut config - m_actionCollection = new KActionCollection( this, componentData() ); + // Shortcut config. The shortcut belongs to the component "kwin"! + m_actionCollection = new KActionCollection( this, KComponentData("kwin") ); + m_actionCollection->setConfigGroup("ThumbnailAside"); m_actionCollection->setConfigGlobal(true); diff --git a/effects/zoom/zoom_config.cpp b/effects/zoom/zoom_config.cpp index e388dec2c6..d8812f65a2 100644 --- a/effects/zoom/zoom_config.cpp +++ b/effects/zoom/zoom_config.cpp @@ -39,7 +39,10 @@ ZoomEffectConfig::ZoomEffectConfig(QWidget* parent, const QVariantList& args) : KCModule(EffectFactory::componentData(), parent, args) { QVBoxLayout* layout = new QVBoxLayout(this); - KActionCollection* actionCollection = new KActionCollection( this, componentData() ); + + // Shortcut config. The shortcut belongs to the component "kwin"! + KActionCollection *actionCollection = new KActionCollection( this, KComponentData("kwin") ); + KAction* a; a = static_cast< KAction* >( actionCollection->addAction( KStandardAction::ZoomIn )); a->setProperty("isConfigurationAction", true);