blob: 12a9da3a4a1505395267242a0b814f59f32ceaae (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
//>>built
define("dojox/gauges/AnalogCircleIndicator", ["dojo/_base/declare","./AnalogIndicatorBase"],
function(declare, AnalogIndicatorBase) {
/*=====
AnalogIndicatorBase = dojox.gauges.AnalogIndicatorBase;
=====*/
return declare("dojox.gauges.AnalogCircleIndicator", [AnalogIndicatorBase], {
// summary:
// An indicator for the AnalogGauge that draws a circle. The center of the circle is positioned
// on the circular gauge according to the value of the indicator. The circle has for radius the
// length of the indicator. This indicator is mainly used to draw round ticks for the scale.
_getShapes: function(group){
// summary:
// Override of dojox.gauges.AnalogLineIndicator._getShapes
var color = this.color ? this.color : 'black';
var strokeColor = this.strokeColor ? this.strokeColor : color;
var stroke = {
color: strokeColor,
width: 1
};
if (this.color.type && !this.strokeColor){
stroke.color = this.color.colors[0].color;
}
return [group.createCircle({
cx: 0,
cy: -this.offset,
r: this.length
}).setFill(color).setStroke(stroke)];
}
});
});
|