Exemplo n.º 1
0
 def set_finished(self):
     """Update event status to finished."""
     self.timerstat = 'finished'
     self.meet.rfu.dearm()
     uiutil.buttonchg(self.meet.stat_but, uiutil.bg_none, 'Finished')
     self.meet.stat_but.set_sensitive(False)
     if self.finish is None:
         self.set_finish(tod.tod('now'))
     self.set_elapsed()
Exemplo n.º 2
0
 def set_finished(self):
     """Update event status to finished."""
     self.timerstat = 'finished'
     self.meet.rfu.dearm()
     uiutil.buttonchg(self.meet.stat_but, uiutil.bg_none, 'Finished')
     self.meet.stat_but.set_sensitive(False)
     if self.finish is None:
         self.set_finish(tod.tod('now'))
     self.set_elapsed()
Exemplo n.º 3
0
 def resettimer(self):
     """Reset race timer."""
     self.set_finish()
     self.set_start()
     self.clear_results()
     self.timerstat = 'idle'
     self.meet.rfu.dearm()
     uiutil.buttonchg(self.meet.stat_but, uiutil.bg_none, 'Idle')
     self.meet.stat_but.set_sensitive(True)
     self.set_elapsed()
Exemplo n.º 4
0
 def armfinish(self):
     """Toggle timer arm finish state."""
     if self.timerstat == 'running':
         self.timerstat = 'armfinish'
         uiutil.buttonchg(self.stat_but, uiutil.bg_armfin, 'Arm Finish')
         self.meet.timer.arm(timy.CHAN_FINISH)
     elif self.timerstat == 'armfinish':
         self.timerstat = 'running'
         uiutil.buttonchg(self.stat_but, uiutil.bg_none, 'Running')
         self.meet.timer.dearm(timy.CHAN_FINISH)
Exemplo n.º 5
0
 def armfinish(self):
     """Process an armfinish request."""
     if self.timerstat in ['running', 'finished']:
         self.timerstat = 'armfinish'
         uiutil.buttonchg(self.meet.stat_but, uiutil.bg_armfin, 'Arm Finish')
         self.meet.stat_but.set_sensitive(True)
         self.meet.rfu.arm()
     elif self.timerstat == 'armfinish':
         self.timerstat = 'running'
         uiutil.buttonchg(self.meet.stat_but, uiutil.bg_none, 'Running')
Exemplo n.º 6
0
 def armfinish(self):
     """Toggle timer arm finish state."""
     if self.timerstat == 'running':
         self.timerstat = 'armfinish'
         uiutil.buttonchg(self.stat_but, uiutil.bg_armfin, 'Arm Finish')
         self.meet.timer.arm(timy.CHAN_FINISH)
     elif self.timerstat == 'armfinish':
         self.timerstat = 'running'
         uiutil.buttonchg(self.stat_but, uiutil.bg_none, 'Running')
         self.meet.timer.dearm(timy.CHAN_FINISH)
Exemplo n.º 7
0
 def resettimer(self):
     """Reset race timer."""
     self.set_finish()
     self.set_start()
     self.clear_results()
     self.timerstat = 'idle'
     self.meet.rfu.dearm()
     uiutil.buttonchg(self.meet.stat_but, uiutil.bg_none, 'Idle')
     self.meet.stat_but.set_sensitive(True)
     self.set_elapsed()
Exemplo n.º 8
0
 def close_event(self):
     """Close the currently opened race."""
     if self.curevent is not None:
         self.curevent.hide()
         self.race_box.remove(self.curevent.frame)
         self.curevent.destroy()
         self.menu_race_close.set_sensitive(False)
         self.menu_race_abort.set_sensitive(False)
         self.curevent = None
         uiutil.buttonchg(self.stat_but, uiutil.bg_none, 'Closed')
         self.stat_but.set_sensitive(False)
Exemplo n.º 9
0
 def close_event(self):
     """Close the currently opened race."""
     if self.curevent is not None:
         self.curevent.hide()
         self.race_box.remove(self.curevent.frame)
         self.curevent.destroy()
         self.menu_race_close.set_sensitive(False)
         self.menu_race_abort.set_sensitive(False)
         self.curevent = None
         uiutil.buttonchg(self.stat_but, uiutil.bg_none, 'Closed')
         self.stat_but.set_sensitive(False)
Exemplo n.º 10
0
 def armfinish(self):
     """Process an armfinish request."""
     if self.timerstat in ['running', 'finished']:
         self.timerstat = 'armfinish'
         uiutil.buttonchg(self.meet.stat_but, uiutil.bg_armfin,
                          'Arm Finish')
         self.meet.stat_but.set_sensitive(True)
         self.meet.rfu.arm()
     elif self.timerstat == 'armfinish':
         self.timerstat = 'running'
         uiutil.buttonchg(self.meet.stat_but, uiutil.bg_none, 'Running')
