Include state in port stats text copy to clipboard

The view uses an icon-only delegate for state to suppress the text
display
This commit is contained in:
Srivats P 2023-07-20 11:13:13 +05:30
parent fff61d7773
commit 1e8486991d

View File

@ -137,7 +137,10 @@ QVariant PortStatsModel::data(const QModelIndex &index, int role) const
// States
case e_COMBO_STATE:
return QVariant();
return QString("Link %1%2%3")
.arg(LinkStateName.at(stats.state().link_state()))
.arg(stats.state().is_transmit_on() ? ";Tx On" : "")
.arg(stats.state().is_capture_on() ? ";Cap On" : "");
// Statistics
case e_STAT_FRAMES_RCVD: