handsomecode / InteractiveSideMenu

iOS Interactive Side Menu written in Swift.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Menu Opening Up on Swipe But Not On Clicking Button

abhimasand opened this issue · comments

I am trying to open the Side Menu by clicking a button, but the menu isn't opening . I am using the showSideMenu() function, and also have the SideMenuItemContent Delegate present ,but the side view isn't coming .

Did you try Sample's implementation? Does it work for you?

Do you use some complex controllers structure or TabBar/NavigationBar controllers? Please, provide specific details.

I have the same issue: swiping works fine, but if I tried to open the Side Menu by IBAction - it crashes. I don't know why, but my class doesn't even call the viewDidLoad, viewWillAppear and so on methods. But it shows me everything I added in xib. So, when I click my UIButton - it crashes with:
2017-11-21 12:14:54.277441+0300 *****[5270:15335230] -[UIViewController showMenuButtonClicked:]: unrecognized selector sent to instance 0x7f86efd09d70

i am also facing same problem on swipe menu is being opened but clicking on menu button does not open menu.

  `let selectViewController = self.storyboard?.instantiateViewController(withIdentifier: "ViewController")
    
    let navigationController = UINavigationController(rootViewController: selectViewController!)
    navigationController.navigationBar.isHidden = true
    
    let menuVC = self.storyboard?.instantiateViewController(withIdentifier: "MenuVC") as! MenuVC
    menuVC.selectContentViewController(selectViewController!)`

@Mashex @ValeriiVV @chetanpanchal94
Would any of you be willing to post additional information about the issues you are seeing? The sample project is working both with swiping and with tapping the menu button on the content view controllers. Without further insight into your issue or your implementation code, it's difficult to figure out what is going on in your application(s).

There is some missing code in the cocoapod. I tried the sample application and it works fine! I wonder why the code is not reflected to cocoapod.
I have the same issue and there are no feedback for further description, except for the version i got from cocapod is 2.2.1 which clearly describe the case.

I used pod 'InteractiveSideMenu', '~> 2.3' when installing using cocoapod but nothing changed.

The Issue I was having was with the parent view controller in showSideMenu function was returning nil , and according to IOS Docs, https://developer.apple.com/documentation/uikit/uiviewcontroller/1621362-parentviewcontroller
this was working untill IOS 5.0

update:

The function worked for me now, I noticed that in the sample app the Host view controller class is subclassed to a view controller.

This fixed the issue for me.

well I can not deny that I am a complete beginner in IOS development. But you guys need to work on the documentation a little bit.