# The controller part of the whole thing

# Take an input event and .. do something
class Controller :

    def __init__(self, model=None):
        self.model = model

    # event has at least a subject
    # e.g.,
    # subject = <http://www.squaremobius.net/fuschia/index.html>
    # At the minute we recognise only one kind of action, and
    # that is changing the subject (usually by clicking on a
    # link)
    def input(self, event):
        if model:
            req = event.subject
            model.root = req
