Quantcast
Channel: Xamarin.Forms — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 91519

TableView SwitchCell Tapped and OnChanged

$
0
0

So, let me get this straight:

With a SwitchCell in a TableView, Tapped() applies to the parent SwitchCell, but not the child Switch, and OnChanged() applies to the Switch, but not the parent SwitchCell.

So, effectively, both handlers have to be redirected to the same business logic in case the user clicks on the Switch and not the outer SwitchCell? Really? Is this correct? Or am I missing something?

Please do not tell me to use a ListView or a CollectionView and Switches.

PS: this is easy enough to accomplish by toggling the Switch state in the Tapped handler (which causes the OnChanged handler to fire) - I just want to make sure I'm not missing something.


Viewing all articles
Browse latest Browse all 91519

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>