From dea4444c4a8d615c68bd6d2b05124cc8d66bd6d7 Mon Sep 17 00:00:00 2001 From: Simon Paul St James Date: Fri, 31 Oct 2008 21:45:51 +0000 Subject: Be better behaved in the presence of scroll events in the middle of an elastic band selection by storing the last selection elastic band in view (rather than viewport) coordinates. svn path=/trunk/KDE/kdebase/apps/; revision=878316 --- src/dolphindetailsview.h | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'src/dolphindetailsview.h') diff --git a/src/dolphindetailsview.h b/src/dolphindetailsview.h index f564773bc..996c87793 100644 --- a/src/dolphindetailsview.h +++ b/src/dolphindetailsview.h @@ -191,8 +191,8 @@ private: { ElasticBand(); - // Elastic band coordinates are relative to the origin of the - // view, not the viewport. + // Elastic band origin and destination coordinates are relative to t + // he origin of the view, not the viewport. bool show; QPoint origin; QPoint destination; @@ -200,10 +200,11 @@ private: // Optimisation mechanisms for use with elastic band selection. // Basically, allow "incremental" updates to the selection based // on the last elastic band shape. - QRect oldSelectionRect; + QPoint lastSelectionOrigin; + QPoint lastSelectionDestination; // If true, compute the set of selected elements from scratch (slower) - bool ignoreOldInfo; + bool ignoreOldInfo; // Edges of the filenames that are closest to the edges of oldSelectionRect. // Used to decide whether horizontal changes in the elastic band are likely -- cgit v1.3