Just take out the part that says && currentPosition != -1 and you will get position -1 for off.
&& currentPosition != -1