Re: [royale-asjs] branch develop updated: improve IActivable to not rely on ids and use new activableName property

2018-12-29 Thread Carlos Rovira
Hi Alex,

El sáb., 29 dic. 2018 a las 8:22, Alex Harui ()
escribió:

> Hi,
>
> In the code you posted, I agree you don't need to change the name of the
> "name" parameter.  I am more interested in every place I see "IActivable"
> and isActive.  I haven't looked at the code in detail, but it sounds like
> you are working on something like a Navigator and IIRC, Flex Navigators
> "select" an INavigatorContent.  They don't "activate" it.
>

ok I grab that names from MDL, for that reason the "active" concept. I just
refactor to ISelectableContent, since I check INavigatorContent and I think
doesn't match exactly the navigators in Jewel. In Flex some navigators has
the content and selection (Accordion) but other not (ViewStack). In Jewel
all this components are just the content part, the component is decoupled.


>
> Also note that for MXML, we try to avoid methods wherever possible in
> favor of properties.  So instead of having a "selectedContent()" method,
> selectedContent would be better in MXML as a property so you can set it
> declaratively.
>

I refactor the "showContent()" to "selectedContent" property, and this
allow to remove the property from the specific content in MXML and set up
on the container that is more "flex" and more robust.

Let me know if you see something more

thanks!

Carlos



