我需要幫助解決Swift 3中的這個錯誤! enter image description hereCGRect.init() - 參數標籤與任何可用的重載不匹配
let button = UIButton(frame: CGRect(0, 0, 40, 40)) // Create new button & set its frame
button.setImage(UIImage(named: "refresh"), for: []) // Assign an image
barButton.customView = button // Set as barButton's customView
使用自動完成或檢查文檔以查找可用的過載。 'CGRect'沒有沒有參數標籤的初始化器,因爲你需要告訴編譯器在什麼座標系中/你需要什麼單位來初始化CGRect。 –