[flexcoders] Re: Prevent ItemRenderer click from selecting row?

2009-02-05 Thread Tim Hoff

Yes, you'd have to extend DataGrid and override the mouseDownHandler and
mouseUpHandler functions.  if ( event.target is Button ) return;

-TH

--- In flexcoders@yahoogroups.com, Dennis Falling dfall...@... wrote:

 That's what I was trying- stopping propagation and preventing default.
 Apparently the datagrid gets the event first.

 On Wed, Feb 4, 2009 at 10:26 PM, arieljake arielj...@... wrote:

  Can you have the items catch the click event of the button and
prevent
  propagation?
 
 
  --- In flexcoders@yahoogroups.com flexcoders%40yahoogroups.com,
Dennis
  Falling dfalling@ wrote:
  
   I'm using a DataGrid. But the problem is that I want the selection
  behavior
   to behave normally, except for when the buttons are clicked.
   Thanks
  
   On Wed, Feb 4, 2009 at 10:09 AM, Fotis Chatzinikos 
   fotis.chatzinikos@ wrote:
  
if you are using a list or tile list there is a property
selectable
which you can make false.
   
   
   
On Wed, Feb 4, 2009 at 6:05 PM, Dennis Falling dfalling@ wrote:
   
Is there one involving item renderers? I believe I scoured
  your site
pretty thoroughly, but the only time I see selection behavior
being
overriden is inside an extended list or DataGrid. Is it
possible
  to pull
this off with only an item renderer?
   
Thanks
   
On Wed, Feb 4, 2009 at 1:16 AM, Alex Harui aharui@ wrote:
   
There a example on preventing list selection on my blog
   
   
   
*From:* flexcoders@yahoogroups.com
flexcoders%40yahoogroups.com
  [mailto:flexcoders@yahoogroups.com flexcoders%40yahoogroups.com]
*On
Behalf Of *Dennis Falling
*Sent:* Tuesday, February 03, 2009 5:30 PM
*To:* flexcoders@yahoogroups.com
flexcoders%40yahoogroups.com
*Subject:* Re: [flexcoders] Re: Prevent ItemRenderer click
from
selecting row?
   
   
   
That would work for invalidating my selection, but I simply
want the
selection to never occur. That way if something was previously
  selected, it
isn't altered.
   
On Tue, Feb 3, 2009 at 5:08 PM, fourctv fourctv@ wrote:
   
have you tried datagrid.selectedItems=null?
   
   
   
--- In flexcoders@yahoogroups.com
flexcoders%40yahoogroups.com
  flexcoders%40yahoogroups.com, Dennis
Falling dfalling@ wrote:

 I have an ItemRenderer with buttons in it. In the click
listener
functions
 for these buttons, I call event.stopImmediatePropagation
(and
 preventDefault, though that doesn't seem relevant), but the
row is
still
 selected. How can I prevent it from receiving the click and
highlighting
 itself?
 Thanks.

   
   
   
   
   
   
   
--
Fotis Chatzinikos, Ph.D.
Founder,
Phinnovation
Fotis.Chatzinikos@,
   
   
   
  
 
 
 






RE: [flexcoders] Re: Prevent ItemRenderer click from selecting row?

2009-02-05 Thread Alex Harui
Sure, because it set up its listener first.  You can set your listener at a 
higher priority.  I'd still start with my list selection example on my blog.  
You should be able to tweak it to just not allow selection if the event.target 
is a button.

Alex Harui
Flex SDK Developer
Adobe Systems Inc.http://www.adobe.com/
Blog: http://blogs.adobe.com/aharui

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf 
Of Dennis Falling
Sent: Wednesday, February 04, 2009 10:20 PM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] Re: Prevent ItemRenderer click from selecting row?


That's what I was trying- stopping propagation and preventing default.  
Apparently the datagrid gets the event first.
On Wed, Feb 4, 2009 at 10:26 PM, arieljake 
arielj...@yahoo.commailto:arielj...@yahoo.com wrote:

