added blurred background and dropshadow for ChangeDesktopOSD

svn path=/trunk/KDE/kdebase/workspace/; revision=1133436
This commit is contained in:
Andreas Demmer 2010-06-01 18:23:14 +00:00
parent d7698b80b3
commit fa7b782462
2 changed files with 14 additions and 1 deletions

View file

@ -300,7 +300,18 @@ void DesktopChangeOSD::resize()
setGeometry( rect );
m_scene->setSceneRect( 0, 0, width, height );
m_frame.resizeFrame( QSize( width, height ) );
setMask( m_frame.mask() );
if (Plasma::Theme::defaultTheme()->windowTranslucencyEnabled())
{
// blur background
Plasma::WindowEffects::enableBlurBehind(winId(), true, m_frame.mask());
Plasma::WindowEffects::overrideShadow(winId(), true);
}
else
{
// do not trim to mask with compositing enabled, otherwise shadows are cropped
setMask( m_frame.mask() );
}
// resize item frame
m_item_frame.setElementPrefix( "normal" );

View file

@ -25,6 +25,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#include <QGraphicsItem>
#include <QTimer>
#include <KDE/Plasma/FrameSvg>
#include <KDE/Plasma/Theme>
#include <KDE/Plasma/WindowEffects>
#include <QWeakPointer>
class QGraphicsScene;