Experts/TC/TFGUI.mqh
super.admin da793cc2e1 convert
2025-05-30 14:54:10 +02:00

71 lines
2.7 KiB
MQL5

//+------------------------------------------------------------------+
//| TFGUI.mqh |
//| Thorsten Fischer Copyright 2020 |
//| https://mql5.tfsystem.de |
//+------------------------------------------------------------------+
#property copyright "Thorsten Fischer Copyright 2020"
#property link "https://mql5.tfsystem.de"
#property version "1.00"
#property strict
//---
#include "TFGUIDialog.mqh"
//+------------------------------------------------------------------+
//| |
//+------------------------------------------------------------------+
class CTFGUI : public CTFObject
{
private:
CTFGUIDialog m_tfgui_dialog;
public:
CTFGUI();
~CTFGUI();
//---
virtual bool OnInitEvent(void);
virtual void OnDeInitEvent(const int aReason=0);
virtual void ChartEvent(const int id,const long &lparam,const double &dparam,const string &sparam);
};
//+------------------------------------------------------------------+
//| |
//+------------------------------------------------------------------+
CTFGUI::CTFGUI()
{
}
//+------------------------------------------------------------------+
//| |
//+------------------------------------------------------------------+
CTFGUI::~CTFGUI()
{
}
//+------------------------------------------------------------------+
//| |
//+------------------------------------------------------------------+
bool CTFGUI::OnInitEvent(void)
{
//---
//---
if(!m_tfgui_dialog.Create(0,"Trading Center",0,0,10,200,300))
return(false);
//---
m_tfgui_dialog.Run();
//---
return(true);
}
//+------------------------------------------------------------------+
//| |
//+------------------------------------------------------------------+
void CTFGUI::OnDeInitEvent(const int aReason=0)
{
//---
m_tfgui_dialog.Destroy(aReason);
}
//+------------------------------------------------------------------+
//| |
//+------------------------------------------------------------------+
void CTFGUI::ChartEvent(const int id,const long &lparam,const double &dparam,const string &sparam)
{
//---
m_tfgui_dialog.ChartEvent(id,lparam,dparam,sparam);
}
//+------------------------------------------------------------------+