search rounded corner view bug fix

This commit is contained in:
Chris Li 2016-10-20 15:13:06 -04:00
parent 8d594535ba
commit 1af328ca3d
3 changed files with 17 additions and 4 deletions

View File

@ -49,7 +49,7 @@
</dict> </dict>
</array> </array>
<key>CFBundleVersion</key> <key>CFBundleVersion</key>
<string>1.8.1862</string> <string>1.8.1869</string>
<key>ITSAppUsesNonExemptEncryption</key> <key>ITSAppUsesNonExemptEncryption</key>
<false/> <false/>
<key>LSRequiresIPhoneOS</key> <key>LSRequiresIPhoneOS</key>

View File

@ -67,8 +67,21 @@ class SearchHRegularDropShadowView: UIView {
} }
class SearchRoundedCornerView: UIView { class SearchRoundedCornerView: UIView {
override func awakeFromNib() { override func awakeFromNib() {
layer.masksToBounds = true layer.masksToBounds = true
layer.cornerRadius = 10.0
} }
}
override func traitCollectionDidChange(previousTraitCollection: UITraitCollection?) {
guard traitCollection != previousTraitCollection else {return}
switch traitCollection.horizontalSizeClass {
case .Regular:
layer.cornerRadius = 10.0
case .Compact:
layer.cornerRadius = 0.0
default:
break
}
}
}

View File

@ -21,7 +21,7 @@
<key>CFBundleSignature</key> <key>CFBundleSignature</key>
<string>????</string> <string>????</string>
<key>CFBundleVersion</key> <key>CFBundleVersion</key>
<string>1.8.1862</string> <string>1.8.1869</string>
<key>NSExtension</key> <key>NSExtension</key>
<dict> <dict>
<key>NSExtensionMainStoryboard</key> <key>NSExtensionMainStoryboard</key>