- No longer need xIsEpochDate, so removed.
"type": "string",
"description": "The range selector mini plot fill color. This can be of the form \"#AABBCC\" or \"rgb(255,100,200)\" or \"yellow\". You can also specify null or \"\" to turn off fill."
},
- "xIsEpochDate": {
- "default": "false",
- "labels": ["CSV parsing"],
- "type": "boolean",
- "description": "When set the X axis is interpreted as Unix epoch date values."
- },
"animatedZooms": {
"default": "false",
"labels": ["Interactive Elements"],
// Shim layer with setTimeout fallback.
// From: http://paulirish.com/2011/requestanimationframe-for-smart-animating/
+// Should be called with the window context:
+// Dygraph.requestAnimFrame.call(window, function() {})
Dygraph.requestAnimFrame = (function(){
return window.requestAnimationFrame ||
window.webkitRequestAnimationFrame ||
(function loop() {
if (frameNumber >= maxFrames) return;
- Dygraph.requestAnimFrame(function() {
+ Dygraph.requestAnimFrame.call(window, function() {
// Determine which frame to draw based on the delay so far. Will skip
// frames if necessary.
var currentTime = new Date().getTime();
rangeSelectorPlotStrokeColor: "#808FAB",
rangeSelectorPlotFillColor: "#A7B1C4",
- xIsEpochDate: false,
-
// The ordering here ensures that central lines always appear above any
// fill bars/error bars.
plotter: [
}
}
- if (this.attr_("xIsEpochDate") || Dygraph.isDateLike(data[0][0])) {
+ if (Dygraph.isDateLike(data[0][0]) {
// Some intelligent defaults for a date x-axis.
this.attrs_.axes.x.valueFormatter = Dygraph.dateString_;
this.attrs_.axes.x.axisLabelFormatter = Dygraph.dateAxisFormatter;
this.attrs_.axes.x.ticker = Dygraph.dateTicker;
- if (this.attr_("xIsEpochDate")) {
- return data;
- }
-
// Assume they're all dates.
var parsedData = Dygraph.clone(data);
for (i = 0; i < data.length; i++) {