使用参数初始化UIButton

时间:2015-09-13 16:32:35

标签: ios swift uibutton

我想使用参数初始化func downloadChapter(notification : NSNotification){ //fetch on different thread let qos = Int(QOS_CLASS_USER_INITIATED.value) dispatch_async(dispatch_get_global_queue(qos, 0), { //download here //back to main thread dispatch_async(dispatch_get_main_queue(), { //if there is something more you wanna do or you can just go back }) }) } @IBAction func downloadBarButton(sender: AnyObject) { var obtainedMangaNameArray = [self.obtainedMangaName] let userInfo = ["downloadList" : self.selectedChapters , "mangaName" : obtainedMangaNameArray] var sdfs = DownloadHandler() let notification = NSNotification(name: "downloadListNotification", object: DownloadRequestListViewController.self, userInfo: userInfo) sdfs.downloadChapter(notification) //NSNotificationCenter.defaultCenter().postNotification(notification) } 的子类,但是我的UIButton方法出现EXC_BAD_INSTRUCTION错误:

init(create: ; coder:)

0 个答案:

没有答案
相关问题