Remove dependency to QWidget / QMainWindow

This not GUI library!
This commit is contained in:
Siegfried Siegert 2023-05-23 14:41:09 +02:00
parent 88cc71e05f
commit 75b597586f
Signed by: SiegfriedSiegert
GPG Key ID: 68371E015E8F0B03
6 changed files with 11 additions and 11 deletions

View File

@ -4,7 +4,7 @@ CONFIG += plugin
#CONFIG -= app_bundle
#QT += widgets
QT -= gui
QT += widgets serialport
QT += serialport
INCLUDEPATH += $${PWD}/plugins
INCLUDEPATH += $${PWD}/include

View File

@ -3,7 +3,7 @@
#ifndef SER_H
#define SER_H
#include <stdint.h>
#include <QMainWindow>
#include <QObject>
#include <QString>
#include <QTimer>
#include <QSerialPort>
@ -15,7 +15,7 @@
// display all inputs and outputs in output window:
//#define PRINTALLDEBUGS 1
class T_com : public QMainWindow //, public QPlainTextEdit
class T_com : public QObject //, public QPlainTextEdit
{
Q_OBJECT
@ -45,7 +45,7 @@ private slots:
public:
T_com(QWidget *parent = nullptr);
T_com(QObject *parent = nullptr);
~T_com();
QTimer *serRecTime;

View File

@ -12,7 +12,7 @@
#include "dcBL.h"
#include <QMainWindow>
#include <QObject>
#include <QString>
#include <QTimer>
#include <QDebug>
@ -278,7 +278,7 @@
class T_datif : public QMainWindow
class T_datif : public QObject
{
Q_OBJECT
@ -315,7 +315,7 @@ private slots:
void StoredRecData();
public:
T_datif(QWidget *parent = nullptr);
T_datif(QObject *parent = nullptr);
T_prot *getProt() { return myDCIF; }
T_prot const *getProt() const { return myDCIF; }

View File

@ -3,7 +3,7 @@
#define SERIAL_FRAME_H
#include <stdint.h>
#include <QMainWindow>
#include <QObject>
#include <QString>
#include <QTimer>
#include "tslib.h"
@ -43,7 +43,7 @@
#define STARTSIGN_RECEIVE_LONG 0x5D
class T_prot : public QMainWindow
class T_prot : public QObject
{
Q_OBJECT

View File

@ -49,7 +49,7 @@ bool T_com::readFromSerial(QByteArray &data, uint16_t &sendLength)
// -------------------------------------------------------------------------------------------------------------
T_com::T_com(QWidget *parent) : QMainWindow(parent)
T_com::T_com(QObject *parent) : QObject(parent)
{
// port settings come from tabCom->Sdata->serial

View File

@ -19,7 +19,7 @@ static uint8_t cycl_running;
//static bool datif_DCdataValid;
T_datif::T_datif(QWidget *parent) : QMainWindow(parent)
T_datif::T_datif(QObject *parent) : QObject(parent)
{
myDCIF = new T_prot();