commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nico...@apache.org
Subject svn commit: r637955 - in /commons/sandbox/monitoring/trunk/src/main: java/org/apache/commons/monitoring/reporting/web/NiceHtmlRenderer.java resources/commons-monitoring.css
Date Mon, 17 Mar 2008 16:03:04 GMT
Author: nicolas
Date: Mon Mar 17 09:02:58 2008
New Revision: 637955

URL: http://svn.apache.org/viewvc?rev=637955&view=rev
Log:
fix unexpected columns when monitors hold heterogenous statvalues - CSS style

Modified:
    commons/sandbox/monitoring/trunk/src/main/java/org/apache/commons/monitoring/reporting/web/NiceHtmlRenderer.java
    commons/sandbox/monitoring/trunk/src/main/resources/commons-monitoring.css

Modified: commons/sandbox/monitoring/trunk/src/main/java/org/apache/commons/monitoring/reporting/web/NiceHtmlRenderer.java
URL: http://svn.apache.org/viewvc/commons/sandbox/monitoring/trunk/src/main/java/org/apache/commons/monitoring/reporting/web/NiceHtmlRenderer.java?rev=637955&r1=637954&r2=637955&view=diff
==============================================================================
--- commons/sandbox/monitoring/trunk/src/main/java/org/apache/commons/monitoring/reporting/web/NiceHtmlRenderer.java
(original)
+++ commons/sandbox/monitoring/trunk/src/main/java/org/apache/commons/monitoring/reporting/web/NiceHtmlRenderer.java
Mon Mar 17 09:02:58 2008
@@ -17,6 +17,8 @@
 
 package org.apache.commons.monitoring.reporting.web;
 
+import java.util.Map;
+
 import org.apache.commons.monitoring.Unit;
 import org.apache.commons.monitoring.reporting.Context;
 import org.apache.commons.monitoring.reporting.HtmlRenderer;
@@ -88,6 +90,16 @@
         }
         writer.println( "</head>" );
         writer.println( "<body>" );
+    }
+
+    @SuppressWarnings("unchecked")
+    @Override
+    protected void renderMissingValue( Context ctx, String role )
+    {
+        Map<String, Integer> columns = (Map<String, Integer>) ctx.get( "columns"
);
+        ctx.print( "<td class='not-applicable' colspan='" );
+        ctx.print( String.valueOf( columns.get( role ) ) );
+        ctx.print( "'>-</td>" );
     }
 
     @Override

Modified: commons/sandbox/monitoring/trunk/src/main/resources/commons-monitoring.css
URL: http://svn.apache.org/viewvc/commons/sandbox/monitoring/trunk/src/main/resources/commons-monitoring.css?rev=637955&r1=637954&r2=637955&view=diff
==============================================================================
--- commons/sandbox/monitoring/trunk/src/main/resources/commons-monitoring.css (original)
+++ commons/sandbox/monitoring/trunk/src/main/resources/commons-monitoring.css Mon Mar 17
09:02:58 2008
@@ -83,4 +83,9 @@
 
 tbody tr td {
     text-align: right;
+}
+
+td.not-applicable {
+    text-align: center;
+    background: #efefef;
 }



Mime
View raw message