ios 视图既显示阴影又有圆角实现

//- (UIView *)createTimeBG

//{

//    UIView *view = [[UIView alloc]init];

//    view.backgroundColor = [UIColor clearColor];

//    view.layer.shadowOffset = CGSizeMake(0, 2);

//    view.layer.shadowColor  =  [[UIColor blackColor] colorWithAlphaComponent:0.35].CGColor;

//    view.layer.shadowOpacity = 1;

//

//    CALayer *sublayer =[CALayer layer];

//    sublayer.frame = CGRectMake(0, 0, 20, 20);

//    sublayer.backgroundColor = [UIColor sy_black2Color].CGColor;

//    sublayer.cornerRadius = 2;

//    sublayer.masksToBounds = YES;

//    [view.layer addSublayer:sublayer];

//    return view;

//}

ios 视图既显示阴影又有圆角实现

上一篇:二叉苹果树(codevs 5565)树形DP


下一篇:Android_(游戏)打飞机02:游戏背景滚动