コード例 #1
0
UnconditionalFrameEditDlg::UnconditionalFrameEditDlg(IFrame** pouFrame, eMode eUIType, QWidget* parent)
    : QDialog(parent)
{
    m_pouFrame = pouFrame;
    m_eUIMode = eUIType;




    m_pouLDFCluster = LDFDatabaseManager::GetDatabaseManager()->GetLDFCluster();
    ui.setupUi(this);
    layout()->setSizeConstraint( QLayout::SetFixedSize );
    SetUpUi();



    connect(ui.btnMapSignal, SIGNAL(clicked(bool)), this, SLOT(onMapSignal(bool)));
    connect(ui.buttonBox, SIGNAL(accepted()), this, SLOT(onSelectionOk()));
    connect(ui.buttonBox, SIGNAL(rejected()), this, SLOT(onSelectionCancel()));
    connect(ui.comboPublisher, SIGNAL(currentIndexChanged(QString)), this, SLOT(onChangePublisher(QString)));
    connect(ui.comboFrameLength, SIGNAL(currentIndexChanged(QString)), this, SLOT(onChangeFrameLength(QString)));

    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);

}
コード例 #2
0
MapSignalsDlg::MapSignalsDlg(UID_ELEMENT uidEcu, int nFrameLen, std::map<UID_ELEMENT, SignalInstanse> mapSignals, QWidget* parent)
{
    IElement* pElement = nullptr;
    m_pouEcu = nullptr;
    m_nFrameLen = nFrameLen;
    if(EC_SUCCESS == LDFDatabaseManager::GetDatabaseManager()->GetLDFCluster()->GetElement(eEcuElement, uidEcu, &pElement))
    {
        m_pouEcu = (IEcu*)pElement;
    }

    m_mapSignalUIDSigInst = mapSignals;
    ui.setupUi(this);



    connect(ui.buttonBox, SIGNAL(accepted()), this, SLOT(onSelectionOk()));
    connect(ui.buttonBox, SIGNAL(rejected()), this, SLOT(onSelectionCancel()));

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

    setWindowIcon(ouWindowIcon);
    std::string strEcuName;
    m_pouEcu->GetName(strEcuName);
    setWindowTitle(tr("Signals Published by ECU - %1").arg(strEcuName.c_str()));

    SetUpUi();
}