Exemplo n.º 11
0
 def armstart(self):
     """Toggle timer arm start state."""
     if self.timerstat == 'idle':
         self.timerstat = 'armstart'
         uiutil.buttonchg(self.stat_but, uiutil.bg_armstart, 'Arm Start')
         self.meet.timer.arm(timy.CHAN_START)
     elif self.timerstat == 'armstart':
         self.timerstat = 'idle'
         self.time_lbl.set_text('')
         uiutil.buttonchg(self.stat_but, uiutil.bg_none, 'Idle')
         self.meet.timer.dearm(timy.CHAN_START)
Exemplo n.º 12
0
 def armstart(self):
     """Toggle timer arm start state."""
     if self.timerstat == 'idle':
         self.timerstat = 'armstart'
         uiutil.buttonchg(self.stat_but, uiutil.bg_armstart, 'Arm Start')
         self.meet.timer.arm(timy.CHAN_START)
     elif self.timerstat == 'armstart':
         self.timerstat = 'idle'
         self.time_lbl.set_text('')
         uiutil.buttonchg(self.stat_but, uiutil.bg_none, 'Idle')
         self.meet.timer.dearm(timy.CHAN_START)
Exemplo n.º 13
0
 def toload(self, bib=None):
     """Load timer."""
     self.status = "load"
     self.starttod = None
     self.recovtod = tod.tod(0)
     self.finishtod = None
     self.set_time()
     self.lap = 0
     self.set_lap()
     self.splits = []
     if bib is not None:
         self.setrider(bib)
     uiutil.buttonchg(self.b, uiutil.bg_none, "Ready")
Exemplo n.º 14
0
 def toload(self, bib=None):
     """Load timer."""
     self.status = 'load'
     self.starttod = None
     self.recovtod = tod.tod(0)
     self.finishtod = None
     self.set_time()
     self.lap = 0
     self.set_lap()
     self.splits = []
     if bib is not None:
         self.setrider(bib)
     uiutil.buttonchg(self.b, uiutil.bg_none, 'Ready')
Exemplo n.º 15
0
 def resettimer(self):
     """Reset race timer."""
     self.finish = None
     self.start = None
     self.lstart = None
     self.timerstat = 'idle'
     self.ctrl_places.set_text('')
     self.placexfer('')
     self.meet.timer.dearm(0)
     self.meet.timer.dearm(1)
     uiutil.buttonchg(self.stat_but, uiutil.bg_none, 'Idle')
     self.stat_but.set_sensitive(True)
     self.set_elapsed()
Exemplo n.º 16
0
 def resettimer(self):
     """Reset race timer."""
     self.finish = None
     self.start = None
     self.lstart = None
     self.timerstat = 'idle'
     self.ctrl_places.set_text('')
     self.placexfer('')
     self.meet.timer.dearm(0)
     self.meet.timer.dearm(1)
     uiutil.buttonchg(self.stat_but, uiutil.bg_none, 'Idle')
     self.stat_but.set_sensitive(True)
     self.set_elapsed()
Exemplo n.º 17
0
 def armstart(self):
     """Process an armstart request."""
     if self.timerstat == 'idle':
         self.timerstat = 'armstart'
         self.meet.rfu.arm()
         uiutil.buttonchg(self.meet.stat_but, uiutil.bg_armstart,
                                 'Arm Start')
     elif self.timerstat == 'armstart':
         self.timerstat = 'idle'
         uiutil.buttonchg(self.meet.stat_but, uiutil.bg_none, 'Idle') 
         self.meet.rfu.dearm()	# superfluous?
     elif self.timerstat == 'running':
         # Possible extra state transition here in response to F5
         pass
Exemplo n.º 18
0
 def armstart(self):
     """Process an armstart request."""
     if self.timerstat == 'idle':
         self.timerstat = 'armstart'
         self.meet.rfu.arm()
         uiutil.buttonchg(self.meet.stat_but, uiutil.bg_armstart,
                          'Arm Start')
     elif self.timerstat == 'armstart':
         self.timerstat = 'idle'
         uiutil.buttonchg(self.meet.stat_but, uiutil.bg_none, 'Idle')
         self.meet.rfu.dearm()  # superfluous?
     elif self.timerstat == 'running':
         # Possible extra state transition here in response to F5
         pass
