Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MAVLink Inspector, show all selected fields in the chart #12342

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/AnalyzeView/MAVLinkMessage.cc
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ void QGCMAVLinkMessage::update(const mavlink_message_t &message)
_count++;
_message = message;

if (_selected) {
if (_selected || _fieldSelected) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, interesting. Shouldn't this just be _fieldSelected? Since the message might be selected but that doesn't mean that a field is selected. Otherwise you end up doing a bunch of work in updateField every time you select a new top level message. Or am I reading the code wrong?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You're right, _selected is not needed. It's not a big overhead though because there's only one message selected at the time.

Do you want me to remove _selected from the if statement?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, you should remove it. Make the code clearer to others looking at it later.

// Don't update field info unless selected to reduce perf hit of message processing
_updateFields();
}
Expand Down
Loading