I am trying to set up a button using UIControlEventTouchDragEnter as the way to trigger the button's method. Specifically, I have a button, and I want the button's method to be triggered if the user presses their finger outside of the button, and drags their finger into the bounds of the button.
According to apple, this event, UIControlEventTouchDragEnter, is: An event where a finger is dragged into the bounds of the control.
However, I can't get the button to trigger. Here is my code:
- (IBAction)touchDragEnter:(UIButton *)sender {
_samlpe.image = [UIImage imageNamed:@"alternate_pic.png"];
}
So, when touchInto for this button is triggered, the method will change the current image of _sample into this alternate image. If I just use touchUpInside, the image does change to the alternate upon button click.
Does anyone know why this isn't working, or have work-arounds? Thanks!