how to check the number of clicks the user clicks on an image in swift -


is there function count numbers of click user clicks on image , when user starts clicking on image count resets. example : there image requires user click on 3 times , image comes out requires user click on 5 times , there function can me in touchbegan method.

you can use uitapgesturerecognizer , add 1 image views need. selector can choose same method every gesture recognizer. when user press in method increase counter , save view has received tap, if user change view can find mismatch between previous view , pressed one. in case reset couter.


Comments

Popular posts from this blog

java - HTTP Status 500 - An exception occurred processing JSP page /second.jsp at line 15 -

SQL Server - MyCTE query based on 24 hour period (next day) -

php - Using str_replace to translate a MySQL Table in html -