Can you have the items catch the click event of the button and prevent
propagation?


--- In flexcoders@yahoogroups.commailto:flexcoders%40yahoogroups.com, Dennis 
Falling dfall...@... wrote:

 I'm using a DataGrid. But the problem is that I want the selection
behavior
 to behave normally, except for when the buttons are clicked.
 Thanks

 On Wed, Feb 4, 2009 at 10:09 AM, Fotis Chatzinikos 
 fotis.chatzini...@... wrote:

  if you are using a list or tile list there is a property selectable
  which you can make false.
 
 
 
  On Wed, Feb 4, 2009 at 6:05 PM, Dennis Falling dfall...@... wrote:
 
  Is there one involving item renderers? I believe I scoured
your site
  pretty thoroughly, but the only time I see selection behavior being
  overriden is inside an extended list or DataGrid. Is it possible
to pull
  this off with only an item renderer?
 
  Thanks
 
  On Wed, Feb 4, 2009 at 1:16 AM, Alex Harui aha...@... wrote:
 
  There a example on preventing list selection on my blog
 
 
 
  *From:* flexcoders@yahoogroups.commailto:flexcoders%40yahoogroups.com
[mailto:flexcoders@yahoogroups.commailto:flexcoders%40yahoogroups.com] *On
  Behalf Of *Dennis Falling
  *Sent:* Tuesday, February 03, 2009 5:30 PM
  *To:* flexcoders@yahoogroups.commailto:flexcoders%40yahoogroups.com
  *Subject:* Re: [flexcoders] Re: Prevent ItemRenderer click from
  selecting row?
 
 
 
  That would work for invalidating my selection, but I simply want the
  selection to never occur. That way if something was previously
selected, it
  isn't altered.
 
  On Tue, Feb 3, 2009 at 5:08 PM, fourctv four...@... wrote:
 
  have you tried datagrid.selectedItems=null?
 
 
 
  --- In flexcoders@yahoogroups.commailto:flexcoders%40yahoogroups.com
