示例#1
0
void CLoginButton::login()
{
    if (isLoggedIn) {
        emit logoutClicked();
    } else {
        emit loginClicked(ui->lineEdit->text(),
                          ui->lineEdit_2->text());
    }

    serverNoResponse.start(2000);
}
示例#2
0
void HeaderWidget::emitSignal(int id)
{
    switch (id) {
    case 1:
        emit backClicked();
        break;
    case 2:
        emit homeClicked();
        break;
    case 3:
        emit logoutClicked();
        break;
    }
}