Home Segments Index Top Previous Next

790: Mainline

A controller is in charge of dealing with input devices—typically, the keyboard and mouse. When a controller notes that a keystroke or mouse click is of interest, that controller sends a message to the corresponding model:

*------------*                         *---------------* 
|            |   Something new!        |               | 
| Controller |   --------------------> | Model         | 
|            |   (Mediated by setter)  |               | 
*------------*                         *---------------*