]>
git.proxmox.com Git - sencha-touch.git/blob - src/src/draw/sprite/Circle.js
2 * @class Ext.draw.sprite.Circle
3 * @extends Ext.draw.sprite.Path
5 * A sprite that represents a circle.
7 * @example preview miniphone
8 * new Ext.draw.Component({
20 Ext
.define("Ext.draw.sprite.Circle", {
21 extend
: "Ext.draw.sprite.Path",
22 alias
: 'sprite.circle',
28 * @cfg {Number} [cx=0] The center coordinate of the sprite on the x-axis.
33 * @cfg {Number} [cy=0] The center coordinate of the sprite on the y-axis.
38 * @cfg {Number} [r=0] The radius of the sprite.
62 updatePlainBBox: function (plain
) {
73 updateTransformedBBox: function (transform
) {
79 scalesX
= matrix
.getScaleX(),
80 scalesY
= matrix
.getScaleY(),
84 transform
.x
= matrix
.x(cx
, cy
) - w
;
85 transform
.y
= matrix
.y(cx
, cy
) - h
;
86 transform
.width
= w
+ w
;
87 transform
.height
= h
+ h
;
90 updatePath: function (path
, attr
) {
91 path
.arc(attr
.cx
, attr
.cy
, attr
.r
, 0, Math
.PI
* 2, false);