- Worked on my list and notification bottom Banner
- Tc - 69 fixed - Tc - 70 fixed - TC 71 fixed - Added local ads to fm and more section - Added local ads to mylist - Fixed a bug for sync * Fixed the crashing by temporary updating the wokastaging with raw data
This commit is contained in:
@@ -6,27 +6,25 @@
|
||||
//
|
||||
|
||||
import UIKit
|
||||
import GoogleMobileAds
|
||||
|
||||
class UserNotificationVC: UIViewController {
|
||||
|
||||
@IBOutlet weak var tableView: UITableView!
|
||||
@IBOutlet weak var noDataStack: UIStackView!
|
||||
@IBOutlet weak var adView: UIView!
|
||||
@IBOutlet weak var adViewHeight: NSLayoutConstraint!
|
||||
|
||||
|
||||
|
||||
var vm = UserNotificationVM()
|
||||
|
||||
override func viewDidLoad() {
|
||||
super.viewDidLoad()
|
||||
vm.vc = self
|
||||
vm.initView()
|
||||
|
||||
navigationController?.navigationBar.setBackgroundImage(UIImage(), for: .default)
|
||||
navigationController?.navigationBar.shadowImage = UIImage()
|
||||
}
|
||||
|
||||
|
||||
|
||||
override func viewWillAppear(_ animated: Bool) {
|
||||
super.viewWillAppear(animated)
|
||||
navigationController?.setNavigationBarHidden(false, animated: animated)
|
||||
@@ -99,3 +97,43 @@ extension UserNotificationVC : TableViewSRC{
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// MARK: - Google Ad Banner Delegate
|
||||
|
||||
extension UserNotificationVC : GADBannerViewDelegate{
|
||||
|
||||
func bannerViewDidReceiveAd(_ bannerView: GADBannerView) {
|
||||
adView.isHidden = false
|
||||
bannerView.alpha = 0
|
||||
UIView.animate(withDuration: 0.2, animations: {
|
||||
bannerView.alpha = 1
|
||||
})
|
||||
print("bannerViewDidReceiveAd")
|
||||
}
|
||||
|
||||
func bannerView(_ bannerView: GADBannerView, didFailToReceiveAdWithError error: Error) {
|
||||
UIView.animate(withDuration: 0.2, animations: { [weak self] in
|
||||
guard let self else{return}
|
||||
bannerView.alpha = 0
|
||||
self.adView.isHidden = false
|
||||
})
|
||||
|
||||
print("bannerView:didFailToReceiveAdWithError: \(error.localizedDescription)")
|
||||
}
|
||||
|
||||
func bannerViewDidRecordImpression(_ bannerView: GADBannerView) {
|
||||
print("bannerViewDidRecordImpression")
|
||||
}
|
||||
|
||||
func bannerViewWillPresentScreen(_ bannerView: GADBannerView) {
|
||||
print("bannerViewWillPresentScreen")
|
||||
}
|
||||
|
||||
func bannerViewWillDismissScreen(_ bannerView: GADBannerView) {
|
||||
print("bannerViewWillDIsmissScreen")
|
||||
}
|
||||
|
||||
func bannerViewDidDismissScreen(_ bannerView: GADBannerView) {
|
||||
print("bannerViewDidDismissScreen")
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user