func applicationWillEnterForeground(_ application: UIApplication) {
// Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background.
let tmpVC = self.window?.rootViewController as! ViewController
tmpVC.functionToCall()
}