重写图线显示
This commit is contained in:
@@ -484,6 +484,8 @@ void MAVLinkInspector::updateField(mavlink_message_t* msg, const mavlink_message
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
|
||||
uint8_t* m = (uint8_t*)&uasMessage->payload64[0];
|
||||
|
||||
switch (msgInfo->fields[fieldid].type)
|
||||
@@ -735,7 +737,7 @@ void MAVLinkInspector::updateField(mavlink_message_t* msg, const mavlink_message
|
||||
{
|
||||
if(scope)
|
||||
{
|
||||
scope->setSerieData(item->data(0,Qt::DisplayRole).toString(),item->data(1,Qt::DisplayRole));
|
||||
scope->setSerieData(QString::number(msg->sysid) + "." + item->data(0,Qt::DisplayRole).toString(),item->data(1,Qt::DisplayRole));
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -778,9 +780,15 @@ void MAVLinkInspector::on_treeWidget_itemChanged(QTreeWidgetItem *item, int colu
|
||||
{
|
||||
if(itemText.size() != -1)
|
||||
{
|
||||
//太频繁,可能会出问题
|
||||
if(scope)
|
||||
{
|
||||
scope->removeSerie(itemText);
|
||||
if(item->parent()->parent())
|
||||
{
|
||||
QString str = item->parent()->parent()->text(0);
|
||||
str = str.mid(str.indexOf(' ') + 1);
|
||||
scope->removeSerie(str + "." + item->data(0,Qt::DisplayRole).toString());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user