New guidance icon, early abort from automatic processing on flag disappearance, show recording icon instead of failed

git-svn-id: file:///root/webif/svn/pkg/webif/trunk@2425 2a923420-c742-0410-a762-8d5b09965624
This commit is contained in:
hummypkg 2015-06-15 17:33:32 +00:00
parent 2ce27624ce
commit bc682f4bef
8 changed files with 32 additions and 20 deletions

View File

@ -1,10 +1,10 @@
Package: webif
Priority: optional
Section: web
Version: 1.2.2-9
Version: 1.2.3
Architecture: mipsel
Maintainer: af123@hummypkg.org.uk
Depends: webif-channelicons(>=1.1.18),lighttpd(>=1.4.35-2),jim(>=0.76),jim-oo,jim-sqlite3(>=0.76),jim-cgi(>=0.7),jim-binary(>=0.76),service-control(>=2.1),busybox(>=1.20.2-1),lsof(>=4.87),epg(>=1.2.0),hmt(>=2.0.3),ssmtp,anacron,trm(>=1.1),openssl-command,nicesplice,id3v2,file,rsvsync(>=1.0.2),webif-charts(>=1.2-1),stripts(>=1.2.5-3),smartmontools,tmenu(>=1.08),ffmpeg,id3v2,multienv(>=1.6),tcpping(>=1.1),e2fsprogs,wireless-tools(>=29-1),dbupdate,recmon(>2.0.3-3)
Depends: webif-channelicons(>=1.1.18),lighttpd(>=1.4.35-2),jim(>=0.76),jim-oo,jim-sqlite3(>=0.76),jim-cgi(>=0.7),jim-binary(>=0.76),service-control(>=2.1),busybox(>=1.20.2-1),lsof(>=4.87),epg(>=1.2.0),hmt(>=2.0.3),ssmtp,anacron,trm(>=1.1),openssl-command,nicesplice,id3v2,file,rsvsync(>=1.0.2),webif-charts(>=1.2-1),stripts(>=1.2.5-3),smartmontools,tmenu(>=1.08),ffmpeg,id3v2,multienv(>=1.6),tcpping(>=1.1),e2fsprogs,wireless-tools(>=29-1),dbupdate,recmon(>2.0.3-3),auto-unprotect(>=2.0.0-1)
Suggests:
Description: An evolving web interface for the Humax.
Tags: http://hummy.tv/forum/threads/5866/

View File

@ -64,7 +64,7 @@ if {$type eq "ts"} {
puts "
<th>Guidance</th>
<td><img class=va
src=/img/Guidance_red.png height=21>
src=/img/Guidance_purple.png height=21>
[$ts get guidance]
</td>
</tr><tr>

View File

@ -117,8 +117,11 @@ proc entry {file} {{i 0}} {
if {$ext eq ".ts" && [file exists "${base}.nts"]} {
set type ts
set ts [ts fetch $file 1]
if {[$ts get status] eq "Valid/OK"} {
set rstat [$ts get status]
if {$rstat eq "Valid/OK"} {
set img Video_TS
} elseif {$rstat eq "Loss of power/OK" && $bfile in $dinuse} {
set img Video_Rec
} else {
set img Video_Failed
}
@ -225,7 +228,7 @@ proc entry {file} {{i 0}} {
# Guidance
if {[$ts flag "Guidance"] > 0} {
icon "/img/Guidance_red.png"
icon "/img/Guidance_purple.png"
}
if {[$ts flag "GGuidance"] > 0} {
icon "/img/Guidance_blue.png"

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.6 KiB

View File

@ -140,7 +140,7 @@ proc entry {file {i 0}} {
# Guidance
if {[$ts flag "Guidance"] > 0} {
icon "/img/Guidance_red.png"
icon "/img/Guidance_purple.png"
}
if {[$ts flag "GGuidance"] > 0} {
icon "/img/Guidance_blue.png"

View File

@ -10,7 +10,6 @@ set audiomp3 [$settings audiomp3]
set modules {decrypt dedup shrink mpg mp3 expire}
set logfile "/mod/tmp/auto.log"
set logfd "unset"
@ -201,7 +200,7 @@ proc endop {} {
file delete "$tmp/.op"
}
proc dedup {dir} {
proc dedup {dir {flag ""}} {
log "DEDUP: \[$dir]" 2
loop i 0 1 {
foreach line [split \
@ -556,8 +555,12 @@ proc do_mp3 {ts} {
endop
}
proc entries {dir callback} {
proc entries {dir callback {flag ""}} {
foreach entry [readdir -nocomplain $dir] {
if {$flag ne "" && ![file exists $flag]} {
log "Flag $flag disappeared mid-run, aborting." 0
break
}
if {![string match {*.ts} $entry]} continue
if {[catch {set ts [ts fetch "$dir/$entry"]}]} continue
if {$ts == 0} continue
@ -565,27 +568,27 @@ proc entries {dir callback} {
}
}
proc shrink {dir} {
proc shrink {dir {flag ""}} {
log "SHRINK: \[$dir]" 2
entries $dir do_shrink
entries $dir do_shrink $flag
}
proc decrypt {dir} {
proc decrypt {dir {flag ""}} {
log "DECRYPT: \[$dir]" 2
if {$::dlnaok} { entries $dir do_decrypt }
if {$::dlnaok} { entries $dir do_decrypt $flag }
}
proc mpg {dir} {
proc mpg {dir {flag ""}} {
log "MPG: \[$dir]" 2
entries $dir do_mpg
entries $dir do_mpg $flag
}
proc mp3 {dir} {
proc mp3 {dir {flag ""}} {
log "MP3: \[$dir]" 2
entries $dir do_mp3
entries $dir do_mp3 $flag
}
proc expire {dir} {
proc expire {dir {flag ""}} {
log "EXPIRE: \[$dir]" 2
# type 0 keep {} days 2 keepnew 0
@ -675,7 +678,7 @@ proc scan_run {dir flag callback} {
}
}
proc xscan {dir attr {force 0} {recurse 1}} {{indent 0}} {
proc xscan {dir attr {force 0} {recurse 1}} {{indent 0} {forceflag ""}} {
global dustbin
incr indent 2
@ -698,6 +701,7 @@ proc xscan {dir attr {force 0} {recurse 1}} {{indent 0}} {
}
if {$force} {
set force 0
set forceflag ""
log "Special folder, overriding recursion." 2
}
}
@ -706,11 +710,16 @@ proc xscan {dir attr {force 0} {recurse 1}} {{indent 0}} {
if {!$force && [file exists "$dir/.auto${attr}r"]} {
log "[string repeat " " $indent] (R)" 2
set force 1
set forceflag "$dir/.auto${attr}r"
}
dsc
if {$force || [file exists "$dir/.auto$attr"]} { $attr $dir }
if {$force} {
$attr $dir $forceflag
} elseif {[file exists "$dir/.auto$attr"]} {
$attr $dir "$dir/.auto$attr"
}
foreach entry [readdir -nocomplain $dir] {
if {$recurse && [file isdirectory "$dir/$entry"]} {