From 6b9054f1bb28b4ac1b0a7b682204baa0e2643220 Mon Sep 17 00:00:00 2001 From: Thales1330 Date: Tue, 29 Nov 2016 18:27:32 -0200 Subject: Text form under implementation --- Project/Text.cpp | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) (limited to 'Project/Text.cpp') diff --git a/Project/Text.cpp b/Project/Text.cpp index 1a89d17..839e6f8 100644 --- a/Project/Text.cpp +++ b/Project/Text.cpp @@ -1,14 +1,7 @@ +#include "TextForm.h" #include "Text.h" -#include "Bus.h" -#include "Line.h" -#include "Transformer.h" -#include "SyncGenerator.h" -#include "IndMotor.h" -#include "SyncMotor.h" -#include "Load.h" -#include "Inductor.h" -#include "Capacitor.h" +#include "ElectricCalculation.h" Text::Text() : Element() { SetText(m_text); } Text::Text(wxPoint2DDouble position) : Element() @@ -84,3 +77,14 @@ void Text::Rotate(bool clockwise) m_angle += rotAngle; if(m_angle >= 360.0) m_angle = 0.0; } + +bool Text::ShowForm(wxWindow* parent, std::vector elementList) +{ + TextForm* textForm = new TextForm(parent, this, elementList); + if(textForm->ShowModal() == wxID_OK) { + textForm->Destroy(); + return true; + } + textForm->Destroy(); + return false; +} -- cgit