Reputation: 27
I just wanted to ask if onmouseup and onmousedown events are supported on touch screen mobile devices when deployed.
I have this code here:
<img src="images/plus.png" id="+" onclick=compare(this.id) onmousedown=changeplus() onmouseup=changeplus2() class=plus_button style="width:100px; height:100px;">
And I'm not sure if the device will support those.
I can't test it because I don't have the device yet. If it is not, is there any alternative for that?
Thanks in advance.
Upvotes: 2
Views: 1329
Reputation: 8710
You can simulate Touch events, in Chrome browser easily.
1- Press F12 to see Developer Tools 2- Click on the 'Settings' icon in bottom-right corner 3- Go to 'Override' section in Settings Panel 4- Activate check-box: 'Emulate Touch Events'
That's all! Ready to test your code.
Upvotes: 2