Exemplo n.º 19
0
 def toidle(self):
     """Set timer state to idle."""
     self.status = "idle"
     self.bib = None
     self.bibent.set_text("")
     self.bibent.set_sensitive(True)
     self.serent.set_sensitive(True)
     self.biblbl.set_text("")
     self.starttod = None
     self.recovtod = tod.tod(0)
     self.finishtod = None
     self.lap = 0
     self.set_lap()
     self.splits = []
     self.set_time()
     uiutil.buttonchg(self.b, uiutil.bg_none, "Idle")
Exemplo n.º 20
0
 def toidle(self):
     """Set timer state to idle."""
     self.status = 'idle'
     self.bib = None
     self.bibent.set_text('')
     self.bibent.set_sensitive(True)
     self.serent.set_sensitive(True)
     self.biblbl.set_text('')
     self.starttod = None
     self.recovtod = tod.tod(0)
     self.finishtod = None
     self.lap = 0
     self.set_lap()
     self.splits = []
     self.set_time()
     uiutil.buttonchg(self.b, uiutil.bg_none, 'Idle')
Exemplo n.º 21
0
 def torunning(self):
     """Update timer state to running."""
     self.bibent.set_sensitive(False)
     self.serent.set_sensitive(False)
     self.status = "running"
     uiutil.buttonchg(self.b, uiutil.bg_none, "Running")
Exemplo n.º 22
0
 def toarmstart(self):
     """Set state to armstart."""
     self.status = "armstart"
     self.set_time("       0.0   ")
     uiutil.buttonchg(self.b, uiutil.bg_armstart, "Start Armed")
Exemplo n.º 23
0
 def set_running(self):
     """Update event status to running."""
     self.timerstat = 'running'
     self.meet.rfu.arm()
     uiutil.buttonchg(self.meet.stat_but, uiutil.bg_none, 'Running')
Exemplo n.º 24
0
 def setrunning(self):
     """Set timer state to 'running'."""
     self.timerstat = 'running'
     uiutil.buttonchg(self.stat_but, uiutil.bg_none, 'Running')
Exemplo n.º 25
0
 def setfinished(self):
     """Set timer state to 'finished'."""
     self.timerstat = 'finished'
     uiutil.buttonchg(self.stat_but, uiutil.bg_none, 'Finished')
     self.stat_but.set_sensitive(False)
     self.ctrl_places.grab_focus()
Exemplo n.º 26
0
 def tofinish(self):
     """Set timer to finished."""
     self.status = "finish"
     uiutil.buttonchg(self.b, uiutil.bg_none, "Finished")
Exemplo n.º 27
0
 def tofinish(self):
     """Set timer to finished."""
     self.status = 'finish'
     uiutil.buttonchg(self.b, uiutil.bg_none, 'Finished')
Exemplo n.º 28
0
 def toarmfin(self):
     """Arm timer for finish."""
     self.status = 'armfin'
     uiutil.buttonchg(self.b, uiutil.bg_armfin, 'Finish Armed')
Exemplo n.º 29
0
 def set_running(self):
     """Update event status to running."""
     self.timerstat = 'running'
     self.meet.rfu.arm()
     uiutil.buttonchg(self.meet.stat_but, uiutil.bg_none, 'Running')
Exemplo n.º 30
0
 def toarmfin(self):
     """Arm timer for finish."""
     self.status = "armfin"
     uiutil.buttonchg(self.b, uiutil.bg_armfin, "Finish Armed")
Exemplo n.º 31
0
 def toarmint(self):
     """Arm timer for intermediate."""
     self.status = 'armint'
     uiutil.buttonchg(self.b, uiutil.bg_armint, 'Intermediate Armed')
Exemplo n.º 32
0
 def torunning(self):
     """Update timer state to running."""
     self.bibent.set_sensitive(False)
     self.serent.set_sensitive(False)
     self.status = 'running'
     uiutil.buttonchg(self.b, uiutil.bg_none, 'Running')
Exemplo n.º 33
0
 def toarmint(self):
     """Arm timer for intermediate."""
     self.status = "armint"
     uiutil.buttonchg(self.b, uiutil.bg_armint, "Intermediate Armed")
Exemplo n.º 34
0
 def toarmstart(self):
     """Set state to armstart."""
     self.status = 'armstart'
     self.set_time('       0.0   ')
     uiutil.buttonchg(self.b, uiutil.bg_armstart, 'Start Armed')
Exemplo n.º 35
0
 def setfinished(self):
     """Set timer state to 'finished'."""
     self.timerstat = 'finished'
     uiutil.buttonchg(self.stat_but, uiutil.bg_none, 'Finished')
     self.stat_but.set_sensitive(False)
     self.ctrl_places.grab_focus()
Exemplo n.º 36
0
 def setrunning(self):
     """Set timer state to 'running'."""
     self.timerstat = 'running'
     uiutil.buttonchg(self.stat_but, uiutil.bg_none, 'Running')