summaryrefslogtreecommitdiffstats
path: root/src/server/mainwindow
diff options
context:
space:
mode:
Diffstat (limited to 'src/server/mainwindow')
-rw-r--r--src/server/mainwindow/mainwindow.cpp11
-rw-r--r--src/server/mainwindow/mainwindow.h3
2 files changed, 14 insertions, 0 deletions
diff --git a/src/server/mainwindow/mainwindow.cpp b/src/server/mainwindow/mainwindow.cpp
index e7b5148..60295a3 100644
--- a/src/server/mainwindow/mainwindow.cpp
+++ b/src/server/mainwindow/mainwindow.cpp
@@ -23,6 +23,7 @@
#include "../clicklabel/clicklabel.h"
#include "../sessionnamewindow/sessionnamewindow.h"
#include "../connectionframe/connectionframe.h"
+#include "../helpwindow/helpwindow.h"
// Network
#include "../net/listenserver.h"
#include "../net/client.h"
@@ -58,6 +59,7 @@ MainWindow::MainWindow(QString ipListUrl, QWidget* parent) :
_selectedFrame = NULL;
_sessionNameWindow = new SessionNameWindow(this);
+ _helpWindow = new HelpWindow(this);
ui->setupUi(this);
Global::setSessionName();
@@ -95,6 +97,7 @@ MainWindow::MainWindow(QString ipListUrl, QWidget* parent) :
connect(ui->action_SetAsTutor, SIGNAL(triggered()), this, SLOT(onButtonSetAsTutor()));
connect(ui->action_SetAsTutor, SIGNAL(triggered()), this, SLOT(onButtonStopProjection()));
connect(ui->action_Lock, SIGNAL(toggled(bool)), this, SLOT(onButtonLock(bool)));
+ connect(ui->action_Help, SIGNAL(triggered()), this, SLOT(onButtonHelp()));
/* Stuff for the button lock */
_buttonLockTimer = new QTimer(this);
@@ -625,6 +628,14 @@ void MainWindow::prepareForProjection(Client * const from, Client * const to)
}
/***************************************************************************//**
+ * Display popup which explains possible actions about the buttons.
+ */
+void MainWindow::onButtonHelp()
+{
+ _helpWindow->show();
+}
+
+/***************************************************************************//**
* Handle projection from tutor to all.
* Get the client who is tutor and set the projectionSource of all
* clients, except the tutor ones, to false.
diff --git a/src/server/mainwindow/mainwindow.h b/src/server/mainwindow/mainwindow.h
index d688b5e..d6b0265 100644
--- a/src/server/mainwindow/mainwindow.h
+++ b/src/server/mainwindow/mainwindow.h
@@ -10,6 +10,7 @@ class SessionNameWindow;
class ConnectionFrame;
class ListenServer;
class DiscoveryListener;
+class HelpWindow;
namespace Ui{
class MainWindow;
@@ -32,6 +33,7 @@ private:
// Ui stuff
Ui::MainWindow *ui;
SessionNameWindow *_sessionNameWindow;
+ HelpWindow *_helpWindow;
QLabel *_sessionNameLabel;
int _tbIconSize;
Qt::ToolBarArea _tbArea;
@@ -89,6 +91,7 @@ protected slots:
void onButtonLock(bool checked);
void onButtonExit();
void onButtonSetAsTutor();
+ void onButtonHelp();
void DisableButtons();
void EnableButtons();
// connection frame