From b487901f1ee835f3e50726823dcb27081b2f425f Mon Sep 17 00:00:00 2001 From: Manuel Schneider Date: Thu, 22 May 2014 14:09:03 +0200 Subject: Make VNCServer::isrunning inline --- src/client/vnc/vncserver.cpp | 11 +---------- src/client/vnc/vncserver.h | 2 +- 2 files changed, 2 insertions(+), 11 deletions(-) diff --git a/src/client/vnc/vncserver.cpp b/src/client/vnc/vncserver.cpp index 56800f4..2b341fb 100644 --- a/src/client/vnc/vncserver.cpp +++ b/src/client/vnc/vncserver.cpp @@ -55,13 +55,6 @@ VncServer::~VncServer() // TODO Auto-generated destructor stub } -bool VncServer::isVncServerRunning() -{ - if (_port > 0) - return true; - return false; -} - void VncServer::start() { // Keep things clean @@ -121,9 +114,7 @@ void VncServer::start() args << rect; qDebug() << "Arguments are: " << args; - _process->start("x11vnc", - args, - QIODevice::ReadOnly); + _process->start("x11vnc", args, QIODevice::ReadOnly); } void VncServer::stop() diff --git a/src/client/vnc/vncserver.h b/src/client/vnc/vncserver.h index 790b295..ac45822 100644 --- a/src/client/vnc/vncserver.h +++ b/src/client/vnc/vncserver.h @@ -31,7 +31,7 @@ private: public: static VncServer *instance(); - bool isVncServerRunning(); + inline bool isVncServerRunning(){ return _port > 0; } void start(); void stop(); -- cgit v1.2.3-55-g7522 From 2c771673608bbaa9617da6a545cbb5d9a8c2114d Mon Sep 17 00:00:00 2001 From: Manuel Schneider Date: Thu, 22 May 2014 14:19:06 +0200 Subject: Stop suggesting the user to be recorded: * Delete red dot camera icons * Disable camera blinking in clients toolbar (sorry bjoern) * Adjust ressource files --- icons/cam_off32.svg | 109 ----------------------------------------- icons/cam_on32.svg | 109 ----------------------------------------- pvsclient.qrc | 88 ++++++++++++++++----------------- pvsmgr.qrc | 4 +- src/client/toolbar/toolbar.cpp | 29 +---------- src/client/toolbar/toolbar.h | 2 - 6 files changed, 46 insertions(+), 295 deletions(-) delete mode 100644 icons/cam_off32.svg delete mode 100644 icons/cam_on32.svg diff --git a/icons/cam_off32.svg b/icons/cam_off32.svg deleted file mode 100644 index 2df7e9c..0000000 --- a/icons/cam_off32.svg +++ /dev/null @@ -1,109 +0,0 @@ - - - - - - - - - - - - - - - - - image/svg+xml - - - - - - - - - - - diff --git a/icons/cam_on32.svg b/icons/cam_on32.svg deleted file mode 100644 index 9f381fe..0000000 --- a/icons/cam_on32.svg +++ /dev/null @@ -1,109 +0,0 @@ - - - - - - - - - - - - - - - - - image/svg+xml - - - - - - - - - - - diff --git a/pvsclient.qrc b/pvsclient.qrc index 3432a62..c8cb796 100644 --- a/pvsclient.qrc +++ b/pvsclient.qrc @@ -1,48 +1,44 @@ - - icons/dark-green-check-mark.svg - icons/darrow16.svg - icons/ok16.svg - - icons/cam32.svg - icons/cam_on32.svg - icons/cam_off32.svg - icons/chat_msg16.svg - icons/keyboard_key.svg - icons/space.svg - icons/help.svg - AUTHORS - TRANSLATION - - - build/pvsclient_de_DE.qm - - - build/pvsclient_de_DE.qm - - - build/pvsclient_fr_FR.qm - - - build/pvsclient_fr_FR.qm - - - build/pvsclient_es_MX.qm - - - build/pvsclient_es_MX.qm - - - build/pvsclient_ar_JO.qm - - - build/pvsclient_ar_JO.qm - - - build/pvsclient_pl_PL.qm - - - build/pvsclient_pl_PL.qm - + + icons/dark-green-check-mark.svg + icons/darrow16.svg + icons/ok16.svg + icons/cam32.svg + icons/chat_msg16.svg + icons/keyboard_key.svg + icons/space.svg + icons/help.svg + AUTHORS + TRANSLATION + + + build/pvsclient_de_DE.qm + + + build/pvsclient_de_DE.qm + + + build/pvsclient_fr_FR.qm + + + build/pvsclient_fr_FR.qm + + + build/pvsclient_es_MX.qm + + + build/pvsclient_es_MX.qm + + + build/pvsclient_ar_JO.qm + + + build/pvsclient_ar_JO.qm + + + build/pvsclient_pl_PL.qm + + + build/pvsclient_pl_PL.qm + diff --git a/pvsmgr.qrc b/pvsmgr.qrc index 007512a..b5269b0 100644 --- a/pvsmgr.qrc +++ b/pvsmgr.qrc @@ -13,8 +13,8 @@ icons/tutor2student.svg icons/stopprojection.svg icons/keyboard_key.svg - icons/student2tutor_extension.svg - icons/help.svg + icons/student2tutor_extension.svg + icons/help.svg AUTHORS TRANSLATION build/pvsmgr_de_DE.qm diff --git a/src/client/toolbar/toolbar.cpp b/src/client/toolbar/toolbar.cpp index 6d9e9a5..7f6d8ad 100644 --- a/src/client/toolbar/toolbar.cpp +++ b/src/client/toolbar/toolbar.cpp @@ -24,7 +24,7 @@ */ Toolbar::Toolbar(QWidget *parent) : QWidget(parent), _ui(new Ui::Toolbar), _hideTimer(this), _connection(NULL), - _blinkTimer(this),_cam32(":cam32.svg"), _camOff32(":cam_off32.svg") + _cam32(":cam32.svg"), _camOff32(":cam_off32.svg") { /* Initialize the GUI */ _ui->setupUi(this); @@ -71,10 +71,6 @@ Toolbar::Toolbar(QWidget *parent) : _hideTimer.setSingleShot(true); connect(&_hideTimer, SIGNAL(timeout()), this, SLOT(hideBar())); _hideTimer.start(); // initially show PVS and hide later - - /* Setup blink timer */ - _blinkTimer.setInterval(500); - connect(&_blinkTimer, SIGNAL(timeout()), this, SLOT(cameraBlink())); } @@ -124,25 +120,6 @@ void Toolbar::enterEvent(QEvent* e) * Slots */ -/***************************************************************************//** - * A slot for changing the camera icon. This slot should be called permanently - * if the vnc server is recording the screen. - */ -void Toolbar::cameraBlink() -{ - static bool showRedDot = false; - if (!showRedDot) - { - _ui->icon_cam->setPixmap(_camOff32); - showRedDot = true; - } - else - { - _ui->icon_cam->setPixmap(_cam32); - showRedDot = false; - } -} - /***************************************************************************//** * A slot for the VncServerIsRunning signal. This slot will change the UI * according to the state fo the VncServer. @@ -151,12 +128,10 @@ void Toolbar::cameraBlink() void Toolbar::onVncServerIsRunning(int port) { if (port > 0){ - _blinkTimer.start(); _ui->lblStatus->setStyleSheet("color:red"); - _ui->lblStatus->setText(tr("Recording")); + _ui->lblStatus->setText(tr("Streaming")); showBar(); } else { - _blinkTimer.stop(); _ui->icon_cam->setPixmap(_cam32); _ui->lblStatus->setStyleSheet("color:green"); _ui->lblStatus->setText(tr("Online")); diff --git a/src/client/toolbar/toolbar.h b/src/client/toolbar/toolbar.h index de09b87..2a19835 100644 --- a/src/client/toolbar/toolbar.h +++ b/src/client/toolbar/toolbar.h @@ -40,7 +40,6 @@ private: QAction *_acnQuit; ConnectWindow *_connectWindow; QTimer _hideTimer; - QTimer _blinkTimer; ServerConnection *_connection; VncWindow *_vnc; const QPixmap _cam32, _camOff32; @@ -54,7 +53,6 @@ private slots: void onConnected(ServerConnection* connection); void onDoDisconnect(); - void cameraBlink(); void showBar(); void hideBar(); }; -- cgit v1.2.3-55-g7522