diff gui/src/WelcomeWizard.cpp @ 13668:421afeae929b

Added a settings wizard that appears at first startup of Octave GUI.
author Jacob Dawid <jacob.dawid@googlemail.com>
date Sat, 10 Sep 2011 18:33:58 +0200
parents
children c0e66d6e3dc8
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gui/src/WelcomeWizard.cpp	Sat Sep 10 18:33:58 2011 +0200
@@ -0,0 +1,36 @@
+#include "WelcomeWizard.h"
+#include "ui_WelcomeWizard.h"
+
+WelcomeWizard::WelcomeWizard (QWidget *parent) :
+  QDialog (parent),
+  ui (new Ui::WelcomeWizard)
+{
+  ui->setupUi (this);
+  connect (ui->nextButton1, SIGNAL (clicked ()), this, SLOT (next ()));
+  connect (ui->nextButton2, SIGNAL (clicked ()), this, SLOT (next ()));
+  connect (ui->nextButton3, SIGNAL (clicked ()), this, SLOT (next ()));
+  connect (ui->nextButton4, SIGNAL (clicked ()), this, SLOT (next ()));
+
+  connect (ui->previousButton2, SIGNAL (clicked ()), this, SLOT (previous ()));
+  connect (ui->previousButton3, SIGNAL (clicked ()), this, SLOT (previous ()));
+  connect (ui->previousButton4, SIGNAL (clicked ()), this, SLOT (previous ()));
+  connect (ui->previousButton5, SIGNAL (clicked ()), this, SLOT (previous ()));
+}
+
+WelcomeWizard::~WelcomeWizard()
+{
+  delete ui;
+}
+
+void
+WelcomeWizard::next ()
+{
+  ui->stackedWidget->setCurrentIndex (ui->stackedWidget->currentIndex () + 1);
+}
+
+void
+WelcomeWizard::previous ()
+{
+  ui->stackedWidget->setCurrentIndex (ui->stackedWidget->currentIndex () - 1);
+}
+