diff options
author | Mika Havela <mika.havela@gmail.com> | 2007-12-22 11:40:31 +0000 |
---|---|---|
committer | Mika Havela <mika.havela@gmail.com> | 2007-12-22 11:40:31 +0000 |
commit | 508d3b942ab47fa7d2fb065ca0737ebe839a6672 (patch) | |
tree | d12d20ae31351a7649a18f34bd35e6d8a9fa472a | |
parent | e0b7bd24427cdc3b98a35c2105063d42a05dbab7 (diff) | |
download | acf-alpine-baselayout-508d3b942ab47fa7d2fb065ca0737ebe839a6672.tar.bz2 acf-alpine-baselayout-508d3b942ab47fa7d2fb065ca0737ebe839a6672.tar.xz |
Hide label when label is too big for the bar
git-svn-id: svn://svn.alpinelinux.org/acf/alpine-baselayout/trunk@449 ab2d0c66-481e-0410-8bed-d214d4d58bed
-rw-r--r-- | health-storage-html.lsp | 4 | ||||
-rw-r--r-- | health-system-html.lsp | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/health-storage-html.lsp b/health-storage-html.lsp index 693822a..15830c3 100644 --- a/health-storage-html.lsp +++ b/health-storage-html.lsp @@ -10,7 +10,7 @@ <? if (view.storage.floppycapacity.used) then ?> <TABLE STYLE="margin:0px;padding:0px;border:0px"> <TR> - <TD>0%</TD><TD WIDTH="<?= view.storage.floppycapacity.used ?>%" STYLE="background:red;"><CENTER><?= view.storage.floppycapacity.used ?>%</CENTER></TD><TD WIDTH="<?= (100-view.storage.floppycapacity.used) ?>%" STYLE="background:green;"><CENTER><?= (100-view.storage.floppycapacity.used) ?>%</CENTER></TD><TD>100%</TD> + <TD>0%</TD><TD WIDTH="<?= view.storage.floppycapacity.used ?>%" STYLE="background:red;"><CENTER><? if ( tonumber(view.storage.floppycapacity.used) > 10) then io.write(view.storage.floppycapacity.used .. "%") end ?></CENTER></TD><TD WIDTH="<?= (100-view.storage.floppycapacity.used) ?>%" STYLE="background:green;"><CENTER><? if ( 90 > tonumber(view.storage.floppycapacity.used)) then io.write((100-view.storage.floppycapacity.used) .. "%") end ?></CENTER></TD><TD>100%</TD> </TR> </TABLE> <TABLE STYLE="margin:0px;padding:0px;border:0px"> @@ -26,7 +26,7 @@ <? if (view.storage.hdcapacity.used) then ?> <TABLE STYLE="margin:0px;padding:0px;border:0px"> <TR> - <TD>0%</TD><TD WIDTH="<?= view.storage.hdcapacity.used ?>%" STYLE="background:red;"><CENTER><?= view.storage.hdcapacity.used ?>%</CENTER></TD><TD WIDTH="<?= (100-view.storage.hdcapacity.used) ?>%" STYLE="background:green;"><CENTER><?= (100-view.storage.hdcapacity.used) ?>%</CENTER></TD><TD>100%</TD> + <TD>0%</TD><TD WIDTH="<?= view.storage.hdcapacity.used ?>%" STYLE="background:red;"><CENTER><? if ( tonumber(view.storage.hdcapacity.used) > 10) then io.write(view.storage.hdcapacity.used .. "%") end ?></CENTER></TD><TD WIDTH="<?= (100-view.storage.hdcapacity.used) ?>%" STYLE="background:green;"><CENTER><? if ( 90 > tonumber(view.storage.hdcapacity.used)) then io.write((100-view.storage.hdcapacity.used) .. "%") end ?></CENTER></TD><TD>100%</TD> </TR> </TABLE> <TABLE STYLE="margin:0px;padding:0px;border:0px"> diff --git a/health-system-html.lsp b/health-system-html.lsp index 62d366c..7cc9287 100644 --- a/health-system-html.lsp +++ b/health-system-html.lsp @@ -18,7 +18,7 @@ <TABLE STYLE="margin:0px;padding:0px;border:0px"> <TR> - <TD>0%</TD><TD WIDTH="<?= view.system.memory.used ?>%" STYLE="background:red;"><CENTER><?= view.system.memory.used ?>%</CENTER></TD><TD WIDTH="<?= (100-view.system.memory.used) ?>%" STYLE="background:green;"><CENTER><?= (100-view.system.memory.used) ?>%</CENTER></TD><TD>100%</TD> + <TD>0%</TD><TD WIDTH="<?= view.system.memory.used ?>%" STYLE="background:red;"><CENTER><? if ( tonumber(view.system.memory.used) > 10) then io.write(view.system.memory.used .. "%") end ?></CENTER></TD><TD WIDTH="<?= (100-view.system.memory.used) ?>%" STYLE="background:green;"><CENTER><? if ( 90 > tonumber(view.system.memory.used)) then io.write((100-view.system.memory.used) .. "%") end ?></CENTER></TD><TD>100%</TD> </TR> </TABLE> <TABLE STYLE="margin:0px;padding:0px;border:0px"> |