OpenASIP 2.2
|
#include <CostEstimationDataDialog.hh>
Public Member Functions | |
CostEstimationDataDialog (wxWindow *parent, wxWindowID id, HDB::HDBManager &hdb, RowID pluginID, RowID dataID) | |
virtual | ~CostEstimationDataDialog () |
Private Types | |
enum | { ID_ENTRY_TYPE = 10000 , ID_ENTRY_ID , ID_NAME , ID_VALUE , ID_TEXT , ID_LINE } |
widget IDs More... | |
Private Member Functions | |
virtual bool | TransferDataToWindow () |
void | onOK (wxCommandEvent &event) |
void | onEntryTypeSelection (wxCommandEvent &event) |
wxSizer * | createContents (wxWindow *parent, bool call_fit, bool set_sizer) |
Private Attributes | |
HDB::HDBManager & | hdb_ |
HDB Containing the data. | |
RowID | pluginID_ |
ID of the data's parent plugin. | |
RowID | dataID_ |
ID of the data to modify, or -1 if new data is being added. | |
wxChoice * | typeChoice_ |
Entry reference type choice widget. | |
wxChoice * | idChoice_ |
Entry reference id choice widget. | |
wxString | name_ |
Name of the data. | |
wxString | value_ |
Value of the data. | |
Static Private Attributes | |
static const wxString | ENTRY_TYPE_NONE = _T("None") |
static const wxString | ENTRY_TYPE_FU = _T("FU") |
static const wxString | ENTRY_TYPE_RF = _T("RF") |
static const wxString | ENTRY_TYPE_BUS = _T("Bus") |
static const wxString | ENTRY_TYPE_SOCKET = _T("Socket") |
Dialog for adding and modifying cost function plugin data.
Definition at line 46 of file CostEstimationDataDialog.hh.
|
private |
widget IDs
Enumerator | |
---|---|
ID_ENTRY_TYPE | |
ID_ENTRY_ID | |
ID_NAME | |
ID_VALUE | |
ID_TEXT | |
ID_LINE |
Definition at line 62 of file CostEstimationDataDialog.hh.
CostEstimationDataDialog::CostEstimationDataDialog | ( | wxWindow * | parent, |
wxWindowID | id, | ||
HDB::HDBManager & | hdb, | ||
RowID | pluginID, | ||
RowID | dataID | ||
) |
The Constructor.
parent | Parent window of the dialog. |
id | Window identifier for the dialog. |
hdb | HDBManager where the data is added/modified. |
dataID | ID of the cost data to modify or -1 if a new data is being added. |
Definition at line 63 of file CostEstimationDataDialog.cc.
|
virtual |
|
private |
Creates the dialog widgets.
Definition at line 239 of file CostEstimationDataDialog.cc.
References ID_ENTRY_ID, ID_ENTRY_TYPE, ID_LINE, ID_NAME, ID_TEXT, and ID_VALUE.
|
private |
Event handler for the entry type choicer selections.
Definition at line 137 of file CostEstimationDataDialog.cc.
References HDB::HDBManager::busEntryIDs(), ENTRY_TYPE_BUS, ENTRY_TYPE_FU, ENTRY_TYPE_RF, ENTRY_TYPE_SOCKET, HDB::HDBManager::fuEntryIDs(), hdb_, idChoice_, HDB::HDBManager::rfEntryIDs(), HDB::HDBManager::socketEntryIDs(), WxConversion::toWxString(), and typeChoice_.
Referenced by TransferDataToWindow().
|
private |
Event handler for the ok-button.
Definition at line 183 of file CostEstimationDataDialog.cc.
References HDB::HDBManager::addCostEstimationData(), dataID_, ENTRY_TYPE_BUS, ENTRY_TYPE_FU, ENTRY_TYPE_NONE, ENTRY_TYPE_RF, ENTRY_TYPE_SOCKET, hdb_, idChoice_, HDB::HDBManager::modifyCostEstimationData(), name_, pluginID_, CostEstimationData::setBusReference(), CostEstimationData::setFUReference(), CostEstimationData::setName(), CostEstimationData::setPluginID(), CostEstimationData::setRFReference(), CostEstimationData::setSocketReference(), CostEstimationData::setValue(), Conversion::toInt(), WxConversion::toString(), typeChoice_, and value_.
|
privatevirtual |
Transfers data to the dialog widgets.
Definition at line 102 of file CostEstimationDataDialog.cc.
References CostEstimationData::busReference(), HDB::HDBManager::costEstimationData(), dataID_, dummy, ENTRY_TYPE_BUS, ENTRY_TYPE_FU, ENTRY_TYPE_RF, ENTRY_TYPE_SOCKET, CostEstimationData::fuReference(), CostEstimationData::hasBusReference(), CostEstimationData::hasFUReference(), CostEstimationData::hasRFReference(), CostEstimationData::hasSocketReference(), hdb_, idChoice_, CostEstimationData::name(), name_, onEntryTypeSelection(), CostEstimationData::rfReference(), CostEstimationData::socketReference(), DataObject::stringValue(), WxConversion::toWxString(), typeChoice_, CostEstimationData::value(), and value_.
|
private |
ID of the data to modify, or -1 if new data is being added.
Definition at line 76 of file CostEstimationDataDialog.hh.
Referenced by onOK(), and TransferDataToWindow().
|
staticprivate |
Definition at line 89 of file CostEstimationDataDialog.hh.
Referenced by onEntryTypeSelection(), onOK(), and TransferDataToWindow().
|
staticprivate |
Definition at line 87 of file CostEstimationDataDialog.hh.
Referenced by onEntryTypeSelection(), onOK(), and TransferDataToWindow().
|
staticprivate |
Definition at line 86 of file CostEstimationDataDialog.hh.
Referenced by onOK().
|
staticprivate |
Definition at line 88 of file CostEstimationDataDialog.hh.
Referenced by onEntryTypeSelection(), onOK(), and TransferDataToWindow().
|
staticprivate |
Definition at line 90 of file CostEstimationDataDialog.hh.
Referenced by onEntryTypeSelection(), onOK(), and TransferDataToWindow().
|
private |
HDB Containing the data.
Definition at line 72 of file CostEstimationDataDialog.hh.
Referenced by onEntryTypeSelection(), onOK(), and TransferDataToWindow().
|
private |
Entry reference id choice widget.
Definition at line 80 of file CostEstimationDataDialog.hh.
Referenced by onEntryTypeSelection(), onOK(), and TransferDataToWindow().
|
private |
Name of the data.
Definition at line 82 of file CostEstimationDataDialog.hh.
Referenced by onOK(), and TransferDataToWindow().
|
private |
ID of the data's parent plugin.
Definition at line 74 of file CostEstimationDataDialog.hh.
Referenced by onOK().
|
private |
Entry reference type choice widget.
Definition at line 78 of file CostEstimationDataDialog.hh.
Referenced by onEntryTypeSelection(), onOK(), and TransferDataToWindow().
|
private |
Value of the data.
Definition at line 84 of file CostEstimationDataDialog.hh.
Referenced by onOK(), and TransferDataToWindow().