![]() |
![]() |
![]() |
![]() |
![]() |
|
Now, if you move one of the sliders with the mouse, or type a new value in the input field, followed by a carriage return, the following occurs:
model instance
variable using the model getter. Then, the controller writes a
new value into the value holder's value instance variable using
the value: setter.
value: setter causes the value holder to send the
changed: message to itself.
changed: method sends update: messages to all
dependent parts, which, in the example, amount to the two sliders views
and the input field view.
update: message by extracting the
new value from the value holder, held by their model instance
variables, and then updating their displayed information.
Thus, both sliders and the input field all display the same value. If you move a slider, the other slider and the input field follow the change.