Mercurial > hg > thermostat-ng > agent
changeset 1732:20606d3afaaf
Do not allow negative ranges in host-memory charts
PR2346
Reviewed-by: omajid
Review-thread: http://icedtea.classpath.org/pipermail/thermostat/2015-May/013679.html
author | Jie Kang <jkang@redhat.com> |
---|---|
date | Fri, 15 May 2015 11:47:14 -0400 |
parents | ee6a994a4a12 |
children | c2f18f81f57a |
files | host-memory/client-swing/src/main/java/com/redhat/thermostat/host/memory/client/swing/internal/HostMemoryPanel.java |
diffstat | 1 files changed, 2 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/host-memory/client-swing/src/main/java/com/redhat/thermostat/host/memory/client/swing/internal/HostMemoryPanel.java Tue May 05 08:59:53 2015 -0400 +++ b/host-memory/client-swing/src/main/java/com/redhat/thermostat/host/memory/client/swing/internal/HostMemoryPanel.java Fri May 15 11:47:14 2015 -0400 @@ -58,6 +58,7 @@ import org.jfree.chart.JFreeChart; import org.jfree.chart.axis.NumberAxis; import org.jfree.chart.renderer.xy.XYItemRenderer; +import org.jfree.data.RangeType; import org.jfree.data.time.FixedMillisecond; import org.jfree.data.time.RegularTimePeriod; import org.jfree.data.time.TimeSeries; @@ -311,6 +312,7 @@ NumberAxis rangeAxis = (NumberAxis) chart.getXYPlot().getRangeAxis(); rangeAxis.setAutoRangeMinimumSize(100); + rangeAxis.setRangeType(RangeType.POSITIVE); return chart; }