|
@@ -13,7 +13,7 @@ class PQPhotoAlbumController: PQBaseViewController {
|
|
var selectedHandle: ((_ selectedData: PQUploadModel?) -> Void)? // 选中/取消选中的回调
|
|
var selectedHandle: ((_ selectedData: PQUploadModel?) -> Void)? // 选中/取消选中的回调
|
|
var isTopShow: Bool = false // 是否显示在顶部
|
|
var isTopShow: Bool = false // 是否显示在顶部
|
|
|
|
|
|
- var categoryH: CGFloat = cDefaultMargin * 26 // 相簿高度
|
|
|
|
|
|
+ var categoryH: CGFloat = cDefaultMargin * 26 // 相簿高度
|
|
var albaumsData: [PQUploadModel] = Array<PQUploadModel>.init()
|
|
var albaumsData: [PQUploadModel] = Array<PQUploadModel>.init()
|
|
let itemSize = CGSize(width: ((cScreenWidth - cDefaultMargin) / 3) * UIScreen.main.scale, height: ((cScreenWidth - cDefaultMargin) / 3) * UIScreen.main.scale)
|
|
let itemSize = CGSize(width: ((cScreenWidth - cDefaultMargin) / 3) * UIScreen.main.scale, height: ((cScreenWidth - cDefaultMargin) / 3) * UIScreen.main.scale)
|
|
var catagerySelectedIndex: IndexPath = IndexPath(item: 0, section: 0) // 更多图库选择
|
|
var catagerySelectedIndex: IndexPath = IndexPath(item: 0, section: 0) // 更多图库选择
|
|
@@ -24,10 +24,10 @@ class PQPhotoAlbumController: PQBaseViewController {
|
|
lazy var albaumCollectionView: UICollectionView = {
|
|
lazy var albaumCollectionView: UICollectionView = {
|
|
let layout = UICollectionViewFlowLayout()
|
|
let layout = UICollectionViewFlowLayout()
|
|
layout.sectionInset = UIEdgeInsets.zero
|
|
layout.sectionInset = UIEdgeInsets.zero
|
|
- layout.itemSize = CGSize(width: view.frame.width, height: cDefaultMargin * 8)
|
|
|
|
|
|
+ layout.itemSize = CGSize(width: view.frame.width, height: cDefaultMargin * 8 )
|
|
layout.minimumLineSpacing = 0
|
|
layout.minimumLineSpacing = 0
|
|
layout.minimumInteritemSpacing = 0
|
|
layout.minimumInteritemSpacing = 0
|
|
- let albaumCollectionView = UICollectionView(frame: CGRect(x: 0, y: isTopShow ? 0 : (albaumView.frame.height - categoryH), width: albaumView.frame.width, height: isTopShow ? 0 : categoryH), collectionViewLayout: layout)
|
|
|
|
|
|
+ let albaumCollectionView = UICollectionView(frame: CGRect(x: 0, y: isTopShow ? 0 : (albaumView.frame.height - categoryH), width: albaumView.frame.width, height: isTopShow ? 0 : categoryH - 300), collectionViewLayout: layout)
|
|
albaumCollectionView.showsVerticalScrollIndicator = false
|
|
albaumCollectionView.showsVerticalScrollIndicator = false
|
|
albaumCollectionView.register(PQAssetCategoryCell.self, forCellWithReuseIdentifier: "PQAssetCategoryCell")
|
|
albaumCollectionView.register(PQAssetCategoryCell.self, forCellWithReuseIdentifier: "PQAssetCategoryCell")
|
|
albaumCollectionView.delegate = self
|
|
albaumCollectionView.delegate = self
|
|
@@ -37,7 +37,7 @@ class PQPhotoAlbumController: PQBaseViewController {
|
|
} else {
|
|
} else {
|
|
automaticallyAdjustsScrollViewInsets = false
|
|
automaticallyAdjustsScrollViewInsets = false
|
|
}
|
|
}
|
|
- albaumCollectionView.backgroundColor = UIColor.clear
|
|
|
|
|
|
+ albaumCollectionView.backgroundColor = UIColor.white
|
|
return albaumCollectionView
|
|
return albaumCollectionView
|
|
}()
|
|
}()
|
|
|
|
|
|
@@ -75,9 +75,9 @@ class PQPhotoAlbumController: PQBaseViewController {
|
|
|
|
|
|
override func viewDidLoad() {
|
|
override func viewDidLoad() {
|
|
super.viewDidLoad()
|
|
super.viewDidLoad()
|
|
-
|
|
|
|
|
|
+
|
|
// Do any additional setup after loading the view.
|
|
// Do any additional setup after loading the view.
|
|
- view.backgroundColor = PQBFConfig.shared.styleBackGroundColor
|
|
|
|
|
|
+ view.backgroundColor = UIColor.init(red: 0, green: 0, blue: 0, alpha: 0.7)
|
|
hiddenNavigation()
|
|
hiddenNavigation()
|
|
loadPhotoData()
|
|
loadPhotoData()
|
|
}
|
|
}
|