コード例 #1
0
ファイル: CodingDlg.cpp プロジェクト: ETAS-Nithin/busmaster
CodingDlg::CodingDlg(ICluster* pouCluster, ICoding** pouCoding, bool bNew, QWidget* parent)
    : QDialog(parent)
{
    ui.setupUi(this);
    m_pLdfCluster = pouCluster;
    m_pCoding = pouCoding;
    m_bEditMode = !bNew;
    vPrepareValidations();
    ui.buttonDeletePhysical->setDisabled(true);
    ui.buttonDeleteLogical->setDisabled(true);


    setWindowTitle("Create Coding");

    if ( true == m_bEditMode )
    {
        vPrepareUiForEdit();
    }
    connect(ui.buttonAddLogical, SIGNAL(clicked()), this, SLOT(AddLogicalRow()));
    connect(ui.buttonAddPhysical, SIGNAL(clicked()), this, SLOT(AddPhysicalRow()));
    connect(ui.buttonDeleteLogical, SIGNAL(clicked()), this, SLOT(DeleteLogicalRow()));
    connect(ui.buttonDeletePhysical, SIGNAL(clicked()), this, SLOT(DeletePhysicalRow()));
    connect(ui.tableLogicalValues, SIGNAL(ui.tableLogicalValues->itemSelectionChanged()), this, SLOT(ItemSelectionChangeLogical()));

    connect(ui.buttonOption, SIGNAL(accepted()), this, SLOT(onSelectionOk()));
    connect(ui.buttonOption, SIGNAL(rejected()), this, SLOT(onSelecetionCancel()));

    QIcon ouWindowIcon;
    ouWindowIcon.addFile(":/LDFEditorIcons/Resources/icons/16x16/Coding.png", QSize(16, 16));
    ouWindowIcon.addFile(":/LDFEditorIcons/Resources/icons/22x22/Coding.png", QSize(16, 16));
    ouWindowIcon.addFile(":/LDFEditorIcons/Resources/icons/32x32/Coding.png", QSize(16, 16));

    setWindowIcon(ouWindowIcon);
}
コード例 #2
0
SporadicFrameEditDlg::SporadicFrameEditDlg(IFrame** pouFrame,eMode ouMode, QWidget* parent)
{
    m_pouFrame = pouFrame;
    ui.setupUi(this);
    m_pLdfCluster = LDFDatabaseManager::GetDatabaseManager()->GetLDFCluster();
    m_ouMode = ouMode;

    connect(ui.buttonOk, SIGNAL(accepted()), this, SLOT(OnButtonClickOk()));
    connect(ui.buttonOk, SIGNAL(rejected()), this, SLOT(reject()));

    vPrepareValidations();

    setWindowTitle("Create SporadicFrame");

    if(m_ouMode == eEdit)
    {
        vPrepareUIForEditMode();
    }

    QIcon ouWindowIcon;
    ouWindowIcon.addFile(":/LDFEditorIcons/Resources/icons/16x16/Frame.png", QSize(16, 16));
    ouWindowIcon.addFile(":/LDFEditorIcons/Resources/icons/22x22/Frame.png", QSize(16, 16));
    ouWindowIcon.addFile(":/LDFEditorIcons/Resources/icons/32x32/Frame.png", QSize(16, 16));

    setWindowIcon(ouWindowIcon);

}