fix: 'data plot' - plot window now hides when keypress Q

This commit is contained in:
iceman1001 2018-04-06 23:52:55 +02:00
commit e8be06dd31
3 changed files with 11 additions and 6 deletions

View file

@ -557,6 +557,8 @@ Plot::Plot(QWidget *parent) : QWidget(parent), GraphStart(0), GraphPixelsPerPoin
CursorBPos = 0;
setWindowTitle(tr("Sliders"));
master = parent;
}
void Plot::closeEvent(QCloseEvent *event)
@ -672,8 +674,7 @@ void Plot::keyPressEvent(QKeyEvent *event)
break;
case Qt::Key_Q:
//this->hide();
this->close();
master->hide();
break;
default:

View file

@ -22,12 +22,16 @@
#include <QtGui>
#include "ui/ui_overlays.h"
class ProxWidget;
/**
* @brief The actual plot, black area were we paint the graph
*/
class Plot: public QWidget
{
private:
QWidget *master;
int GraphStart;
double GraphPixelsPerPoint;
int CursorAPos;

View file

@ -159,9 +159,9 @@ void PrintAndLog(char *fmt, ...) {
}
va_end(argptr2);
if (g_flushAfterWrite == 1) {
if (g_flushAfterWrite == 1)
fflush(NULL);
}
//release lock
pthread_mutex_unlock(&print_lock);
}