| | |
| | | private var totalInterval:TimeInterval = 0 |
| | | |
| | | private var model:MeditationModel? |
| | | private var gradientLayer:CAGradientLayer? |
| | | |
| | | init(model:MeditationModel) { |
| | | super.init(nibName: nil, bundle: nil) |
| | |
| | | override func viewDidDisappear(_ animated: Bool) { |
| | | super.viewDidDisappear(animated) |
| | | |
| | | if let m = model,timeLook > 0{ |
| | | audioPlayer.lisenMuseTime = 0 |
| | | Services.watchMuse(id: m.id, timeLook: timeLook).subscribe(onNext: {_ in |
| | | NotificationCenter.default.post(name: TreeTaskUpdate_Noti, object: nil) |
| | | }).disposed(by: disposeBag) |
| | | } |
| | | // if let m = model,timeLook > 0{ |
| | | // audioPlayer.lisenMuseTime = 0 |
| | | // Services.watchMuse(id: m.id, timeLook: timeLook).subscribe(onNext: {_ in |
| | | // NotificationCenter.default.post(name: TreeTaskUpdate_Noti, object: nil) |
| | | // }).disposed(by: disposeBag) |
| | | // } |
| | | } |
| | | |
| | | override func setUI() { |
| | |
| | | |
| | | override func viewDidLayoutSubviews() { |
| | | super.viewDidLayoutSubviews() |
| | | |
| | | view_function.jq_gradientColor(colorArr: [UIColor.black.withAlphaComponent(0.35).cgColor,UIColor.clear.cgColor], cornerRadius: 0, startPoint: CGPoint(x: 0, y: 1), endPoint: CGPoint(x: 0, y: 0), bounds: nil, locations: nil) |
| | | if gradientLayer == nil{ |
| | | gradientLayer = view_function.jq_gradientColor(colorArr: [UIColor.black.withAlphaComponent(0.35).cgColor,UIColor.clear.cgColor], cornerRadius: 0, startPoint: CGPoint(x: 0, y: 1), endPoint: CGPoint(x: 0, y: 0), bounds: nil, locations: nil) |
| | | } |
| | | } |
| | | |
| | | |