Array element cannot be bridged to Objective-C

后端 未结 5 1459
庸人自扰
庸人自扰 2020-12-01 14:13

I have this code that creates a view and applies a gradient to it.

import UIKit
import QuartzCore


let rect : CGRect = CGRectMake(0,0,320,100)

var vista :          


        
5条回答
  •  臣服心动
    2020-12-01 14:22

    With Swift arrays, you can call bridgeToObjectiveC() on them, and they'll turn into NSArrays. The same is true of Swift dictionaries.

提交回复
热议问题