On Thu, Sep 18, 2014 at 9:07 AM, Alex Harui <[email protected]> wrote:
> BTW, I was thinking about this some moreŠ > > I haven't looked at your code, but are GraphicShapes actually allowed to > be children of any container? Or do they have to be children of a > GraphicsContainer? If the latter, then they shouldn't implement IUIBase > and the developer may have to first place a GraphicsContainer in the DOM > to contain them. > > The plan is to support both. GraphicShape is the base class for individual shapes like Rect, Ellipse, etc. It is also the base class for GraphicsContainer which exposes methods like drawRect, drawEllipse, etc. In the former case, Rects can be directly added to a container. In the latter case, GraphicsContainer can be added to a container. Thanks, Om > -Alex > > On 9/18/14 6:29 AM, "Alex Harui" <[email protected]> wrote: > > > > > > >On 9/17/14 10:50 PM, "OmPrakash Muppirala" <[email protected]> wrote: > > > >>On Wed, Sep 17, 2014 at 9:58 PM, Alex Harui <[email protected]> wrote: > >> > >>> You sure you won't need more of IUIBase like x,y,w,h? > >>> > >>> > >>On the AS side, flash.display.Shape would have those properties. On the > >>HTML/JS side, the x,y,w,h are part of the shape's description drawn in > >>the > >>parent SVG's co-ordinate space. > >>There might be scenarios where we'll need x,y,w,h. > >> > >>What is the lightest implementation of IUIBase that I can use? > >Create your own base class that extends IUIBase. > > > >> I am trying > >>to avoid extending UIBase. Or, am I worrying too much about how heavy it > >>is? > >Well, UIBase is likely to be in every app. Currently it is about 80 bytes > >per instance on top of its base class. On the AS side, that is Sprite. > >The question is: is it running code you don't need? I would think on the > >AS-side, you don't need Sprite under the hood. > > > >-Alex > > > >
