##// END OF EJS Templates
Removes VisualizationController::onVariableCreated() slot...
Removes VisualizationController::onVariableCreated() slot The slot is replaced by a signal that only propagates the VariableController signal. This new signal will be intercepted by the VisualizationWidget to create a new graph from the created variable

File last commit:

r120:c1f92d4a498b
r174:992eeb099247
Show More
VisualizationGraphWidget.cpp
47 lines | 1.1 KiB | text/x-c | CppLexer
/ gui / src / Visualization / VisualizationGraphWidget.cpp
mv visualization -> Visualization...
r95 #include "Visualization/VisualizationGraphWidget.h"
Creation of VisualizationWidget, VizualizationTabWidget, VisualizationZoneWidget, VisualizationGraphWidget
r58 #include "ui_VisualizationGraphWidget.h"
Add the visualization gui classes
r118 #include <Variable/Variable.h>
#include <unordered_map>
struct VisualizationGraphWidget::VisualizationGraphWidgetPrivate {
// 1 variable -> n qcpplot
std::unordered_map<std::shared_ptr<Variable>, std::unique_ptr<QCPAbstractPlottable> >
m_VariableToPlotMap;
};
Creation of VisualizationWidget, VizualizationTabWidget, VisualizationZoneWidget, VisualizationGraphWidget
r58 VisualizationGraphWidget::VisualizationGraphWidget(QWidget *parent)
add {} missing
r120 : QWidget{parent},
ui{new Ui::VisualizationGraphWidget},
Add the visualization gui classes
r118 impl{spimpl::make_unique_impl<VisualizationGraphWidgetPrivate>()}
Creation of VisualizationWidget, VizualizationTabWidget, VisualizationZoneWidget, VisualizationGraphWidget
r58 {
ui->setupUi(this);
}
VisualizationGraphWidget::~VisualizationGraphWidget()
{
delete ui;
}
Add the visualization gui classes
r118
void VisualizationGraphWidget::addVariable(std::shared_ptr<Variable> variable)
{
// todo: first check is variable contains data then check how many plot have to be created
}
void VisualizationGraphWidget::accept(IVisualizationWidget *visitor)
{
// TODO: manage the visitor
}
void VisualizationGraphWidget::close()
{
// The main view cannot be directly closed.
return;
}
Add const and override
r119 QString VisualizationGraphWidget::name() const
Add the visualization gui classes
r118 {
return QStringLiteral("MainView");
}