嗨,我是 iOS 初学者,我无法手动安装 Guillotine Menu https://github.com/Yalantis/GuillotineMenu
使用 Xcode 6.3 & iOS8.3
这就是我所做的 1) 从示例中添加 Guillotine Menu 文件和资产,复制到选定的项目目标并放在我的项目名称的文件下
2) 在界面生成器中创建 ViewController 并将类设置为 GuillotineMeneViewController,它在下拉列表中
3) 在单视图应用程序附带的 ViewController 中,我在界面生成器中创建了条形按钮项和按钮,将按钮出口连接到代码
4) 控件拖到 GuillotineMenuViewController 设置 segue 到 Custom 和类 GuillotineMenu 它在下拉列表中
5) 在我的 ViewController 中,我将导航条码从示例复制到 viewDidLoad,然后复制为 segue 做准备
试图运行并不断收到使用未声明类型“guillotineMenuViewController”的错误
这是我的 ViewController 代码
import UIKit
class ViewController: UIViewController {
@IBOutlet weak var barButton: UIButton!
override func viewDidLoad() {
super.viewDidLoad()
let navBar = self.navigationController!.navigationBar
navBar.barTintColor = UIColor(red: 65.0 / 255.0, green: 62.0 / 255.0, blue: 79.0 / 255.0, alpha: 1)
navBar.titleTextAttributes = [NSForegroundColorAttributeName: UIColor.whiteColor()]
}
override func prepareForSegue(segue: UIStoryboardSegue, sender: AnyObject?) {
// Your Menu View Controller vew must know the following data for the proper animatio
let destinationVC = segue.destinationViewController as! GuillotineMenuViewController
destinationVC.hostNavigationBarHeight = self.navigationController!.navigationBar.frame.size.height
destinationVC.hostTitleText = self.navigationItem.title
destinationVC.view.backgroundColor = self.navigationController!.navigationBar.barTintColor
destinationVC.setMenuButtonWithImage(barButton.imageView!.image!)
}
}