20 lines
550 B
Plaintext
Executable File
20 lines
550 B
Plaintext
Executable File
# Build HTML timeselector option list
|
|
proc timelist {sel} {
|
|
|
|
puts -nonewline "<option value=\"0\""
|
|
if {$sel eq 0} {
|
|
puts -nonewline " selected=yes"
|
|
}
|
|
puts ">ASAP</option>"
|
|
|
|
for {set t 0} {$t <1440} {incr t 30} {
|
|
# (mis)use the the fact of 60 sec per min 60 min per hour to format hh:mm, t is min per period
|
|
set ft [clock format $t -format %M:%S]
|
|
puts -nonewline "<option value=\"$ft\""
|
|
if {$sel eq $ft} {
|
|
puts -nonewline " selected=yes"
|
|
}
|
|
puts ">$ft</option>"
|
|
}
|
|
}
|