簡體   English   中英

從情節提要中設置時,UITabBarController過渡不起作用

[英]UITabBarController transition not working when set from storyboard

我的應用程序在UITabBarController中有四個選項卡。 我正在使用情節提要來布局我的應用程序。 在“ Attributes Inspector我將UITabBarController的Transition Style設置為“ Cross Dissolve 但是,當我運行該應用程序時,選項卡仍會卡入到位而沒有任何過渡。 謝謝你的幫助。

更新

進一步的調查使我進入了委托方法

`tabBarController:animationControllerForTransitionFromViewController:toViewController:`

但是此方法的問題在於文檔說明Called to allow the delegate to return a UIViewControllerAnimatedTransitioning delegate object for use during a noninteractive tab bar view controller transition.該方法, Called to allow the delegate to return a UIViewControllerAnimatedTransitioning delegate object for use during a noninteractive tab bar view controller transition. 在這里,我將非交互式表示“不是由於用戶點擊”。 但是我要定義的過渡恰好是針對用戶點擊TabBar圖標時的情況。

以下文章應滿足您的需求。 它有各種各樣的例子,還有一個git項目。 http://objectivetoast.com/2014/03/17/custom-transitions-on-ios/ 要查看的git項目是

https://github.com/ObjectiveToast/CustomTransitions

https://github.com/twotoasters/Toast

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM