Thanks Alex, that was partially my initial approach, I'm going to try to expose it as a style so I could define it using CSS so people wouldn't need to re-implement all the skins. As stated before, my goal is to preserve the current behavior as the default one.
On 18 July 2014 06:14, Alex Harui <aha...@adobe.com> wrote: > Yes, this is why FlexxJS has beads. Even simple things like > enable/disable can have different implementations. > > I took a quick look at SkinnableComponent. It looks like it might be > possible for the skin to detect the state change and override the > mouseEnabled/mouseChildren change then implement some other behavior. So > then the set of changes would be: > > 1) add flag disableUsesMouseEnabled to SkinnableComponent and change the > enabled setter to check that flag before setting mouseEnabled/mouseChildren > 2) make a new skin base class that sets that flag an implements mx > behavior. > > Then all skins that derive from that new base class will have the disabled > behavior you desire. > > Of course, I could be wrongŠ > > -Alex > > On 7/17/14 6:51 AM, "João Fernandes" <joaopedromartinsfernan...@gmail.com> > wrote: > > >On 17 July 2014 12:48, Tom Chiverton <t...@extravision.com> wrote: > > > >> On 17/07/14 12:43, DarkStone wrote: > >> > But after all, this is just my own opinion, others may disagree with > >>me. > >> I don't see any other way to achieve changes in behaviour in a base > >> class extended by some many other ones ? > >> > >> I suppose I'd just have an 'enable helper' I could call in my app that > >> would walk the display list and set children based on their parents. You > >> could hook it to the global 'add' event and it'd be automatic? > >> > > > >it won't work because if parent has mouseChildren = false, even if you set > >mouseEnabled on children, the app won't react. > >A helper won't be able to override the default behavior because the > >skinnableComponent behaviors always check "enabled" an prevent changing > >mouseEnabled/mouseChildren. > >Also, crawling the full displaylist clearly doesn't seem like the right > >way > >to do anything. > > > >-- > > > >João Fernandes > > -- João Fernandes