function GroveSlide(pin) {
this._pin = pin;
this._name = function () {
return 'GroveSlide(' + this._pin + ')';
};
this._bounds = function () {
return { x: -35, y: -15, width: 70, height: 30 };
};
this.value = function () {
return 0;
};
this._print = function (g, options) {
g.drawCircle(- 20, - 10, 1);
g.drawCircle(- 20, + 10, 1);
g.drawCircle(+ 20, - 10, 1);
g.drawCircle(+ 20, + 10, 1);
if (!options.print) {
g.drawRectangle(- 30, - 10, 60, 20);
g.drawCircle(- 20, - 10, 2);
g.drawCircle(- 20, + 10, 2);
g.drawCircle(+ 20, - 10, 2);
g.drawCircle(+ 20, + 10, 2);
g.drawText(this._name(), - 30, + 10);
}
};
}