- Fixed the my list gradient issue
- Worked on web series bug fixes for moving view.
This commit is contained in:
@@ -55,6 +55,10 @@ class MyListVC: UIViewController{
|
||||
|
||||
}
|
||||
|
||||
override func viewDidLayoutSubviews() {
|
||||
vm.addGradient()
|
||||
}
|
||||
|
||||
override func viewDidAppear(_ animated: Bool) {
|
||||
if K.GVar.reloadMyList{
|
||||
K.GVar.reloadMyList = false
|
||||
|
||||
@@ -875,7 +875,7 @@
|
||||
<rect key="frame" x="0.0" y="574.33333333333337" width="430" height="294.66666666666663"/>
|
||||
</imageView>
|
||||
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="cxl-Av-gEU">
|
||||
<rect key="frame" x="0.0" y="0.0" width="430" height="119"/>
|
||||
<rect key="frame" x="0.0" y="0.0" width="430" height="116"/>
|
||||
<color key="backgroundColor" systemColor="systemMintColor"/>
|
||||
</view>
|
||||
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="a7Y-B6-f0Q">
|
||||
@@ -1118,10 +1118,10 @@
|
||||
<constraint firstItem="SyC-Qw-kzE" firstAttribute="bottom" secondItem="fPD-rO-ZgU" secondAttribute="bottom" id="7R3-kt-ANX"/>
|
||||
<constraint firstItem="fTK-nk-bN9" firstAttribute="leading" secondItem="fPD-rO-ZgU" secondAttribute="leading" id="KDZ-vt-s13"/>
|
||||
<constraint firstItem="a7Y-B6-f0Q" firstAttribute="top" secondItem="fPD-rO-ZgU" secondAttribute="top" constant="10" id="L4o-KM-D1O"/>
|
||||
<constraint firstItem="cxl-Av-gEU" firstAttribute="bottom" secondItem="a7Y-B6-f0Q" secondAttribute="bottom" constant="7" id="Lur-Ax-w8w"/>
|
||||
<constraint firstItem="SyC-Qw-kzE" firstAttribute="trailing" secondItem="fPD-rO-ZgU" secondAttribute="trailing" id="M3t-nE-gwc"/>
|
||||
<constraint firstItem="5ML-g4-686" firstAttribute="leading" secondItem="23B-pX-ODs" secondAttribute="leading" constant="5" id="Na5-Wr-DSa"/>
|
||||
<constraint firstItem="SyC-Qw-kzE" firstAttribute="top" secondItem="a7Y-B6-f0Q" secondAttribute="bottom" constant="10" id="Nyh-j8-zuL"/>
|
||||
<constraint firstItem="SyC-Qw-kzE" firstAttribute="top" secondItem="cxl-Av-gEU" secondAttribute="bottom" id="Qiy-pS-3K3"/>
|
||||
<constraint firstItem="fPD-rO-ZgU" firstAttribute="trailing" secondItem="fTK-nk-bN9" secondAttribute="trailing" id="XRW-xO-sGx"/>
|
||||
<constraint firstItem="cxl-Av-gEU" firstAttribute="top" secondItem="23B-pX-ODs" secondAttribute="top" id="Y0G-Ua-UcP"/>
|
||||
<constraint firstItem="QHo-nZ-miK" firstAttribute="centerX" secondItem="fPD-rO-ZgU" secondAttribute="centerX" id="ZkK-bD-6Ys"/>
|
||||
|
||||
@@ -28,17 +28,19 @@ class MyListVM{
|
||||
var selectedCollection : CollectionSelectionMyList?
|
||||
|
||||
func initView(){
|
||||
let color1 = #colorLiteral(red: 0.6745098039, green: 0.6235294118, blue: 0.1725490196, alpha: 1)
|
||||
let color2 = #colorLiteral(red: 0.5450980392, green: 0.6745098039, blue: 0.1725490196, alpha: 1)
|
||||
|
||||
vc.gradientView.applyGradient(colors: [color2, color1], startPoint: CGPoint(x: 0, y: 0), endPoint: CGPoint(x: 0.8, y: 0))
|
||||
|
||||
setupCell()
|
||||
Utilities.startProgressHUD()
|
||||
getFavouriteListing()
|
||||
NotificationCenter.default.addObserver(self, selector: #selector(languageChanged), name: .languageDidChange, object: nil)
|
||||
}
|
||||
|
||||
func addGradient(){
|
||||
let color1 = #colorLiteral(red: 0.6745098039, green: 0.6235294118, blue: 0.1725490196, alpha: 1)
|
||||
let color2 = #colorLiteral(red: 0.5450980392, green: 0.6745098039, blue: 0.1725490196, alpha: 1)
|
||||
|
||||
vc.gradientView.applyGradient(colors: [color2, color1], startPoint: CGPoint(x: 0, y: 0), endPoint: CGPoint(x: 0.8, y: 0))
|
||||
}
|
||||
|
||||
@objc func languageChanged(){
|
||||
self.reloadCollections()
|
||||
}
|
||||
|
||||
@@ -153,7 +153,7 @@
|
||||
<constraint firstAttribute="height" constant="75" id="kT7-18-wB5"/>
|
||||
</constraints>
|
||||
</imageView>
|
||||
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="edI-4n-4AY">
|
||||
<view userInteractionEnabled="NO" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="edI-4n-4AY">
|
||||
<rect key="frame" x="14.333333333333329" y="58.333333333333336" width="167" height="114.33333333333331"/>
|
||||
<color key="backgroundColor" systemColor="systemGreenColor"/>
|
||||
</view>
|
||||
|
||||
@@ -110,6 +110,7 @@ class PlayerVC: JWPlayerViewController, JWPlayerViewControllerDelegate {
|
||||
player.play()
|
||||
}else{
|
||||
player.play()
|
||||
player.stop()
|
||||
player.nextUpPlaylistIndex = videoIndex ?? 0
|
||||
player.next()
|
||||
}
|
||||
|
||||
@@ -81,6 +81,10 @@ class ThemeOneVC: UIViewController {
|
||||
}
|
||||
}
|
||||
|
||||
@IBAction func clickedBtn(_ sender: UIButton) {
|
||||
print("Clicked")
|
||||
}
|
||||
|
||||
@IBAction func barButtonTapped(_ sender: UIButton) {
|
||||
self.sideMenuController?.revealMenu()
|
||||
}
|
||||
|
||||
@@ -45,7 +45,6 @@ class MoreVM{
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
func setupAudioSession() {
|
||||
let session = AVAudioSession.sharedInstance()
|
||||
do {
|
||||
@@ -111,7 +110,8 @@ class MoreVM{
|
||||
|
||||
func getBLogs(){
|
||||
Utilities.startProgressHUD()
|
||||
NetworkManager.shareInstance.apiRequest(url: APIEndPoints.Home.blogs, method: .get) {(result : Result<BaseResponseModel<BlogDM>, NetworkManager.APIError>) in
|
||||
NetworkManager.shareInstance.apiRequest(url: APIEndPoints.Home.blogs, method: .get) { [weak self](result : Result<BaseResponseModel<BlogDM>, NetworkManager.APIError>) in
|
||||
guard let self else{return}
|
||||
switch result{
|
||||
case .success(let data):
|
||||
switch data.success{
|
||||
@@ -120,13 +120,13 @@ class MoreVM{
|
||||
Error
|
||||
*/
|
||||
Utilities.dismissProgressHUD()
|
||||
self.vc.toast(msg: data.message ?? "Unrecognised error" , time: 2)
|
||||
vc.toast(msg: data.message ?? "Unrecognised error" , time: 2)
|
||||
case 1:
|
||||
Utilities.dismissProgressHUD()
|
||||
guard let data = data.data?.blogs else{return}
|
||||
self.blogData = data
|
||||
self.blogData.append(contentsOf: data)
|
||||
self.vc.blogsCollectionView.reloadData()
|
||||
blogData = data
|
||||
blogData.append(contentsOf: data)
|
||||
vc.blogsCollectionView.reloadData()
|
||||
//Fetched Blogs
|
||||
break
|
||||
default:
|
||||
@@ -134,13 +134,14 @@ class MoreVM{
|
||||
}
|
||||
case .failure(let error):
|
||||
Utilities.dismissProgressHUD()
|
||||
self.vc.toast(msg: error.localizedDescription , time: 2)
|
||||
vc.toast(msg: error.localizedDescription , time: 2)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func getSong(){
|
||||
NetworkManager.shareInstance.apiRequest(url: APIEndPoints.Home.song_listing, method: .post) {(result : Result<BaseResponseModel<SongBlogDM>, NetworkManager.APIError>) in
|
||||
NetworkManager.shareInstance.apiRequest(url: APIEndPoints.Home.song_listing, method: .post) { [weak self](result : Result<BaseResponseModel<SongBlogDM>, NetworkManager.APIError>) in
|
||||
guard let self else{return}
|
||||
switch result{
|
||||
case .success(let data):
|
||||
switch data.success{
|
||||
@@ -149,19 +150,19 @@ class MoreVM{
|
||||
Error
|
||||
*/
|
||||
Utilities.dismissProgressHUD()
|
||||
self.vc.toast(msg: data.message ?? "Unrecognised error" , time: 2)
|
||||
vc.toast(msg: data.message ?? "Unrecognised error" , time: 2)
|
||||
case 1:
|
||||
Utilities.dismissProgressHUD()
|
||||
guard let data = data.data?.paintData else{return}
|
||||
self.songData = data
|
||||
self.vc.songTableView.reloadData()
|
||||
songData = data
|
||||
vc.songTableView.reloadData()
|
||||
break
|
||||
default:
|
||||
break
|
||||
}
|
||||
case .failure(let error):
|
||||
Utilities.dismissProgressHUD()
|
||||
self.vc.toast(msg: error.localizedDescription , time: 2)
|
||||
vc.toast(msg: error.localizedDescription , time: 2)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -119,13 +119,13 @@ class ThemeOneVM{
|
||||
func handleTaps(){
|
||||
//WebSeries
|
||||
vc.webSeriesView.addTapGesture {
|
||||
ViewButtonAnimation.sharedInstance.btnTapped(in: self.vc, view: self.vc.webSeriesView) {
|
||||
ViewButtonAnimation.sharedInstance.btnTapped(in: self.vc, view: self.vc.webSeriesView) { [weak self] in
|
||||
guard let self else{return}
|
||||
let sb = UIStoryboard(name: K.StoryBoard.webSeries, bundle: nil)
|
||||
let vcPush = sb.instantiateViewController(withIdentifier: K.StoryBoardID.WebSeries.webSeriesVC) as! WebSeriesVC
|
||||
self.vc.navigationController?.pushViewController(vcPush, animated: true)
|
||||
vc.navigationController?.pushViewController(vcPush, animated: true)
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// MARK: - Animate Clouds and LiveTV
|
||||
@@ -134,6 +134,7 @@ class ThemeOneVM{
|
||||
DispatchQueue.main.async { [weak self] in
|
||||
guard let self = self else { return }
|
||||
self.vc.liveTVView.center.x = self.vc.view.center.x // Center the liveTVView horizontally
|
||||
self.vc.liveTVView.layoutIfNeeded()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -341,3 +342,18 @@ class ThemeOneVM{
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
//class CustomLiveTVView: UIView {
|
||||
// override func hitTest(_ point: CGPoint, with event: UIEvent?) -> UIView? {
|
||||
// let hitView = super.hitTest(point, with: event)
|
||||
// // Debug statement to check when hitTest is called
|
||||
// print("hitTest called with point: \(point)")
|
||||
//
|
||||
// // Check if the touch is within the bounds of this view
|
||||
// if hitView == self {
|
||||
// return hitView
|
||||
// }
|
||||
// // If the touch is outside the bounds, return nil
|
||||
// return nil
|
||||
// }
|
||||
//}
|
||||
|
||||
@@ -46,8 +46,8 @@
|
||||
<rect key="frame" x="10" y="183" width="487" height="35"/>
|
||||
<subviews>
|
||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="m8K-7d-Jib">
|
||||
<rect key="frame" x="0.0" y="8.6666666666666572" width="39" height="18"/>
|
||||
<fontDescription key="fontDescription" name="Exo2-Bold" family="Exo 2" pointSize="15"/>
|
||||
<rect key="frame" x="0.0" y="7.9999999999999982" width="41.666666666666664" height="19.333333333333329"/>
|
||||
<fontDescription key="fontDescription" name="Exo2-Bold" family="Exo 2" pointSize="16"/>
|
||||
<color key="textColor" name="ImageDarkBlue"/>
|
||||
<nil key="highlightedColor"/>
|
||||
</label>
|
||||
@@ -142,7 +142,7 @@
|
||||
<image name="FavouriteRemove" width="42.666667938232422" height="42.666667938232422"/>
|
||||
<image name="LikeRemove" width="42.666667938232422" height="42.666667938232422"/>
|
||||
<namedColor name="ImageDarkBlue">
|
||||
<color red="0.035294117647058823" green="0.0" blue="0.36470588235294116" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color red="0.035000000149011612" green="0.0" blue="0.36500000953674316" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</namedColor>
|
||||
<systemColor name="systemBackgroundColor">
|
||||
<color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
|
||||
|
||||
@@ -58,11 +58,11 @@
|
||||
<rect key="frame" x="0.0" y="0.0" width="393" height="108"/>
|
||||
<subviews>
|
||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="MASILA" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="RDe-bw-Rsd">
|
||||
<rect key="frame" x="145.66666666666666" y="0.0" width="102" height="50"/>
|
||||
<rect key="frame" x="149.33333333333334" y="0.0" width="94.666666666666657" height="50"/>
|
||||
<constraints>
|
||||
<constraint firstAttribute="height" constant="50" id="niS-eQ-1x0"/>
|
||||
</constraints>
|
||||
<fontDescription key="fontDescription" name="Exo2-Bold" family="Exo 2" pointSize="28"/>
|
||||
<fontDescription key="fontDescription" name="Exo2-Bold" family="Exo 2" pointSize="26"/>
|
||||
<color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
|
||||
<nil key="highlightedColor"/>
|
||||
</label>
|
||||
@@ -220,7 +220,7 @@
|
||||
<viewLayoutGuide key="frameLayoutGuide" id="kWi-Yi-A7Z"/>
|
||||
</scrollView>
|
||||
</subviews>
|
||||
<color key="backgroundColor" red="0.035294117647058823" green="0.0" blue="0.36470588235294116" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="backgroundColor" red="0.019607843137254902" green="0.0" blue="0.2196078431372549" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</stackView>
|
||||
</subviews>
|
||||
<viewLayoutGuide key="safeArea" id="vDu-zF-Fre"/>
|
||||
@@ -644,7 +644,7 @@
|
||||
</subviews>
|
||||
</stackView>
|
||||
</subviews>
|
||||
<color key="backgroundColor" red="0.035294117649999998" green="0.0" blue="0.36470588240000001" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="backgroundColor" red="0.019607843137254902" green="0.0" blue="0.2196078431372549" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<constraints>
|
||||
<constraint firstItem="JVZ-ee-mig" firstAttribute="leading" secondItem="6BC-EI-c6S" secondAttribute="leading" id="539-an-m3X"/>
|
||||
<constraint firstItem="JVZ-ee-mig" firstAttribute="top" secondItem="Ka5-Rt-V3L" secondAttribute="top" id="Bgm-6h-ooD"/>
|
||||
@@ -657,7 +657,7 @@
|
||||
</scrollView>
|
||||
</subviews>
|
||||
<viewLayoutGuide key="safeArea" id="5r4-z5-Bnx"/>
|
||||
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
|
||||
<color key="backgroundColor" red="0.019607843140000001" green="0.0" blue="0.21960784310000001" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<constraints>
|
||||
<constraint firstItem="Ka5-Rt-V3L" firstAttribute="top" secondItem="5r4-z5-Bnx" secondAttribute="top" id="9Yv-dh-L30"/>
|
||||
<constraint firstAttribute="bottom" secondItem="Ka5-Rt-V3L" secondAttribute="bottom" id="HYj-vK-Xwc"/>
|
||||
@@ -1069,7 +1069,7 @@
|
||||
<image name="hand.thumbsup.fill" catalog="system" width="128" height="121"/>
|
||||
<image name="heart" catalog="system" width="128" height="107"/>
|
||||
<namedColor name="ImageDarkBlue">
|
||||
<color red="0.035294117647058823" green="0.0" blue="0.36470588235294116" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color red="0.035000000149011612" green="0.0" blue="0.36500000953674316" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</namedColor>
|
||||
<namedColor name="TextDarkBlue">
|
||||
<color red="0.10599999874830246" green="0.050999999046325684" blue="0.60399997234344482" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
|
||||
Reference in New Issue
Block a user