There has been a problem with corona that when you place one view over the other and when you touch the object in front of the other, touch will be migrated to the object below it. To prevent this there is a mechanism in corona.
Here is how we solve this in corona.
here is a sample code.
local img1 = display.newImage("android_1.png") local img2 = display.newImage("android_2.png") function touchedImageOne() print ("touched Image One") end function touchedImageTwo() print ("touched Image two") end display.getCurrentStage():setFocus( img2 ) img1:addEventListener("tap",touchedImageOne); img2:addEventListener("tap",touchedImageTwo);
Check the console for the output
Here is a source code example for this project.