>
> My 2 cents,
> -Alex
>
> On 12/28/18, 10:45 AM, "Carlos Rovira"  wrote:
>
> Hi,
>
> while doing the refactor for "name" to "selectedContent", I saw that
> maybe
> the discussion is not having the real code into account.
>
> I think what we really want to change is the method in the components
> that
> are responsible to select the content, not the property "name" itself.
>
> In this case, we have in all this components is "showContent" method
> that
> maybe should be renamed to "selectedContent".
>
> Here's the code:
>
>
> /**
>  * shows a concrete content and hides the rest
>  *
>  * @param name, the name of the container to show
>  *
>  * @langversion 3.0
>  * @playerversion Flash 10.2
>  * @playerversion AIR 2.6
>  * @productversion Royale 0.9.4
>  */
> public function showContent(name:String):void
> {
> try
> {
> for (var i:int = 0; i < numElements; i++)
> {
> var content:IActivable = getElementAt(i) as
> IActivable;
>
> if(content.name == name)
> {
> content.isActive = true;
> }
> else
> {
> content.isActive = false;
> }
> }
> }
> catch (error:Error)
> {
> throw new Error ("One or more content in TabBarContent
> is
> not implementing IActivable interface.");
> }
> }
>
> Thoughts?
>
>
> El vie., 28 dic. 2018 a las 7:52, Alex Harui ( >)
> escribió:
>
> > I'm not sure I care what comes after "selected".  I was just trying
> to
> > point out that we already have precedent for using "selected" as
> > "one-of-many".
> >
> > -Alex
> >
> > On 12/27/18, 11:06 AM, "Carlos Rovira" 
> wrote:
> >
> > ok, so I what you propose is to change current "name" to
> > "selectedWhatever". I understand that we can't create
> "selectedIndex"
> > for
> > now since we are dealing with names and not with indexes. So
> this is
> > what I
> > guess for your suggestion:
> >
> > * ApplicationMainContent -> selectedContent or
> selectedMainContent
> > * TabBarContent -> selectedContent or selectedTabContent
> > * WizardContent -> selectedContent, selectedPage or
> selectedWizardPage
> >
> > it seems to me that "selectedContent" will be valid for all, to
> avoid
> > different API names and be more user friendly and seems as well
> it
> > conforms
> > to the concept of "navigation content only" of that components.
> >
> > what you (and others) prefer?
> >
> > Thanks
> >
> >
> > El jue., 27 dic. 2018 a las 18:34, Alex Harui
> > ()
> > escribió:
> >
> > > Hi Carlos,
> > >
> > > IMO, you don't have to have a dataProvider as a public API to
> also
> > offer
> > > selectedIndex/Item/Tab.  No refactoring is needed, just
> changing the
> > name.
> > >
> > > Flex Navigators used selectedIndex as will other Royale
> Navigators
> > and the
> > > Royale emulation components.
> > >
> > > "active" and "activation" have other meanings (active Window
> is the
> > window
> > > getting input).  I'm not even sure "

Re: [royale-asjs] branch develop updated: improve IActivable to not rely on ids and use new activableName property

2018-12-28 Thread Alex Harui
Hi,

In the code you posted, I agree you don't need to change the name of the "name" 
parameter.  I am more interested in every place I see "IActivable" and 
isActive.  I haven't looked at the code in detail, but it sounds like you are 
working on something like a Navigator and IIRC, Flex Navigators "select" an 
INavigatorContent.  They don't "activate" it.

Also note that for MXML, we try to avoid methods wherever possible in favor of 
properties.  So instead of having a "selectedContent()" method, selectedContent 
would be better in MXML as a property so you can set it declaratively.

My 2 cents,
-Alex

On 12/28/18, 10:45 AM, "Carlos Rovira"  wrote:

Hi,

while doing the refactor for "name" to "selectedContent", I saw that maybe
the discussion is not having the real code into account.

I think what we really want to change is the method in the components that
are responsible to select the content, not the property "name" itself.

In this case, we have in all this components is "showContent" method that
maybe should be renamed to "selectedContent".

Here's the code:


/**
 * shows a concrete content and hides the rest
 *
 * @param name, the name of the container to show
 *
 * @langversion 3.0
 * @playerversion Flash 10.2
 * @playerversion AIR 2.6
 * @productversion Royale 0.9.4
 */
public function showContent(name:String):void
{
try
{
for (var i:int = 0; i < numElements; i++)
{
var content:IActivable = getElementAt(i) as IActivable;

if(content.name == name)
{
content.isActive = true;
}
else
{
content.isActive = false;
}
}
}
catch (error:Error)
{
throw new Error ("One or more content in TabBarContent is
not implementing IActivable interface.");
}
}

Thoughts?


El vie., 28 dic. 2018 a las 7:52, Alex Harui ()
escribió:

> I'm not sure I care what comes after "selected".  I was just trying to
> point out that we already have precedent for using "selected" as
> "one-of-many".
>
> -Alex
>
> On 12/27/18, 11:06 AM, "Carlos Rovira"  wrote:
>
> ok, so I what you propose is to change current "name" to
> "selectedWhatever". I understand that we can't create "selectedIndex"
> for
> now since we are dealing with names and not with indexes. So this is
> what I
> guess for your suggestion:
>
> * ApplicationMainContent -> selectedContent or selectedMainContent
> * TabBarContent -> selectedContent or selectedTabContent
> * WizardContent -> selectedContent, selectedPage or selectedWizardPage
>
> it seems to me that "selectedContent" will be valid for all, to avoid
> different API names and be more user friendly and seems as well it
> conforms
> to the concept of "navigation content only" of that components.
>
> what you (and others) prefer?
>
> Thanks
>
>
> El jue., 27 dic. 2018 a las 18:34, Alex Harui
> ()
> escribió:
>
> > Hi Carlos,
> >
> > IMO, you don't have to have a dataProvider as a public API to also
> offer
> > selectedIndex/Item/Tab.  No refactoring is needed, just changing the
> name.
> >
> > Flex Navigators used selectedIndex as will other Royale Navigators
> and the
> > Royale emulation components.
> >
> > "active" and "activation" have other meanings (active Window is the
> window
> > getting input).  I'm not even sure "activable" is a word, my spell
> checker
> > doesn't like it.
> >
> > My 2 cents,
> > -Alex
> >
> > On 12/27/18, 1:22 AM, "Carlos Rovira" 
> wrote:
> >
> > Hi Alex,
> >
> > currently this components shows content based on the "name" of
> the
> > screen
> > (some days ago was "id" what I want to avoid due to id
> conflicts). They
> > don't have the concept of
> dataProvider/selectedItem/selectedIndex.
> > It could be refactor but don't have clear if we need this kind 
of
> > navigation components use the same paradigm like list component.
> In my
> > case
> > I didn't find the need while working with this, maybe others
> could
> > need it?
> >
> > The components in Jewel that are "navigation c

Re: [royale-asjs] branch develop updated: improve IActivable to not rely on ids and use new activableName property

2018-12-28 Thread Carlos Rovira
Hi,

while doing the refactor for "name" to "selectedContent", I saw that maybe
the discussion is not having the real code into account.

I think what we really want to change is the method in the components that
are responsible to select the content, not the property "name" itself.

In this case, we have in all this components is "showContent" method that
maybe should be renamed to "selectedContent".

Here's the code:


/**
 * shows a concrete content and hides the rest
 *
 * @param name, the name of the container to show
 *
 * @langversion 3.0
 * @playerversion Flash 10.2
 * @playerversion AIR 2.6
 * @productversion Royale 0.9.4
 */
public function showContent(name:String):void
{
try
{
for (var i:int = 0; i < numElements; i++)
{
var content:IActivable = getElementAt(i) as IActivable;

if(content.name == name)
{
content.isActive = true;
}
else
{
content.isActive = false;
}
}
}
catch (error:Error)
{
throw new Error ("One or more content in TabBarContent is
not implementing IActivable interface.");
}
}

Thoughts?


El vie., 28 dic. 2018 a las 7:52, Alex Harui ()
escribió:

> I'm not sure I care what comes after "selected".  I was just trying to
> point out that we already have precedent for using "selected" as
> "one-of-many".
>
> -Alex
>
> On 12/27/18, 11:06 AM, "Carlos Rovira"  wrote:
>
> ok, so I what you propose is to change current "name" to
> "selectedWhatever". I understand that we can't create "selectedIndex"
> for
> now since we are dealing with names and not with indexes. So this is
> what I
> guess for your suggestion:
>
> * ApplicationMainContent -> selectedContent or selectedMainContent
> * TabBarContent -> selectedContent or selectedTabContent
> * WizardContent -> selectedContent, selectedPage or selectedWizardPage
>
> it seems to me that "selectedContent" will be valid for all, to avoid
> different API names and be more user friendly and seems as well it
> conforms
> to the concept of "navigation content only" of that components.
>
> what you (and others) prefer?
>
> Thanks
>
>
> El jue., 27 dic. 2018 a las 18:34, Alex Harui
> ()
> escribió:
>
> > Hi Carlos,
> >
> > IMO, you don't have to have a dataProvider as a public API to also
> offer
> > selectedIndex/Item/Tab.  No refactoring is needed, just changing the
> name.
> >
> > Flex Navigators used selectedIndex as will other Royale Navigators
> and the
> > Royale emulation components.
> >
> > "active" and "activation" have other meanings (active Window is the
> window
> > getting input).  I'm not even sure "activable" is a word, my spell
> checker
> > doesn't like it.
> >
> > My 2 cents,
> > -Alex
> >
> > On 12/27/18, 1:22 AM, "Carlos Rovira" 
> wrote:
> >
> > Hi Alex,
> >
> > currently this components shows content based on the "name" of
> the
> > screen
> > (some days ago was "id" what I want to avoid due to id
> conflicts). They
> > don't have the concept of
> dataProvider/selectedItem/selectedIndex.
> > It could be refactor but don't have clear if we need this kind of
> > navigation components use the same paradigm like list component.
> In my
> > case
> > I didn't find the need while working with this, maybe others
> could
> > need it?
> >
> > The components in Jewel that are "navigation components" are:
> >
> > * ApplicationMainContent
> > * TabBarContent
> > * WizardContent
> >
> > As well we could create new versions based on dataProvider API so
> > people
> > can choose between both depending on their needs and that will
> be more
> > PAYG.
> >
> > In the other hand, those components are only the content part,
> and for
> > example we have TabBar that is the list of tab buttons (with
> > dataProvider
> > API) that can be used with a TabBarContent to navigate it, but
> the
> > former
> > delegates the selection (based on name property) to the latter.
> >
> > Thoughts?
> >
> >
> >
> >
> > El jue., 27 dic. 2018 a las 2:44, Alex Harui
> ( > >)
> > escribió:
> >
> > > I'm wondering what "active" or "activatable" means and how it
> is
> > different
> > > from selectedIndex/Item/Tab used elsewhere.
> > >
> > > -Alex
> > >
> > > On 12/26/18, 5:13 AM, "Harbs"  wrote:
> > >
> > > I’m fine with any of those suggestions. I don’t see

Re: [royale-asjs] branch develop updated: improve IActivable to not rely on ids and use new activableName property

2018-12-27 Thread Alex Harui
I'm not sure I care what comes after "selected".  I was just trying to point 
out that we already have precedent for using "selected" as "one-of-many".

-Alex

On 12/27/18, 11:06 AM, "Carlos Rovira"  wrote:

ok, so I what you propose is to change current "name" to
"selectedWhatever". I understand that we can't create "selectedIndex" for
now since we are dealing with names and not with indexes. So this is what I
guess for your suggestion:

* ApplicationMainContent -> selectedContent or selectedMainContent
* TabBarContent -> selectedContent or selectedTabContent
* WizardContent -> selectedContent, selectedPage or selectedWizardPage

it seems to me that "selectedContent" will be valid for all, to avoid
different API names and be more user friendly and seems as well it conforms
to the concept of "navigation content only" of that components.

what you (and others) prefer?

Thanks


El jue., 27 dic. 2018 a las 18:34, Alex Harui ()
escribió:

> Hi Carlos,
>
> IMO, you don't have to have a dataProvider as a public API to also offer
> selectedIndex/Item/Tab.  No refactoring is needed, just changing the name.
>
> Flex Navigators used selectedIndex as will other Royale Navigators and the
> Royale emulation components.
>
> "active" and "activation" have other meanings (active Window is the window
> getting input).  I'm not even sure "activable" is a word, my spell checker
> doesn't like it.
>
> My 2 cents,
> -Alex
>
> On 12/27/18, 1:22 AM, "Carlos Rovira"  wrote:
>
> Hi Alex,
>
> currently this components shows content based on the "name" of the
> screen
> (some days ago was "id" what I want to avoid due to id conflicts). 
They
> don't have the concept of dataProvider/selectedItem/selectedIndex.
> It could be refactor but don't have clear if we need this kind of
> navigation components use the same paradigm like list component. In my
> case
> I didn't find the need while working with this, maybe others could
> need it?
>
> The components in Jewel that are "navigation components" are:
>
> * ApplicationMainContent
> * TabBarContent
> * WizardContent
>
> As well we could create new versions based on dataProvider API so
> people
> can choose between both depending on their needs and that will be more
> PAYG.
>
> In the other hand, those components are only the content part, and for
> example we have TabBar that is the list of tab buttons (with
> dataProvider
> API) that can be used with a TabBarContent to navigate it, but the
> former
> delegates the selection (based on name property) to the latter.
>
> Thoughts?
>
>
>
>
> El jue., 27 dic. 2018 a las 2:44, Alex Harui 
( >)
> escribió:
>
> > I'm wondering what "active" or "activatable" means and how it is
> different
> > from selectedIndex/Item/Tab used elsewhere.
> >
> > -Alex
> >
> > On 12/26/18, 5:13 AM, "Harbs"  wrote:
> >
> > I’m fine with any of those suggestions. I don’t see why name
> can’t
> > work.
> >
> > I think anything is better than “activableName”… ;-)
> >
> > My $0.02,
> > Harbs
> >
> > > On Dec 26, 2018, at 1:10 PM, Carlos Rovira <
> > carlos.rov...@codeoscopic.com> wrote:
> > >
> > > Hi Harbs,
> > >
> > > until now I used "id" in html tag to switch between contents,
> but I
> > want to
> > > avoid "id" if possible for this reason this change.
> > > We only need some component property, so don't need to have
> "id"
> > suffix or
> > > prefix. I think it could be even "name", but maybe that's
> already
> > used and
> > > can create some conflict. We can change to "activeId" as well
> as you
> > > proposed, but we can even try some shorter one, maybe "nameId"
> if
> > "name is
> > > not available for this use?
> > >
> > >
> > >
> > > El mié., 26 dic. 2018 a las 11:08, Harbs (<
> harbs.li...@gmail.com>)
> > escribió:
> > >
> > >> “activableName” sounds kind of awkward. What about activeName
> > instead? Or
> > >> ActiveId? ActiveId seems the best fit considering it’s using
> the
> > element id
> > >> if I understand correctly.
> > >>
> > >>
> > >>> On Dec 26, 2018, at 11:50 AM, carlosrov...@apache.org wrote:
> > >>>
> > >>> This is an automated email from the ASF dua

Re: [royale-asjs] branch develop updated: improve IActivable to not rely on ids and use new activableName property

2018-12-27 Thread Carlos Rovira
ok, so I what you propose is to change current "name" to
"selectedWhatever". I understand that we can't create "selectedIndex" for
now since we are dealing with names and not with indexes. So this is what I
guess for your suggestion:

* ApplicationMainContent -> selectedContent or selectedMainContent
* TabBarContent -> selectedContent or selectedTabContent
* WizardContent -> selectedContent, selectedPage or selectedWizardPage

it seems to me that "selectedContent" will be valid for all, to avoid
different API names and be more user friendly and seems as well it conforms
to the concept of "navigation content only" of that components.

what you (and others) prefer?

Thanks


El jue., 27 dic. 2018 a las 18:34, Alex Harui ()
escribió:

> Hi Carlos,
>
> IMO, you don't have to have a dataProvider as a public API to also offer
> selectedIndex/Item/Tab.  No refactoring is needed, just changing the name.
>
> Flex Navigators used selectedIndex as will other Royale Navigators and the
> Royale emulation components.
>
> "active" and "activation" have other meanings (active Window is the window
> getting input).  I'm not even sure "activable" is a word, my spell checker
> doesn't like it.
>
> My 2 cents,
> -Alex
>
> On 12/27/18, 1:22 AM, "Carlos Rovira"  wrote:
>
> Hi Alex,
>
> currently this components shows content based on the "name" of the
> screen
> (some days ago was "id" what I want to avoid due to id conflicts). They
> don't have the concept of dataProvider/selectedItem/selectedIndex.
> It could be refactor but don't have clear if we need this kind of
> navigation components use the same paradigm like list component. In my
> case
> I didn't find the need while working with this, maybe others could
> need it?
>
> The components in Jewel that are "navigation components" are:
>
> * ApplicationMainContent
> * TabBarContent
> * WizardContent
>
> As well we could create new versions based on dataProvider API so
> people
> can choose between both depending on their needs and that will be more
> PAYG.
>
> In the other hand, those components are only the content part, and for
> example we have TabBar that is the list of tab buttons (with
> dataProvider
> API) that can be used with a TabBarContent to navigate it, but the
> former
> delegates the selection (based on name property) to the latter.
>
> Thoughts?
>
>
>
>
> El jue., 27 dic. 2018 a las 2:44, Alex Harui ( >)
> escribió:
>
> > I'm wondering what "active" or "activatable" means and how it is
> different
> > from selectedIndex/Item/Tab used elsewhere.
> >
> > -Alex
> >
> > On 12/26/18, 5:13 AM, "Harbs"  wrote:
> >
> > I’m fine with any of those suggestions. I don’t see why name
> can’t
> > work.
> >
> > I think anything is better than “activableName”… ;-)
> >
> > My $0.02,
> > Harbs
> >
> > > On Dec 26, 2018, at 1:10 PM, Carlos Rovira <
> > carlos.rov...@codeoscopic.com> wrote:
> > >
> > > Hi Harbs,
> > >
> > > until now I used "id" in html tag to switch between contents,
> but I
> > want to
> > > avoid "id" if possible for this reason this change.
> > > We only need some component property, so don't need to have
> "id"
> > suffix or
> > > prefix. I think it could be even "name", but maybe that's
> already
> > used and
> > > can create some conflict. We can change to "activeId" as well
> as you
> > > proposed, but we can even try some shorter one, maybe "nameId"
> if
> > "name is
> > > not available for this use?
> > >
> > >
> > >
> > > El mié., 26 dic. 2018 a las 11:08, Harbs (<
> harbs.li...@gmail.com>)
> > escribió:
> > >
> > >> “activableName” sounds kind of awkward. What about activeName
> > instead? Or
> > >> ActiveId? ActiveId seems the best fit considering it’s using
> the
> > element id
> > >> if I understand correctly.
> > >>
> > >>
> > >>> On Dec 26, 2018, at 11:50 AM, carlosrov...@apache.org wrote:
> > >>>
> > >>> This is an automated email from the ASF dual-hosted git
> repository.
> > >>>
> > >>> carlosrovira pushed a commit to branch develop
> > >>> in repository
> >
> https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgitbox.apache.org%2Frepos%2Fasf%2Froyale-asjs.git&data=02%7C01%7Caharui%40adobe.com%7C7136d39b0085415062a208d66bdcdca9%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636814993674111621&sdata=OQuSZwFm%2BjJn2UA%2FUgWXSaSzyHJ30a%2B4eDVs7PjLGRA%3D&reserved=0
> > >>>
> > >>>
> > >>> The following commit(s) were added to refs/heads/develop by
> this
> > push:
> > >>>new f47a24a  improve IActivable to not rely on ids and
> use new
> > >> activableName property
> > >>> f47a24a

Re: [royale-asjs] branch develop updated: improve IActivable to not rely on ids and use new activableName property

2018-12-27 Thread Alex Harui
Hi Carlos,

IMO, you don't have to have a dataProvider as a public API to also offer 
selectedIndex/Item/Tab.  No refactoring is needed, just changing the name.

Flex Navigators used selectedIndex as will other Royale Navigators and the 
Royale emulation components.

"active" and "activation" have other meanings (active Window is the window 
getting input).  I'm not even sure "activable" is a word, my spell checker 
doesn't like it.

My 2 cents,
-Alex

On 12/27/18, 1:22 AM, "Carlos Rovira"  wrote:

Hi Alex,

currently this components shows content based on the "name" of the screen
(some days ago was "id" what I want to avoid due to id conflicts). They
don't have the concept of dataProvider/selectedItem/selectedIndex.
It could be refactor but don't have clear if we need this kind of
navigation components use the same paradigm like list component. In my case
I didn't find the need while working with this, maybe others could need it?

The components in Jewel that are "navigation components" are:

* ApplicationMainContent
* TabBarContent
* WizardContent

As well we could create new versions based on dataProvider API so people
can choose between both depending on their needs and that will be more PAYG.

In the other hand, those components are only the content part, and for
example we have TabBar that is the list of tab buttons (with dataProvider
API) that can be used with a TabBarContent to navigate it, but the former
delegates the selection (based on name property) to the latter.

Thoughts?




El jue., 27 dic. 2018 a las 2:44, Alex Harui ()
escribió:

> I'm wondering what "active" or "activatable" means and how it is different
> from selectedIndex/Item/Tab used elsewhere.
>
> -Alex
>
> On 12/26/18, 5:13 AM, "Harbs"  wrote:
>
> I’m fine with any of those suggestions. I don’t see why name can’t
> work.
>
> I think anything is better than “activableName”… ;-)
>
> My $0.02,
> Harbs
>
> > On Dec 26, 2018, at 1:10 PM, Carlos Rovira <
> carlos.rov...@codeoscopic.com> wrote:
> >
> > Hi Harbs,
> >
> > until now I used "id" in html tag to switch between contents, but I
> want to
> > avoid "id" if possible for this reason this change.
> > We only need some component property, so don't need to have "id"
> suffix or
> > prefix. I think it could be even "name", but maybe that's already
> used and
> > can create some conflict. We can change to "activeId" as well as you
> > proposed, but we can even try some shorter one, maybe "nameId" if
> "name is
> > not available for this use?
> >
> >
> >
> > El mié., 26 dic. 2018 a las 11:08, Harbs ()
> escribió:
> >
> >> “activableName” sounds kind of awkward. What about activeName
> instead? Or
> >> ActiveId? ActiveId seems the best fit considering it’s using the
> element id
> >> if I understand correctly.
> >>
> >>
> >>> On Dec 26, 2018, at 11:50 AM, carlosrov...@apache.org wrote:
> >>>
> >>> This is an automated email from the ASF dual-hosted git 
repository.
> >>>
> >>> carlosrovira pushed a commit to branch develop
> >>> in repository
> 
https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgitbox.apache.org%2Frepos%2Fasf%2Froyale-asjs.git&data=02%7C01%7Caharui%40adobe.com%7C7136d39b0085415062a208d66bdcdca9%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636814993674111621&sdata=OQuSZwFm%2BjJn2UA%2FUgWXSaSzyHJ30a%2B4eDVs7PjLGRA%3D&reserved=0
> >>>
> >>>
> >>> The following commit(s) were added to refs/heads/develop by this
> push:
> >>>new f47a24a  improve IActivable to not rely on ids and use new
> >> activableName property
> >>> f47a24a is described below
> >>>
> >>> commit f47a24a6cade10a8da297f2f9cd86dc4632754e6
> >>> Author: Carlos Rovira 
> >>> AuthorDate: Wed Dec 26 10:50:21 2018 +0100
> >>>
> >>>   improve IActivable to not rely on ids and use new activableName
> >> property
> >>> ---
> >>> .../apache/royale/jewel/ApplicationMainContent.as  |  6 +++---
> >>> .../org/apache/royale/jewel/SectionContent.as  | 23
> >> ++
> >>> .../org/apache/royale/jewel/TabBarContent.as   |  6 +++---
> >>> .../org/apache/royale/jewel/WizardContent.as   |  6 +++---
> >>> .../royale/jewel/supportClasses/IActivable.as  | 11 
+++
> >>> 5 files changed, 43 insertions(+), 9 deletions(-)
> >>>
> >>> diff --git
> >>
> 
a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainCon

