LoginSignup
0
0

More than 5 years have passed since last update.

CGRectContainsPoint - Swift 3 調整記

Last updated at Posted at 2016-10-24

今天寫了這個:

CGRectContainsPoint(rect, anotherRect.origin)

Xcode 8 告訴我,
這個方式被調整成這個寫法:

rect.contains(anotherRect.origin)

除了移除 C style 的全域方法呼叫方式,使用時的語意相較起來比較合理清楚,也更加物件導向。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0