You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@flex.apache.org by Olaf Krueger <ma...@olafkrueger.net> on 2018/01/02 16:44:55 UTC

Preserve 'selectedItems' after appling 'filterFunction'

Hi,
It seems to me that 'selectedItems' property of a s:List is always emtied
after a filter is applied to its 'dataProvider' by using a custom
'filterFunction'.
Is there a way to preserve the selectedItems?

Or do I have to backup the 'selectedItems' manually in order to re-assign it
after the filter is applied?

Thanks,
Olaf




--
Sent from: http://apache-flex-users.2333346.n4.nabble.com/

Re: Preserve 'selectedItems' after appling 'filterFunction'

Posted by Olaf Krueger <ma...@olafkrueger.net>.
Thank you, guys!
I will go the way to backup the selected items before filtering.

Thanks,
Olaf



--
Sent from: http://apache-flex-users.2333346.n4.nabble.com/

Re: Preserve 'selectedItems' after appling 'filterFunction'

Posted by GhaziTriki <gh...@gmail.com>.
Hello,

I have implemented a similar feature for the DataGrid component. You can
check it here
https://github.com/bigbluebutton/bigbluebutton/blob/master/bigbluebutton-client/src/org/bigbluebutton/main/views/BBBDataGrid.as#L36

Thanks,
Ghazi



--
Sent from: http://apache-flex-users.2333346.n4.nabble.com/

Re: Preserve 'selectedItems' after appling 'filterFunction'

Posted by Alex Harui <ah...@adobe.com.INVALID>.
IIRC, you have to back it up and filter it.  I'm not sure what will happen
if one or more of the selectedItems is no longer in the filtered data
provider.

HTH,
-Alex

On 1/2/18, 8:44 AM, "Olaf Krueger" <ma...@olafkrueger.net> wrote:

>Hi,
>It seems to me that 'selectedItems' property of a s:List is always emtied
>after a filter is applied to its 'dataProvider' by using a custom
>'filterFunction'.
>Is there a way to preserve the selectedItems?
>
>Or do I have to backup the 'selectedItems' manually in order to re-assign
>it
>after the filter is applied?
>
>Thanks,
>Olaf
>
>
>
>
>--
>Sent from: 
>https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fapache-fle
>x-users.2333346.n4.nabble.com%2F&data=02%7C01%7Caharui%40adobe.com%7Cb2c07
>96c7eb64d9d0ea708d552002a2f%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C6
>36505083018035029&sdata=NzLa4NEXvF7uDUM6hKW0hIMXRsnUV7oN3aFWKRw6KbA%3D&res
>erved=0