Esempio n. 1
0
void guiInfoboxPageManager::slotGeneralBtnClicked(uint16 id)
{
    switch (id) {
    case 0://CTRL_CLOSE
        emit signalSwitchPage(MAIN_PAGE);
        break;

    case 1://BTN_CALL
        if (mBtnState == PATIENTBTN_NORMAL || (mBtnState == PATIENTBTN_SOS && mMediaState == GUI_STATE_NONE))
        {
            emit signalCallOperate(CALL_TYPE_CLLOUT, PATIENT_INFO_PAGE, (char *)&mInfoIndex);
        }
        else if (mBtnState == PATIENTBTN_TALK || mBtnState == PATIENTBTN_CALLING)
        {
            emit signalCallOperate(CALL_TYPE_HANGUP, PATIENT_INFO_PAGE, (char *)&mInfoIndex);
        }
        else if (mBtnState == PATIENTBTN_SOS && mMediaState != GUI_STATE_NONE)
        {
            emit signalCallOperate(CALL_TYPE_ANSWER, PATIENT_INFO_PAGE, (char *)&mInfoIndex);
        }
        break;

    default:
        break;
    }
}
Esempio n. 2
0
void guiUsrSettings::slotBottomBarClicked(GUI_OBJS_NAME prePage, GUI_OBJS_NAME curPage, uint16 btnId)
{
    qDebug()<<"guiUsrSettings mPrePageId  =   "<<prePage;
    qDebug()<<"guiUsrSettings mCurPageId  =   "<<curPage;

    mPrePageId = prePage;
    mCurPageId = curPage;

    switch(mCurPageId)
    {
    case OBJ_USR_SETTINGS:
        switch(btnId)
        {
        case OBJ_BOTTOM_BTN_EXIT:
            emit signalSwitchPage(MAIN_PAGE);
            break;

        case OBJ_BOTTOM_BTN_UP:
            if(mPageIndex == 0)
                break;
            else
                setGuiShowPage(0);
            break;

        case OBJ_BOTTOM_BTN_SAVE:
            break;

        case OBJ_BOTTOM_BTN_DOWN:
            if(mPageIndex == 1)
                break;
            else
                setGuiShowPage(1);
            break;

        default:
            break;
        }
        break;

    case OBJ_USR_PWDMODIFY:
        setPreCurPageId(OBJ_MAIN_PAGE, OBJ_USR_SETTINGS);
        mUsrPwdModify->hide();
        break;

    case OBJ_USR_RINGTONE:
        setPreCurPageId(OBJ_MAIN_PAGE, OBJ_USR_SETTINGS);
        mRingToneSettings->hide();
        break;

    case OBJ_USR_CALLTRAN:
    case OBJ_USR_SCREENSAVER:
    case OBJ_USR_TURNOFFLCD:
    case OBJ_USR_ALARM:
        setPreCurPageId(OBJ_MAIN_PAGE, OBJ_USR_SETTINGS);
        mUsrParaInput->hide();
        break;

    default:
        emit signalBottomBarClicked(mPrePageId, mCurPageId, OBJ_BOTTOM_BTN_EXIT);
        break;
    }

}