Re: [flexcoders] ComboBox and Icons

2005-11-18 Thread Anatole Tartakovsky





Andre,
Here is the way to replace combobox dropdown with 
configurable datagrid from my recent post:
http://www.mail-archive.com/flexcoders@yahoogroups.com/msg15878.html

Adding icon might looksimplier if you apply 
iconField to dropdown property of the combobox, but making sure that symbols are 
linked can be tricky. You might consider using control.dropdown.iconFunction 
instead as it gives you an ability to debug the data requested and symbol 
returned. Also please make sure you apply these properties after the combobox is 
initialized for "dropdown" to work, and association is created in the code 
rather then on the control itself (and the later the better) as the "dropdown" 
can be destroyed and recreated (on reassignment of dataProvider as an example). 


However, using cusom class overloading getDropdown 
method as in the link provided is going to be the most reliable solution - and 
you can replace dropdown with datagrid or tree or any other "list" tailored for 
RIA experience.

HTH,
Anatole Tartakovsky
[EMAIL PROTECTED]




  - Original Message - 
  From: 
  Andre Ehlert 
  To: flexcoders@yahoogroups.com 
  Sent: Thursday, November 17, 2005 10:53 
  AM
  Subject: [flexcoders] ComboBox and 
  Icons
  Hi all, does anybody know, if there is a possibility to add an 
  icon to each item of a combobox - (I 
  know it works with a mx:List via attribute iconField... :) 
  thanxs andré ehlert 
  





--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com





  




  
  
  YAHOO! GROUPS LINKS



  Visit your group "flexcoders" on the web.
  To unsubscribe from this group, send an email to:[EMAIL PROTECTED]
  Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.



  









RE: [flexcoders] ComboBox and Icons

2005-11-18 Thread Andre Ehlert




Hi Jim,

thanks for your reply, but i found out
a solution:

In shortform:

Definition of icons in application:

/** embed icons for cbx user status
*/
/** status away */
[Embed(source=/pics/userStatus/away.gif)]
var iconAway:String;
/** status don't disturb */
[Embed(source=/pics/userStatus/dontDisturb.gif)]
var iconDontDisturb:String;
/** status active */
[Embed(source=/pics/userStatus/active.gif)]
var iconActive:String;

Definition of Dataprovider for UserStatus

_arrOffItems:Array = new Array();
_arrOffItems.addItem({label:I'm
away, icon:iconAway, status:0, showAt:2});
_arrOffItems.addItem({label:Don't
disturb me, icon:iconDontDisturb, status:1, showAt:1});
_arrOffItems.addItem({label:I'm
active, icon:iconActive, status:2, showAt:0});

Set Dataprovider

cbxCurrentUserStatus.dataProvider =
_arrOffItems;


andré





Jim Phelan
[EMAIL PROTECTED] 
Sent by: flexcoders@yahoogroups.com
18.11.2005 02:42



Please respond to
flexcoders@yahoogroups.com





To
flexcoders@yahoogroups.com


cc



Subject
RE: [flexcoders] ComboBox
and Icons








Hey Andre,

I just had to address this
earlier this week, and I had to write two custom subclasses to make it
work. If you’re interested I might be able to clean them up and share
it, but it might take a day or two to get around to it.

Jim




From: flexcoders@yahoogroups.com
[mailto:[EMAIL PROTECTED] On Behalf Of Andre Ehlert
Sent: Thursday, November 17, 2005 10:53 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] ComboBox and Icons


Hi all, 

does anybody know, if there is a possibility to add an icon to each item
of a combobox - 
(I know it works with a mx:List via attribute iconField... :)


thanxs 
andré ehlert 


--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com





YAHOO! GROUPS LINKS



Visit your group flexcoders
on the web.
 
To unsubscribe from this group,
send an email to:
 [EMAIL PROTECTED]
 
Your use of Yahoo! Groups is
subject to the Yahoo!
Terms of Service.










--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com








  
  
SPONSORED LINKS
  
  
  

Web site design development
  
  
Computer software development
  
  
Software design and development
  
  


Macromedia flex
  
  
Software development best practice
  

   
  







  
  
  YAHOO! GROUPS LINKS



  Visit your group "flexcoders" on the web.
  To unsubscribe from this group, send an email to:[EMAIL PROTECTED]
  Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.



  









[flexcoders] ComboBox and Icons

2005-11-17 Thread Andre Ehlert




Hi all,

does anybody know, if there is a possibility
to add an icon to each item of a combobox - 
(I know it works with a mx:List via
attribute iconField... :)

thanxs
andré ehlert





--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com








  
  
SPONSORED LINKS
  
  
  

Web site design development
  
  
Computer software development
  
  
Software design and development
  
  


Macromedia flex
  
  
Software development best practice
  

   
  







  
  
  YAHOO! GROUPS LINKS



  Visit your group "flexcoders" on the web.
  To unsubscribe from this group, send an email to:[EMAIL PROTECTED]
  Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.



  









RE: [flexcoders] ComboBox and Icons

2005-11-17 Thread Jim Phelan










Hey Andre,



I just had to address this earlier this
week, and I had to write two custom subclasses to make it work. If youre
interested I might be able to clean them up and share it, but it might take a
day or two to get around to it.



Jim











From: flexcoders@yahoogroups.com [mailto:flexcoders@yahoogroups.com] On Behalf Of Andre Ehlert
Sent: Thursday, November 17, 2005
10:53 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] ComboBox and
Icons






Hi all, 

does
anybody know, if there is a possibility to add an icon to each item of a
combobox - 
(I
know it works with a mx:List via attribute iconField... :) 

thanxs

andré
ehlert 







--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com





  




  
  
  YAHOO! GROUPS LINKS



  Visit your group "flexcoders" on the web.
  To unsubscribe from this group, send an email to:[EMAIL PROTECTED]
  Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.