#ifndef ADSMONITORWIDGET_H
#define ADSMONITORWIDGET_H

#include <QWidget>

class QStatusBar;

#include "ads_manager.h"

namespace Ui {
    class AdsMonitorWidget;
}

class AdsMonitorWidget : public QWidget
{
    Q_OBJECT

public:
    explicit AdsMonitorWidget(QWidget *parent = 0);
    ~AdsMonitorWidget();

    bool connectToManager();

    ADS_SLOT(_onCheckUpdated, (Ads1553MessageCheck&))

public slots:
    void updateDataList();

private slots:
    void on_pbChecksRefresh_clicked();
    void on_tbZoomOut_clicked();
    void on_tbZoomIn_clicked();
    void on_tbHistoryView_currentChanged(int index);
    void on_pbRefresh_clicked();
    void on_pushButton_Acq_toggled(bool checked);
    void updateGraphicPaneVisibility(int);

    void _onMessageListChanged();
    void _onTerminalListChanged();
    void _onRunStatusChanged(Ads1553Manager::run_sts_t);

    void _onMonitorUpdated(avb_1553_monitor_info_t* info);

    void _onAcqUpdated(bool in_progress, unsigned int filled_percentage);

    void _stackRefresh();

    void _onGfxCursorPos(double x, unsigned int crs);

    void _onCheckAdded(Ads1553MessageCheck& chk);

    void plotSourceSelection();

    void on_pushButton_Acq_clicked();

private:
    Ui::AdsMonitorWidget *ui;

    class Private;
    Private& p_;

    friend class Private;
};

#endif // ADSMONITORWIDGET_H
