[MCP] [Q] Color change notification

diegogomezdeck at consultar.com diegogomezdeck at consultar.com
Sun Mar 16 16:51:52 UTC 2003


Hannes,

Thank for your fast answer...

> Hi Diego
>
> I understand what you write and how your proposed solution works.
> However from the example  of the current solution you give
> I do not yet see the advantage(s) of your proposal.
> What is the benefit of having two methods
> instead of one
>
> color: aColor
> onColorChange
>
> Is it to more clearly show non-standard behavior?

The idea is to give more semantic value to the message names.  Some code on
#onColorChange clearly shows an intention to the reader.

> The main problem with the instance variable 'color'
> is if I remember correctly that it is just labeled 'color'
> but in many cases contains other objects.
>
> Perhaps your solution helps to better see the difficulties
> caused by this.
>
> Regards
> Hannes

TIA,

Diego





More information about the Squeak-dev mailing list