相关疑难解决方法(0)

iPhone 7/7plus上的空snapshotView

我的第一个问题:)最近我将我的Xcode更新为8,并且该resizableSnapshotView方法在某些模拟器上无法正常工作.snapshotView适用于所有iOS9/10测试设备和iPhone6s下的模拟器,但在iPhone7/7p模拟器上它是空的.我认为7/7p可能需要一些权限来访问快照,但我不知道它们是什么.

let cell = self.tableView.cellForRow(at: IndexPath(row: 0, section: 0)) as! CalendarCell     
var topFrame = cell.frame
topFrame.origin.y = tableView.contentOffset.y
topFrame.size.height -= tableView.contentOffset.y
topSnapshotView = tableView.resizableSnapshotView(from: topFrame, afterScreenUpdates: false, withCapInsets: UIEdgeInsets.zero)
Run Code Online (Sandbox Code Playgroud)

iphone ios swift3 ios10

12
推荐指数
1
解决办法
2239
查看次数

标签 统计

ios ×1

ios10 ×1

iphone ×1

swift3 ×1