我在 CarPlay 模拟器上运行我的应用程序,但它不支持任何触摸,也不显示标签栏。我添加了 com.apple.developer.playable-content 权利。是否需要添加任何其他权利才能在 CarPlay 模拟器上使用触摸功能。仅供引用,默认消息应用程序使用触摸功能。
最佳答案
经过几天的努力。我终于开始工作了。
1) 在您的项目中设置权利
<key>com.apple.developer.carplay-protocols</key> <array> <string>com.brand.carplay.feature</string> </array>
2) 在终端中激活 CarPlay 窗口
defaults write com.apple.iphonesimulator CarPlay -bool YES
3) 激活额外选项
defaults write com.apple.iphonesimulator CarPlayExtraOptions -bool YES
4) 将您的 CarPlay 协议(protocol)添加到 iPhone 模拟器
defaults write com.apple.iphonesimulator CarPlayProtocols -array-add com.brand.carplay.feature
您应该清理项目并从 iOS 模拟器中删除应用程序。之后 - 触摸屏和 UITabBarController 在我的应用程序中工作。
关于ios - 如何在carplay模拟器中启用触摸,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/53914249/