Объединение двух графических объектов в один

 

Доброго времени суток. Решил написать расширение класса стандартной библиотеки CChartObjectHLine. Расширение выглядит как текстовое поле привязанное к горизонтальной линии и правому краю экрана. Беда в том, что в итоге, при перемещении линии текстовое поле остается на месте. Далее привожу свои наброски кода:

#include <ChartObjects\ChartObjectsLines.mqh>
#include <ChartObjects\ChartObjectsTxtControls.mqh>
#include <Canvas\Canvas.mqh>
//+------------------------------------------------------------------+
//|                                                                  |
//+------------------------------------------------------------------+
class CCustomHLine:public CChartObjectHLine
  {
private:
   CChartObjectText  m_Text;
   double            lvl_price;//значение цены уровня
   datetime          lvl_time;//значение времени уровня
   int               chart_width;//ширина графика
public:
                     CCustomHLine();
                    ~CCustomHLine();
//--- Методы отрисовки
   bool              Create(long chart_id,const string name,const int window,const double price,const string text,const color textcolor);
   bool              Refresh();
//--- Методы доступа к данным
   bool              Text(const string text);
   bool              TextColor(const color textcolor);
   double            Price(){return lvl_price;};
   bool              Font(const string font);
   bool              FontColor(const color fontcolor);
   bool              FontSize(const int fontsize);
   bool              Color(const color linecolor);
  };
//+------------------------------------------------------------------+
//|                                                                  |
//+------------------------------------------------------------------+
CCustomHLine::CCustomHLine()
  {
  }
//+------------------------------------------------------------------+
//|                                                                  |
//+------------------------------------------------------------------+
CCustomHLine::~CCustomHLine()
  {
  }
//+------------------------------------------------------------------+
bool CCustomHLine::Create(long chart_id,const string name,const int window,const double price,const string text,const color textcolor)
  {
   color    m_fontColor=StringToColor("51,255,51");//цвет шрифта
   int      m_fontSize=8;//размер шрифта
   string   m_font="Verdana";//шрифт
   int X=0; int Y=0;//координаты в пикселях
   chart_width=(int)ChartGetInteger(chart_id,CHART_WIDTH_IN_PIXELS);//получаем ширину окна в пикселях
   int sub_window=window;
   if(!ChartXYToTimePrice(chart_id,chart_width,Y,sub_window,lvl_time,lvl_price))
      return false;
   lvl_price=price;//выставляем значение цены
   if(!CChartObjectHLine::Create(chart_id,name,window,price))
      return false;
   if(!m_Text.Create(chart_id,name+"_text",window,lvl_time,lvl_price))
      return false;
   m_Text.Anchor(ANCHOR_RIGHT_UPPER);
   m_Text.Description(text);
   m_Text.FontSize(m_fontSize);
   m_Text.Font(m_font);
   m_Text.Color(textcolor);
   ChartRedraw();
   return true;
  }
//+------------------------------------------------------------------+
bool CCustomHLine::Refresh(void)
  {
//обновляем ширину окна
   int sub_window=m_Text.Window();
   chart_width=(int)ChartGetInteger(0,CHART_WIDTH_IN_PIXELS);//получаем ширину окна в пикселях
   int Y=0;
//переводим координаты в пикселях в координаты время/цена
   if(!ChartXYToTimePrice(0,chart_width,Y,sub_window,lvl_time,lvl_price))
      return false;
//обновляем поле цена для текста
   lvl_price=Price(0);
   if(!m_Text.Price(0,lvl_price))
      return false;
//обновляем поле время для текста
   if(!m_Text.Time(0,lvl_time))
      return false;
   return true;
  }
//+------------------------------------------------------------------+
bool CCustomHLine::Text(const string text)
  {
   if(!m_Text.Description(text))
      return false;
   return true;
  }
//+------------------------------------------------------------------+
bool CCustomHLine::TextColor(const color textcolor)
  {
   if(!m_Text.Color(textcolor))
      return false;
   return true;
  }
//+------------------------------------------------------------------+
bool CCustomHLine::Font(const string font)
  {
   if(!m_Text.Font(font))
      return false;
   return true;
  }
//+------------------------------------------------------------------+
bool CCustomHLine::FontColor(const color fontcolor)
  {
   if(!m_Text.Color(fontcolor))
      return false;
   return true;
  }
//+------------------------------------------------------------------+
bool CCustomHLine::FontSize(const int fontsize)
  {
   if(!m_Text.FontSize(fontsize))
      return false;
   return true;
  }
//+------------------------------------------------------------------+
bool CCustomHLine::Color(const color linecolor)
{
   if(!Color(linecolor))
      return false;
   return true;
}

Собственно прошу помощи. Так как по документации не смог разобраться, какой метод в родительском классе отвечает за перерисовку линии при ее перемещении, дабы переписать этот метод в наследнике и совместить перемещение линии и текстовой метки как единого целого.