flexcoders%40yahoogroups.comhttp://40yahoogroups.com, Dennis

  Falling dfalling@ wrote:
  
   I have an ItemRenderer with buttons in it. In the click listener
  functions
   for these buttons, I call event.stopImmediatePropagation (and
   preventDefault, though that doesn't seem relevant), but the row is
  still
   selected. How can I prevent it from receiving the click and
  highlighting
   itself?
   Thanks.
  
 
 
 
 
 
 
 
  --
  Fotis Chatzinikos, Ph.D.
  Founder,
  Phinnovation
  fotis.chatzini...@...,
 
 
 





Re: [flexcoders] Re: Prevent ItemRenderer click from selecting row?

2009-02-05 Thread Dennis Falling
Wow, I don't know how many times I've typed ,0 and ignored priority.
 Thanks!

On Thu, Feb 5, 2009 at 12:14 PM, Alex Harui aha...@adobe.com wrote:

Sure, because it set up its listener first.  You can set your listener
 at a higher priority.  I'd still start with my list selection example on my
 blog.  You should be able to tweak it to just not allow selection if the
 event.target is a button.



 Alex Harui

 Flex SDK Developer

 Adobe Systems Inc. http://www.adobe.com/

 Blog: http://blogs.adobe.com/aharui



 *From:* flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] *On
 Behalf Of *Dennis Falling
 *Sent:* Wednesday, February 04, 2009 10:20 PM

 *To:* flexcoders@yahoogroups.com
 *Subject:* Re: [flexcoders] Re: Prevent ItemRenderer click from selecting
 row?



 That's what I was trying- stopping propagation and preventing default.
  Apparently the datagrid gets the event first.

 On Wed, Feb 4, 2009 at 10:26 PM, arieljake arielj...@yahoo.com wrote:

 Can you have the items catch the click event of the button and prevent
 propagation?



 --- In flexcoders@yahoogroups.com flexcoders%40yahoogroups.com, Dennis
 Falling dfall...@... wrote:
 

  I'm using a DataGrid. But the problem is that I want the selection
 behavior
  to behave normally, except for when the buttons are clicked.
  Thanks
 
  On Wed, Feb 4, 2009 at 10:09 AM, Fotis Chatzinikos 

  fotis.chatzini...@... wrote:
 
   if you are using a list or tile list there is a property selectable
   which you can make false.
  
  
  

   On Wed, Feb 4, 2009 at 6:05 PM, Dennis Falling dfall...@... wrote:
  
   Is there one involving item renderers? I believe I scoured
 your site
   pretty thoroughly, but the only time I see selection behavior being
   overriden is inside an extended list or DataGrid. Is it possible
 to pull
   this off with only an item renderer?
  
   Thanks
  

   On Wed, Feb 4, 2009 at 1:16 AM, Alex Harui aha...@... wrote:
  
   There a example on preventing list selection on my blog
  
  
  
   *From:* flexcoders@yahoogroups.com flexcoders%40yahoogroups.com
 [mailto:flexcoders@yahoogroups.com flexcoders%40yahoogroups.com] *On
   Behalf Of *Dennis Falling
   *Sent:* Tuesday, February 03, 2009 5:30 PM
   *To:* flexcoders@yahoogroups.com flexcoders%40yahoogroups.com
   *Subject:* Re: [flexcoders] Re: Prevent ItemRenderer click from
   selecting row?
  
  
  
   That would work for invalidating my selection, but I simply want the
   selection to never occur. That way if something was previously
 selected, it
   isn't altered.
  

   On Tue, Feb 3, 2009 at 5:08 PM, fourctv four...@... wrote:
  
   have you tried datagrid.selectedItems=null?
  
  
  
   --- In flexcoders@yahoogroups.com flexcoders%40yahoogroups.com

 flexcoders%40yahoogroups.com, Dennis


   Falling dfalling@ wrote:
   
I have an ItemRenderer with buttons in it. In the click listener
   functions
