after initial composition with the same value that you set in the Switch.
For what it worth, the more correct handling of the callback would be
onCheckedChange = { lselected = it }
as switch already gives you the hint about to which state it wants to change
matvei
09/09/2020, 11:06 AM
If you change it like this -- there will be no oscillation
m
MBegemot
09/09/2020, 11:34 AM
Thank you so much, still both components checkbox and switch should work equally I guess ... some day .. in the future
m
matvei
09/09/2020, 12:20 PM
Could you please clarify what you mean by "equally"? What's the difference between Checkbox and Switch behaviour that you see aside from that bug?
m
MBegemot
09/09/2020, 12:25 PM
Jesus I don't want to argue at all, I'm quite satisfied, and I don't see any difference aside from that bug. I swear it!
😎 1
🤔 6
m
matvei
09/09/2020, 12:42 PM
Sorry if I sounded rude, I didn't mean it. Thanks for your report and if you will find anything unusual or unpredictable about selection controls in the future -- please do let me know 🙂