From d8b442f484d8ec9fbbaa914c328048e85e860ade Mon Sep 17 00:00:00 2001 From: Chris Esposito Date: Sun, 5 Jul 2020 13:08:46 +1000 Subject: [PATCH] Tooltip appears when gobindar detected --- Desktop_Interface/genericusbdriver.cpp | 24 ++++++++++++++++-------- 1 file changed, 16 insertions(+), 8 deletions(-) diff --git a/Desktop_Interface/genericusbdriver.cpp b/Desktop_Interface/genericusbdriver.cpp index 6370482d..997769b4 100644 --- a/Desktop_Interface/genericusbdriver.cpp +++ b/Desktop_Interface/genericusbdriver.cpp @@ -7,6 +7,20 @@ #include "platformspecific.h" #endif +#include + +class GobindarDialog : public QDialog +{ +public: + GobindarDialog(); +}; + +GobindarDialog::GobindarDialog() +: QDialog() +{ + setWindowFlags(Qt::ToolTip); +} + genericUsbDriver::genericUsbDriver(QWidget *parent) : QLabel(parent) { connectedStatus(false); @@ -357,16 +371,10 @@ void genericUsbDriver::requestFirmwareVariant(void){ variant = *((unsigned char *) inBuffer); } -#include -#include - void genericUsbDriver::deGobindarise() { - while(1) - { - qDebug() << "Gobindar board detected!!!"; - std::this_thread::sleep_for(std::chrono::milliseconds(100)); - } + GobindarDialog gobindarDialog; + gobindarDialog.exec(); } void genericUsbDriver::saveState(int *_out_deviceMode, double *_out_scopeGain, double *_out_currentPsuVoltage, int *_out_digitalPinState){