var DygraphOptions = function(dygraph) {
/**
* The dygraph.
- * @type {Dygraph}
+ * @type {!Dygraph}
*/
this.dygraph_ = dygraph;
* Not optimal, but does the trick when you're only using two axes.
* If we move to more axes, this can just become a function.
*
- * @type {Object.<string, number>}
+ * @type {Object.<number>}
* @private
*/
DygraphOptions.AXIS_STRING_MAPPINGS_ = {
}
// User-specified global options second.
- var result = this.getGlobalUser_(name);
- if (result !== null) {
- return result;
+ // But, hack, ignore globally-specified 'logscale' for 'x' axis declaration.
+ if (!(axis === 'x' && name === 'logscale')) {
+ var result = this.getGlobalUser_(name);
+ if (result !== null) {
+ return result;
+ }
}
-
// Default axis options third.
var defaultAxisOptions = Dygraph.DEFAULT_ATTRS.axes[axisString];
if (defaultAxisOptions.hasOwnProperty(name)) {
return this.labels_;
};
-/* Are we using this? */
-/**
- * Return the index of the specified series.
- * @param {string} series the series name.
- */
-DygraphOptions.prototype.indexOfSeries = function(series) {
- return this.series_[series].idx;
-};
-
return DygraphOptions;
})();