ENSwiftSideMenu icon indicating copy to clipboard operation
ENSwiftSideMenu copied to clipboard

Present destViewController modally

Open zentraedi opened this issue 10 years ago • 3 comments

Hi! Congratulations on an excellent library.

I would like to know if there's a way to change the default push behaviour of the destination view controllers and present them modally, just like the Uber menu does.

Thanks in advance

zentraedi avatar Mar 04 '16 14:03 zentraedi

Hi, You can present view modally by selecting table view's row, but in this case the side menu will not be accessible from modal view controller.

evnaz avatar Mar 05 '16 11:03 evnaz

Thanks! I used:

self.view.window?.rootViewController?.presentViewController(destViewController, animated: true, completion: nil)
sideMenuController()?.sideMenu?.toggleMenu()

...and everything worked fine

zentraedi avatar Mar 05 '16 18:03 zentraedi

@zentraedi i try to use your sugestion but when i put the view controller in the destViewController i get an error cannot convert value of type "myViewController " to expected argument type "UIViewController". also myviewController is a subclass of UIViewController

ghost avatar Jun 14 '16 22:06 ghost