| 1 | """Switchboard class.
|
|---|
| 2 |
|
|---|
| 3 | This class is used to coordinate updates among all Viewers. Every Viewer must
|
|---|
| 4 | conform to the following interface:
|
|---|
| 5 |
|
|---|
| 6 | - it must include a method called update_yourself() which takes three
|
|---|
| 7 | arguments; the red, green, and blue values of the selected color.
|
|---|
| 8 |
|
|---|
| 9 | - When a Viewer selects a color and wishes to update all other Views, it
|
|---|
| 10 | should call update_views() on the Switchboard object. Note that the
|
|---|
| 11 | Viewer typically does *not* update itself before calling update_views(),
|
|---|
| 12 | since this would cause it to get updated twice.
|
|---|
|
|---|