Re: [royale-asjs] branch develop updated: improve IActivable to not rely on ids and use new activableName property

2018-12-27 Thread Carlos Rovira
Hi Alex,

currently this components shows content based on the "name" of the screen
(some days ago was "id" what I want to avoid due to id conflicts). They
don't have the concept of dataProvider/selectedItem/selectedIndex.
It could be refactor but don't have clear if we need this kind of
navigation components use the same paradigm like list component. In my case
I didn't find the need while working with this, maybe others could need it?

The components in Jewel that are "navigation components" are:

* ApplicationMainContent
* TabBarContent
* WizardContent

As well we could create new versions based on dataProvider API so people
can choose between both depending on their needs and that will be more PAYG.

In the other hand, those components are only the content part, and for
example we have TabBar that is the list of tab buttons (with dataProvider
API) that can be used with a TabBarContent to navigate it, but the former
delegates the selection (based on name property) to the latter.

Thoughts?




El jue., 27 dic. 2018 a las 2:44, Alex Harui ()
escribió:

> I'm wondering what "active" or "activatable" means and how it is different
> from selectedIndex/Item/Tab used elsewhere.
>
> -Alex
>
> On 12/26/18, 5:13 AM, "Harbs"  wrote:
>
> I’m fine with any of those suggestions. I don’t see why name can’t
> work.
>
> I think anything is better than “activableName”… ;-)
>
> My $0.02,
> Harbs
>
> > On Dec 26, 2018, at 1:10 PM, Carlos Rovira <
> carlos.rov...@codeoscopic.com> wrote:
> >
> > Hi Harbs,
> >
> > until now I used "id" in html tag to switch between contents, but I
> want to
> > avoid "id" if possible for this reason this change.
> > We only need some component property, so don't need to have "id"
> suffix or
> > prefix. I think it could be even "name", but maybe that's already
> used and
> > can create some conflict. We can change to "activeId" as well as you
> > proposed, but we can even try some shorter one, maybe "nameId" if
> "name is
> > not available for this use?
> >
> >
> >
> > El mié., 26 dic. 2018 a las 11:08, Harbs ()
> escribió:
> >
> >> “activableName” sounds kind of awkward. What about activeName
> instead? Or
> >> ActiveId? ActiveId seems the best fit considering it’s using the
> element id
> >> if I understand correctly.
> >>
> >>
> >>> On Dec 26, 2018, at 11:50 AM, carlosrov...@apache.org wrote:
> >>>
> >>> This is an automated email from the ASF dual-hosted git repository.
> >>>
> >>> carlosrovira pushed a commit to branch develop
> >>> in repository
> https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgitbox.apache.org%2Frepos%2Fasf%2Froyale-asjs.git&data=02%7C01%7Caharui%40adobe.com%7C5bb5d6e43fde477ee43e08d66b33f9c0%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636814268310528526&sdata=AAHJ0IgolSYQQD3tWRiimGvmyx6l9Fb%2FXsfJSZWV7rY%3D&reserved=0
> >>>
> >>>
> >>> The following commit(s) were added to refs/heads/develop by this
> push:
> >>>new f47a24a  improve IActivable to not rely on ids and use new
> >> activableName property
> >>> f47a24a is described below
> >>>
> >>> commit f47a24a6cade10a8da297f2f9cd86dc4632754e6
> >>> Author: Carlos Rovira 
> >>> AuthorDate: Wed Dec 26 10:50:21 2018 +0100
> >>>
> >>>   improve IActivable to not rely on ids and use new activableName
> >> property
> >>> ---
> >>> .../apache/royale/jewel/ApplicationMainContent.as  |  6 +++---
> >>> .../org/apache/royale/jewel/SectionContent.as  | 23
> >> ++
> >>> .../org/apache/royale/jewel/TabBarContent.as   |  6 +++---
> >>> .../org/apache/royale/jewel/WizardContent.as   |  6 +++---
> >>> .../royale/jewel/supportClasses/IActivable.as  | 11 +++
> >>> 5 files changed, 43 insertions(+), 9 deletions(-)
> >>>
> >>> diff --git
> >>
> a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainContent.as
> >>
> b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainContent.as
> >>> index 21c47a0..389c209 100644
> >>> ---
> >>
> a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainContent.as
> >>> +++
> >>
> b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainContent.as
> >>> @@ -85,14 +85,14 @@ package org.apache.royale.jewel
> >>>  /**
> >>>   *  shows a concrete content and hides the rest
> >>>   *
> >>> -  *  @param id, the id of the container to show
> >>> +  *  @param activableName, the activableName of the
> >> container to show
> >>>   *
> >>>   *  @langversion 3.0
> >>>   *  @playerversion Flash 10.2
> >>>   *  @playerversion AIR 2.6
> >>>

Re: [royale-asjs] branch develop updated: improve IActivable to not rely on ids and use new activableName property

2018-12-26 Thread Alex Harui
I'm wondering what "active" or "activatable" means and how it is different from 
selectedIndex/Item/Tab used elsewhere.

-Alex

On 12/26/18, 5:13 AM, "Harbs"  wrote:

I’m fine with any of those suggestions. I don’t see why name can’t work.

I think anything is better than “activableName”… ;-)

My $0.02,
Harbs

> On Dec 26, 2018, at 1:10 PM, Carlos Rovira 
 wrote:
> 
> Hi Harbs,
> 
> until now I used "id" in html tag to switch between contents, but I want 
to
> avoid "id" if possible for this reason this change.
> We only need some component property, so don't need to have "id" suffix or
> prefix. I think it could be even "name", but maybe that's already used and
> can create some conflict. We can change to "activeId" as well as you
> proposed, but we can even try some shorter one, maybe "nameId" if "name is
> not available for this use?
> 
> 
> 
> El mié., 26 dic. 2018 a las 11:08, Harbs () 
escribió:
> 
>> “activableName” sounds kind of awkward. What about activeName instead? Or
>> ActiveId? ActiveId seems the best fit considering it’s using the element 
id
>> if I understand correctly.
>> 
>> 
>>> On Dec 26, 2018, at 11:50 AM, carlosrov...@apache.org wrote:
>>> 
>>> This is an automated email from the ASF dual-hosted git repository.
>>> 
>>> carlosrovira pushed a commit to branch develop
>>> in repository 
https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgitbox.apache.org%2Frepos%2Fasf%2Froyale-asjs.git&data=02%7C01%7Caharui%40adobe.com%7C5bb5d6e43fde477ee43e08d66b33f9c0%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636814268310528526&sdata=AAHJ0IgolSYQQD3tWRiimGvmyx6l9Fb%2FXsfJSZWV7rY%3D&reserved=0
>>> 
>>> 
>>> The following commit(s) were added to refs/heads/develop by this push:
>>>new f47a24a  improve IActivable to not rely on ids and use new
>> activableName property
>>> f47a24a is described below
>>> 
>>> commit f47a24a6cade10a8da297f2f9cd86dc4632754e6
>>> Author: Carlos Rovira 
>>> AuthorDate: Wed Dec 26 10:50:21 2018 +0100
>>> 
>>>   improve IActivable to not rely on ids and use new activableName
>> property
>>> ---
>>> .../apache/royale/jewel/ApplicationMainContent.as  |  6 +++---
>>> .../org/apache/royale/jewel/SectionContent.as  | 23
>> ++
>>> .../org/apache/royale/jewel/TabBarContent.as   |  6 +++---
>>> .../org/apache/royale/jewel/WizardContent.as   |  6 +++---
>>> .../royale/jewel/supportClasses/IActivable.as  | 11 +++
>>> 5 files changed, 43 insertions(+), 9 deletions(-)
>>> 
>>> diff --git
>> 
a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainContent.as
>> 
b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainContent.as
>>> index 21c47a0..389c209 100644
>>> ---
>> 
a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainContent.as
>>> +++
>> 
b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainContent.as
>>> @@ -85,14 +85,14 @@ package org.apache.royale.jewel
>>>  /**
>>>   *  shows a concrete content and hides the rest
>>>   *
>>> -  *  @param id, the id of the container to show
>>> +  *  @param activableName, the activableName of the
>> container to show
>>>   *
>>>   *  @langversion 3.0
>>>   *  @playerversion Flash 10.2
>>>   *  @playerversion AIR 2.6
>>>   *  @productversion Royale 0.9.4
>>>   */
>>> -public function showContent(id:String):void
>>> +public function showContent(activableName:String):void
>>>{
>>>  try
>>>  {
>>> @@ -100,7 +100,7 @@ package org.apache.royale.jewel
>>>  {
>>>  var content:IActivable =
>> getElementAt(i) as IActivable;
>>> 
>>> - if(content.id == id)
>>> + if(content.activableName ==
>> activableName)
>>>  {
>>>  content.isActive = true;
>>>  }
>>> diff --git
>> 
a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/SectionContent.as
>> 
b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/SectionContent.as
>>> index 056514e..515320e 100644
>>> ---
>> 
a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/SectionContent.as
>>> +++
>> 
b/frameworks/projects/Jewel/src/main/royale/org/apache/royal

Re: [royale-asjs] branch develop updated: improve IActivable to not rely on ids and use new activableName property

2018-12-26 Thread Carlos Rovira
finally rename to "name", the problem is that since it comes from SWF, it
needs to be override in SectionContent.as, to conform to IActivable
interface for SWF and be declare in JS since doesn't exits for that target.

El mié., 26 dic. 2018 a las 14:13, Harbs () escribió:

> I’m fine with any of those suggestions. I don’t see why name can’t work.
>
> I think anything is better than “activableName”… ;-)
>
> My $0.02,
> Harbs
>
> > On Dec 26, 2018, at 1:10 PM, Carlos Rovira <
> carlos.rov...@codeoscopic.com> wrote:
> >
> > Hi Harbs,
> >
> > until now I used "id" in html tag to switch between contents, but I want
> to
> > avoid "id" if possible for this reason this change.
> > We only need some component property, so don't need to have "id" suffix
> or
> > prefix. I think it could be even "name", but maybe that's already used
> and
> > can create some conflict. We can change to "activeId" as well as you
> > proposed, but we can even try some shorter one, maybe "nameId" if "name
> is
> > not available for this use?
> >
> >
> >
> > El mié., 26 dic. 2018 a las 11:08, Harbs ()
> escribió:
> >
> >> “activableName” sounds kind of awkward. What about activeName instead?
> Or
> >> ActiveId? ActiveId seems the best fit considering it’s using the
> element id
> >> if I understand correctly.
> >>
> >>
> >>> On Dec 26, 2018, at 11:50 AM, carlosrov...@apache.org wrote:
> >>>
> >>> This is an automated email from the ASF dual-hosted git repository.
> >>>
> >>> carlosrovira pushed a commit to branch develop
> >>> in repository https://gitbox.apache.org/repos/asf/royale-asjs.git
> >>>
> >>>
> >>> The following commit(s) were added to refs/heads/develop by this push:
> >>>new f47a24a  improve IActivable to not rely on ids and use new
> >> activableName property
> >>> f47a24a is described below
> >>>
> >>> commit f47a24a6cade10a8da297f2f9cd86dc4632754e6
> >>> Author: Carlos Rovira 
> >>> AuthorDate: Wed Dec 26 10:50:21 2018 +0100
> >>>
> >>>   improve IActivable to not rely on ids and use new activableName
> >> property
> >>> ---
> >>> .../apache/royale/jewel/ApplicationMainContent.as  |  6 +++---
> >>> .../org/apache/royale/jewel/SectionContent.as  | 23
> >> ++
> >>> .../org/apache/royale/jewel/TabBarContent.as   |  6 +++---
> >>> .../org/apache/royale/jewel/WizardContent.as   |  6 +++---
> >>> .../royale/jewel/supportClasses/IActivable.as  | 11 +++
> >>> 5 files changed, 43 insertions(+), 9 deletions(-)
> >>>
> >>> diff --git
> >>
> a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainContent.as
> >>
> b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainContent.as
> >>> index 21c47a0..389c209 100644
> >>> ---
> >>
> a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainContent.as
> >>> +++
> >>
> b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainContent.as
> >>> @@ -85,14 +85,14 @@ package org.apache.royale.jewel
> >>>  /**
> >>>   *  shows a concrete content and hides the rest
> >>>   *
> >>> -  *  @param id, the id of the container to show
> >>> +  *  @param activableName, the activableName of the
> >> container to show
> >>>   *
> >>>   *  @langversion 3.0
> >>>   *  @playerversion Flash 10.2
> >>>   *  @playerversion AIR 2.6
> >>>   *  @productversion Royale 0.9.4
> >>>   */
> >>> -public function showContent(id:String):void
> >>> +public function showContent(activableName:String):void
> >>>{
> >>>  try
> >>>  {
> >>> @@ -100,7 +100,7 @@ package org.apache.royale.jewel
> >>>  {
> >>>  var content:IActivable =
> >> getElementAt(i) as IActivable;
> >>>
> >>> - if(content.id == id)
> >>> + if(content.activableName ==
> >> activableName)
> >>>  {
> >>>  content.isActive = true;
> >>>  }
> >>> diff --git
> >>
> a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/SectionContent.as
> >>
> b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/SectionContent.as
> >>> index 056514e..515320e 100644
> >>> ---
> >>
> a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/SectionContent.as
> >>> +++
> >>
> b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/SectionContent.as
> >>> @@ -87,5 +87,28 @@ package org.apache.royale.jewel
> >>>toggleClass("is-active", _isActive);
> >>>}
> >>>  }
> >>> +
> >>> + private var _activableName:String;
> >>> +
> >>> +/**
> >>> + *  activableName is the name od this ac

Re: [royale-asjs] branch develop updated: improve IActivable to not rely on ids and use new activableName property

2018-12-26 Thread Harbs
I’m fine with any of those suggestions. I don’t see why name can’t work.

I think anything is better than “activableName”… ;-)

My $0.02,
Harbs

> On Dec 26, 2018, at 1:10 PM, Carlos Rovira  
> wrote:
> 
> Hi Harbs,
> 
> until now I used "id" in html tag to switch between contents, but I want to
> avoid "id" if possible for this reason this change.
> We only need some component property, so don't need to have "id" suffix or
> prefix. I think it could be even "name", but maybe that's already used and
> can create some conflict. We can change to "activeId" as well as you
> proposed, but we can even try some shorter one, maybe "nameId" if "name is
> not available for this use?
> 
> 
> 
> El mié., 26 dic. 2018 a las 11:08, Harbs () escribió:
> 
>> “activableName” sounds kind of awkward. What about activeName instead? Or
>> ActiveId? ActiveId seems the best fit considering it’s using the element id
>> if I understand correctly.
>> 
>> 
>>> On Dec 26, 2018, at 11:50 AM, carlosrov...@apache.org wrote:
>>> 
>>> This is an automated email from the ASF dual-hosted git repository.
>>> 
>>> carlosrovira pushed a commit to branch develop
>>> in repository https://gitbox.apache.org/repos/asf/royale-asjs.git
>>> 
>>> 
>>> The following commit(s) were added to refs/heads/develop by this push:
>>>new f47a24a  improve IActivable to not rely on ids and use new
>> activableName property
>>> f47a24a is described below
>>> 
>>> commit f47a24a6cade10a8da297f2f9cd86dc4632754e6
>>> Author: Carlos Rovira 
>>> AuthorDate: Wed Dec 26 10:50:21 2018 +0100
>>> 
>>>   improve IActivable to not rely on ids and use new activableName
>> property
>>> ---
>>> .../apache/royale/jewel/ApplicationMainContent.as  |  6 +++---
>>> .../org/apache/royale/jewel/SectionContent.as  | 23
>> ++
>>> .../org/apache/royale/jewel/TabBarContent.as   |  6 +++---
>>> .../org/apache/royale/jewel/WizardContent.as   |  6 +++---
>>> .../royale/jewel/supportClasses/IActivable.as  | 11 +++
>>> 5 files changed, 43 insertions(+), 9 deletions(-)
>>> 
>>> diff --git
>> a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainContent.as
>> b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainContent.as
>>> index 21c47a0..389c209 100644
>>> ---
>> a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainContent.as
>>> +++
>> b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainContent.as
>>> @@ -85,14 +85,14 @@ package org.apache.royale.jewel
>>>  /**
>>>   *  shows a concrete content and hides the rest
>>>   *
>>> -  *  @param id, the id of the container to show
>>> +  *  @param activableName, the activableName of the
>> container to show
>>>   *
>>>   *  @langversion 3.0
>>>   *  @playerversion Flash 10.2
>>>   *  @playerversion AIR 2.6
>>>   *  @productversion Royale 0.9.4
>>>   */
>>> -public function showContent(id:String):void
>>> +public function showContent(activableName:String):void
>>>{
>>>  try
>>>  {
>>> @@ -100,7 +100,7 @@ package org.apache.royale.jewel
>>>  {
>>>  var content:IActivable =
>> getElementAt(i) as IActivable;
>>> 
>>> - if(content.id == id)
>>> + if(content.activableName ==
>> activableName)
>>>  {
>>>  content.isActive = true;
>>>  }
>>> diff --git
>> a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/SectionContent.as
>> b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/SectionContent.as
>>> index 056514e..515320e 100644
>>> ---
>> a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/SectionContent.as
>>> +++
>> b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/SectionContent.as
>>> @@ -87,5 +87,28 @@ package org.apache.royale.jewel
>>>toggleClass("is-active", _isActive);
>>>}
>>>  }
>>> +
>>> + private var _activableName:String;
>>> +
>>> +/**
>>> + *  activableName is the name od this activable content
>>> + *
>>> + *  @langversion 3.0
>>> + *  @playerversion Flash 10.2
>>> + *  @playerversion AIR 2.6
>>> + *  @productversion Royale 0.9.4
>>> + */
>>> + public function get activableName():String
>>> + {
>>> +return _activableName;
>>> + }
>>> +
>>> + public function set activableName(value:String):void
>>> + {
>>> +if (_activableName != value)
>>> +{
>>> +

Re: [royale-asjs] branch develop updated: improve IActivable to not rely on ids and use new activableName property

2018-12-26 Thread Carlos Rovira
Hi Harbs,

until now I used "id" in html tag to switch between contents, but I want to
avoid "id" if possible for this reason this change.
We only need some component property, so don't need to have "id" suffix or
prefix. I think it could be even "name", but maybe that's already used and
can create some conflict. We can change to "activeId" as well as you
proposed, but we can even try some shorter one, maybe "nameId" if "name is
not available for this use?



El mié., 26 dic. 2018 a las 11:08, Harbs () escribió:

> “activableName” sounds kind of awkward. What about activeName instead? Or
> ActiveId? ActiveId seems the best fit considering it’s using the element id
> if I understand correctly.
>
>
> > On Dec 26, 2018, at 11:50 AM, carlosrov...@apache.org wrote:
> >
> > This is an automated email from the ASF dual-hosted git repository.
> >
> > carlosrovira pushed a commit to branch develop
> > in repository https://gitbox.apache.org/repos/asf/royale-asjs.git
> >
> >
> > The following commit(s) were added to refs/heads/develop by this push:
> > new f47a24a  improve IActivable to not rely on ids and use new
> activableName property
> > f47a24a is described below
> >
> > commit f47a24a6cade10a8da297f2f9cd86dc4632754e6
> > Author: Carlos Rovira 
> > AuthorDate: Wed Dec 26 10:50:21 2018 +0100
> >
> >improve IActivable to not rely on ids and use new activableName
> property
> > ---
> > .../apache/royale/jewel/ApplicationMainContent.as  |  6 +++---
> > .../org/apache/royale/jewel/SectionContent.as  | 23
> ++
> > .../org/apache/royale/jewel/TabBarContent.as   |  6 +++---
> > .../org/apache/royale/jewel/WizardContent.as   |  6 +++---
> > .../royale/jewel/supportClasses/IActivable.as  | 11 +++
> > 5 files changed, 43 insertions(+), 9 deletions(-)
> >
> > diff --git
> a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainContent.as
> b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainContent.as
> > index 21c47a0..389c209 100644
> > ---
> a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainContent.as
> > +++
> b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainContent.as
> > @@ -85,14 +85,14 @@ package org.apache.royale.jewel
> >   /**
> >*  shows a concrete content and hides the rest
> >*
> > -  *  @param id, the id of the container to show
> > +  *  @param activableName, the activableName of the
> container to show
> >*
> >*  @langversion 3.0
> >*  @playerversion Flash 10.2
> >*  @playerversion AIR 2.6
> >*  @productversion Royale 0.9.4
> >*/
> > -public function showContent(id:String):void
> > +public function showContent(activableName:String):void
> > {
> >   try
> >   {
> > @@ -100,7 +100,7 @@ package org.apache.royale.jewel
> >   {
> >   var content:IActivable =
> getElementAt(i) as IActivable;
> >
> > - if(content.id == id)
> > + if(content.activableName ==
> activableName)
> >   {
> >   content.isActive = true;
> >   }
> > diff --git
> a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/SectionContent.as
> b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/SectionContent.as
> > index 056514e..515320e 100644
> > ---
> a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/SectionContent.as
> > +++
> b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/SectionContent.as
> > @@ -87,5 +87,28 @@ package org.apache.royale.jewel
> > toggleClass("is-active", _isActive);
> > }
> >   }
> > +
> > + private var _activableName:String;
> > +
> > +/**
> > + *  activableName is the name od this activable content
> > + *
> > + *  @langversion 3.0
> > + *  @playerversion Flash 10.2
> > + *  @playerversion AIR 2.6
> > + *  @productversion Royale 0.9.4
> > + */
> > + public function get activableName():String
> > + {
> > +return _activableName;
> > + }
> > +
> > + public function set activableName(value:String):void
> > + {
> > +if (_activableName != value)
> > +{
> > +_activableName = value;
> > +}
> > + }
> >   }
> > }
> > diff --git
> a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/TabBarContent.as
> b/frameworks/projects/Jewel/src/main/royale/org/apache

Re: [royale-asjs] branch develop updated: improve IActivable to not rely on ids and use new activableName property

2018-12-26 Thread Harbs
“activableName” sounds kind of awkward. What about activeName instead? Or 
ActiveId? ActiveId seems the best fit considering it’s using the element id if 
I understand correctly.


> On Dec 26, 2018, at 11:50 AM, carlosrov...@apache.org wrote:
> 
> This is an automated email from the ASF dual-hosted git repository.
> 
> carlosrovira pushed a commit to branch develop
> in repository https://gitbox.apache.org/repos/asf/royale-asjs.git
> 
> 
> The following commit(s) were added to refs/heads/develop by this push:
> new f47a24a  improve IActivable to not rely on ids and use new 
> activableName property
> f47a24a is described below
> 
> commit f47a24a6cade10a8da297f2f9cd86dc4632754e6
> Author: Carlos Rovira 
> AuthorDate: Wed Dec 26 10:50:21 2018 +0100
> 
>improve IActivable to not rely on ids and use new activableName property
> ---
> .../apache/royale/jewel/ApplicationMainContent.as  |  6 +++---
> .../org/apache/royale/jewel/SectionContent.as  | 23 ++
> .../org/apache/royale/jewel/TabBarContent.as   |  6 +++---
> .../org/apache/royale/jewel/WizardContent.as   |  6 +++---
> .../royale/jewel/supportClasses/IActivable.as  | 11 +++
> 5 files changed, 43 insertions(+), 9 deletions(-)
> 
> diff --git 
> a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainContent.as
>  
> b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainContent.as
> index 21c47a0..389c209 100644
> --- 
> a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainContent.as
> +++ 
> b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/ApplicationMainContent.as
> @@ -85,14 +85,14 @@ package org.apache.royale.jewel
>   /**
>*  shows a concrete content and hides the rest
>* 
> -  *  @param id, the id of the container to show
> +  *  @param activableName, the activableName of the container to 
> show
>*
>*  @langversion 3.0
>*  @playerversion Flash 10.2
>*  @playerversion AIR 2.6
>*  @productversion Royale 0.9.4
>*/
> -public function showContent(id:String):void
> +public function showContent(activableName:String):void
> {
>   try
>   {
> @@ -100,7 +100,7 @@ package org.apache.royale.jewel
>   {
>   var content:IActivable = 
> getElementAt(i) as IActivable;
>   
> - if(content.id == id)
> + if(content.activableName == 
> activableName)
>   {
>   content.isActive = true;
>   }
> diff --git 
> a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/SectionContent.as
>  
> b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/SectionContent.as
> index 056514e..515320e 100644
> --- 
> a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/SectionContent.as
> +++ 
> b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/SectionContent.as
> @@ -87,5 +87,28 @@ package org.apache.royale.jewel
> toggleClass("is-active", _isActive);
> }
>   }
> + 
> + private var _activableName:String;
> +
> +/**
> + *  activableName is the name od this activable content
> + *  
> + *  @langversion 3.0
> + *  @playerversion Flash 10.2
> + *  @playerversion AIR 2.6
> + *  @productversion Royale 0.9.4
> + */
> + public function get activableName():String
> + {
> +return _activableName;
> + }
> +
> + public function set activableName(value:String):void
> + {
> +if (_activableName != value)
> +{
> +_activableName = value;
> +}
> + }
>   }
> }
> diff --git 
> a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/TabBarContent.as
>  
> b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/TabBarContent.as
> index 7bd118e..91b95d1 100644
> --- 
> a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/TabBarContent.as
> +++ 
> b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/TabBarContent.as
> @@ -56,14 +56,14 @@ package org.apache.royale.jewel
>   /**
>*  shows a concrete content and hides the rest
>* 
> -  *  @param id, the id of the container to show
> +  *  @param name, the name of the container to show
>*
>*  @langversion 3.0
>*  @player