     restoreSelected()
     $scope.mode.onNextMode(direction)
     $scope.mode.onChanged()
+
 
   ###
    Workaround for restore selected state on switching view.

    onTimerStopped: (time) =>
      # nothing to do

  ###
   Start Initialize.
  ###

      DataAdapter.selectedActivity = tmpActivity
    , SWITCHING_TIME / 2


  ###
   Start or End Time tracking
  ###
  $scope.clickSubmitButton = () ->
    $scope.mode.onSubmitClick()


  ###
   on timer stopped, send time entry.
  ###
  $scope.$on 'timer-stopped', (e, time) ->
    $scope.mode.onTimerStopped(time)


  ###
   on timer ticked, update title.
