Commit 3aec7ce0 authored by David Schnur's avatar David Schnur

Merge pull request #1221 from soenter/master

Improve the performance of large data processing
parents b36246bb 38f7a8c5
......@@ -67,12 +67,14 @@
var zoom = $("#zoom").attr("checked");
if (zoom) {
plot = $.plot(placeholder, data, $.extend(true, {}, options, {
xaxis: {
min: ranges.xaxis.from,
max: ranges.xaxis.to
}
}));
$.each(plot.getXAxes(), function(_, axis) {
var opts = axis.options;
opts.min = ranges.xaxis.from;
opts.max = ranges.xaxis.to;
});
plot.setupGrid();
plot.draw();
plot.clearSelection();
}
});
......
......@@ -92,13 +92,14 @@
$("#placeholder").bind("plotselected", function (event, ranges) {
// do the zooming
plot = $.plot("#placeholder", [d], $.extend(true, {}, options, {
xaxis: {
min: ranges.xaxis.from,
max: ranges.xaxis.to
}
}));
$.each(plot.getXAxes(), function(_, axis) {
var opts = axis.options;
opts.min = ranges.xaxis.from;
opts.max = ranges.xaxis.to;
});
plot.setupGrid();
plot.draw();
plot.clearSelection();
// don't fire event on the overview to prevent eternal loop
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment