Commit a9a05d7b authored by Oliver Bock's avatar Oliver Bock

Connected main GUI signals to animation widget slots

parent 00afd809
......@@ -23,10 +23,28 @@
PulsatingScience::PulsatingScience(QWidget *parent) : QMainWindow(parent)
{
ui.setupUi(this);
ui.menuView->addAction(ui.dockAnimControl->toggleViewAction());
connect(ui.actionRun, SIGNAL(activated()),
ui.pulsarGlWidget, SLOT(runAnimation()));
connect(ui.actionPause, SIGNAL(activated()),
ui.pulsarGlWidget, SLOT(pauseAnimation()));
connect(ui.actionStop, SIGNAL(activated()),
ui.pulsarGlWidget, SLOT(stopAnimation()));
on_sliderSpinFrequency_valueChanged(ui.sliderSpinFrequency->value());
}
PulsatingScience::~PulsatingScience()
{
}
void PulsatingScience::on_sliderSpinFrequency_valueChanged(int value)
{
ui.pulsarGlWidget->setPulsarSpinFrequency(value / 10.0);
ui.lcdSpinFrequency->display(QString::number(value / 10.0, 'f', 1));
}
......@@ -32,6 +32,9 @@ public:
PulsatingScience(QWidget *parent = 0);
~PulsatingScience();
public slots:
void on_sliderSpinFrequency_valueChanged(int value);
private:
Ui::PulsatingScienceClass ui;
};
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment