I want to call a ViewController
's member function in AppDelegate
's applicationWillResignActive
function. Not sure what is the best way to do so. I tried doing so this way:
let landmark = LandmarkViewController()
landmark.test()
but it somehow doesn't seem right. I'm essentially creating new instance of the controller instead of using the already existent one.