onlinereadbook / bookswift

線上swift讀書會
82 stars 6 forks source link

[實作 Youtube 播放影片仿製 ] 心得分享 #39

Open helloworldsmart opened 7 years ago

helloworldsmart commented 7 years ago

各位大大如果有問題,歡迎給妳滿滿的大發問 😏 😏

source code: https://github.com/mosluce/YoutubeVideoViewControllerDemo

群聊筆記 fallthrough https://developer.apple.com/library/content/documentation/Swift/Conceptual/Swift_Programming_Language/Statements.html

蘇健豪對所有人說: (08:38 下午) 現在好像不用 remove 耶 蘇健豪對所有人說: (08:38 下午) 等一下貼文章 你先繼續 現在是那個 viewController 被系統釋放時 nick對所有人說: (08:39 下午) 因為他是換成weak模式,所以不remove一樣會call , 只是Call了不會掛 蘇健豪對所有人說: (08:39 下午) 系統會幫你呼叫 remove nick對所有人說: (08:39 下午) iOS 9之後 蘇健豪對所有人說: (08:39 下午) 之前看到有人特別去驗證 這篇 http://www.jianshu.com/p/a4d519e4e0d5

yinghong對所有人說: (08:57 下午) 不好意思問一下 case .ended: 前面那個.是什麼意思啊? jun對所有人說: (08:58 下午) AVPlayerLayer <- 這個才對 恩 nick對所有人說: (08:58 下午) if UIDevice.current.orientation == UIDeviceOrientation.landscapeLeft{ print("這是Home鍵在右橫的的方向") }else if UIDevice.current.orientation == UIDeviceOrientation.landscapeRight{ print("這是Home鍵在左橫的的方向") }else if UIDevice.current.orientation == UIDeviceOrientation.portrait{ print("這是Home鍵在下直立的方向") }else if UIDevice.current.orientation == UIDeviceOrientation.portraitUpsideDown{ print("這是Home鍵在上直立的方向") } 我對所有人說: (08:59 下午) 轉型還會耗效能 (筆記 蘇健豪對所有人說: (08:59 下午) 補充一下問那個 case . 的問題 switch 那裡放 enum 的值就可以這樣寫 nick對所有人說: (09:00 下午) 很多地方 只要是指定某個特定enum的時候,就可以簡寫

yinghong對所有人說: (09:01 下午) 像fun 前面 _ 這個是?

nick對所有人說: (09:01 下午) 省略外部參數 nick對所有人說: (09:08 下午) 官方是把介系詞放在那個位置