From 55c5a2f1080e304da8be5e7c9a004e1604c0211b Mon Sep 17 00:00:00 2001 From: tpearson Date: Fri, 23 Sep 2011 04:01:04 +0000 Subject: Fix ksmserver flicker on logout with ARGB visuals git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdebase@1255031 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- ksmserver/shutdowndlg.cpp | 27 +++++++++++++-------------- 1 file changed, 13 insertions(+), 14 deletions(-) (limited to 'ksmserver/shutdowndlg.cpp') diff --git a/ksmserver/shutdowndlg.cpp b/ksmserver/shutdowndlg.cpp index a86887e9b..1ca240738 100644 --- a/ksmserver/shutdowndlg.cpp +++ b/ksmserver/shutdowndlg.cpp @@ -533,7 +533,19 @@ KSMShutdownIPFeedback::KSMShutdownIPFeedback() system("krootbacking &"); } - resize(0, 0); + // eliminate nasty flicker on first show + m_root.resize( kapp->desktop()->width(), kapp->desktop()->height() ); + TQImage blendedImage = TQImage( kapp->desktop()->width(), kapp->desktop()->height(), 32 ); + TQPainter p; + p.begin( &m_root ); + blendedImage.setAlphaBuffer(false); + p.drawImage( 0, 0, blendedImage ); + p.end(); + + setBackgroundPixmap( m_root ); + setGeometry( TQApplication::desktop()->geometry() ); + setBackgroundMode( TQWidget::NoBackground ); + setShown(true); } @@ -563,19 +575,6 @@ void KSMShutdownIPFeedback::slotPaintEffect() { TQPixmap pm = m_rootPixmap; if (mPixmapTimeout == 0) { - // eliminate nasty flicker on first show - m_root.resize( kapp->desktop()->width(), kapp->desktop()->height() ); - TQImage blendedImage = TQImage( kapp->desktop()->width(), kapp->desktop()->height(), 32 ); - TQPainter p; - p.begin( &m_root ); - blendedImage.setAlphaBuffer(false); - p.drawImage( 0, 0, blendedImage ); - p.end(); - - setBackgroundPixmap( m_root ); - setGeometry( TQApplication::desktop()->geometry() ); - setBackgroundMode( TQWidget::NoBackground ); - if (TQPaintDevice::x11AppDepth() != 32) { m_sharedRootPixmap->start(); } -- cgit v1.2.1