MattBlack
MattBlack

Reputation: 3828

Shake Gesture not Working

I have a project set up using SWReveal for the slide out menu.

When I place a motion ended override function it never seems to be called even though everything else in the class loads (indicated with the 'loading'.

I have had a good play around and found that if I change the segue to the page to a 'show' segue the code functions as I would expect it to.

However when I use a custom segue with the SWReveal as the class the motion ended does not work.

I have attached a screen shot to help describe the issue.

Any help much appreciated.enter image description here

Upvotes: 0

Views: 123

Answers (1)

Maksym Musiienko
Maksym Musiienko

Reputation: 1248

You need to override canBecomeFirstResponder method.

override func canBecomeFirstResponder() -> Bool {
    return true
}

Upvotes: 1

Related Questions