Re: Modular code (was: ComboBox Selection (was: combo box))

2012-04-10 Thread Bogdan DINU
Hi Erik, this was discussed in the past here on the list - you can check it here. Frédéric Thomas have started to put this into practice (for UIComponent) and the

Re: combo box

2012-04-10 Thread Cosma Colanicchia
Ok, in my (brand new) github at [1] I tried to reimplement the thing, refactoring the EmptyItemComboBox code into an IList implementation as suggested by Alex. I also quickly adapted the same simple test app that I attached to the stackoverflow response to see the class in action [2]. [1] https:

Re: Modular code (was: ComboBox Selection (was: combo box))

2012-04-10 Thread Jonathan Campos
Someone call Ben! (Reflex) On Apr 10, 2012 4:06 PM, "Erik Lundgren" wrote: > > 10 apr 2012 kl. 21.08 skrev Michael A. Labriola: > > > It could certainly be added, but I would like you to consider thinking > about it a different way. Rather than adding more heft to the base > component, we could a

Modular code (was: ComboBox Selection (was: combo box))

2012-04-10 Thread Erik Lundgren
10 apr 2012 kl. 21.08 skrev Michael A. Labriola: > It could certainly be added, but I would like you to consider thinking about > it a different way. Rather than adding more heft to the base component, we > could add another object that interacted with the ComboBox to facilitate that > selecti

Re: combo box

2012-04-10 Thread Cosma Colanicchia
@Alex didn't know that MX components received this kind of upgrades in the 4.x branch, I thought they were in "maintenance mode" (exluding the work on spark skins for halo). 2012/4/10 Cosma Colanicchia : > The EmptyItemComboBox class posted by David Coleman looks similar to > some code I posted y

Re: combo box

2012-04-10 Thread Cosma Colanicchia
The EmptyItemComboBox class posted by David Coleman looks similar to some code I posted years ago on StackOverflow [1]. I added some explanation and a snippet of code showing its usage there. I'm not particularly proud of this code, but didn't managed to find a better way. The behavior approach se

RE: ComboBox Selection (was: combo box)

2012-04-10 Thread David Coleman
I think that it would be beneficial to have them as native behaviors (if they are delicately and correctly implemented). > Subject: Re: ComboBox Selection (was: combo box) > From: archeme...@mac.com > Date: Tue, 10 Apr 2012 21:51:13 +0200 > To: flex-dev@incubator.apache.org > >

Re: ComboBox Selection (was: combo box)

2012-04-10 Thread Mick Powell
Hello All, I haven't spoken yet on this list although I have been receiving mail for a few months. I have been developing Flex applications for a number of years now (professionally), and I have found the pattern that Mike suggests to be something I have used time and again. I would argue that

Re: ComboBox Selection (was: combo box)

2012-04-10 Thread Dany Dhondt
Hi Mike, The behavior solution would be an acceptable solution. Whether the functionality should be implemented in the base component or higher up is up to the contributors with their level of expertise but the use case of setting a combobox' selected item by an arbitrary value id is very commo

Re: combo box

2012-04-10 Thread Alex Harui
On 4/10/12 12:17 PM, "Jeffry Houser" wrote: > I gave it a selectedValue property, a valueField property, and a > valueFunction property; similar--in concept--to how the selectedItem, > labelField, and labelFunction work. > > Really the code is just a layer of abstraction for a loop. If I

RE: ComboBox Selection (was: combo box)

2012-04-10 Thread Michael A. Labriola
>I think you are referring to the decorator pattern. It has pros and cons, as >do all architectural decisions. Personally I am more interested in the >what/result, not so much in the how/way. But it takes all sorts, right? Nope. It's not a decorator pattern. Yes this idea does have pros and cons

Re: ComboBox Selection (was: combo box)

2012-04-10 Thread John Cunliffe
I think you are referring to the decorator pattern. It has pros and cons, as do all architectural decisions. Personally I am more interested in the what/result, not so much in the how/way. But it takes all sorts, right? John Am 10.04.2012 21:08 schrieb "Michael A. Labriola" < labri...@digitalprima

Re: combo box

2012-04-10 Thread Jeffry Houser
On 4/10/2012 2:59 PM, Dany Dhondt wrote: Hi, Now there's a discussion about the comboBox, I'd like to address an issue. Sorry in advance if it had been addressed already. Using the component, one can set the selectedIndex or the selectedItem properties. There's no way to set a 'selectedValue'

ComboBox Selection (was: combo box)

