TestViewController.m 1.14 KB
//
//  TestViewController.m
//  CNLivePublishContent
//
//  Created by 殷巧娟 on 2019/1/16.
//

#import "TestViewController.h"

@interface TestViewController ()
@property (nonatomic, strong) UILabel *nameLabel;
@end

@implementation TestViewController
-(instancetype)initWithName:(NSString *)name {
    self = [super init];
    if (self) {
        _nameLabel.text = name;
    }
    return self;
}
- (void)viewDidLoad {
    [super viewDidLoad];
    self.view.backgroundColor = [UIColor whiteColor];
    NSLog(@"测试一下啊啊啊啊");
    _nameLabel = [[UILabel alloc]initWithFrame:CGRectMake(100, 100, 200, 50)];
    _nameLabel.textColor = [UIColor blackColor];
    _nameLabel.backgroundColor = [UIColor cyanColor];
    [self.view addSubview:_nameLabel];
    // Do any additional setup after loading the view.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end