////
////  WA_HomeVC.swift
////  wallpaper_project
////
////  Created by 忆海16 on 2024/3/11.
////
//
import UIKit
//import JXSegmentedView
//import SnapKit
//import Photos
//
//
class WA_HomeVC: WA_RootVC {
//    @IBOutlet weak var segmentedView: JXSegmentedView!
//    var  segmentedDataSource = JXSegmentedTitleDataSource()
//    var listContainerView: JXSegmentedListContainerView!
//    
//    override func viewDidLoad() {
//        super.viewDidLoad()
//        
//        setSegamented()
////        requestPhotoLibraryPermission()
//       
//    }
//    
//    override func viewWillAppear(_ animated: Bool) {
//        super.viewWillAppear(true)
//        self.navigationController?.navigationBar.isHidden = true
//    }
//    
//   
//    
//    
//    func setSegamented(){
//        segmentedView.delegate = self
//        //配置数据源相关配置属性
//        segmentedDataSource.titles = [ "LIVE","4K"]
//        segmentedDataSource.titleSelectedColor = .hexSting(color: "#000000", alpha: 1)
//        segmentedDataSource.titleNormalColor = .hexSting(color: "#A1B2AF", alpha: 1)
//        
//        segmentedDataSource.titleSelectedFont = .boldSystemFont(ofSize: 20)
//        segmentedDataSource.titleNormalFont = .systemFont(ofSize: 18)
//        segmentedDataSource.isTitleColorGradientEnabled = true
//        self.segmentedDataSource.reloadData(selectedIndex: 0)
//        //关联dataSource
//        self.segmentedView.dataSource = segmentedDataSource
//        
//        
//        let indicator = JXSegmentedIndicatorLineView()
//        indicator.indicatorColor = .hexSting(color: "#1FD7B2", alpha: 1)
//        self.segmentedView.indicators = [indicator]
//        
//        listContainerView =  JXSegmentedListContainerView(dataSource: self)
//        self.view.addSubview(listContainerView)
//        
//        segmentedView.listContainer = listContainerView
//    }
//    override func viewDidLayoutSubviews() {
//        super.viewDidLayoutSubviews()
//        listContainerView.snp.makeConstraints { make in
//            make.top.equalTo(segmentedView.snp.bottom).offset(0)
//            make.width.equalToSuperview()
//            make.bottom.equalToSuperview()
//        }
//    }
//    
//    
//    
//    
}
//extension WA_HomeVC:JXSegmentedListContainerViewDataSource,JXSegmentedViewDelegate{
//    
//    //返回列表的数量
//    func numberOfLists(in listContainerView: JXSegmentedListContainerView) -> Int {
//        return 2
//    }
//    //返回遵从`JXSegmentedListContainerViewListDelegate`协议的实例
//    func listContainerView(_ listContainerView: JXSegmentedListContainerView, initListAt index: Int) -> JXSegmentedListContainerViewListDelegate {
//        
//        if index == 0  {
//            let vc = WA_LIVEVC()
//            return vc
//        }else{
//            let vc = WA_4KVC()
//            return vc
//        }
//    }
//}
