summaryrefslogtreecommitdiffstats
path: root/Project/LoadForm.cpp
diff options
context:
space:
mode:
authorThales1330 <thaleslima.ufu@gmail.com>2016-10-21 17:44:27 -0200
committerThales1330 <thaleslima.ufu@gmail.com>2016-10-21 17:44:27 -0200
commit58cc8933337d4681025f890af78bfddc45c212d0 (patch)
treeffe3737ba2b86aab8d4832d9a2c5533fbc63342c /Project/LoadForm.cpp
parentdc8e7b67eb2141cfbed0f26ac50a8d14104f391b (diff)
downloadPSP.git-58cc8933337d4681025f890af78bfddc45c212d0.tar.gz
PSP.git-58cc8933337d4681025f890af78bfddc45c212d0.tar.xz
PSP.git-58cc8933337d4681025f890af78bfddc45c212d0.zip
Load form under implementation
Diffstat (limited to 'Project/LoadForm.cpp')
-rw-r--r--Project/LoadForm.cpp43
1 files changed, 43 insertions, 0 deletions
diff --git a/Project/LoadForm.cpp b/Project/LoadForm.cpp
new file mode 100644
index 0000000..3b7a926
--- /dev/null
+++ b/Project/LoadForm.cpp
@@ -0,0 +1,43 @@
+#include "LoadForm.h"
+#include "Load.h"
+
+LoadForm::LoadForm(wxWindow* parent, Load* load)
+ : LoadFormBase(parent)
+{
+ LoadElectricalData data = load->GetElectricalData();
+
+ m_textCtrlName->SetValue(data.name);
+
+ m_textCtrlActivePower->SetValue(Load::StringFromDouble(data.activePower));
+ switch(data.activePowerUnit) {
+ case UNIT_PU: {
+ m_choiceActivePower->SetSelection(0);
+ }
+ case UNIT_W: {
+ m_choiceActivePower->SetSelection(1);
+ }
+ case UNIT_kW: {
+ m_choiceActivePower->SetSelection(2);
+ }
+ case UNIT_MW: {
+ m_choiceActivePower->SetSelection(3);
+ }
+ }
+
+ m_parent = parent;
+ m_load = load;
+}
+
+LoadForm::~LoadForm()
+{
+}
+
+void LoadForm::OnCancelButtonClick(wxCommandEvent& event)
+{
+}
+void LoadForm::OnOnButtonClick(wxCommandEvent& event)
+{
+}
+void LoadForm::OnStabilityButtonClick(wxCommandEvent& event)
+{
+}