struct vehicle_priv *priv;
struct callback_list *cbl;
struct log *nmea_log, *gpx_log;
+ char *gpx_desc;
struct attr **attrs;
// cursor
if (ret)
return ret;
}
+ if (type == attr_log_gpx_desc) {
+ attr->u.str = this_->gpx_desc;
+ return 1;
+ }
return attr_generic_get_attr(this_->attrs, NULL, type, attr, iter);
}
int ret=1;
if (this_->meth.set_attr)
ret=this_->meth.set_attr(this_->priv, attr);
+ if (ret == 1 && attr->type == attr_log_gpx_desc) {
+ g_free(this_->gpx_desc);
+ this_->gpx_desc = attr->u.str;
+ }
if (ret == 1 && attr->type != attr_navit)
this_->attrs=attr_generic_set_attr(this_->attrs, attr);
return ret != 0;
g_free(timep);
}
}
+ if (this_->gpx_desc) {
+ logstr=g_strconcat_printf(logstr,"\t<desc>%s</desc>\n",this_->gpx_desc);
+ g_free(this_->gpx_desc);
+ this_->gpx_desc = NULL;
+ }
if (attr_types_contains_default(attr_types, attr_position_direction,0) && this_->meth.position_attr_get(this_->priv, attr_position_direction, &attr))
logstr=g_strconcat_printf(logstr,"\t<course>%.1f</course>\n",*attr.u.numd);
if (attr_types_contains_default(attr_types, attr_position_speed, 0) && this_->meth.position_attr_get(this_->priv, attr_position_speed, &attr))