From kfm-devel Wed Dec 18 20:04:18 2002 From: Wilco Greven Date: Wed, 18 Dec 2002 20:04:18 +0000 To: kfm-devel Subject: Reduce flicker in KonqIconView X-MARC-Message: https://marc.info/?l=kfm-devel&m=104024185323389 MIME-Version: 1 Content-Type: multipart/mixed; boundary="--Boundary-00=_CTNA+PddcsGXZMZ" --Boundary-00=_CTNA+PddcsGXZMZ Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Content-Disposition: inline Hi, Following up on an earlier thread on this list I tried to get rid of some more of the flicker occuring when you switch to another directory. The accompanying patch solves the problem that newIconSize starts a preview job which is immediately stopped again in mimeTypeDeterminationFinished. When the preview job is stopped the view is updated. The best way to prevent this preview job from starting we can check whether the current icon size is already the correct one and if so, do nothing. -- Greetings, Wilco --Boundary-00=_CTNA+PddcsGXZMZ Content-Type: text/x-diff; charset="us-ascii"; name="konq_iconview.cc.diff" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="konq_iconview.cc.diff" Index: konq_iconview.cc =================================================================== RCS file: /home/kde/kdebase/konqueror/iconview/konq_iconview.cc,v retrieving revision 1.421 diff -u -p -b -r1.421 konq_iconview.cc --- konq_iconview.cc 23 Nov 2002 22:45:11 -0000 1.421 +++ konq_iconview.cc 18 Dec 2002 20:01:56 -0000 @@ -584,6 +584,9 @@ void KonqKfmIconView::slotSortDirsFirst( void KonqKfmIconView::newIconSize( int size ) { + if ( size == m_pIconView->iconSize() ) + return; + KonqDirPart::newIconSize( size ); m_pIconView->setIcons( size ); if ( m_pProps->isShowingPreview() ) --Boundary-00=_CTNA+PddcsGXZMZ--