//
//  HomeVideoContentCell.m
//  Open
//
//  Created by 雷俊博 on 2021/6/6.
//  Copyright © 2021 黄江涛 . All rights reserved.
//

#import "HomeVideoContentCell.h"



@interface HomeVideoContentCell ()<UIGestureRecognizerDelegate>

@property (nonatomic, strong)UIViewController *vc1;
@end

@implementation HomeVideoContentCell

- (void)awakeFromNib {
    [super awakeFromNib];
    // Initialization code
}
- (void)setupVideoVCWithSelf:(UIViewController *)vc
{

    if (self.feedPage) {
        [self.feedPage.feedViewController removeFromParentViewController];
        self.feedPage = nil;
    }
    KSCUFeedPage *feedPage = [[KSCUFeedPage alloc] initWithPosId:@"6030000009"];
    self.feedPage = feedPage;
    self.feedPage.videoStateDelegate = vc;
    self.feedPage.stateDelegate = vc;
    self.feedPage.callBackDelegate = vc;
    self.feedPage.hidesBottomBarWhenPushed = YES;
    UIViewController *vc1 = self.feedPage.feedViewController;

    [vc1 setKscu_feedPageDelegate:vc];
    [vc addChildViewController:vc1];
    [self.contentView addSubview:vc1.view];
    [vc1.view mas_makeConstraints:^(MASConstraintMaker *make) {
        make.top.right.bottom.left.offset(0);
    }];
    
}

- (BOOL)gestureRecognizer:(UIGestureRecognizer *)gestureRecognizer shouldRecognizeSimultaneouslyWithGestureRecognizer:(UIGestureRecognizer *)otherGestureRecognizer{

    return YES;
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
