运动/材质不平衡调用以开始/结束外观转换

时间:2018-07-02 12:48:45

标签: swift cosmicmind material-swift

我使用的是Swift(2.16.0)的最新版本的Material库。在我的项目中,我将NavigationDrawer控制器与ToolBarController用作根视图控制器。然后我尝试以模态呈现SearchBarController,动作动画效果完美

let searchController = AppStoryboard.Tree.viewController(viewControllerClass: SearchViewController.self)
let searchBarController = SearchBarController(rootViewController: searchController)
searchBarController.isMotionEnabled = true
searchBarController.motionTransitionType = .autoReverse(presenting: .fade)
toolbarController?.present(searchBarController, animated: true)

但是在日志中,我看到消息:

Unbalanced calls to begin/end appearance transitions for <Material.SearchBarController: 0x7f8db554bde0>.
Unbalanced calls to begin/end appearance transitions for <NavigationDrawerController: 0x7f8db680b000>.

我知道,Motion库具有transition(to: <UIViewController>)方法。但是这种方法对我不起作用,因为它代替了rootViewController

1 个答案:

答案 0 :(得分:0)

此问题已在CosmicMind/Motion #42中修复,并在Motion 1.4.3随附的Material 2.16.3中发布