forked from I2P_Developers/i2p.i2p
explicit merge of 'daa35ac8b482063c4db4b6205ca5dacc045080a4'
and 'cde8ce662bee407206b7fea94beaa230f052f501'
This commit is contained in:
@@ -803,7 +803,7 @@ public class I2PSnarkServlet extends Default {
|
||||
ngettext("1 peer", "{0} peers", knownPeers);
|
||||
else if (isRunning && knownPeers > 0)
|
||||
statusString = "<img alt=\"\" border=\"0\" src=\"" + _imgPath + "nopeers.png\" ></td><td class=\"snarkTorrentStatus " + rowClass + "\">" + _("No Peers") +
|
||||
": 0 / " + knownPeers ;
|
||||
": 0" + thinsp(isDegraded) + knownPeers ;
|
||||
else if (isRunning)
|
||||
statusString = "<img alt=\"\" border=\"0\" src=\"" + _imgPath + "nopeers.png\" ></td><td class=\"snarkTorrentStatus " + rowClass + "\">" + _("No Peers");
|
||||
else
|
||||
|
@@ -267,7 +267,7 @@ public class SummaryBarRenderer {
|
||||
.append(":</b></td><td align=\"right\">");
|
||||
int active = _helper.getActivePeers();
|
||||
buf.append(active)
|
||||
.append(" / ")
|
||||
.append(SummaryHelper.THINSP)
|
||||
.append(Math.max(active, _helper.getActiveProfiles()))
|
||||
.append("</td></tr>\n" +
|
||||
|
||||
@@ -376,7 +376,7 @@ public class SummaryBarRenderer {
|
||||
.append(_("Used"))
|
||||
.append(":</b></td><td align=\"right\">")
|
||||
.append(_helper.getInboundTransferred())
|
||||
.append(" / ")
|
||||
.append(SummaryHelper.THINSP)
|
||||
.append(_helper.getOutboundTransferred())
|
||||
.append("</td></tr></table>\n" +
|
||||
|
||||
|
@@ -29,6 +29,11 @@ import net.i2p.stat.RateStat;
|
||||
* the summary sections on the router console.
|
||||
*/
|
||||
public class SummaryHelper extends HelperBase {
|
||||
|
||||
// Opera 10.63 doesn't have the char, TODO check UA
|
||||
//static final String THINSP = " / ";
|
||||
static final String THINSP = " / ";
|
||||
|
||||
/**
|
||||
* Retrieve the shortened 4 character ident for the router located within
|
||||
* the current JVM at the given context.
|
||||
@@ -321,7 +326,7 @@ public class SummaryHelper extends HelperBase {
|
||||
fmt = new DecimalFormat("#0.0");
|
||||
else
|
||||
fmt = new DecimalFormat("#0.00");
|
||||
return fmt.format(in) + " / " + fmt.format(out) + " " +
|
||||
return fmt.format(in) + THINSP + fmt.format(out) + " " +
|
||||
(mega ? 'M' : 'K');
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user