mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-17 21:46:17 +00:00
Do not save bearing to XML if it has not changed
Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
This commit is contained in:
parent
9576a9ba8a
commit
643085f992
1 changed files with 4 additions and 1 deletions
|
@ -283,7 +283,10 @@ static void save_sample(struct membuffer *b, struct sample *sample, struct sampl
|
|||
old->setpoint = sample->setpoint;
|
||||
}
|
||||
show_index(b, sample->heartbeat, "heartbeat='", "'");
|
||||
show_index(b, sample->bearing.degrees, "bearing='", "'");
|
||||
if (sample->bearing.degrees != old->bearing.degrees) {
|
||||
show_index(b, sample->bearing.degrees, "bearing='", "'");
|
||||
old->bearing.degrees = sample->bearing.degrees;
|
||||
}
|
||||
put_format(b, " />\n");
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue