ios - IB 可设计 : Failed to render and update auto layout status for Google Maps

标签 ios uiview uistoryboard google-maps-sdk-ios

我在我的项目中使用 GoogleMaps Pod。我的 Storyboard之一有错误:

error: IB Designables: Failed to render and update auto layout status for MapViewController: dlopen(GoogleMaps.framework, 1): no suitable image found. Did find: GoogleMaps.framework: mach-o, but wrong filetype

我已将 View 类设置为 GMSMapView:

enter image description here

应用程序正在模拟器上运行。我该如何修复这个错误?它导致整个 Storyboard一片空白。

最佳答案

创建 GMSMapView 的子类并使用该类名而不是 GMSMapView。添加后,不会发生此错误,并且整个 Storyboard正在工作。

import GoogleMaps

class GoogleMapView : GMSMapView {

}

关于ios - IB 可设计 : Failed to render and update auto layout status for Google Maps,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/59260463/

相关文章:

ios - 如何将 swift pod 类导入 Objective C UIView 类

ios - NSDateFormatter "Month"3 个字母而不是完整的单词

ios - 保存 UIView 时不断出现空白图像...如何将 UIView 和 subview 保存到相机胶卷上?

ios - 嵌套的 UIViewController 返回 :'ing out too far

ios - 无法将表格 View 或 ScrollView 拖到 Storyboard View Controller 中

ios - UIScrollView 优于 MKMapView

ios - MonoTouch试用版已提交给App Store?

ios - 使用 UIWebView/WKWebView 时出现奇怪的填充

ios - 使用 UIPanGestureRecognizer 从 CGRect 获取 UIView - Swift 2.0

ios - 在 Swift 中以编程方式在两个 subview 之间添加约束