2
我想獲取tabbarController的選定索引。獲取選定的索引tabbar控制器Swift
let application = UIApplication.sharedApplication().delegate as AppDelegate
let tabbarController = application.tabBarController as UITabBarController
let selectedIndex = tabBarController.selectedIndex
我得到這個錯誤:'UITabBarController?' does not have a member named 'selectedIndex'
我缺少的東西?