# HG changeset patch # User Claus Gittinger # Date 910629080 -3600 # Node ID cb753ba02fb449841ae015b6e4b4a61e573fbcfa # Parent b9d07088fe743e1c3c99dac5ad0b0c00306bc5d5 remember old width/height before doing a repairDamage in #scrollTo:redraw:; under Win32, resizes may arrive in between. diff -r b9d07088fe74 -r cb753ba02fb4 ListView.st --- a/ListView.st Mon Nov 09 14:34:37 1998 +0100 +++ b/ListView.st Mon Nov 09 17:31:20 1998 +0100 @@ -3230,7 +3230,8 @@ y1 "{ Class:SmallInteger }" y "{ Class:SmallInteger }" x "{ Class:SmallInteger }" - delta newFirstLine newViewOrigin newLeftOffset| + delta newFirstLine newViewOrigin newLeftOffset + hBefore wBefore inv| dltOrg := anOrigin - viewOrigin. @@ -3307,6 +3308,8 @@ ^ self originChanged:delta ]. + hBefore := height. + wBefore := width. self repairDamage. self originWillChange. @@ -3319,8 +3322,8 @@ x == 0 ifTrue:[ "/ scrolling vertical y0 := textStartTop + (y abs). - h := height - margin - y0. - w := width - margin. + h := hBefore - margin - y0. + w := wBefore - margin. y > 0 ifTrue:[ "/ copy down self copyFrom:self @@ -3334,20 +3337,18 @@ y1 := 0. ]. - self invalidate:((margin@y1) extent:(w@y0)). - "/ self redrawX:margin y:y1 width:w height:y0. - + inv := (margin@y1) extent:(w@y0). ] ifFalse:[ "/ scrolling horizontal x > 0 ifTrue:[ "/ scrolling right y0 := margin + x. - y1 := width - y0. + y1 := wBefore - y0. ] ifFalse:[ "/ scrolling left y0 := margin - x. y1 := 0. ]. - h := height - margin - margin. - w := width - margin - y0. + h := hBefore - margin - margin. + w := wBefore - margin - y0. x > 0 ifTrue:[ "/ copy right self copyFrom:self x:y0 y:margin toX:margin y:margin @@ -3358,14 +3359,15 @@ width:w height:h async:true. ]. - self invalidate:((y1@margin) extent:(y0@h)). - "/ self redrawX:y1 y:margin width:y0 height:h. + inv := (y1@margin) extent:(y0@h). ]. + self invalidate:inv. + self waitForExpose. self originChanged:delta. - "Modified: / 2.10.1998 / 01:13:16 / cg" + "Modified: / 9.11.1998 / 17:24:53 / cg" ! ! !ListView methodsFor:'searching'! @@ -3835,5 +3837,5 @@ !ListView class methodsFor:'documentation'! version - ^ '$Header: /cvs/stx/stx/libwidg/ListView.st,v 1.176 1998-10-03 21:54:14 cg Exp $' + ^ '$Header: /cvs/stx/stx/libwidg/ListView.st,v 1.177 1998-11-09 16:31:20 cg Exp $' ! !