Skip to content

Commit

Permalink
Fix bugs with tx
Browse files Browse the repository at this point in the history
  • Loading branch information
ClementTsang committed Mar 23, 2021
1 parent a48917f commit 3f9fa3e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/canvas/widgets/network_graph.rs
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ impl NetworkGraphWidget for Painter {
tx.iter().position(|(time, _data)| *time >= time_start),
tx.iter().rposition(|(time, _data)| *time <= 0.0),
) {
Some(&rx[tx_start..=tx_end])
Some(&tx[tx_start..=tx_end])
} else {
None
};
Expand Down
4 changes: 2 additions & 2 deletions src/data_conversion.rs
Original file line number Diff line number Diff line change
Expand Up @@ -511,7 +511,7 @@ pub fn convert_network_data_points(
}
} else {
let rx_display = format!(
"RX: {:<9} All: {:<9}",
"RX: {:<8} All: {}",
if network_use_binary_prefix {
format!("{:.1}{:3}", rx_converted_result.0, rx_converted_result.1)
} else {
Expand All @@ -530,7 +530,7 @@ pub fn convert_network_data_points(
}
);
let tx_display = format!(
"TX: {:<9} All: {:<9}",
"TX: {:<8} All: {}",
if network_use_binary_prefix {
format!("{:.1}{:3}", tx_converted_result.0, tx_converted_result.1)
} else {
Expand Down

0 comments on commit 3f9fa3e

Please sign in to comment.