|
@@ -49,16 +49,30 @@ class BFVoiceSettingView: UIView {
|
|
|
var curretnCategory: BFVoiceCategoryModel?
|
|
|
// 当前选择的发音人
|
|
|
public var selectVoice: PQVoiceModel?
|
|
|
+
|
|
|
+
|
|
|
|
|
|
+ lazy var line1:UIView = {
|
|
|
+ let line1 = UIView.init(frame: CGRect(x: 0, y: catagaryCollectView.frame.minY - 1, width: cScreenWidth, height: 1))
|
|
|
+ line1.backgroundColor = UIColor.hexColor(hexadecimal: "#272727")
|
|
|
+ return line1
|
|
|
+
|
|
|
+ }()
|
|
|
+ lazy var line2:UIView = {
|
|
|
+ let line2 = UIView.init(frame: CGRect(x: 0, y: catagaryCollectView.frame.maxY + 1, width: cScreenWidth, height: 1))
|
|
|
+ line2.backgroundColor = UIColor.hexColor(hexadecimal: "#272727")
|
|
|
+ return line2
|
|
|
+
|
|
|
+ }()
|
|
|
// 分类列表
|
|
|
lazy var catagaryCollectView: UICollectionView = {
|
|
|
let layout = UICollectionViewFlowLayout()
|
|
|
layout.scrollDirection = .horizontal
|
|
|
layout.itemSize = itemSize
|
|
|
- layout.minimumLineSpacing = 10
|
|
|
+ layout.minimumLineSpacing = 30
|
|
|
layout.sectionInset = UIEdgeInsets.zero
|
|
|
layout.minimumInteritemSpacing = 0
|
|
|
- let collectView = UICollectionView(frame: CGRect(x: 60, y: 0, width: cScreenWidth, height: 40), collectionViewLayout: layout)
|
|
|
+ let collectView = UICollectionView(frame: CGRect(x: 60, y: 0, width: cScreenWidth - 60, height: 40), collectionViewLayout: layout)
|
|
|
collectView.isPagingEnabled = false
|
|
|
collectView.showsHorizontalScrollIndicator = false
|
|
|
collectView.showsVerticalScrollIndicator = false
|
|
@@ -97,12 +111,12 @@ class BFVoiceSettingView: UIView {
|
|
|
layout.scrollDirection = .vertical
|
|
|
layout.itemSize = CGSize(width: adapterWidth(width: 60), height: 78)
|
|
|
// 每行最小边距
|
|
|
- layout.minimumLineSpacing = 10
|
|
|
+ layout.minimumLineSpacing = 34
|
|
|
// 每列最小边距
|
|
|
- layout.minimumInteritemSpacing = 0
|
|
|
+ layout.minimumInteritemSpacing = 20
|
|
|
layout.sectionInset = UIEdgeInsets.zero
|
|
|
|
|
|
- let collectView = UICollectionView(frame: CGRect(x: 0, y: 98, width: cScreenWidth, height: 242 - cSafeAreaHeight), collectionViewLayout: layout)
|
|
|
+ let collectView = UICollectionView(frame: CGRect(x: 32, y: 100, width: cScreenWidth - 32 * 2, height: 242 - cSafeAreaHeight), collectionViewLayout: layout)
|
|
|
collectView.isPagingEnabled = false
|
|
|
collectView.showsHorizontalScrollIndicator = false
|
|
|
collectView.showsVerticalScrollIndicator = false
|
|
@@ -187,6 +201,8 @@ class BFVoiceSettingView: UIView {
|
|
|
}
|
|
|
|
|
|
catagaryBackView.addSubview(catagaryCollectView)
|
|
|
+ catagaryBackView.addSubview(line1)
|
|
|
+ catagaryBackView.addSubview(line2)
|
|
|
|
|
|
catagaryBackView.addSubview(deleteBtn)
|
|
|
deleteBtn.snp.makeConstraints { make in
|