Thomas Vachuska

Forgot the icons... doh!

Change-Id: Ic0d7848ea857b9fa78f3399ab98651358da78e73
...@@ -25,7 +25,7 @@ import java.util.concurrent.Future; ...@@ -25,7 +25,7 @@ import java.util.concurrent.Future;
25 */ 25 */
26 public interface FlowRuleProvider extends Provider { 26 public interface FlowRuleProvider extends Provider {
27 27
28 - static final int POLL_INTERVAL = 1; 28 + static final int POLL_INTERVAL = 2;
29 29
30 /** 30 /**
31 * Instructs the provider to apply the specified flow rules to their 31 * Instructs the provider to apply the specified flow rules to their
......
...@@ -429,7 +429,7 @@ public abstract class TopologyViewMessages { ...@@ -429,7 +429,7 @@ public abstract class TopologyViewMessages {
429 String label = ""; 429 String label = "";
430 if (load.rate() > 0) { 430 if (load.rate() > 0) {
431 hasTraffic = true; 431 hasTraffic = true;
432 - label = load.toString(); 432 + label = load.latest() + " bytes";
433 } 433 }
434 labels.add(label); 434 labels.add(label);
435 } 435 }
......
...@@ -140,6 +140,7 @@ ...@@ -140,6 +140,7 @@
140 P: togglePorts, 140 P: togglePorts,
141 U: unpin, 141 U: unpin,
142 R: resetZoomPan, 142 R: resetZoomPan,
143 + H: toggleHover,
143 esc: handleEscape 144 esc: handleEscape
144 }; 145 };
145 146
...@@ -176,7 +177,7 @@ ...@@ -176,7 +177,7 @@
176 onosOrder = [], 177 onosOrder = [],
177 oiBox, 178 oiBox,
178 oiShowMaster = false, 179 oiShowMaster = false,
179 - 180 + hoverEnabled = false,
180 portLabelsOn = false; 181 portLabelsOn = false;
181 182
182 // D3 selections 183 // D3 selections
...@@ -310,6 +311,10 @@ ...@@ -310,6 +311,10 @@
310 }); 311 });
311 } 312 }
312 313
314 + function toggleHover(view) {
315 + hoverEnabled = !hoverEnabled;
316 + }
317 +
313 function togglePorts(view) { 318 function togglePorts(view) {
314 view.alert('togglePorts() callback') 319 view.alert('togglePorts() callback')
315 } 320 }
...@@ -1077,6 +1082,8 @@ ...@@ -1077,6 +1082,8 @@
1077 linkLabel = linkLabelG.selectAll('.linkLabel') 1082 linkLabel = linkLabelG.selectAll('.linkLabel')
1078 .data(data, function (d) { return d.id; }); 1083 .data(data, function (d) { return d.id; });
1079 1084
1085 + linkLabel.text(function (d) { return d.label; });
1086 +
1080 entering = linkLabel.enter().append('g') 1087 entering = linkLabel.enter().append('g')
1081 .classed('linkLabel', true) 1088 .classed('linkLabel', true)
1082 .attr('id', function (d) { return d.id; }); 1089 .attr('id', function (d) { return d.id; });
...@@ -1973,8 +1980,7 @@ ...@@ -1973,8 +1980,7 @@
1973 } 1980 }
1974 1981
1975 function trafficHover() { 1982 function trafficHover() {
1976 - return false; 1983 + return hoverEnabled;
1977 - //return showTrafficOnHover.classed('active');
1978 } 1984 }
1979 function toggleTrafficHover() { 1985 function toggleTrafficHover() {
1980 showTrafficOnHover.classed('active', !trafficHover()); 1986 showTrafficOnHover.classed('active', !trafficHover());
......