2012-04-10 Thread Michael A. Labriola
>Is there a possibility to add this feature to ComboBox? Dany, It could certainly be added, but I would like you to consider thinking about it a different way. Rather than adding more heft to the base component, we could add another object that interacted with the ComboBox to facilitate that s

Re: combo box

2012-04-10 Thread Dany Dhondt
Hi, Now there's a discussion about the comboBox, I'd like to address an issue. Sorry in advance if it had been addressed already. Using the component, one can set the selectedIndex or the selectedItem properties. There's no way to set a 'selectedValue' property. I've solved this by using a cust

Re: combo box

2012-04-10 Thread Jeffry Houser
On 4/10/2012 1:30 PM, John Cunliffe wrote: Great thinking. Personally I would love seeing something like the flexlib library being revived. Anybody else? John I'm not sure about FlexLib; since most of those components were pre-spark. However, I think there is a lot of potential to create S

Re: combo box

2012-04-10 Thread Alex Harui
On 4/10/12 10:59 AM, "David Coleman" wrote: > > Wow, what a great idea... maybe we can merge both of our ideas into a single > better component! > Possibly. In theory, you can grab code off my blog and just use it, although the licensing is not explicit. I've been planning to get a ruling

RE: combo box

2012-04-10 Thread David Coleman
Wow, what a great idea... maybe we can merge both of our ideas into a single better component! > From: aha...@adobe.com > To: flex-dev@incubator.apache.org > Date: Tue, 10 Apr 2012 10:56:33 -0700 > Subject: Re: combo box > > > > > On 4/10/12 10:45

Re: combo box

2012-04-10 Thread Alex Harui
On 4/10/12 10:45 AM, "David Coleman" wrote: > > sure give me a few days to dedicate some time to this example, I'm up to my > eyeballs in work for the next 48 or so! > > my github user is davidcoleman007 and I'll share something asap! > Interesting. Several years back I proposed doing thi

RE: combo box

2012-04-10 Thread David Coleman
sure give me a few days to dedicate some time to this example, I'm up to my eyeballs in work for the next 48 or so! my github user is davidcoleman007 and I'll share something asap! > From: f...@tink.ws > To: flex-dev@incubator.apache.org > Subject: Re: combo box > Date:

Re: combo box

2012-04-10 Thread Tink
On 10 Apr 2012, at 18:40, David Coleman wrote: Yes and no. with this you can set the actual emptyItemValue to be whatever you want. For instance if you have some complex set of dto's etc, you can set the emptyItemValue to be an actual object and have it be able to work more seamlessly w

RE: combo box

2012-04-10 Thread David Coleman
a few edge cases where you might want to distinguish the empty item by some value other than -1, but still represent the selectedIndex as -1 for compatibility with the framework. > Date: Tue, 10 Apr 2012 10:36:09 -0700 > Subject: Re: combo box > From: s9tpep...@apache.org

Re: combo box

2012-04-10 Thread Omar Gonzalez
On Tue, Apr 10, 2012 at 10:32 AM, David Coleman < david_coleman_...@hotmail.com> wrote: > > h it seems the listsrv ate my file. :-( > > here, I'll paste it in. And BTW: it is for spark. > > ... Hey David, http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/spark/components/

Re: combo box

2012-04-10 Thread Omar Gonzalez
On Tue, Apr 10, 2012 at 10:30 AM, John Cunliffe wrote: > Great thinking. Personally I would love seeing something like the flexlib > library being revived. Anybody else? > John Honestly, I'd rather see the developers of those components start to contribute components to the Apache Flex SDK. ;)

RE: combo box

2012-04-10 Thread David Coleman
mLabel():String { return _emptyItemLabel; } public function set emptyItemLabel(value:String):void { _emptyItemLabel = value; _emptyItem.label = value; clearEmptyItem(); addEmptyItem(); //LogObj(emptyItem); } } } >

Re: combo box

2012-04-10 Thread Omar Gonzalez
s for some time. It is a tweak to the > combo box that allows you to have a blank item as the first item, allowing > you to de-select the selected item and reset the combo to empty. It has a > configurable value (which defaults to -1) and a configurable label to show > in the list (in c

Re: combo box

2012-04-10 Thread John Cunliffe
t; changed nearly every other release) made remember something that i have had > sitting around in my personal files for some time. It is a tweak to the > combo box that allows you to have a blank item as the first item, allowing > you to de-select the selected item and reset the

combo box

2012-04-10 Thread David Coleman
Hi everyone. Mike's most recent mail (mentioning that ComboBoxes have changed nearly every other release) made remember something that i have had sitting around in my personal files for some time. It is a tweak to the combo box that allows you to have a blank item as the first item, all