Merge 8be3dbbbf3 into d0cb33b6fc
This commit is contained in:
commit
f4bc84dbe8
1 changed files with 3 additions and 2 deletions
|
|
@ -93,6 +93,9 @@ def writetime(the_hr, the_min):
|
|||
the_hr = the_hr + 1 # for the TO case
|
||||
value = value | TO
|
||||
# set hour
|
||||
if the_hr == 24: # special case for Midnight
|
||||
value = value | MIDNIGHT
|
||||
return value
|
||||
if the_hr > 12:
|
||||
the_hr = the_hr - 12 # Convert 24 hour format to 12 hour
|
||||
if the_hr == 1:
|
||||
|
|
@ -117,8 +120,6 @@ def writetime(the_hr, the_min):
|
|||
value = value | TEN
|
||||
if the_hr == 11:
|
||||
value = value | ELEVEN
|
||||
if the_hr == 0:
|
||||
value = value | MIDNIGHT
|
||||
if the_hr == 12:
|
||||
value = value | NOON
|
||||
return value
|
||||
|
|
|
|||
Loading…
Reference in a new issue