Sorry, but I'm going to avoid your question (I canβt answer it anyway) and suggest you use a different approach.
You could (I suppose) use the checkbox to just as easily provide the opportunity to the person using the application. After the toggle switch has the same functionality as the checkbox (specify / select between two states), it simply implements the interaction in different ways.
The toggle switch was not designed / built (AFAIK) to support use on top of that which also supports the same gesture.
As a general rule of usability, having control over yourself (or even next to each other) that support the same gesture can cause problems for the user. Even if the problems are caused by accidentally triggering the wrong gesture or expectations about how their gesture will be interpreted.
In short: this is a really difficult problem to solve; I donβt think you can with controls as they are; and the problem goes away completely if you use another control to switch anyway.
source share