update to 0.9.13
git-svn-id: file:///root/webif/svn/humax/pkg/src/webif/trunk@1100 2a923420-c742-0410-a762-8d5b09965624
This commit is contained in:
parent
39b3dee3e1
commit
24d26aee75
@ -1,7 +1,7 @@
|
||||
Package: webif
|
||||
Priority: optional
|
||||
Section: web
|
||||
Version: 0.9.12-7
|
||||
Version: 0.9.13
|
||||
Architecture: mipsel
|
||||
Maintainer: af123@hummypkg.org.uk
|
||||
Depends: webif-channelicons(>=1.0.2),mongoose(>=3.0-7),jim(>=0.73-1),jim-oo,jim-sqlite3(>=0.73),jim-cgi(>=0.5),service-control(>=1.2),busybox(>=1.19.3-1),lsof,epg(>=1.0.9),hmt(>=1.1.6),ssmtp,anacron,trm,openssl-command,nicesplice,id3v2,file,rsvsync(>=1.0.2),webif-charts(>=1.2),stripts(>=1.1.2)
|
||||
|
@ -91,6 +91,23 @@ if {$url ne ""} {
|
||||
<td><a href=\"$url\">$url</a></td>"
|
||||
}
|
||||
puts "
|
||||
</tr><tr>
|
||||
<th>Files</th>
|
||||
<td>
|
||||
"
|
||||
|
||||
set fileset [$ts fileset]
|
||||
puts -nonewline "<img id=xfileset class=va src=/img/tree/plusonly.png>"
|
||||
puts -nonewline "[llength $fileset] file"
|
||||
if {[llength $fileset] != 1} { puts -nonewline "s" }
|
||||
puts -nonewline " in set."
|
||||
puts "<div id=fileset class=hidden><ul>"
|
||||
foreach f $fileset {
|
||||
puts "<li>[file tail $f] ([pretty_size [file size $f]])</li>"
|
||||
}
|
||||
puts "</ul></div>"
|
||||
|
||||
puts "</td>
|
||||
</tr><tr>
|
||||
<th>Flags</th>
|
||||
<td>[$ts get flags]
|
||||
@ -101,6 +118,18 @@ if {[$ts get bookmarks]} {
|
||||
|
||||
puts "</tr>"
|
||||
puts "</table>"
|
||||
puts {
|
||||
<script type=text/javascript>
|
||||
$('#xfileset').click(function() {
|
||||
$('#fileset').slideToggle('slow', function() {
|
||||
if ($('#fileset').is(':visible'))
|
||||
$('#xfileset').attr('src', '/img/tree/minustop.png');
|
||||
else
|
||||
$('#xfileset').attr('src', '/img/tree/plusonly.png');
|
||||
});
|
||||
});
|
||||
</script>
|
||||
}
|
||||
exit
|
||||
}
|
||||
|
||||
|
BIN
var/mongoose/html/img/tree/minustop.png
Normal file
BIN
var/mongoose/html/img/tree/minustop.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 238 B |
BIN
var/mongoose/html/img/tree/plusonly.png
Normal file
BIN
var/mongoose/html/img/tree/plusonly.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 242 B |
60
var/mongoose/html/pkg/index.shtml
Normal file
60
var/mongoose/html/pkg/index.shtml
Normal file
@ -0,0 +1,60 @@
|
||||
<!--#include virtual="/lib/header.shtml" -->
|
||||
|
||||
<link href=style.css rel=stylesheet type=text/css />
|
||||
|
||||
<div class=va style="padding: 0 0 1em 0">
|
||||
<h1 style="display: inline" class=va>
|
||||
Package Management
|
||||
</h1>
|
||||
|
||||
<button class="hidden va" id=opkgupdate>
|
||||
Update package list from Internet
|
||||
</button>
|
||||
|
||||
<button class="hidden va" id=opkgupgradeall>
|
||||
Upgrade all packages
|
||||
</button>
|
||||
</div>
|
||||
|
||||
<div id=refreshing class="hidden shadowbox" style="margin: 1 0 1em 0">
|
||||
<div>
|
||||
<img border=0 src=/img/loading.gif>
|
||||
Refreshing...
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id=dialogue class=hidden style="align: center">
|
||||
<pre id=dresults></pre>
|
||||
<div id=dspinner>
|
||||
<img border=0 src=/img/loading.gif>
|
||||
Processing request...
|
||||
</div>
|
||||
<div class=hidden id=complete>
|
||||
<img border=0 src=/images/167_2_00_Check_W2_SUB.png>
|
||||
Operation complete.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script type=text/javascript src=/js/enadis.js></script>
|
||||
<script type=text/javascript src=/js/iajax.js></script>
|
||||
<script type=text/javascript src=script.js></script>
|
||||
|
||||
<div id=pkgtabs>
|
||||
<ul>
|
||||
<li>
|
||||
<a class=tablink href=pkg.jim?type=upgr>
|
||||
<span>Upgrades</span>
|
||||
</a>
|
||||
</li><li>
|
||||
<a class=tablink href=pkg.jim?type=inst>
|
||||
<span>Installed</span>
|
||||
</a>
|
||||
</li><li>
|
||||
<a class=tablink href=pkg.jim?type=avail>
|
||||
<span>Available</span>
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<!--#include virtual="/lib/footer.shtml" -->
|
@ -17,10 +17,15 @@ if {![dict exists $_cgi type]} { set _cgi(type) avail }
|
||||
|
||||
proc pkgrow {pkg} {
|
||||
set name [$pkg get name]
|
||||
altrow
|
||||
puts "
|
||||
<td nowrap>$name</td>
|
||||
"
|
||||
altrow "pkg=\"$name\""
|
||||
puts "<td nowrap>$name"
|
||||
if {$::type eq "inst"} {
|
||||
puts "<br><a href=# class=depends>
|
||||
<img class=va border=0
|
||||
src=/images/421_1_00_CH_Title_2R_Arrow.png height=14>
|
||||
<span class=\"va footnote\">Info</span></a>"
|
||||
}
|
||||
puts "</td>"
|
||||
|
||||
if {$::type eq "avail"} {
|
||||
puts "<td nowrap>[$pkg get latest]</td>"
|
||||
@ -46,7 +51,7 @@ proc pkgrow {pkg} {
|
||||
set type Remove
|
||||
}
|
||||
|
||||
puts "<td align=center><small><button id=\"[$pkg get name]\"
|
||||
puts "<td align=center><small><button id=\"$name\"
|
||||
action=[string tolower $type]
|
||||
class=\"va [string tolower $type]\">$type</button></small></td>"
|
||||
|
@ -1,63 +1,9 @@
|
||||
<!--#include virtual="/lib/header.shtml" -->
|
||||
|
||||
<style type=text/css>
|
||||
button.install
|
||||
{
|
||||
display: none;
|
||||
background-image: none;
|
||||
background: #ccff99;
|
||||
}
|
||||
button.remove
|
||||
{
|
||||
display: none;
|
||||
background-image: none;
|
||||
background: #ff6666;
|
||||
}
|
||||
button.upgrade
|
||||
{
|
||||
display: none;
|
||||
}
|
||||
</style>
|
||||
|
||||
<div class=va style="padding: 0 0 1em 0">
|
||||
<h1 style="display: inline" class=va>Package Management</h1>
|
||||
<small>
|
||||
<button class=va id=opkgupdate style="display: none">
|
||||
Update package list from Internet
|
||||
</button>
|
||||
<button class=va id=opkgupgradeall style="display: none">
|
||||
Upgrade all packages
|
||||
</button>
|
||||
</small>
|
||||
</div>
|
||||
|
||||
<div id=refreshing class=shadowbox
|
||||
style="display: none; margin: 1 0 1em 0">
|
||||
<div>
|
||||
<img border=0 src=/img/loading.gif>
|
||||
Refreshing...
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id=dialogue style="display: none; align: center">
|
||||
<pre id=dresults></pre>
|
||||
<div id=dspinner>
|
||||
<img border=0 src=/img/loading.gif>
|
||||
Processing request...
|
||||
</div>
|
||||
<div class=hidden id=complete>
|
||||
<img border=0 src=/images/167_2_00_Check_W2_SUB.png>
|
||||
Operation complete.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script type=text/javascript src=/js/iajax.js></script>
|
||||
<script type=text/javascript>
|
||||
|
||||
var opkg = '/cgi-bin/opkg.jim?cmd=';
|
||||
|
||||
$(document).ready(function() {
|
||||
|
||||
var busy = false;
|
||||
|
||||
$('#opkgupdate')
|
||||
.button()
|
||||
.click(function() { execopkg('update'); })
|
||||
@ -69,7 +15,22 @@ $(document).ready(function() {
|
||||
.fadeIn('slow');
|
||||
|
||||
$('#pkgtabs').tabs({
|
||||
load: setup_buttons,
|
||||
select: function() {
|
||||
if (busy)
|
||||
{
|
||||
alert('Please wait until the current ' +
|
||||
'operation completes.');
|
||||
return false;
|
||||
}
|
||||
busy = true;
|
||||
$('#pkgtabs')
|
||||
.tabs('option', 'disabled', [0,1,2]);
|
||||
},
|
||||
load: function() {
|
||||
busy = false;
|
||||
setup_buttons();
|
||||
$('#pkgtabs').tabs('option', 'disabled', []);
|
||||
},
|
||||
spinner: '<img border=0 src=/img/loading.gif> ' +
|
||||
'<em>Loading...</em>'
|
||||
});
|
||||
@ -83,9 +44,14 @@ $(document).ready(function() {
|
||||
buttons: { "Close":
|
||||
function() {$(this).dialog('close');}},
|
||||
close: function(e,u) {
|
||||
$('#refreshing').show('slow');
|
||||
$('#pkgtabs').hide('fast');
|
||||
window.location.reload(true);
|
||||
//$('#refreshing').show('slow');
|
||||
//$('#pkgtabs').hide('fast');
|
||||
//window.location.reload(true);
|
||||
var pkg = $('#dialogue').attr('pkg');
|
||||
$('tr[pkg="' + pkg + '"]')
|
||||
.disable()
|
||||
.find('button').removeClass('va');
|
||||
$('button.va').enable();
|
||||
}
|
||||
});
|
||||
|
||||
@ -106,14 +72,20 @@ $(document).ready(function() {
|
||||
}
|
||||
}
|
||||
|
||||
function execopkg(arg)
|
||||
function execopkg(arg, pkg)
|
||||
{
|
||||
$('button.va')
|
||||
.attr('disabled', true)
|
||||
.addClass('ui-state-disabled');
|
||||
if (busy)
|
||||
{
|
||||
alert('Please wait until the current ' +
|
||||
'operation completes.');
|
||||
return;
|
||||
}
|
||||
busy = true;
|
||||
$('button.va').disable();
|
||||
$('#dspinner').show();
|
||||
$('#complete').hide();
|
||||
$('#dresults').empty();
|
||||
$('#dialogue').attr('pkg', pkg);
|
||||
$dialog.dialog('open');
|
||||
|
||||
// $('#dresults').load(opkg + arg, function() {
|
||||
@ -133,6 +105,7 @@ $(document).ready(function() {
|
||||
alert(e);
|
||||
}
|
||||
});
|
||||
busy = false;
|
||||
}
|
||||
|
||||
function setup_buttons()
|
||||
@ -144,31 +117,19 @@ $(document).ready(function() {
|
||||
!confirm('Please confirm removal of the ' +
|
||||
$(this).attr('id') + ' package.'))
|
||||
return;
|
||||
|
||||
execopkg(encodeURIComponent($(this).attr('action') +
|
||||
' ' + $(this).attr('id')));
|
||||
' ' + $(this).attr('id')),
|
||||
$(this).closest('tr').attr('pkg'));
|
||||
}).fadeIn('slow');
|
||||
|
||||
$('a.depends').click(function(e) {
|
||||
e.preventDefault();
|
||||
var pkg = $(this).closest('tr').attr('pkg');
|
||||
execopkg(encodeURIComponent('whatdepends ' + pkg),
|
||||
false);
|
||||
});
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
<div id=pkgtabs>
|
||||
<ul>
|
||||
<li>
|
||||
<a href=/cgi-bin/pkg.jim?type=upgr>
|
||||
<span>Upgrades</span>
|
||||
</a>
|
||||
</li><li>
|
||||
<a href=/cgi-bin/pkg.jim?type=inst>
|
||||
<span>Installed</span>
|
||||
</a>
|
||||
</li><li>
|
||||
<a href=/cgi-bin/pkg.jim?type=avail>
|
||||
<span>Available</span>
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<!--#include virtual="/lib/footer.shtml" -->
|
16
var/mongoose/html/pkg/style.css
Normal file
16
var/mongoose/html/pkg/style.css
Normal file
@ -0,0 +1,16 @@
|
||||
button.install
|
||||
{
|
||||
display: none;
|
||||
background-image: none;
|
||||
background: #ccff99;
|
||||
}
|
||||
button.remove
|
||||
{
|
||||
display: none;
|
||||
background-image: none;
|
||||
background: #ff6666;
|
||||
}
|
||||
button.upgrade
|
||||
{
|
||||
display: none;
|
||||
}
|
@ -43,7 +43,7 @@ puts {</div><div style="clear: both; padding-top: 1em">}
|
||||
menuitem "Service Management" "/img/spanner.png" \
|
||||
/services.shtml 217 228
|
||||
menuitem "Package Management" "/img/packages.png" \
|
||||
/pkg.shtml 217 228
|
||||
/pkg/index.shtml 217 228
|
||||
menuitem "Settings" "/images/326_1_00_Menu_Settings.png" \
|
||||
/cgi-bin/settings.jim 217 228
|
||||
menuitem "Diagnostics" "/img/diagnostics.png" \
|
||||
|
@ -39,7 +39,7 @@ tb "/images/323_1_10_Menu_Video.png" "Browse" "/cgi-bin/browse.jim"
|
||||
tb "/images/321_1_00_Menu_CHList.png" "Schedule" "/sched/sched.jim"
|
||||
tb "/images/328_1_26_Menu_TV_Guide.png" "EPG" $epglink
|
||||
tb "/img/spanner.png" "Services" "/services.shtml"
|
||||
tb "/img/packages.png" "Packages" "/pkg.shtml"
|
||||
tb "/img/packages.png" "Packages" "/pkg/index.shtml"
|
||||
tb "/images/326_1_00_Menu_Settings.png" "Settings" "/cgi-bin/settings.jim"
|
||||
tb "/img/diagnostics.png" "Diag" "/diag/diag.jim"
|
||||
eval_plugins toolbar
|
||||
|
@ -52,7 +52,7 @@ proc do_shrink {ts} {
|
||||
|
||||
set file [file rootname [$ts get file]]
|
||||
if {[catch {
|
||||
set perc [exec /mod/bin/stripts -aq [escape $file]]
|
||||
set perc [exec /mod/bin/stripts -aq $file]
|
||||
} msg]} {
|
||||
puts " Error: $msg"
|
||||
return
|
||||
@ -71,7 +71,7 @@ proc do_shrink {ts} {
|
||||
puts " Estimate $perc% saving."
|
||||
puts " Shrinking..."
|
||||
if {[catch {
|
||||
puts [exec /mod/bin/stripts -q [escape $file] $tmp/shrunk]
|
||||
puts [exec /mod/bin/stripts -q $file $tmp/shrunk]
|
||||
} msg]} {
|
||||
puts "Error during shrink: $msg"
|
||||
return
|
||||
|
@ -157,6 +157,12 @@ ts method copy {dst} {
|
||||
return 1
|
||||
}
|
||||
|
||||
ts method fileset {} {
|
||||
set root [file rootname $file]
|
||||
regsub -all {([\\["$])} $root {\\\1} root
|
||||
return [glob -nocomplain "${root}.*"]
|
||||
}
|
||||
|
||||
ts method settitle {newtitle} {
|
||||
if {[string length newtitle] > 48} { return }
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user