[squeak-dev] duplicated rectangles in DamageRecorder

Yoshiki Ohshima yoshiki at vpri.org
Sat Oct 3 06:50:25 UTC 2009


At Fri, 02 Oct 2009 08:53:26 -0300,
Juan Vuletich wrote:
> 
> Playing a bit with it (in Cuis), it seems to happen because of unneeded 
> calls to #changed. I could avoid some of them by making property setter 
> methods do nothing if the property is set. For example, 
> BorderedMorph>>#borderWidth: TextMorph>>#backgroundColor: and 
> TransformMorph>>#offset can use a check with the argument and just exit, 
> like for example Morph>>#extent:.

  Ah ha.  Good catch.

> Besides, 
> MenuMorph>>#popUpAt:forHand:in:allowKeyboard: does not need the last 
> line (self changed).

  Right.  fillStyle: for example does it.

> In any case, unneeded calls to self changed are usual, as it says in the 
> last comment of TextMorph>>#fit. So, I think that the check and early 
> exit you propose in #recordInvalidRect: is a good idea and will include 
> it in Cuis.

  Thank you for validating the idea!

-- Yoshiki



More information about the Squeak-dev mailing list