-function def_draw_one (def, data, series_array) /* {{{ */
-{
- var chart_series = new Object ();
-
- chart_series.type = 'line';
- chart_series.pointInterval = data.interval * 1000.0;
- chart_series.pointStart = data.first_value_time * 1000.0;
- chart_series.data = data.data;
- chart_series.lineWidth = 1;
- chart_series.shadow = false;
- chart_series.marker = { enabled: false };
-
- if (def.legend)
- chart_series.name = def.legend;
- else if (def.ds_name)
- chart_series.name = def.ds_name;
-
- if (def.area)
- chart_series.type = 'area';
-
- if (def.stack)
- chart_series.stacking = 'normal';
-
- if ((def.color) && (def.color != 'random'))
- chart_series.color = def.color;
-
- series_array.push (chart_series);
-} /* }}} function def_draw_one */
-
-function def_draw (def, data_list, series_array) /* {{{ */
-{
- var i;
-
- for (i = 0; i < data_list.length; i++)
- {
- if ((def.ds_name) && (def.ds_name != data_list[i].data_source))
- continue;
- if (!ident_matches (def.select, data_list[i].file))
- continue;
-
- def_draw_one (def, data_list[i], series_array);
- }
-} /* }}} function def_draw */
-