#include "instantchartpanel.h"
#include "instantchart.h"

#include <QVBoxLayout>
#include <QSlider>

InstantChartPanel::InstantChartPanel(QWidget *parent)
    : QWidget(parent)
{
    initUI();
}

InstantChartPanel::~InstantChartPanel()
{

}

void InstantChartPanel::initUI()
{
    mMainVLayout = new QVBoxLayout;
    mInstantChart = new InstantChart;
    mSlider = new QSlider;
    mSlider->setRange(1, 2999);
    mSlider->setOrientation(Qt::Horizontal);
    mMainVLayout->addWidget(mInstantChart);
    mMainVLayout->addWidget(mSlider);
    this->setLayout(mMainVLayout);

    connect(mSlider, SIGNAL(valueChanged(int)), mInstantChart, SLOT(setValue(int)));
    mSlider->setValue(88);
}
