wxMultiChoiceDialog (Select All/Select None)

BlitzMax Forums/Brucey's Modules/wxMultiChoiceDialog (Select All/Select None)

kenshin(Posted 2009) [#1]
I'm using the wxMultiChoiceDialog for some reasonable size lists. Is there any way to get "ALL / NONE" buttons (or something functionally equivalent) on it in addition to the "OK / CANCEL" ones?

I can't find any evidence of this option, although it seems like such an obvious thing to have when multiple-selection from a list is being done.

btw v2.8.9 is working great here.


kenshin(Posted 2009) [#2]
I've knocked up a type that can be used as an alternative to the modal wxMultiChoiceDialog requester, but also implements the 'Select All' and 'Select None' buttons. It's pretty much a drop in replacement for the original requester except for minor differences. I've also made it to look and act as close as possible to the original requester as I could.

Here it is with a demo showing how to use it. Just copy, paste, and run. Hope this helps anyone else looking for the extra All/None function.



DavidDC(Posted 2009) [#3]
If you create the OK and CANCEL buttons with the stock id's wxID_OK and wxID_CANCEL respectively then you shouldn't need to: connect them to anything, call close() or end modal().

Thanks for sharing.


kenshin(Posted 2009) [#4]
Thanks for the tip:)
I'll look at doing it tonight. About to go to work now.