Get /graphs.jsp looking a bit more presentable.

This commit is contained in:
z3d
2009-07-25 19:47:16 +00:00
parent 22744084dc
commit c5555350ae
6 changed files with 76 additions and 9 deletions

View File

@ -57,7 +57,7 @@ public class GraphHelper extends HelperBase {
}
if (hasTx && hasRx && !_showEvents) {
_out.write("<a href=\"viewstat.jsp?stat=bw.combined"
_out.write("<div class=\"graphspanel\"><a href=\"viewstat.jsp?stat=bw.combined"
+ "&amp;periodCount=" + (3 * _periodCount )
+ "&amp;width=" + (3 * _width)
+ "&amp;height=" + (3 * _height)
@ -83,7 +83,7 @@ public class GraphHelper extends HelperBase {
+ "&amp;width=" + (3 * _width)
+ "&amp;height=" + (3 * _height)
+ "\" />");
_out.write("<img border=\"0\" width=\""
_out.write("<img class=\"statimage\" border=\"0\" width=\""
+ (_width + 83) + "\" height=\"" + (_height + 92)
+ "\" src=\"viewstat.jsp?stat="
+ r.getRateStat().getName()
@ -105,7 +105,8 @@ public class GraphHelper extends HelperBase {
}
public String getForm() {
try {
_out.write("<p /><a href=\"configstats.jsp\">Select Stats to Graph</a><p />");
_out.write("<hr /><h3>Configure Graph Display</h3>");
_out.write("<p />[<a href=\"configstats.jsp\">Select Stats to Graph</a>]<p />");
_out.write("<form action=\"graphs.jsp\" method=\"GET\">");
_out.write("Periods: <input size=\"3\" type=\"text\" name=\"periodCount\" value=\"" + _periodCount + "\" /><br />\n");
_out.write("Plot averages: <input type=\"radio\" name=\"showEvents\" value=\"false\" " + (_showEvents ? "" : "checked=\"true\" ") + " /> ");
@ -113,8 +114,8 @@ public class GraphHelper extends HelperBase {
_out.write("Image sizes: width: <input size=\"4\" type=\"text\" name=\"width\" value=\"" + _width
+ "\" /> pixels, height: <input size=\"4\" type=\"text\" name=\"height\" value=\"" + _height
+ "\" /><br />\n");
_out.write("Refresh delay: <select name=\"refreshDelay\"><option value=\"60\">1 minute</option><option value=\"120\">2 minutes</option><option value=\"300\">5 minutes</option><option value=\"600\">10 minutes</option><option value=\"-1\">Never</option></select><br />\n");
_out.write("<input type=\"submit\" value=\"Redraw\" />");
_out.write("Refresh delay: <select name=\"refreshDelay\"><option value=\"60\">1 minute</option><option value=\"120\">2 minutes</option><option value=\"300\">5 minutes</option><option value=\"600\">10 minutes</option><option value=\"1800\">30 minutes</option><option value=\"3600\">1 hour</option><option value=\"-1\">Never</option></select><br />\n");
_out.write("<hr /><input type=\"submit\" value=\"Redraw\" /></div>");
} catch (IOException ioe) {
ioe.printStackTrace();
}

View File

@ -15,9 +15,7 @@
<jsp:setProperty name="graphHelper" property="contextId" value="<%=(String)session.getAttribute("i2p.contextId")%>" />
<jsp:setProperty name="graphHelper" property="writer" value="<%=out%>" />
<jsp:getProperty name="graphHelper" property="images" />
<div class="configure">
<jsp:getProperty name="graphHelper" property="form" />
</div>
</div>
</body>
</html>
</html>

View File

@ -1,3 +1,8 @@
2009-07-25 dr|z3d
* Enhance the layout of /graphs.jsp
* Fix some of the irks in I2PSnark UI.
* Ongoing tweaks and fiddles the the theme css. Not finished by any means!
2009-07-24 zzz
* Eepsite: Add Deutsch index page and css (thanks sperrbezirk!)
* Router: Support i2p.dir.base and i2p.dir.config passed in via properties

View File

@ -213,6 +213,37 @@ div.messages li {
border: 0px !important;
}
div.graphspanel {
padding: 15px 15px 15px 15px;
margin: 10px 0px;
background: #005;
-moz-border-radius: 4px;
-khtml-border-radius: 4px;
border-radius: 4px;
border: 1px solid #99f;
background: #003 url(images/darkbluebg.png);
-moz-box-shadow: inset 0px 0px 1px 0px #eef;
}
div.graphspanel img {
border: 1px solid #001;
padding: 3px;
margin: 5px;
text-align: center !important;
background: #002;
-moz-box-shadow: inset 0px 0px 1px 0px #eef;
opacity: 0.9;
}
div.graphspanel img:hover {
border: 1px solid #001;
padding: 3px;
margin: 5px;
text-align: center !important;
background: #002;
-moz-box-shadow: inset 0px 0px 1px 1px #f60;
opacity: 1;
}
table {
border-collapse: collapse;
width: 100%;

View File

@ -229,6 +229,38 @@ div.configure {
-moz-box-shadow: inset 0px 0px 1px 0px #002;
}
div.graphspanel {
padding: 12px;
margin: 10px 0px 25px 0;
background: #ddf url('images/lightbluetile.png');
-moz-border-radius: 4px;
-khtml-border-radius: 4px;
border-radius: 4px;
border: 1px solid #000022;
-moz-box-shadow: inset 0px 0px 1px 0px #002;
}
div.graphspanel img {
border: 1px solid #003;
padding: 2px;
margin: 6px;
text-align: center !important;
background: #001;
-moz-box-shadow: inset 0px 0px 1px 1px #99f;
opacity: 0.9;
}
div.graphspanel img:hover {
border: 1px solid #003;
padding: 2px;
margin: 6px;
text-align: center !important;
background: #001;
-moz-box-shadow: inset 0px 0px 2px 1px #f60;
opacity: 1;
}
div.messages {
padding: 10px;
margin: 10px 0 20px 0;

View File

@ -18,7 +18,7 @@ public class RouterVersion {
/** deprecated */
public final static String ID = "Monotone";
public final static String VERSION = CoreVersion.VERSION;
public final static long BUILD = 23;
public final static long BUILD = 25;
/** for example "-test" */
public final static String EXTRA = "-rc";
public final static String FULL_VERSION = VERSION + "-" + BUILD + EXTRA;