for these buttons, I call event.stopImmediatePropagation (and
preventDefault, though that doesn't seem relevant), but the row is
   still
selected. How can I prevent it from receiving the click and
   highlighting
itself?
Thanks.
   
  
  
  
  
  
  
  
   --
   Fotis Chatzinikos, Ph.D.
   Founder,
   Phinnovation

   fotis.chatzini...@...,
  
  
  
 



   



Re: [flexcoders] Re: Prevent ItemRenderer click from selecting row?

2009-02-04 Thread Dennis Falling
Is there one involving item renderers?  I believe I scoured your site pretty
thoroughly, but the only time I see selection behavior being overriden is
inside an extended list or DataGrid.  Is it possible to pull this off with
only an item renderer?
Thanks

On Wed, Feb 4, 2009 at 1:16 AM, Alex Harui aha...@adobe.com wrote:

There a example on preventing list selection on my blog



 *From:* flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] *On
 Behalf Of *Dennis Falling
 *Sent:* Tuesday, February 03, 2009 5:30 PM
 *To:* flexcoders@yahoogroups.com
 *Subject:* Re: [flexcoders] Re: Prevent ItemRenderer click from selecting
 row?



 That would work for invalidating my selection, but I simply want the
 selection to never occur.  That way if something was previously selected, it
 isn't altered.

 On Tue, Feb 3, 2009 at 5:08 PM, fourctv four...@yahoo.com wrote:

 have you tried datagrid.selectedItems=null?



 --- In flexcoders@yahoogroups.com flexcoders%40yahoogroups.com, Dennis
 Falling dfall...@... wrote:
 
  I have an ItemRenderer with buttons in it. In the click listener
 functions
  for these buttons, I call event.stopImmediatePropagation (and
  preventDefault, though that doesn't seem relevant), but the row is still
  selected. How can I prevent it from receiving the click and highlighting
  itself?
  Thanks.
 



   



Re: [flexcoders] Re: Prevent ItemRenderer click from selecting row?

2009-02-04 Thread Fotis Chatzinikos
if you are using a list or tile list there is a property selectable which
you can make false.


On Wed, Feb 4, 2009 at 6:05 PM, Dennis Falling dfall...@gmail.com wrote:

   Is there one involving item renderers?  I believe I scoured your site
 pretty thoroughly, but the only time I see selection behavior being
 overriden is inside an extended list or DataGrid.  Is it possible to pull
 this off with only an item renderer?

 Thanks

 On Wed, Feb 4, 2009 at 1:16 AM, Alex Harui aha...@adobe.com wrote:

There a example on preventing list selection on my blog



 *From:* flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] *On
 Behalf Of *Dennis Falling
 *Sent:* Tuesday, February 03, 2009 5:30 PM
 *To:* flexcoders@yahoogroups.com
 *Subject:* Re: [flexcoders] Re: Prevent ItemRenderer click from selecting
 row?



 That would work for invalidating my selection, but I simply want the
 selection to never occur.  That way if something was previously selected, it
 isn't altered.

 On Tue, Feb 3, 2009 at 5:08 PM, fourctv four...@yahoo.com wrote:

 have you tried datagrid.selectedItems=null?



 --- In flexcoders@yahoogroups.com flexcoders%40yahoogroups.com, Dennis
 Falling dfall...@... wrote:
 
  I have an ItemRenderer with buttons in it. In the click listener
 functions
  for these buttons, I call event.stopImmediatePropagation (and
  preventDefault, though that doesn't seem relevant), but the row is still
  selected. How can I prevent it from receiving the click and highlighting
  itself?
  Thanks.
 




  




-- 
Fotis Chatzinikos, Ph.D.
Founder,
Phinnovation
fotis.chatzini...@gmail.com,


Re: [flexcoders] Re: Prevent ItemRenderer click from selecting row?

2009-02-04 Thread Dennis Falling
I'm using a DataGrid.  But the problem is that I want the selection behavior
to behave normally, except for when the buttons are clicked.
Thanks

On Wed, Feb 4, 2009 at 10:09 AM, Fotis Chatzinikos 
fotis.chatzini...@gmail.com wrote:

   if you are using a list or tile list there is a property selectable
 which you can make false.



 On Wed, Feb 4, 2009 at 6:05 PM, Dennis Falling dfall...@gmail.com wrote:

   Is there one involving item renderers?  I believe I scoured your site
 pretty thoroughly, but the only time I see selection behavior being
 overriden is inside an extended list or DataGrid.  Is it possible to pull
 this off with only an item renderer?

 Thanks

 On Wed, Feb 4, 2009 at 1:16 AM, Alex Harui aha...@adobe.com wrote:

There a example on preventing list selection on my blog



 *From:* flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] *On
 Behalf Of *Dennis Falling
 *Sent:* Tuesday, February 03, 2009 5:30 PM
 *To:* flexcoders@yahoogroups.com
 *Subject:* Re: [flexcoders] Re: Prevent ItemRenderer click from
 selecting row?



 That would work for invalidating my selection, but I simply want the
 selection to never occur.  That way if something was previously selected, it
 isn't altered.

 On Tue, Feb 3, 2009 at 5:08 PM, fourctv four...@yahoo.com wrote:

 have you tried datagrid.selectedItems=null?



 --- In flexcoders@yahoogroups.com flexcoders%40yahoogroups.com, Dennis
 Falling dfall...@... wrote:
 
  I have an ItemRenderer with buttons in it. In the click listener
 functions
  for these buttons, I call event.stopImmediatePropagation (and
  preventDefault, though that doesn't seem relevant), but the row is
 still
  selected. How can I prevent it from receiving the click and
 highlighting
  itself?
  Thanks.
 







 --
 Fotis Chatzinikos, Ph.D.
 Founder,
 Phinnovation
 fotis.chatzini...@gmail.com,

  



[flexcoders] Re: Prevent ItemRenderer click from selecting row?

2009-02-04 Thread arieljake
Can you have the items catch the click event of the button and prevent
propagation?

--- In flexcoders@yahoogroups.com, Dennis Falling dfall...@... wrote:

 I'm using a DataGrid.  But the problem is that I want the selection
behavior
 to behave normally, except for when the buttons are clicked.
 Thanks
 
 On Wed, Feb 4, 2009 at 10:09 AM, Fotis Chatzinikos 
 fotis.chatzini...@... wrote:
 
if you are using a list or tile list there is a property selectable
  which you can make false.
 
 
 
  On Wed, Feb 4, 2009 at 6:05 PM, Dennis Falling dfall...@... wrote:
 
Is there one involving item renderers?  I believe I scoured
your site
  pretty thoroughly, but the only time I see selection behavior being
  overriden is inside an extended list or DataGrid.  Is it possible
to pull
  this off with only an item renderer?
 
  Thanks
 
  On Wed, Feb 4, 2009 at 1:16 AM, Alex Harui aha...@... wrote:
 
 There a example on preventing list selection on my blog
 
 
 
  *From:* flexcoders@yahoogroups.com
[mailto:flexcod...@yahoogroups.com] *On
  Behalf Of *Dennis Falling
  *Sent:* Tuesday, February 03, 2009 5:30 PM
  *To:* flexcoders@yahoogroups.com
  *Subject:* Re: [flexcoders] Re: Prevent ItemRenderer click from
  selecting row?
 
 
 
  That would work for invalidating my selection, but I simply want the
  selection to never occur.  That way if something was previously
selected, it
  isn't altered.
 
  On Tue, Feb 3, 2009 at 5:08 PM, fourctv four...@... wrote:
 
  have you tried datagrid.selectedItems=null?
 
 
 
  --- In flexcoders@yahoogroups.com
flexcoders%40yahoogroups.com, Dennis
  Falling dfalling@ wrote:
  
   I have an ItemRenderer with buttons in it. In the click listener
  functions
   for these buttons, I call event.stopImmediatePropagation (and
   preventDefault, though that doesn't seem relevant), but the row is
  still
   selected. How can I prevent it from receiving the click and
  highlighting
   itself?
   Thanks.
  
 
 
 
 
 
 
 
  --
  Fotis Chatzinikos, Ph.D.
  Founder,
  Phinnovation
  fotis.chatzini...@...,
 
   
 





Re: [flexcoders] Re: Prevent ItemRenderer click from selecting row?

2009-02-04 Thread Dennis Falling
That's what I was trying- stopping propagation and preventing default.
 Apparently the datagrid gets the event first.

On Wed, Feb 4, 2009 at 10:26 PM, arieljake arielj...@yahoo.com wrote:

   Can you have the items catch the click event of the button and prevent
 propagation?


 --- In flexcoders@yahoogroups.com flexcoders%40yahoogroups.com, Dennis
 Falling dfall...@... wrote:
 
  I'm using a DataGrid. But the problem is that I want the selection
 behavior
  to behave normally, except for when the buttons are clicked.
  Thanks
 
  On Wed, Feb 4, 2009 at 10:09 AM, Fotis Chatzinikos 
  fotis.chatzini...@... wrote:
 
   if you are using a list or tile list there is a property selectable
   which you can make false.
  
  
  
   On Wed, Feb 4, 2009 at 6:05 PM, Dennis Falling dfall...@... wrote:
  
   Is there one involving item renderers? I believe I scoured
 your site
   pretty thoroughly, but the only time I see selection behavior being
   overriden is inside an extended list or DataGrid. Is it possible
 to pull
   this off with only an item renderer?
  
   Thanks
  
   On Wed, Feb 4, 2009 at 1:16 AM, Alex Harui aha...@... wrote:
  
   There a example on preventing list selection on my blog
  
  
  
   *From:* flexcoders@yahoogroups.com flexcoders%40yahoogroups.com
 [mailto:flexcoders@yahoogroups.com flexcoders%40yahoogroups.com] *On
   Behalf Of *Dennis Falling
   *Sent:* Tuesday, February 03, 2009 5:30 PM
   *To:* flexcoders@yahoogroups.com flexcoders%40yahoogroups.com
   *Subject:* Re: [flexcoders] Re: Prevent ItemRenderer click from
   selecting row?
  
  
  
   That would work for invalidating my selection, but I simply want the
   selection to never occur. That way if something was previously
 selected, it
   isn't altered.
  
   On Tue, Feb 3, 2009 at 5:08 PM, fourctv four...@... wrote:
  
   have you tried datagrid.selectedItems=null?
  
  
  
   --- In flexcoders@yahoogroups.com flexcoders%40yahoogroups.com
 flexcoders%40yahoogroups.com, Dennis
   Falling dfalling@ wrote:
   
I have an ItemRenderer with buttons in it. In the click listener
   functions
for these buttons, I call event.stopImmediatePropagation (and
preventDefault, though that doesn't seem relevant), but the row is
   still
selected. How can I prevent it from receiving the click and
   highlighting
itself?
Thanks.
   
  
  
  
  
  
  
  
   --
   Fotis Chatzinikos, Ph.D.
   Founder,
   Phinnovation
   fotis.chatzini...@...,
  
  
  
 

  



[flexcoders] Re: Prevent ItemRenderer click from selecting row?

2009-02-03 Thread fourctv
have you tried datagrid.selectedItems=null?

--- In flexcoders@yahoogroups.com, Dennis Falling dfall...@... wrote:

 I have an ItemRenderer with buttons in it.  In the click listener functions
 for these buttons, I call event.stopImmediatePropagation (and
 preventDefault, though that doesn't seem relevant), but the row is still
 selected.  How can I prevent it from receiving the click and highlighting
 itself?
 Thanks.






Re: [flexcoders] Re: Prevent ItemRenderer click from selecting row?

2009-02-03 Thread Dennis Falling
That would work for invalidating my selection, but I simply want the
selection to never occur.  That way if something was previously selected, it
isn't altered.

On Tue, Feb 3, 2009 at 5:08 PM, fourctv four...@yahoo.com wrote:

   have you tried datagrid.selectedItems=null?


 --- In flexcoders@yahoogroups.com flexcoders%40yahoogroups.com, Dennis
 Falling dfall...@... wrote:
 
  I have an ItemRenderer with buttons in it. In the click listener
 functions
  for these buttons, I call event.stopImmediatePropagation (and
  preventDefault, though that doesn't seem relevant), but the row is still
  selected. How can I prevent it from receiving the click and highlighting
  itself?
  Thanks.
 

  



RE: [flexcoders] Re: Prevent ItemRenderer click from selecting row?

2009-02-03 Thread Alex Harui
There a example on preventing list selection on my blog

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf 
Of Dennis Falling
Sent: Tuesday, February 03, 2009 5:30 PM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] Re: Prevent ItemRenderer click from selecting row?


That would work for invalidating my selection, but I simply want the selection 
to never occur.  That way if something was previously selected, it isn't 
altered.
On Tue, Feb 3, 2009 at 5:08 PM, fourctv 
four...@yahoo.commailto:four...@yahoo.com wrote:

have you tried datagrid.selectedItems=null?


--- In flexcoders@yahoogroups.commailto:flexcoders%40yahoogroups.com, Dennis 
Falling dfall...@... wrote:

 I have an ItemRenderer with buttons in it. In the click listener functions
 for these buttons, I call event.stopImmediatePropagation (and
 preventDefault, though that doesn't seem relevant), but the row is still
 selected. How can I prevent it from receiving the click and highlighting
 itself?
 Thanks.