         'click .input-details-trigger': -> @switchToScreen('details')
         'click .input-alert': -> @switchToScreen('alert')
         'click .input-repeat': -> @switchToScreen('repeat')
+
+
+    initialize: ->
+        # Listen to the model's change to update the view accordingly.
+        # `start` and `end` are updated when one changed to prevent overlapping
+        # times.
+        @listenTo @model, "change:start", @onStartChange
+        @listenTo @model, "change:end", @onEndChange
+
+
+    # Remove the listeners when the screen is left.
+    onLeaveScreen: ->
+        @stopListening @model
 
 
     getRenderData: ->

    expandPopover: ->
        @$optionalFields.attr 'aria-hidden', false
        @$moreDetailsButton.hide()


    onSetPlace: (ev) ->
        @model.set 'place', ev.target.value


    onSetStart: ->
