Skip to content

自动布局不会显示 #5

@yaooort

Description

@yaooort

你好,自动布局不会显示

//滑动开关
    self.switchClose = [[LLSwitch alloc] init];
    self.switchClose.onColor = [UIColor colorWithHex:BG_SHOUYE alpha:0.86];    // switch is open color    开关打开的颜色
    self.switchClose.offColor = [UIColor colorWithHex:BG_SHOUYE alpha:0.66];    // switch is close color    开关关闭的颜色
    self.switchClose.faceColor = HEXCOLOR(COLOR_TONGYI_LV);    // switch face color    圆脸的颜色
    self.switchClose.animationDuration = 1.2f;    // switch open or close animation time    开关的动画时间
    [self.view addSubview:self.switchClose];
    [self.switchClose makeConstraints:^(MASConstraintMaker *make) {
        make.left.equalTo(self.view).offset(INSET);
//        make.top.equalTo(self.).offset(INSET);
        make.bottom.equalTo(self.bottomView.top).offset(-INSET);
        make.width.equalTo(WIDTH_1*2);
        make.height.equalTo(HEIGHT_6);
    }];
 

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions