mirror of
https://gitea.msk.dinamika-avia.ru/Constanta-Design/RRJClient.git
synced 2026-03-28 05:25:39 +03:00
Init commit
This commit is contained in:
20
Core/FileData.h
Normal file
20
Core/FileData.h
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
#include <QString>
|
||||||
|
|
||||||
|
#ifndef FILEDATA_H
|
||||||
|
#define FILEDATA_H
|
||||||
|
|
||||||
|
struct FileData
|
||||||
|
{
|
||||||
|
QString path;
|
||||||
|
QString hash;
|
||||||
|
|
||||||
|
bool operator==(const FileData& other)const{
|
||||||
|
if(this->path==(other.path)) return true;
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
}; //путь
|
||||||
|
|
||||||
|
|
||||||
|
#endif // FILEDATA_H
|
||||||
|
|
||||||
112
Core/UpdateController.cpp
Normal file
112
Core/UpdateController.cpp
Normal file
@@ -0,0 +1,112 @@
|
|||||||
|
#include "UpdateController.h"
|
||||||
|
|
||||||
|
UpdateController::UpdateController(DataParser *parser, QObject *parent) :
|
||||||
|
QObject(parent)
|
||||||
|
{
|
||||||
|
this->dataParser = parser;
|
||||||
|
localPath = QDir::currentPath() + "/Application";
|
||||||
|
countSend = 0;
|
||||||
|
CalculateHash();
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void UpdateController::SendFile(QDataStream &stream)
|
||||||
|
{
|
||||||
|
/* Открываем файл для Чтения*/
|
||||||
|
QFile file(hashFilename);
|
||||||
|
|
||||||
|
stream << PacketType::TYPE_FILE; //Отправляем тип блока
|
||||||
|
QFileInfo fileInfo(file);
|
||||||
|
fileSize = fileInfo.size();
|
||||||
|
|
||||||
|
stream << fileSize;
|
||||||
|
|
||||||
|
if(file.open(QFile::ReadOnly | QFile::Text)){
|
||||||
|
while(!file.atEnd()){
|
||||||
|
QByteArray data = file.readAll();//file.read(1025*250);
|
||||||
|
stream << data;
|
||||||
|
countSend++;
|
||||||
|
}
|
||||||
|
|
||||||
|
qDebug() << Tools::GetTime() << "count end Final: " << countSend;
|
||||||
|
}
|
||||||
|
|
||||||
|
file.close();
|
||||||
|
countSend = 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
void UpdateController::CalculateHash()
|
||||||
|
{
|
||||||
|
QDirIterator iterator(localPath,QDirIterator::Subdirectories);
|
||||||
|
fileDataList.clear();
|
||||||
|
QList<FileData> *files = new QList<FileData>;
|
||||||
|
QList<FileData> * folders = new QList<FileData>;
|
||||||
|
|
||||||
|
if(!QDir("Application").exists()){ //проверка на наличие папки
|
||||||
|
QDir().mkdir("Application");
|
||||||
|
}
|
||||||
|
|
||||||
|
QDir dir(localPath);
|
||||||
|
QString hashString;
|
||||||
|
|
||||||
|
while (iterator.hasNext())
|
||||||
|
{
|
||||||
|
iterator.next();
|
||||||
|
QFileInfo fileInfo = iterator.fileInfo();
|
||||||
|
FileData currentFile;
|
||||||
|
QFile file(fileInfo.absoluteFilePath());
|
||||||
|
|
||||||
|
quint64 fileSize = file.size(); //буффер для хэширования крупных файлов
|
||||||
|
const quint64 bufferSize = 10240;
|
||||||
|
|
||||||
|
if(fileInfo.isHidden()) continue;
|
||||||
|
|
||||||
|
if(fileInfo.isFile() && file.open(QIODevice::ReadOnly))
|
||||||
|
{
|
||||||
|
char buffer[bufferSize];
|
||||||
|
int bytesRead;
|
||||||
|
int readSize = qMin(fileSize,bufferSize);
|
||||||
|
|
||||||
|
QCryptographicHash hash(QCryptographicHash::Md5);
|
||||||
|
|
||||||
|
while(readSize > 0 && (bytesRead = file.read(buffer,readSize)) > 0){
|
||||||
|
fileSize -= bytesRead;
|
||||||
|
hash.addData(buffer,bytesRead);
|
||||||
|
readSize = qMin(fileSize,bufferSize);
|
||||||
|
}
|
||||||
|
hashString = QString(hash.result().toHex());
|
||||||
|
currentFile.path = Tools::CreateLocalPath(fileInfo.absoluteFilePath());
|
||||||
|
currentFile.hash = hashString;
|
||||||
|
files->push_back(currentFile);
|
||||||
|
}
|
||||||
|
else if (fileInfo.isDir() && !fileInfo.isRoot() && fileInfo.fileName() != "..")
|
||||||
|
{
|
||||||
|
currentFile.path = Tools::CreateLocalPath(fileInfo.path());
|
||||||
|
currentFile.hash = "FOLDER";
|
||||||
|
|
||||||
|
if(!folders->contains(currentFile)){
|
||||||
|
folders->push_back(currentFile);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
fileDataList.append(*folders);
|
||||||
|
fileDataList.append(*files);
|
||||||
|
|
||||||
|
dataParser->CreateXML(fileDataList);
|
||||||
|
|
||||||
|
delete folders;
|
||||||
|
delete files;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
UpdateController::~UpdateController()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
40
Core/UpdateController.h
Normal file
40
Core/UpdateController.h
Normal file
@@ -0,0 +1,40 @@
|
|||||||
|
#ifndef FILEMANAGER_H
|
||||||
|
#define FILEMANAGER_H
|
||||||
|
|
||||||
|
#include "Core\FileData.h"
|
||||||
|
#include "Core\dataparser.h"
|
||||||
|
#include "Core\tcpclient.h"
|
||||||
|
#include <QXmlStreamWriter>
|
||||||
|
#include <QXmlStreamReader>
|
||||||
|
#include <QXmlStreamAttribute>
|
||||||
|
#include <QCryptographicHash>
|
||||||
|
#include <QDirIterator>
|
||||||
|
#include <QFile>
|
||||||
|
#include <QTextStream>
|
||||||
|
#include <QDateTime>
|
||||||
|
#include <QDebug>
|
||||||
|
#include <QList>
|
||||||
|
#include <QObject>
|
||||||
|
|
||||||
|
class UpdateController : public QObject
|
||||||
|
{
|
||||||
|
|
||||||
|
Q_OBJECT
|
||||||
|
|
||||||
|
public:
|
||||||
|
explicit UpdateController(DataParser *parser,QObject *parent = 0);
|
||||||
|
void SendFile(QDataStream &stream);
|
||||||
|
void CalculateHash();
|
||||||
|
~UpdateController();
|
||||||
|
|
||||||
|
|
||||||
|
private:
|
||||||
|
DataParser *dataParser;
|
||||||
|
QString localPath;
|
||||||
|
QList<FileData> fileDataList;
|
||||||
|
quint64 fileSize;
|
||||||
|
int countSend;
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // FILEMANAGER_H
|
||||||
98
Core/dataparser.cpp
Normal file
98
Core/dataparser.cpp
Normal file
@@ -0,0 +1,98 @@
|
|||||||
|
#include "FileData.h"
|
||||||
|
#include "dataparser.h"
|
||||||
|
#include "tools.h"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
DataParser::DataParser()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void DataParser::CreateXML(QList<FileData> fileDataList)
|
||||||
|
{
|
||||||
|
|
||||||
|
QFile file(hashFilename);
|
||||||
|
file.open(QIODevice::WriteOnly);
|
||||||
|
QXmlStreamWriter xmlWriter(&file);
|
||||||
|
|
||||||
|
xmlWriter.setAutoFormatting(true);
|
||||||
|
xmlWriter.writeStartDocument();
|
||||||
|
xmlWriter.writeStartElement("FileDataList");
|
||||||
|
|
||||||
|
foreach (FileData data,fileDataList)
|
||||||
|
{
|
||||||
|
xmlWriter.writeStartElement("FileData");
|
||||||
|
|
||||||
|
xmlWriter.writeAttribute("Path",data.path);
|
||||||
|
xmlWriter.writeAttribute("Hash",data.hash);
|
||||||
|
|
||||||
|
xmlWriter.writeEndElement();
|
||||||
|
}
|
||||||
|
|
||||||
|
xmlWriter.writeEndElement();
|
||||||
|
xmlWriter.writeEndDocument();
|
||||||
|
|
||||||
|
file.close();
|
||||||
|
}
|
||||||
|
|
||||||
|
void DataParser::CreateServerSettings(QString address, QString port)
|
||||||
|
{
|
||||||
|
QFile file(settingsName);
|
||||||
|
|
||||||
|
file.open(QIODevice::WriteOnly);
|
||||||
|
|
||||||
|
QXmlStreamWriter xmlWriter(&file);
|
||||||
|
|
||||||
|
xmlWriter.setAutoFormatting(true);
|
||||||
|
xmlWriter.writeStartDocument();
|
||||||
|
xmlWriter.writeStartElement("ServerSettingsContainer");
|
||||||
|
|
||||||
|
xmlWriter.writeStartElement("ServerSettings");
|
||||||
|
xmlWriter.writeAttribute("Address",address);
|
||||||
|
xmlWriter.writeAttribute("Port",port);
|
||||||
|
|
||||||
|
xmlWriter.writeEndElement();
|
||||||
|
xmlWriter.writeEndElement();
|
||||||
|
|
||||||
|
xmlWriter.writeEndDocument();
|
||||||
|
|
||||||
|
file.close();
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
ServerSettings *DataParser::GetServerSettings()
|
||||||
|
{
|
||||||
|
ServerSettings *settings = new ServerSettings;
|
||||||
|
QFile file(settingsName);
|
||||||
|
file.open(QIODevice::ReadOnly);
|
||||||
|
QXmlStreamReader xmlReader(&file);
|
||||||
|
|
||||||
|
while (!xmlReader.atEnd()){
|
||||||
|
|
||||||
|
if(xmlReader.isStartElement()){
|
||||||
|
|
||||||
|
if(xmlReader.name() == "ServerSettings"){
|
||||||
|
|
||||||
|
foreach(const QXmlStreamAttribute &attr, xmlReader.attributes()){
|
||||||
|
QString name = attr.name().toString();
|
||||||
|
QString value = attr.value().toString();
|
||||||
|
|
||||||
|
if(name == "Address"){
|
||||||
|
settings->Address = value;
|
||||||
|
}
|
||||||
|
|
||||||
|
if(name == "Port"){
|
||||||
|
settings->Port = value;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
xmlReader.readNext();
|
||||||
|
}
|
||||||
|
|
||||||
|
return settings;
|
||||||
|
}
|
||||||
|
|
||||||
21
Core/dataparser.h
Normal file
21
Core/dataparser.h
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
#ifndef DATAPARSER_H
|
||||||
|
#define DATAPARSER_H
|
||||||
|
|
||||||
|
#include "FileData.h"
|
||||||
|
|
||||||
|
#include <Datas.h>
|
||||||
|
#include <QFile>
|
||||||
|
#include <QXmlStreamWriter>
|
||||||
|
|
||||||
|
|
||||||
|
class DataParser
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
DataParser();
|
||||||
|
~DataParser();
|
||||||
|
void CreateServerSettings(QString server,QString port);
|
||||||
|
ServerSettings* GetServerSettings();
|
||||||
|
void CreateXML(QList<FileData> fileDataList);
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // DATAPARSER_H
|
||||||
37
Core/externalexecuter.cpp
Normal file
37
Core/externalexecuter.cpp
Normal file
@@ -0,0 +1,37 @@
|
|||||||
|
#include "externalexecuter.h"
|
||||||
|
|
||||||
|
|
||||||
|
ExternalExecuter::ExternalExecuter()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
ExternalExecuter::~ExternalExecuter()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void ExternalExecuter::CallApp()
|
||||||
|
{
|
||||||
|
QProcess myProcess(this);
|
||||||
|
QStringList args;
|
||||||
|
args << "1";
|
||||||
|
|
||||||
|
myProcess.start(programPath,args);
|
||||||
|
myProcess.waitForFinished(-1);
|
||||||
|
}
|
||||||
|
|
||||||
|
void ExternalExecuter::FindApp()
|
||||||
|
{
|
||||||
|
QString localPath = QDir::currentPath() + "/Application";
|
||||||
|
QDirIterator iterator(localPath,QDirIterator::Subdirectories);
|
||||||
|
|
||||||
|
while(iterator.hasNext()){
|
||||||
|
iterator.next();
|
||||||
|
|
||||||
|
if(iterator.fileInfo().fileName() == "RRJ.exe"){
|
||||||
|
programPath = iterator.fileInfo().absoluteFilePath();
|
||||||
|
qDebug() << "Bin found: " << programPath;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
25
Core/externalexecuter.h
Normal file
25
Core/externalexecuter.h
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
#ifndef EXTERNALEXECUTER_H
|
||||||
|
#define EXTERNALEXECUTER_H
|
||||||
|
|
||||||
|
#include <QObject>
|
||||||
|
#include <QString>
|
||||||
|
#include <QDir>
|
||||||
|
#include <QDirIterator>
|
||||||
|
#include <QProcess>
|
||||||
|
#include <QDebug>
|
||||||
|
|
||||||
|
class ExternalExecuter : public QObject
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
|
||||||
|
public:
|
||||||
|
ExternalExecuter();
|
||||||
|
void CallApp();
|
||||||
|
void FindApp();
|
||||||
|
~ExternalExecuter();
|
||||||
|
|
||||||
|
private:
|
||||||
|
QString programPath;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // EXTERNALEXECUTER_H
|
||||||
36
Core/main.cpp
Normal file
36
Core/main.cpp
Normal file
@@ -0,0 +1,36 @@
|
|||||||
|
#include "UpdateController.h"
|
||||||
|
#include "dataparser.h"
|
||||||
|
#include "externalexecuter.h"
|
||||||
|
#include "screenchecker.h"
|
||||||
|
|
||||||
|
#include <QCoreApplication>
|
||||||
|
#include <QDebug>
|
||||||
|
#include <QObject>
|
||||||
|
#include <nonblockedinput.h>
|
||||||
|
#include <tcpclient.h>
|
||||||
|
#include <QTextCodec>
|
||||||
|
#include <QProcess>
|
||||||
|
|
||||||
|
int main(int argc, char *argv[])
|
||||||
|
{
|
||||||
|
QCoreApplication a(argc, argv);
|
||||||
|
setlocale(LC_ALL,"Russian");
|
||||||
|
|
||||||
|
NonBlockedInput cli;
|
||||||
|
TCPClient *client = new TCPClient;
|
||||||
|
DataParser *parser = new DataParser;
|
||||||
|
UpdateController *updateController = new UpdateController(parser);
|
||||||
|
RecognizeSystem *recognizeSystem = new RecognizeSystem;
|
||||||
|
ScreenChecker *screenChecker = new ScreenChecker;
|
||||||
|
ExternalExecuter *externalExecuter = new ExternalExecuter;
|
||||||
|
|
||||||
|
|
||||||
|
client->Initialize(updateController,recognizeSystem,externalExecuter);
|
||||||
|
recognizeSystem->Initialize(updateController);
|
||||||
|
|
||||||
|
QObject::connect(&cli,&NonBlockedInput::LineIsRead,client,&TCPClient::onMessageEntered);
|
||||||
|
|
||||||
|
//screenChecker->Check();
|
||||||
|
return a.exec();
|
||||||
|
|
||||||
|
}
|
||||||
18
Core/nonblockedinput.cpp
Normal file
18
Core/nonblockedinput.cpp
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
#include "nonblockedinput.h"
|
||||||
|
|
||||||
|
NonBlockedInput::NonBlockedInput(QObject *parent)
|
||||||
|
{
|
||||||
|
this->moveToThread(&thread);
|
||||||
|
connect(&thread,&QThread::started, this, &NonBlockedInput::ReadLine);
|
||||||
|
thread.start();
|
||||||
|
}
|
||||||
|
|
||||||
|
void NonBlockedInput::ReadLine()
|
||||||
|
{
|
||||||
|
QTextStream inputStream(stdin);
|
||||||
|
QString line;
|
||||||
|
|
||||||
|
while (inputStream.readLineInto(&line)){
|
||||||
|
emit LineIsRead(line);
|
||||||
|
}
|
||||||
|
}
|
||||||
24
Core/nonblockedinput.h
Normal file
24
Core/nonblockedinput.h
Normal file
@@ -0,0 +1,24 @@
|
|||||||
|
#ifndef NONBLOCKEDINPUT_H
|
||||||
|
#define NONBLOCKEDINPUT_H
|
||||||
|
|
||||||
|
#include <QTextStream>
|
||||||
|
#include <QDebug>
|
||||||
|
#include <QThread>
|
||||||
|
|
||||||
|
class NonBlockedInput : public QObject
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
|
||||||
|
public:
|
||||||
|
explicit NonBlockedInput(QObject* parent = nullptr);
|
||||||
|
|
||||||
|
private:
|
||||||
|
QThread thread;
|
||||||
|
|
||||||
|
signals:
|
||||||
|
void LineIsRead(QString line);
|
||||||
|
private slots:
|
||||||
|
void ReadLine();
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // NONBLOCKEDINPUT_H
|
||||||
243
Core/recognizesystem.cpp
Normal file
243
Core/recognizesystem.cpp
Normal file
@@ -0,0 +1,243 @@
|
|||||||
|
#include "Core/recognizesystem.h"
|
||||||
|
|
||||||
|
RecognizeSystem::RecognizeSystem(QObject *parent):
|
||||||
|
QObject(parent)
|
||||||
|
{
|
||||||
|
packetType = PacketType::TYPE_NONE;
|
||||||
|
filePath.clear();
|
||||||
|
fileSize = 0;
|
||||||
|
message.clear();
|
||||||
|
sizeReceiveData = 0;
|
||||||
|
tmpBlock.clear();
|
||||||
|
countSend = 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
RecognizeSystem::~RecognizeSystem()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void RecognizeSystem::Initialize(UpdateController *updateController)
|
||||||
|
{
|
||||||
|
this->updateController = updateController;
|
||||||
|
}
|
||||||
|
|
||||||
|
void RecognizeSystem::SetSocket(QTcpSocket *socket)
|
||||||
|
{
|
||||||
|
this->socket = socket;
|
||||||
|
}
|
||||||
|
|
||||||
|
void RecognizeSystem::Recognize()
|
||||||
|
{
|
||||||
|
QDataStream stream(socket);
|
||||||
|
stream.setVersion(QDataStream::Qt_DefaultCompiledVersion);
|
||||||
|
|
||||||
|
while(socket->bytesAvailable())
|
||||||
|
{
|
||||||
|
|
||||||
|
if(packetType == PacketType::TYPE_NONE){ //определение первичного пакета
|
||||||
|
|
||||||
|
stream.startTransaction();
|
||||||
|
stream >> packetType;
|
||||||
|
|
||||||
|
if(!stream.commitTransaction()){
|
||||||
|
emit onSendDebugLog(Tools::GetTime() + " CLIENT: packetType - FAIL commitTransaction");
|
||||||
|
|
||||||
|
if(socket->waitForReadyRead(TCP_READ_TIMEOUT)){
|
||||||
|
emit onSendDebugLog("ERROR: PACKET TYPE READ TIMEOUT");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
continue;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
//qDebug() << Tools::GetTime() << "CLIENT: type: " << packetType;
|
||||||
|
}
|
||||||
|
|
||||||
|
if(packetType == PacketType::TYPE_MSG){ //поведение на тип пакета с сообщением
|
||||||
|
|
||||||
|
stream.startTransaction();
|
||||||
|
stream >> message;
|
||||||
|
|
||||||
|
if(!stream.commitTransaction()){
|
||||||
|
emit onSendDebugLog(Tools::GetTime() + "CLIENT: Message - FAIL commitTransaction");
|
||||||
|
if(socket->waitForReadyRead(TCP_READ_TIMEOUT)){
|
||||||
|
emit onSendDebugLog(Tools::GetTime() + "ERROR: MESSAGE READ TIMEOUT");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
emit onSendDebugLog(Tools::GetTime() + " CLIENT: Message from server " + message); //результат обрабатывать тут?
|
||||||
|
packetType = PacketType::TYPE_NONE;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
if(packetType == PacketType::TYPE_FOLDER){ //создание папок
|
||||||
|
stream.startTransaction();
|
||||||
|
stream >> filePath;
|
||||||
|
|
||||||
|
if(!stream.commitTransaction()){
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
filePath = Tools::CreateFullPath(filePath);
|
||||||
|
|
||||||
|
QDir dir(filePath);
|
||||||
|
if(!dir.exists()){
|
||||||
|
if(dir.mkpath(filePath)){
|
||||||
|
qDebug() << "Dir Created";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
packetType = PacketType::TYPE_NONE;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
if(packetType == PacketType::TYPE_FILE) //загрузка файлов
|
||||||
|
{
|
||||||
|
|
||||||
|
//ПОЛУЧЕНИЕ ПУТИ
|
||||||
|
//ПОЛУЧЕНИЕ РАЗМЕРА ФАЙЛА
|
||||||
|
forever
|
||||||
|
{
|
||||||
|
stream.startTransaction();
|
||||||
|
stream >> filePath;
|
||||||
|
stream >> fileSize;
|
||||||
|
|
||||||
|
if(!stream.commitTransaction()){
|
||||||
|
emit onSendDebugLog(Tools::GetTime() + "CLIENT: filePath, fileSize - FAIL commitTransaction");
|
||||||
|
|
||||||
|
if (!socket->waitForReadyRead(TCP_READ_TIMEOUT)) {
|
||||||
|
emit onSendDebugLog(Tools::GetTime() + "CLIENT: ERROR! readyRead timeout - filePath, fileSize!!!");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
continue;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
filePath = Tools::CreateFullPath(filePath);
|
||||||
|
|
||||||
|
emit onSendDebugLog("CLIENT: filesize: " + QString::number(fileSize));
|
||||||
|
emit onSendDebugLog("CLIENT: filePath: " + filePath);
|
||||||
|
|
||||||
|
socket->waitForReadyRead(100);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
//ПОЛУЧЕНИЕ САМОГО ФАЙЛА
|
||||||
|
emit onSendDebugLog(Tools::GetTime() + "AfterRead size and path BytesAvailable: " + socket->bytesAvailable());
|
||||||
|
|
||||||
|
//УКАЗАНИЕ ПУТИ ФАЙЛА
|
||||||
|
QFile file(filePath);
|
||||||
|
|
||||||
|
if (file.exists())
|
||||||
|
{
|
||||||
|
file.remove(); //удаление файла, если он уже есть, но необходимо обновить
|
||||||
|
emit onSendDebugLog(Tools::GetTime() + "Delete exist file: " + filePath);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
file.open(QFile::Append);
|
||||||
|
|
||||||
|
forever
|
||||||
|
{
|
||||||
|
stream.startTransaction();
|
||||||
|
stream >> tmpBlock;
|
||||||
|
|
||||||
|
if(!stream.commitTransaction()){
|
||||||
|
//qDebug() << Tools::GetTime() << "CLIENT: tmpBlock - FAIL";
|
||||||
|
if(socket->waitForReadyRead(TCP_READ_TIMEOUT)){
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
quint64 toFile = file.write(tmpBlock);
|
||||||
|
emit onSendDebugLog(Tools::GetTime() + "CLIENT: toFile :" + toFile);
|
||||||
|
|
||||||
|
sizeReceiveData += toFile;
|
||||||
|
countSend++;
|
||||||
|
|
||||||
|
emit UpdateBytesAvailable(fileSize,sizeReceiveData);
|
||||||
|
|
||||||
|
tmpBlock.clear();
|
||||||
|
|
||||||
|
if(sizeReceiveData == fileSize){
|
||||||
|
emit onSendDebugLog(Tools::GetTime() + "FINAL Count send: " + QString::number(countSend));
|
||||||
|
emit onSendDebugLog(Tools::GetTime() + "FINAL Size received: " + QString::number(sizeReceiveData));
|
||||||
|
emit onSendDebugLog(Tools::GetTime() + "FINAL File size" + QString::number(fileSize));
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
file.close();
|
||||||
|
emit onSendDebugLog(Tools::GetTime() + "File loaded");
|
||||||
|
|
||||||
|
//ОЧИСТКА ПОСЛЕ ПЕРЕДАЧИ
|
||||||
|
|
||||||
|
filePath.clear();
|
||||||
|
fileSize = 0;
|
||||||
|
tmpBlock.clear();
|
||||||
|
sizeReceiveData = 0;
|
||||||
|
countSend = 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
if(packetType == PacketType::TYPE_DELETE) //удаление лишних файлов (рекурсивно удаляет все содежимое)
|
||||||
|
{
|
||||||
|
stream.startTransaction();
|
||||||
|
stream >> filePath;
|
||||||
|
|
||||||
|
if(!stream.commitTransaction()){
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
filePath = Tools::CreateFullPath(filePath);
|
||||||
|
|
||||||
|
QFileInfo fileInfo(filePath);
|
||||||
|
|
||||||
|
|
||||||
|
if(fileInfo.exists())
|
||||||
|
{
|
||||||
|
if(fileInfo.isFile()){
|
||||||
|
QFile file(filePath);
|
||||||
|
file.remove();
|
||||||
|
}
|
||||||
|
|
||||||
|
if(fileInfo.isDir()){
|
||||||
|
QDir dir(filePath);
|
||||||
|
dir.removeRecursively();
|
||||||
|
}
|
||||||
|
|
||||||
|
qDebug() << Tools::GetTime() << "Deleted: " << filePath;
|
||||||
|
}
|
||||||
|
|
||||||
|
packetType = PacketType::TYPE_NONE;
|
||||||
|
continue;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
if(packetType ==PacketType::TYPE_FINISH){ //для повторного создания хэша после загрузки
|
||||||
|
updateController->CalculateHash();
|
||||||
|
emit LoadComplete();
|
||||||
|
packetType = PacketType::TYPE_NONE;
|
||||||
|
}
|
||||||
|
|
||||||
|
if(packetType == PacketType::TYPE_NEEDUPDATE){
|
||||||
|
|
||||||
|
bool flag;
|
||||||
|
|
||||||
|
stream.startTransaction();
|
||||||
|
stream >> flag;
|
||||||
|
|
||||||
|
|
||||||
|
emit onNeedUpdate(flag);
|
||||||
|
packetType = PacketType::TYPE_NONE;
|
||||||
|
}
|
||||||
|
packetType = PacketType::TYPE_NONE;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
45
Core/recognizesystem.h
Normal file
45
Core/recognizesystem.h
Normal file
@@ -0,0 +1,45 @@
|
|||||||
|
#ifndef RECOGNIZESYSTEM_H
|
||||||
|
#define RECOGNIZESYSTEM_H
|
||||||
|
|
||||||
|
#include <QObject>
|
||||||
|
#include <QDataStream>
|
||||||
|
#include <QTcpSocket>
|
||||||
|
#include <mainwindow.h>
|
||||||
|
#include <Core\tools.h>
|
||||||
|
#include <Core\UpdateController.h>
|
||||||
|
|
||||||
|
class UpdateController;
|
||||||
|
|
||||||
|
class RecognizeSystem : public QObject
|
||||||
|
{
|
||||||
|
|
||||||
|
Q_OBJECT
|
||||||
|
|
||||||
|
public:
|
||||||
|
explicit RecognizeSystem(QObject *parent = 0);
|
||||||
|
~RecognizeSystem();
|
||||||
|
void Initialize(UpdateController* updateController);
|
||||||
|
void SetSocket(QTcpSocket *socket);
|
||||||
|
void Recognize();
|
||||||
|
|
||||||
|
signals:
|
||||||
|
void UpdateBytesAvailable(qint64 size,quint64 sended);
|
||||||
|
void LoadComplete();
|
||||||
|
void onNeedUpdate(bool flag);
|
||||||
|
void onSendDebugLog(QString message);
|
||||||
|
|
||||||
|
private:
|
||||||
|
UpdateController *updateController;
|
||||||
|
QTcpSocket *socket;
|
||||||
|
PacketType packetType;
|
||||||
|
QString message;
|
||||||
|
QString filePath;
|
||||||
|
QByteArray tmpBlock;
|
||||||
|
|
||||||
|
qint64 sizeReceiveData;
|
||||||
|
qint64 fileSize;
|
||||||
|
int countSend;
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // RECOGNIZESYSTEM_H
|
||||||
24
Core/screenchecker.cpp
Normal file
24
Core/screenchecker.cpp
Normal file
@@ -0,0 +1,24 @@
|
|||||||
|
#include "screenchecker.h"
|
||||||
|
|
||||||
|
ScreenChecker::ScreenChecker()
|
||||||
|
{
|
||||||
|
screenCount = 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
void ScreenChecker::Check()
|
||||||
|
{
|
||||||
|
screens = QGuiApplication::screens();
|
||||||
|
|
||||||
|
for (int i = 0; i < screens.size();i++){
|
||||||
|
|
||||||
|
qDebug() << screens[i]->name();
|
||||||
|
screenCount++;
|
||||||
|
}
|
||||||
|
|
||||||
|
qDebug() << "Now worked: " << screenCount <<" displays" << endl;
|
||||||
|
}
|
||||||
|
|
||||||
|
QString ScreenChecker::getScreenCount() const
|
||||||
|
{
|
||||||
|
return QString::number(screenCount);
|
||||||
|
}
|
||||||
21
Core/screenchecker.h
Normal file
21
Core/screenchecker.h
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
#ifndef SCREENCHECKER_H
|
||||||
|
#define SCREENCHECKER_H
|
||||||
|
|
||||||
|
#include <QObject>
|
||||||
|
#include <QScreen>
|
||||||
|
#include <QGuiApplication>
|
||||||
|
#include <QDebug>
|
||||||
|
|
||||||
|
class ScreenChecker
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
ScreenChecker();
|
||||||
|
void Check();
|
||||||
|
QString getScreenCount() const;
|
||||||
|
|
||||||
|
private:
|
||||||
|
qint64 screenCount;
|
||||||
|
QList<QScreen *> screens;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // SCREENCHECKER_H
|
||||||
100
Core/tcpclient.cpp
Normal file
100
Core/tcpclient.cpp
Normal file
@@ -0,0 +1,100 @@
|
|||||||
|
#include "tcpclient.h"
|
||||||
|
#include "UpdateController.h"
|
||||||
|
#include "externalexecuter.h"
|
||||||
|
|
||||||
|
#include <QDir>
|
||||||
|
|
||||||
|
TCPClient::TCPClient(QObject *parent) :
|
||||||
|
QObject(parent)
|
||||||
|
{
|
||||||
|
socket = new QTcpSocket(this);
|
||||||
|
|
||||||
|
connect(socket,&QTcpSocket::readyRead,this,&TCPClient::onReadyRead);
|
||||||
|
}
|
||||||
|
|
||||||
|
void TCPClient::Initialize(UpdateController *updateController,
|
||||||
|
RecognizeSystem *recognize,
|
||||||
|
ExternalExecuter *externalExecuter)
|
||||||
|
{
|
||||||
|
this->updateController = updateController;
|
||||||
|
this->recognizeSystem = recognize;
|
||||||
|
this->externalExecuter = externalExecuter;
|
||||||
|
|
||||||
|
recognize->SetSocket(socket);
|
||||||
|
emit onSendDebugLog(Tools::GetTime() + " Client started");
|
||||||
|
}
|
||||||
|
|
||||||
|
void TCPClient::SetConnect(ServerSettings *serverSettings)
|
||||||
|
{
|
||||||
|
socket->connectToHost(serverSettings->Address,serverSettings->Port.toShort());
|
||||||
|
emit onSendDebugLog("Try connect...");
|
||||||
|
|
||||||
|
socket->waitForReadyRead();
|
||||||
|
|
||||||
|
if(socket->state() != QTcpSocket::ConnectedState){
|
||||||
|
emit onSendDebugLog("Connect invalid");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void TCPClient::WaitWrites()
|
||||||
|
{
|
||||||
|
socket->waitForBytesWritten();
|
||||||
|
}
|
||||||
|
|
||||||
|
QTcpSocket *TCPClient::GetSocket()
|
||||||
|
{
|
||||||
|
return socket;
|
||||||
|
}
|
||||||
|
|
||||||
|
TCPClient::~TCPClient()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void TCPClient::onMessageEntered(QString message)
|
||||||
|
{
|
||||||
|
QDataStream stream(socket);
|
||||||
|
QByteArray data;
|
||||||
|
stream.setVersion(QDataStream::Qt_DefaultCompiledVersion);
|
||||||
|
|
||||||
|
if(!message.isEmpty() && socket->state() == QTcpSocket::ConnectedState){
|
||||||
|
|
||||||
|
socket->waitForBytesWritten();
|
||||||
|
|
||||||
|
if(message == "check")
|
||||||
|
{
|
||||||
|
stream << PacketType::TYPE_COMMAND;
|
||||||
|
stream << message;
|
||||||
|
socket->waitForBytesWritten();
|
||||||
|
|
||||||
|
updateController->SendFile(stream);
|
||||||
|
emit onSendDebugLog(Tools::GetTime() + " Local checkFile sended");
|
||||||
|
WaitWrites();
|
||||||
|
socket->readyRead();
|
||||||
|
}
|
||||||
|
else if(message == "update"){
|
||||||
|
emit onSendDebugLog("Update started");
|
||||||
|
stream << PacketType::TYPE_COMMAND;
|
||||||
|
stream << message;
|
||||||
|
socket->waitForBytesWritten();
|
||||||
|
}
|
||||||
|
else if(message == "run"){
|
||||||
|
externalExecuter->CallApp();
|
||||||
|
}
|
||||||
|
}else{
|
||||||
|
emit onSendDebugLog("WRONG SOCKET AFTER ENTERED");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void TCPClient::onReadyRead()
|
||||||
|
{
|
||||||
|
if(!socket){
|
||||||
|
emit onSendDebugLog("WRONG SOCKET");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
//возврат на случай недоступного сокета
|
||||||
|
|
||||||
|
recognizeSystem->Recognize();
|
||||||
|
}
|
||||||
46
Core/tcpclient.h
Normal file
46
Core/tcpclient.h
Normal file
@@ -0,0 +1,46 @@
|
|||||||
|
#ifndef TCPCLIENT_H
|
||||||
|
#define TCPCLIENT_H
|
||||||
|
|
||||||
|
#include <QObject>
|
||||||
|
#include <QTcpSocket>
|
||||||
|
#include <QHostAddress>
|
||||||
|
#include <QDataStream>
|
||||||
|
#include <QTcpServer>
|
||||||
|
#include <QFile>
|
||||||
|
#include <QCoreApplication>
|
||||||
|
#include "Core\recognizesystem.h"
|
||||||
|
#include "Core\tools.h"
|
||||||
|
#include "Core\UpdateController.h"
|
||||||
|
#include "Core\externalexecuter.h"
|
||||||
|
|
||||||
|
class UpdateController;
|
||||||
|
class RecognizeSystem;
|
||||||
|
|
||||||
|
class TCPClient : public QObject
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
public:
|
||||||
|
explicit TCPClient(QObject *parent = 0);
|
||||||
|
void Initialize(UpdateController *updateController,RecognizeSystem *recognize,ExternalExecuter *externalExecuter);
|
||||||
|
void SetConnect(ServerSettings *serverSettings);
|
||||||
|
void WaitWrites();
|
||||||
|
QTcpSocket* GetSocket();
|
||||||
|
~TCPClient();
|
||||||
|
|
||||||
|
signals:
|
||||||
|
void onSendDebugLog(QString message);
|
||||||
|
|
||||||
|
public slots:
|
||||||
|
void onMessageEntered(QString message);
|
||||||
|
|
||||||
|
private slots:
|
||||||
|
void onReadyRead();
|
||||||
|
|
||||||
|
private:
|
||||||
|
QTcpSocket *socket;
|
||||||
|
UpdateController *updateController;
|
||||||
|
RecognizeSystem *recognizeSystem;
|
||||||
|
ExternalExecuter * externalExecuter;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // TCPCLIENT_H
|
||||||
38
Core/tools.cpp
Normal file
38
Core/tools.cpp
Normal file
@@ -0,0 +1,38 @@
|
|||||||
|
#include "tools.h"
|
||||||
|
|
||||||
|
#include <qdir.h>
|
||||||
|
|
||||||
|
|
||||||
|
void Tools::PrintTime()
|
||||||
|
{
|
||||||
|
qDebug() << QTime::currentTime().toString("hh:mm:ss");
|
||||||
|
}
|
||||||
|
|
||||||
|
QString Tools::GetTime()
|
||||||
|
{
|
||||||
|
return QTime::currentTime().toString(("hh:mm:ss"));
|
||||||
|
}
|
||||||
|
|
||||||
|
QString Tools::CreateLocalPath(QString path)
|
||||||
|
{
|
||||||
|
qDebug() << "Full path: " << path;
|
||||||
|
qint8 pos = path.indexOf("Application");
|
||||||
|
|
||||||
|
QString localPath = path.remove(0,--pos);
|
||||||
|
|
||||||
|
qDebug() << "Local path: " << localPath;
|
||||||
|
return localPath;
|
||||||
|
}
|
||||||
|
|
||||||
|
QString Tools::CreateFullPath(QString path)
|
||||||
|
{
|
||||||
|
QString fullPath;
|
||||||
|
qint8 pos = path.indexOf("Application");
|
||||||
|
|
||||||
|
QString localPath = path.remove(0,--pos);
|
||||||
|
|
||||||
|
qDebug() << "CLIENT: localPath" << localPath;
|
||||||
|
fullPath = QDir::currentPath() + localPath;
|
||||||
|
|
||||||
|
return fullPath;
|
||||||
|
}
|
||||||
33
Core/tools.h
Normal file
33
Core/tools.h
Normal file
@@ -0,0 +1,33 @@
|
|||||||
|
#ifndef GLOBAL_H
|
||||||
|
#define GLOBAL_H
|
||||||
|
|
||||||
|
#include <QString>
|
||||||
|
#include <QTime>
|
||||||
|
#include <QDebug>
|
||||||
|
|
||||||
|
#define TCP_READ_TIMEOUT 1000
|
||||||
|
|
||||||
|
static QString hashFilename = "hash.xml";
|
||||||
|
static QString settingsName = "settings.xml";
|
||||||
|
|
||||||
|
enum PacketType{
|
||||||
|
TYPE_NONE = 0,
|
||||||
|
TYPE_MSG = 1,
|
||||||
|
TYPE_FILE = 2,
|
||||||
|
TYPE_COMMAND = 3,
|
||||||
|
TYPE_FOLDER = 4,
|
||||||
|
TYPE_DELETE = 5,
|
||||||
|
TYPE_FINISH = 6,
|
||||||
|
TYPE_NEEDUPDATE =7
|
||||||
|
};
|
||||||
|
|
||||||
|
class Tools {
|
||||||
|
public:
|
||||||
|
|
||||||
|
static void PrintTime();
|
||||||
|
static QString GetTime();
|
||||||
|
static QString CreateLocalPath(QString path);
|
||||||
|
static QString CreateFullPath(QString path);
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // GLOBAL_H
|
||||||
BIN
debug/RRJClient.exe
Normal file
BIN
debug/RRJClient.exe
Normal file
Binary file not shown.
BIN
debug/UpdateController.o
Normal file
BIN
debug/UpdateController.o
Normal file
Binary file not shown.
BIN
debug/dataparser.o
Normal file
BIN
debug/dataparser.o
Normal file
Binary file not shown.
BIN
debug/externalexecuter.o
Normal file
BIN
debug/externalexecuter.o
Normal file
Binary file not shown.
BIN
debug/main.o
Normal file
BIN
debug/main.o
Normal file
Binary file not shown.
BIN
debug/mainwindow.o
Normal file
BIN
debug/mainwindow.o
Normal file
Binary file not shown.
95
debug/moc_UpdateController.cpp
Normal file
95
debug/moc_UpdateController.cpp
Normal file
@@ -0,0 +1,95 @@
|
|||||||
|
/****************************************************************************
|
||||||
|
** Meta object code from reading C++ file 'UpdateController.h'
|
||||||
|
**
|
||||||
|
** Created by: The Qt Meta Object Compiler version 67 (Qt 5.14.2)
|
||||||
|
**
|
||||||
|
** WARNING! All changes made in this file will be lost!
|
||||||
|
*****************************************************************************/
|
||||||
|
|
||||||
|
#include <memory>
|
||||||
|
#include "../Core/UpdateController.h"
|
||||||
|
#include <QtCore/qbytearray.h>
|
||||||
|
#include <QtCore/qmetatype.h>
|
||||||
|
#if !defined(Q_MOC_OUTPUT_REVISION)
|
||||||
|
#error "The header file 'UpdateController.h' doesn't include <QObject>."
|
||||||
|
#elif Q_MOC_OUTPUT_REVISION != 67
|
||||||
|
#error "This file was generated using the moc from 5.14.2. It"
|
||||||
|
#error "cannot be used with the include files from this version of Qt."
|
||||||
|
#error "(The moc has changed too much.)"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
QT_BEGIN_MOC_NAMESPACE
|
||||||
|
QT_WARNING_PUSH
|
||||||
|
QT_WARNING_DISABLE_DEPRECATED
|
||||||
|
struct qt_meta_stringdata_UpdateController_t {
|
||||||
|
QByteArrayData data[1];
|
||||||
|
char stringdata0[17];
|
||||||
|
};
|
||||||
|
#define QT_MOC_LITERAL(idx, ofs, len) \
|
||||||
|
Q_STATIC_BYTE_ARRAY_DATA_HEADER_INITIALIZER_WITH_OFFSET(len, \
|
||||||
|
qptrdiff(offsetof(qt_meta_stringdata_UpdateController_t, stringdata0) + ofs \
|
||||||
|
- idx * sizeof(QByteArrayData)) \
|
||||||
|
)
|
||||||
|
static const qt_meta_stringdata_UpdateController_t qt_meta_stringdata_UpdateController = {
|
||||||
|
{
|
||||||
|
QT_MOC_LITERAL(0, 0, 16) // "UpdateController"
|
||||||
|
|
||||||
|
},
|
||||||
|
"UpdateController"
|
||||||
|
};
|
||||||
|
#undef QT_MOC_LITERAL
|
||||||
|
|
||||||
|
static const uint qt_meta_data_UpdateController[] = {
|
||||||
|
|
||||||
|
// content:
|
||||||
|
8, // revision
|
||||||
|
0, // classname
|
||||||
|
0, 0, // classinfo
|
||||||
|
0, 0, // methods
|
||||||
|
0, 0, // properties
|
||||||
|
0, 0, // enums/sets
|
||||||
|
0, 0, // constructors
|
||||||
|
0, // flags
|
||||||
|
0, // signalCount
|
||||||
|
|
||||||
|
0 // eod
|
||||||
|
};
|
||||||
|
|
||||||
|
void UpdateController::qt_static_metacall(QObject *_o, QMetaObject::Call _c, int _id, void **_a)
|
||||||
|
{
|
||||||
|
Q_UNUSED(_o);
|
||||||
|
Q_UNUSED(_id);
|
||||||
|
Q_UNUSED(_c);
|
||||||
|
Q_UNUSED(_a);
|
||||||
|
}
|
||||||
|
|
||||||
|
QT_INIT_METAOBJECT const QMetaObject UpdateController::staticMetaObject = { {
|
||||||
|
QMetaObject::SuperData::link<QObject::staticMetaObject>(),
|
||||||
|
qt_meta_stringdata_UpdateController.data,
|
||||||
|
qt_meta_data_UpdateController,
|
||||||
|
qt_static_metacall,
|
||||||
|
nullptr,
|
||||||
|
nullptr
|
||||||
|
} };
|
||||||
|
|
||||||
|
|
||||||
|
const QMetaObject *UpdateController::metaObject() const
|
||||||
|
{
|
||||||
|
return QObject::d_ptr->metaObject ? QObject::d_ptr->dynamicMetaObject() : &staticMetaObject;
|
||||||
|
}
|
||||||
|
|
||||||
|
void *UpdateController::qt_metacast(const char *_clname)
|
||||||
|
{
|
||||||
|
if (!_clname) return nullptr;
|
||||||
|
if (!strcmp(_clname, qt_meta_stringdata_UpdateController.stringdata0))
|
||||||
|
return static_cast<void*>(this);
|
||||||
|
return QObject::qt_metacast(_clname);
|
||||||
|
}
|
||||||
|
|
||||||
|
int UpdateController::qt_metacall(QMetaObject::Call _c, int _id, void **_a)
|
||||||
|
{
|
||||||
|
_id = QObject::qt_metacall(_c, _id, _a);
|
||||||
|
return _id;
|
||||||
|
}
|
||||||
|
QT_WARNING_POP
|
||||||
|
QT_END_MOC_NAMESPACE
|
||||||
BIN
debug/moc_UpdateController.o
Normal file
BIN
debug/moc_UpdateController.o
Normal file
Binary file not shown.
95
debug/moc_externalexecuter.cpp
Normal file
95
debug/moc_externalexecuter.cpp
Normal file
@@ -0,0 +1,95 @@
|
|||||||
|
/****************************************************************************
|
||||||
|
** Meta object code from reading C++ file 'externalexecuter.h'
|
||||||
|
**
|
||||||
|
** Created by: The Qt Meta Object Compiler version 67 (Qt 5.14.2)
|
||||||
|
**
|
||||||
|
** WARNING! All changes made in this file will be lost!
|
||||||
|
*****************************************************************************/
|
||||||
|
|
||||||
|
#include <memory>
|
||||||
|
#include "../Core/externalexecuter.h"
|
||||||
|
#include <QtCore/qbytearray.h>
|
||||||
|
#include <QtCore/qmetatype.h>
|
||||||
|
#if !defined(Q_MOC_OUTPUT_REVISION)
|
||||||
|
#error "The header file 'externalexecuter.h' doesn't include <QObject>."
|
||||||
|
#elif Q_MOC_OUTPUT_REVISION != 67
|
||||||
|
#error "This file was generated using the moc from 5.14.2. It"
|
||||||
|
#error "cannot be used with the include files from this version of Qt."
|
||||||
|
#error "(The moc has changed too much.)"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
QT_BEGIN_MOC_NAMESPACE
|
||||||
|
QT_WARNING_PUSH
|
||||||
|
QT_WARNING_DISABLE_DEPRECATED
|
||||||
|
struct qt_meta_stringdata_ExternalExecuter_t {
|
||||||
|
QByteArrayData data[1];
|
||||||
|
char stringdata0[17];
|
||||||
|
};
|
||||||
|
#define QT_MOC_LITERAL(idx, ofs, len) \
|
||||||
|
Q_STATIC_BYTE_ARRAY_DATA_HEADER_INITIALIZER_WITH_OFFSET(len, \
|
||||||
|
qptrdiff(offsetof(qt_meta_stringdata_ExternalExecuter_t, stringdata0) + ofs \
|
||||||
|
- idx * sizeof(QByteArrayData)) \
|
||||||
|
)
|
||||||
|
static const qt_meta_stringdata_ExternalExecuter_t qt_meta_stringdata_ExternalExecuter = {
|
||||||
|
{
|
||||||
|
QT_MOC_LITERAL(0, 0, 16) // "ExternalExecuter"
|
||||||
|
|
||||||
|
},
|
||||||
|
"ExternalExecuter"
|
||||||
|
};
|
||||||
|
#undef QT_MOC_LITERAL
|
||||||
|
|
||||||
|
static const uint qt_meta_data_ExternalExecuter[] = {
|
||||||
|
|
||||||
|
// content:
|
||||||
|
8, // revision
|
||||||
|
0, // classname
|
||||||
|
0, 0, // classinfo
|
||||||
|
0, 0, // methods
|
||||||
|
0, 0, // properties
|
||||||
|
0, 0, // enums/sets
|
||||||
|
0, 0, // constructors
|
||||||
|
0, // flags
|
||||||
|
0, // signalCount
|
||||||
|
|
||||||
|
0 // eod
|
||||||
|
};
|
||||||
|
|
||||||
|
void ExternalExecuter::qt_static_metacall(QObject *_o, QMetaObject::Call _c, int _id, void **_a)
|
||||||
|
{
|
||||||
|
Q_UNUSED(_o);
|
||||||
|
Q_UNUSED(_id);
|
||||||
|
Q_UNUSED(_c);
|
||||||
|
Q_UNUSED(_a);
|
||||||
|
}
|
||||||
|
|
||||||
|
QT_INIT_METAOBJECT const QMetaObject ExternalExecuter::staticMetaObject = { {
|
||||||
|
QMetaObject::SuperData::link<QObject::staticMetaObject>(),
|
||||||
|
qt_meta_stringdata_ExternalExecuter.data,
|
||||||
|
qt_meta_data_ExternalExecuter,
|
||||||
|
qt_static_metacall,
|
||||||
|
nullptr,
|
||||||
|
nullptr
|
||||||
|
} };
|
||||||
|
|
||||||
|
|
||||||
|
const QMetaObject *ExternalExecuter::metaObject() const
|
||||||
|
{
|
||||||
|
return QObject::d_ptr->metaObject ? QObject::d_ptr->dynamicMetaObject() : &staticMetaObject;
|
||||||
|
}
|
||||||
|
|
||||||
|
void *ExternalExecuter::qt_metacast(const char *_clname)
|
||||||
|
{
|
||||||
|
if (!_clname) return nullptr;
|
||||||
|
if (!strcmp(_clname, qt_meta_stringdata_ExternalExecuter.stringdata0))
|
||||||
|
return static_cast<void*>(this);
|
||||||
|
return QObject::qt_metacast(_clname);
|
||||||
|
}
|
||||||
|
|
||||||
|
int ExternalExecuter::qt_metacall(QMetaObject::Call _c, int _id, void **_a)
|
||||||
|
{
|
||||||
|
_id = QObject::qt_metacall(_c, _id, _a);
|
||||||
|
return _id;
|
||||||
|
}
|
||||||
|
QT_WARNING_POP
|
||||||
|
QT_END_MOC_NAMESPACE
|
||||||
BIN
debug/moc_externalexecuter.o
Normal file
BIN
debug/moc_externalexecuter.o
Normal file
Binary file not shown.
143
debug/moc_mainwindow.cpp
Normal file
143
debug/moc_mainwindow.cpp
Normal file
@@ -0,0 +1,143 @@
|
|||||||
|
/****************************************************************************
|
||||||
|
** Meta object code from reading C++ file 'mainwindow.h'
|
||||||
|
**
|
||||||
|
** Created by: The Qt Meta Object Compiler version 67 (Qt 5.14.2)
|
||||||
|
**
|
||||||
|
** WARNING! All changes made in this file will be lost!
|
||||||
|
*****************************************************************************/
|
||||||
|
|
||||||
|
#include <memory>
|
||||||
|
#include "../mainwindow.h"
|
||||||
|
#include <QtCore/qbytearray.h>
|
||||||
|
#include <QtCore/qmetatype.h>
|
||||||
|
#if !defined(Q_MOC_OUTPUT_REVISION)
|
||||||
|
#error "The header file 'mainwindow.h' doesn't include <QObject>."
|
||||||
|
#elif Q_MOC_OUTPUT_REVISION != 67
|
||||||
|
#error "This file was generated using the moc from 5.14.2. It"
|
||||||
|
#error "cannot be used with the include files from this version of Qt."
|
||||||
|
#error "(The moc has changed too much.)"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
QT_BEGIN_MOC_NAMESPACE
|
||||||
|
QT_WARNING_PUSH
|
||||||
|
QT_WARNING_DISABLE_DEPRECATED
|
||||||
|
struct qt_meta_stringdata_MainWindow_t {
|
||||||
|
QByteArrayData data[8];
|
||||||
|
char stringdata0[159];
|
||||||
|
};
|
||||||
|
#define QT_MOC_LITERAL(idx, ofs, len) \
|
||||||
|
Q_STATIC_BYTE_ARRAY_DATA_HEADER_INITIALIZER_WITH_OFFSET(len, \
|
||||||
|
qptrdiff(offsetof(qt_meta_stringdata_MainWindow_t, stringdata0) + ofs \
|
||||||
|
- idx * sizeof(QByteArrayData)) \
|
||||||
|
)
|
||||||
|
static const qt_meta_stringdata_MainWindow_t qt_meta_stringdata_MainWindow = {
|
||||||
|
{
|
||||||
|
QT_MOC_LITERAL(0, 0, 10), // "MainWindow"
|
||||||
|
QT_MOC_LITERAL(1, 11, 22), // "on_loginButton_clicked"
|
||||||
|
QT_MOC_LITERAL(2, 34, 0), // ""
|
||||||
|
QT_MOC_LITERAL(3, 35, 23), // "on_updateButton_clicked"
|
||||||
|
QT_MOC_LITERAL(4, 59, 22), // "on_startButton_clicked"
|
||||||
|
QT_MOC_LITERAL(5, 82, 27), // "on_saveServerButton_clicked"
|
||||||
|
QT_MOC_LITERAL(6, 110, 25), // "on_settingsButton_clicked"
|
||||||
|
QT_MOC_LITERAL(7, 136, 22) // "on_checkUpdate_clicked"
|
||||||
|
|
||||||
|
},
|
||||||
|
"MainWindow\0on_loginButton_clicked\0\0"
|
||||||
|
"on_updateButton_clicked\0on_startButton_clicked\0"
|
||||||
|
"on_saveServerButton_clicked\0"
|
||||||
|
"on_settingsButton_clicked\0"
|
||||||
|
"on_checkUpdate_clicked"
|
||||||
|
};
|
||||||
|
#undef QT_MOC_LITERAL
|
||||||
|
|
||||||
|
static const uint qt_meta_data_MainWindow[] = {
|
||||||
|
|
||||||
|
// content:
|
||||||
|
8, // revision
|
||||||
|
0, // classname
|
||||||
|
0, 0, // classinfo
|
||||||
|
6, 14, // methods
|
||||||
|
0, 0, // properties
|
||||||
|
0, 0, // enums/sets
|
||||||
|
0, 0, // constructors
|
||||||
|
0, // flags
|
||||||
|
0, // signalCount
|
||||||
|
|
||||||
|
// slots: name, argc, parameters, tag, flags
|
||||||
|
1, 0, 44, 2, 0x08 /* Private */,
|
||||||
|
3, 0, 45, 2, 0x08 /* Private */,
|
||||||
|
4, 0, 46, 2, 0x08 /* Private */,
|
||||||
|
5, 0, 47, 2, 0x08 /* Private */,
|
||||||
|
6, 0, 48, 2, 0x08 /* Private */,
|
||||||
|
7, 0, 49, 2, 0x08 /* Private */,
|
||||||
|
|
||||||
|
// slots: parameters
|
||||||
|
QMetaType::Void,
|
||||||
|
QMetaType::Void,
|
||||||
|
QMetaType::Void,
|
||||||
|
QMetaType::Void,
|
||||||
|
QMetaType::Void,
|
||||||
|
QMetaType::Void,
|
||||||
|
|
||||||
|
0 // eod
|
||||||
|
};
|
||||||
|
|
||||||
|
void MainWindow::qt_static_metacall(QObject *_o, QMetaObject::Call _c, int _id, void **_a)
|
||||||
|
{
|
||||||
|
if (_c == QMetaObject::InvokeMetaMethod) {
|
||||||
|
auto *_t = static_cast<MainWindow *>(_o);
|
||||||
|
Q_UNUSED(_t)
|
||||||
|
switch (_id) {
|
||||||
|
case 0: _t->on_loginButton_clicked(); break;
|
||||||
|
case 1: _t->on_updateButton_clicked(); break;
|
||||||
|
case 2: _t->on_startButton_clicked(); break;
|
||||||
|
case 3: _t->on_saveServerButton_clicked(); break;
|
||||||
|
case 4: _t->on_settingsButton_clicked(); break;
|
||||||
|
case 5: _t->on_checkUpdate_clicked(); break;
|
||||||
|
default: ;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Q_UNUSED(_a);
|
||||||
|
}
|
||||||
|
|
||||||
|
QT_INIT_METAOBJECT const QMetaObject MainWindow::staticMetaObject = { {
|
||||||
|
QMetaObject::SuperData::link<QMainWindow::staticMetaObject>(),
|
||||||
|
qt_meta_stringdata_MainWindow.data,
|
||||||
|
qt_meta_data_MainWindow,
|
||||||
|
qt_static_metacall,
|
||||||
|
nullptr,
|
||||||
|
nullptr
|
||||||
|
} };
|
||||||
|
|
||||||
|
|
||||||
|
const QMetaObject *MainWindow::metaObject() const
|
||||||
|
{
|
||||||
|
return QObject::d_ptr->metaObject ? QObject::d_ptr->dynamicMetaObject() : &staticMetaObject;
|
||||||
|
}
|
||||||
|
|
||||||
|
void *MainWindow::qt_metacast(const char *_clname)
|
||||||
|
{
|
||||||
|
if (!_clname) return nullptr;
|
||||||
|
if (!strcmp(_clname, qt_meta_stringdata_MainWindow.stringdata0))
|
||||||
|
return static_cast<void*>(this);
|
||||||
|
return QMainWindow::qt_metacast(_clname);
|
||||||
|
}
|
||||||
|
|
||||||
|
int MainWindow::qt_metacall(QMetaObject::Call _c, int _id, void **_a)
|
||||||
|
{
|
||||||
|
_id = QMainWindow::qt_metacall(_c, _id, _a);
|
||||||
|
if (_id < 0)
|
||||||
|
return _id;
|
||||||
|
if (_c == QMetaObject::InvokeMetaMethod) {
|
||||||
|
if (_id < 6)
|
||||||
|
qt_static_metacall(this, _c, _id, _a);
|
||||||
|
_id -= 6;
|
||||||
|
} else if (_c == QMetaObject::RegisterMethodArgumentMetaType) {
|
||||||
|
if (_id < 6)
|
||||||
|
*reinterpret_cast<int*>(_a[0]) = -1;
|
||||||
|
_id -= 6;
|
||||||
|
}
|
||||||
|
return _id;
|
||||||
|
}
|
||||||
|
QT_WARNING_POP
|
||||||
|
QT_END_MOC_NAMESPACE
|
||||||
BIN
debug/moc_mainwindow.o
Normal file
BIN
debug/moc_mainwindow.o
Normal file
Binary file not shown.
394
debug/moc_predefs.h
Normal file
394
debug/moc_predefs.h
Normal file
@@ -0,0 +1,394 @@
|
|||||||
|
#define __DBL_MIN_EXP__ (-1021)
|
||||||
|
#define __FLT32X_MAX_EXP__ 1024
|
||||||
|
#define __cpp_attributes 200809
|
||||||
|
#define __UINT_LEAST16_MAX__ 0xffff
|
||||||
|
#define __ATOMIC_ACQUIRE 2
|
||||||
|
#define __FLT128_MAX_10_EXP__ 4932
|
||||||
|
#define __FLT_MIN__ 1.17549435082228750796873653722224568e-38F
|
||||||
|
#define __GCC_IEC_559_COMPLEX 2
|
||||||
|
#define __UINT_LEAST8_TYPE__ unsigned char
|
||||||
|
#define __SIZEOF_FLOAT80__ 16
|
||||||
|
#define _WIN32 1
|
||||||
|
#define __INTMAX_C(c) c ## LL
|
||||||
|
#define __CHAR_BIT__ 8
|
||||||
|
#define __UINT8_MAX__ 0xff
|
||||||
|
#define _WIN64 1
|
||||||
|
#define __WINT_MAX__ 0xffff
|
||||||
|
#define __FLT32_MIN_EXP__ (-125)
|
||||||
|
#define __cpp_static_assert 200410
|
||||||
|
#define __ORDER_LITTLE_ENDIAN__ 1234
|
||||||
|
#define __SIZE_MAX__ 0xffffffffffffffffULL
|
||||||
|
#define __WCHAR_MAX__ 0xffff
|
||||||
|
#define __GCC_HAVE_SYNC_COMPARE_AND_SWAP_1 1
|
||||||
|
#define __GCC_HAVE_SYNC_COMPARE_AND_SWAP_2 1
|
||||||
|
#define __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4 1
|
||||||
|
#define __DBL_DENORM_MIN__ double(4.94065645841246544176568792868221372e-324L)
|
||||||
|
#define __GCC_HAVE_SYNC_COMPARE_AND_SWAP_8 1
|
||||||
|
#define __GCC_ATOMIC_CHAR_LOCK_FREE 2
|
||||||
|
#define __GCC_IEC_559 2
|
||||||
|
#define __FLT32X_DECIMAL_DIG__ 17
|
||||||
|
#define __FLT_EVAL_METHOD__ 0
|
||||||
|
#define __cpp_binary_literals 201304
|
||||||
|
#define __FLT64_DECIMAL_DIG__ 17
|
||||||
|
#define __GCC_ATOMIC_CHAR32_T_LOCK_FREE 2
|
||||||
|
#define __x86_64 1
|
||||||
|
#define __cpp_variadic_templates 200704
|
||||||
|
#define __UINT_FAST64_MAX__ 0xffffffffffffffffULL
|
||||||
|
#define __SIG_ATOMIC_TYPE__ int
|
||||||
|
#define __DBL_MIN_10_EXP__ (-307)
|
||||||
|
#define __FINITE_MATH_ONLY__ 0
|
||||||
|
#define __GNUC_PATCHLEVEL__ 0
|
||||||
|
#define __FLT32_HAS_DENORM__ 1
|
||||||
|
#define __UINT_FAST8_MAX__ 0xff
|
||||||
|
#define __has_include(STR) __has_include__(STR)
|
||||||
|
#define _stdcall __attribute__((__stdcall__))
|
||||||
|
#define __DEC64_MAX_EXP__ 385
|
||||||
|
#define __INT8_C(c) c
|
||||||
|
#define __INT_LEAST8_WIDTH__ 8
|
||||||
|
#define __UINT_LEAST64_MAX__ 0xffffffffffffffffULL
|
||||||
|
#define __SHRT_MAX__ 0x7fff
|
||||||
|
#define __LDBL_MAX__ 1.18973149535723176502126385303097021e+4932L
|
||||||
|
#define __FLT64X_MAX_10_EXP__ 4932
|
||||||
|
#define __UINT_LEAST8_MAX__ 0xff
|
||||||
|
#define __GCC_ATOMIC_BOOL_LOCK_FREE 2
|
||||||
|
#define __FLT128_DENORM_MIN__ 6.47517511943802511092443895822764655e-4966F128
|
||||||
|
#define __UINTMAX_TYPE__ long long unsigned int
|
||||||
|
#define __DEC32_EPSILON__ 1E-6DF
|
||||||
|
#define __FLT_EVAL_METHOD_TS_18661_3__ 0
|
||||||
|
#define __UINT32_MAX__ 0xffffffffU
|
||||||
|
#define __GXX_EXPERIMENTAL_CXX0X__ 1
|
||||||
|
#define __LDBL_MAX_EXP__ 16384
|
||||||
|
#define __FLT128_MIN_EXP__ (-16381)
|
||||||
|
#define __WINT_MIN__ 0
|
||||||
|
#define __FLT128_MIN_10_EXP__ (-4931)
|
||||||
|
#define __INT_LEAST16_WIDTH__ 16
|
||||||
|
#define __SCHAR_MAX__ 0x7f
|
||||||
|
#define __FLT128_MANT_DIG__ 113
|
||||||
|
#define __WCHAR_MIN__ 0
|
||||||
|
#define __INT64_C(c) c ## LL
|
||||||
|
#define __DBL_DIG__ 15
|
||||||
|
#define __GCC_ATOMIC_POINTER_LOCK_FREE 2
|
||||||
|
#define __FLT64X_MANT_DIG__ 64
|
||||||
|
#define __SIZEOF_INT__ 4
|
||||||
|
#define __SIZEOF_POINTER__ 8
|
||||||
|
#define __GCC_ATOMIC_CHAR16_T_LOCK_FREE 2
|
||||||
|
#define __USER_LABEL_PREFIX__
|
||||||
|
#define __FLT64X_EPSILON__ 1.08420217248550443400745280086994171e-19F64x
|
||||||
|
#define __STDC_HOSTED__ 1
|
||||||
|
#define __WIN32 1
|
||||||
|
#define __LDBL_HAS_INFINITY__ 1
|
||||||
|
#define __WIN64 1
|
||||||
|
#define __FLT32_DIG__ 6
|
||||||
|
#define __FLT_EPSILON__ 1.19209289550781250000000000000000000e-7F
|
||||||
|
#define __GXX_WEAK__ 1
|
||||||
|
#define __SHRT_WIDTH__ 16
|
||||||
|
#define __LDBL_MIN__ 3.36210314311209350626267781732175260e-4932L
|
||||||
|
#define __DEC32_MAX__ 9.999999E96DF
|
||||||
|
#define __cpp_threadsafe_static_init 200806
|
||||||
|
#define __FLT64X_DENORM_MIN__ 3.64519953188247460252840593361941982e-4951F64x
|
||||||
|
#define __MINGW32__ 1
|
||||||
|
#define __FLT32X_HAS_INFINITY__ 1
|
||||||
|
#define __INT32_MAX__ 0x7fffffff
|
||||||
|
#define __INT_WIDTH__ 32
|
||||||
|
#define __SIZEOF_LONG__ 4
|
||||||
|
#define __UINT16_C(c) c
|
||||||
|
#define __PTRDIFF_WIDTH__ 64
|
||||||
|
#define __DECIMAL_DIG__ 21
|
||||||
|
#define __FLT64_EPSILON__ 2.22044604925031308084726333618164062e-16F64
|
||||||
|
#define __INTMAX_WIDTH__ 64
|
||||||
|
#define __FLT64_MIN_EXP__ (-1021)
|
||||||
|
#define __has_include_next(STR) __has_include_next__(STR)
|
||||||
|
#define __FLT64X_MIN_10_EXP__ (-4931)
|
||||||
|
#define __LDBL_HAS_QUIET_NAN__ 1
|
||||||
|
#define __FLT64_MANT_DIG__ 53
|
||||||
|
#define _REENTRANT 1
|
||||||
|
#define __GNUC__ 7
|
||||||
|
#define _cdecl __attribute__((__cdecl__))
|
||||||
|
#define __GXX_RTTI 1
|
||||||
|
#define __MMX__ 1
|
||||||
|
#define __cpp_delegating_constructors 200604
|
||||||
|
#define __FLT_HAS_DENORM__ 1
|
||||||
|
#define __SIZEOF_LONG_DOUBLE__ 16
|
||||||
|
#define __BIGGEST_ALIGNMENT__ 16
|
||||||
|
#define __STDC_UTF_16__ 1
|
||||||
|
#define __FLT64_MAX_10_EXP__ 308
|
||||||
|
#define __FLT32_HAS_INFINITY__ 1
|
||||||
|
#define __DBL_MAX__ double(1.79769313486231570814527423731704357e+308L)
|
||||||
|
#define _thiscall __attribute__((__thiscall__))
|
||||||
|
#define __cpp_raw_strings 200710
|
||||||
|
#define __INT_FAST32_MAX__ 0x7fffffff
|
||||||
|
#define __WINNT 1
|
||||||
|
#define __DBL_HAS_INFINITY__ 1
|
||||||
|
#define __INT64_MAX__ 0x7fffffffffffffffLL
|
||||||
|
#define __WINNT__ 1
|
||||||
|
#define __DEC32_MIN_EXP__ (-94)
|
||||||
|
#define __INTPTR_WIDTH__ 64
|
||||||
|
#define __FLT32X_HAS_DENORM__ 1
|
||||||
|
#define __INT_FAST16_TYPE__ short int
|
||||||
|
#define _fastcall __attribute__((__fastcall__))
|
||||||
|
#define __LDBL_HAS_DENORM__ 1
|
||||||
|
#define __cplusplus 201103L
|
||||||
|
#define __cpp_ref_qualifiers 200710
|
||||||
|
#define __DEC128_MAX__ 9.999999999999999999999999999999999E6144DL
|
||||||
|
#define __INT_LEAST32_MAX__ 0x7fffffff
|
||||||
|
#define __DEC32_MIN__ 1E-95DF
|
||||||
|
#define __DEPRECATED 1
|
||||||
|
#define __cpp_rvalue_references 200610
|
||||||
|
#define __DBL_MAX_EXP__ 1024
|
||||||
|
#define __WCHAR_WIDTH__ 16
|
||||||
|
#define __FLT32_MAX__ 3.40282346638528859811704183484516925e+38F32
|
||||||
|
#define __DEC128_EPSILON__ 1E-33DL
|
||||||
|
#define __SSE2_MATH__ 1
|
||||||
|
#define __ATOMIC_HLE_RELEASE 131072
|
||||||
|
#define __WIN32__ 1
|
||||||
|
#define __PTRDIFF_MAX__ 0x7fffffffffffffffLL
|
||||||
|
#define __amd64 1
|
||||||
|
#define __tune_core2__ 1
|
||||||
|
#define __ATOMIC_HLE_ACQUIRE 65536
|
||||||
|
#define __FLT32_HAS_QUIET_NAN__ 1
|
||||||
|
#define __GNUG__ 7
|
||||||
|
#define __LONG_LONG_MAX__ 0x7fffffffffffffffLL
|
||||||
|
#define __SIZEOF_SIZE_T__ 8
|
||||||
|
#define __cpp_rvalue_reference 200610
|
||||||
|
#define __cpp_nsdmi 200809
|
||||||
|
#define __FLT64X_MIN_EXP__ (-16381)
|
||||||
|
#define __SIZEOF_WINT_T__ 2
|
||||||
|
#define __LONG_LONG_WIDTH__ 64
|
||||||
|
#define __cpp_initializer_lists 200806
|
||||||
|
#define __FLT32_MAX_EXP__ 128
|
||||||
|
#define __cpp_hex_float 201603
|
||||||
|
#define __GCC_HAVE_DWARF2_CFI_ASM 1
|
||||||
|
#define __GXX_ABI_VERSION 1011
|
||||||
|
#define __FLT128_HAS_INFINITY__ 1
|
||||||
|
#define __FLT_MIN_EXP__ (-125)
|
||||||
|
#define __cpp_lambdas 200907
|
||||||
|
#define __FLT64X_HAS_QUIET_NAN__ 1
|
||||||
|
#define __INT_FAST64_TYPE__ long long int
|
||||||
|
#define __FLT64_DENORM_MIN__ 4.94065645841246544176568792868221372e-324F64
|
||||||
|
#define __DBL_MIN__ double(2.22507385850720138309023271733240406e-308L)
|
||||||
|
#define __FLT32X_EPSILON__ 2.22044604925031308084726333618164062e-16F32x
|
||||||
|
#define __DECIMAL_BID_FORMAT__ 1
|
||||||
|
#define __GXX_TYPEINFO_EQUALITY_INLINE 0
|
||||||
|
#define __FLT64_MIN_10_EXP__ (-307)
|
||||||
|
#define __FLT64X_DECIMAL_DIG__ 21
|
||||||
|
#define __DEC128_MIN__ 1E-6143DL
|
||||||
|
#define __REGISTER_PREFIX__
|
||||||
|
#define __UINT16_MAX__ 0xffff
|
||||||
|
#define __DBL_HAS_DENORM__ 1
|
||||||
|
#define __cdecl __attribute__((__cdecl__))
|
||||||
|
#define __FLT32_MIN__ 1.17549435082228750796873653722224568e-38F32
|
||||||
|
#define __UINT8_TYPE__ unsigned char
|
||||||
|
#define __NO_INLINE__ 1
|
||||||
|
#define __FLT_MANT_DIG__ 24
|
||||||
|
#define __LDBL_DECIMAL_DIG__ 21
|
||||||
|
#define __VERSION__ "7.3.0"
|
||||||
|
#define __UINT64_C(c) c ## ULL
|
||||||
|
#define __cpp_unicode_characters 200704
|
||||||
|
#define __GCC_ATOMIC_INT_LOCK_FREE 2
|
||||||
|
#define __FLT128_MAX_EXP__ 16384
|
||||||
|
#define __FLT32_MANT_DIG__ 24
|
||||||
|
#define __FLOAT_WORD_ORDER__ __ORDER_LITTLE_ENDIAN__
|
||||||
|
#define __FLT128_HAS_DENORM__ 1
|
||||||
|
#define __FLT128_DIG__ 33
|
||||||
|
#define __SCHAR_WIDTH__ 8
|
||||||
|
#define __INT32_C(c) c
|
||||||
|
#define __DEC64_EPSILON__ 1E-15DD
|
||||||
|
#define __ORDER_PDP_ENDIAN__ 3412
|
||||||
|
#define __DEC128_MIN_EXP__ (-6142)
|
||||||
|
#define __FLT32_MAX_10_EXP__ 38
|
||||||
|
#define __INT_FAST32_TYPE__ int
|
||||||
|
#define __UINT_LEAST16_TYPE__ short unsigned int
|
||||||
|
#define __FLT64X_HAS_INFINITY__ 1
|
||||||
|
#define __INT16_MAX__ 0x7fff
|
||||||
|
#define __cpp_rtti 199711
|
||||||
|
#define __SIZE_TYPE__ long long unsigned int
|
||||||
|
#define __UINT64_MAX__ 0xffffffffffffffffULL
|
||||||
|
#define __FLT64X_DIG__ 18
|
||||||
|
#define __INT8_TYPE__ signed char
|
||||||
|
#define __GCC_ASM_FLAG_OUTPUTS__ 1
|
||||||
|
#define __FLT_RADIX__ 2
|
||||||
|
#define __INT_LEAST16_TYPE__ short int
|
||||||
|
#define __LDBL_EPSILON__ 1.08420217248550443400745280086994171e-19L
|
||||||
|
#define __UINTMAX_C(c) c ## ULL
|
||||||
|
#define __GLIBCXX_BITSIZE_INT_N_0 128
|
||||||
|
#define __SEH__ 1
|
||||||
|
#define __SIG_ATOMIC_MAX__ 0x7fffffff
|
||||||
|
#define __GCC_ATOMIC_WCHAR_T_LOCK_FREE 2
|
||||||
|
#define __SIZEOF_PTRDIFF_T__ 8
|
||||||
|
#define __FLT32X_MANT_DIG__ 53
|
||||||
|
#define __x86_64__ 1
|
||||||
|
#define __FLT32X_MIN_EXP__ (-1021)
|
||||||
|
#define __DEC32_SUBNORMAL_MIN__ 0.000001E-95DF
|
||||||
|
#define __MSVCRT__ 1
|
||||||
|
#define __INT_FAST16_MAX__ 0x7fff
|
||||||
|
#define __FLT64_DIG__ 15
|
||||||
|
#define __UINT_FAST32_MAX__ 0xffffffffU
|
||||||
|
#define __UINT_LEAST64_TYPE__ long long unsigned int
|
||||||
|
#define __FLT_HAS_QUIET_NAN__ 1
|
||||||
|
#define __FLT_MAX_10_EXP__ 38
|
||||||
|
#define __LONG_MAX__ 0x7fffffffL
|
||||||
|
#define __FLT64X_HAS_DENORM__ 1
|
||||||
|
#define __DEC128_SUBNORMAL_MIN__ 0.000000000000000000000000000000001E-6143DL
|
||||||
|
#define __FLT_HAS_INFINITY__ 1
|
||||||
|
#define __cpp_unicode_literals 200710
|
||||||
|
#define __UINT_FAST16_TYPE__ short unsigned int
|
||||||
|
#define __DEC64_MAX__ 9.999999999999999E384DD
|
||||||
|
#define __INT_FAST32_WIDTH__ 32
|
||||||
|
#define __CHAR16_TYPE__ short unsigned int
|
||||||
|
#define __PRAGMA_REDEFINE_EXTNAME 1
|
||||||
|
#define __SIZE_WIDTH__ 64
|
||||||
|
#define __SEG_FS 1
|
||||||
|
#define __INT_LEAST16_MAX__ 0x7fff
|
||||||
|
#define __DEC64_MANT_DIG__ 16
|
||||||
|
#define __UINT_LEAST32_MAX__ 0xffffffffU
|
||||||
|
#define __SEG_GS 1
|
||||||
|
#define __FLT32_DENORM_MIN__ 1.40129846432481707092372958328991613e-45F32
|
||||||
|
#define __GCC_ATOMIC_LONG_LOCK_FREE 2
|
||||||
|
#define __SIG_ATOMIC_WIDTH__ 32
|
||||||
|
#define __INT_LEAST64_TYPE__ long long int
|
||||||
|
#define __INT16_TYPE__ short int
|
||||||
|
#define __INT_LEAST8_TYPE__ signed char
|
||||||
|
#define __DEC32_MAX_EXP__ 97
|
||||||
|
#define __INT_FAST8_MAX__ 0x7f
|
||||||
|
#define __FLT128_MAX__ 1.18973149535723176508575932662800702e+4932F128
|
||||||
|
#define __INTPTR_MAX__ 0x7fffffffffffffffLL
|
||||||
|
#define __GXX_MERGED_TYPEINFO_NAMES 0
|
||||||
|
#define __cpp_range_based_for 200907
|
||||||
|
#define __FLT64_HAS_QUIET_NAN__ 1
|
||||||
|
#define __stdcall __attribute__((__stdcall__))
|
||||||
|
#define __FLT32_MIN_10_EXP__ (-37)
|
||||||
|
#define __SSE2__ 1
|
||||||
|
#define __EXCEPTIONS 1
|
||||||
|
#define __LDBL_MANT_DIG__ 64
|
||||||
|
#define __DBL_HAS_QUIET_NAN__ 1
|
||||||
|
#define __FLT64_HAS_INFINITY__ 1
|
||||||
|
#define __FLT64X_MAX__ 1.18973149535723176502126385303097021e+4932F64x
|
||||||
|
#define __SIG_ATOMIC_MIN__ (-__SIG_ATOMIC_MAX__ - 1)
|
||||||
|
#define __INTPTR_TYPE__ long long int
|
||||||
|
#define __UINT16_TYPE__ short unsigned int
|
||||||
|
#define __WCHAR_TYPE__ short unsigned int
|
||||||
|
#define __SIZEOF_FLOAT__ 4
|
||||||
|
#define __pic__ 1
|
||||||
|
#define __UINTPTR_MAX__ 0xffffffffffffffffULL
|
||||||
|
#define __INT_FAST64_WIDTH__ 64
|
||||||
|
#define __DEC64_MIN_EXP__ (-382)
|
||||||
|
#define __cpp_decltype 200707
|
||||||
|
#define __FLT32_DECIMAL_DIG__ 9
|
||||||
|
#define __INT_FAST64_MAX__ 0x7fffffffffffffffLL
|
||||||
|
#define __GCC_ATOMIC_TEST_AND_SET_TRUEVAL 1
|
||||||
|
#define __FLT_DIG__ 6
|
||||||
|
#define __FLT64X_MAX_EXP__ 16384
|
||||||
|
#define __UINT_FAST64_TYPE__ long long unsigned int
|
||||||
|
#define __INT_MAX__ 0x7fffffff
|
||||||
|
#define __amd64__ 1
|
||||||
|
#define WIN32 1
|
||||||
|
#define __nocona 1
|
||||||
|
#define __code_model_medium__ 1
|
||||||
|
#define __INT64_TYPE__ long long int
|
||||||
|
#define __FLT_MAX_EXP__ 128
|
||||||
|
#define WIN64 1
|
||||||
|
#define __ORDER_BIG_ENDIAN__ 4321
|
||||||
|
#define __DBL_MANT_DIG__ 53
|
||||||
|
#define __cpp_inheriting_constructors 201511
|
||||||
|
#define __SIZEOF_FLOAT128__ 16
|
||||||
|
#define __INT_LEAST64_MAX__ 0x7fffffffffffffffLL
|
||||||
|
#define __DEC64_MIN__ 1E-383DD
|
||||||
|
#define __WINT_TYPE__ short unsigned int
|
||||||
|
#define __UINT_LEAST32_TYPE__ unsigned int
|
||||||
|
#define __SIZEOF_SHORT__ 2
|
||||||
|
#define __SSE__ 1
|
||||||
|
#define __LDBL_MIN_EXP__ (-16381)
|
||||||
|
#define __FLT64_MAX__ 1.79769313486231570814527423731704357e+308F64
|
||||||
|
#define __WINT_WIDTH__ 16
|
||||||
|
#define __INT_LEAST8_MAX__ 0x7f
|
||||||
|
#define __FLT32X_MAX_10_EXP__ 308
|
||||||
|
#define __SIZEOF_INT128__ 16
|
||||||
|
#define __WCHAR_UNSIGNED__ 1
|
||||||
|
#define __LDBL_MAX_10_EXP__ 4932
|
||||||
|
#define __ATOMIC_RELAXED 0
|
||||||
|
#define __DBL_EPSILON__ double(2.22044604925031308084726333618164062e-16L)
|
||||||
|
#define __thiscall __attribute__((__thiscall__))
|
||||||
|
#define __FLT128_MIN__ 3.36210314311209350626267781732175260e-4932F128
|
||||||
|
#define __UINT8_C(c) c
|
||||||
|
#define __FLT64_MAX_EXP__ 1024
|
||||||
|
#define __INT_LEAST32_TYPE__ int
|
||||||
|
#define __SIZEOF_WCHAR_T__ 2
|
||||||
|
#define __FLT128_HAS_QUIET_NAN__ 1
|
||||||
|
#define __INT_FAST8_TYPE__ signed char
|
||||||
|
#define __fastcall __attribute__((__fastcall__))
|
||||||
|
#define __FLT64X_MIN__ 3.36210314311209350626267781732175260e-4932F64x
|
||||||
|
#define __GNUC_STDC_INLINE__ 1
|
||||||
|
#define __FLT64_HAS_DENORM__ 1
|
||||||
|
#define __FLT32_EPSILON__ 1.19209289550781250000000000000000000e-7F32
|
||||||
|
#define __DBL_DECIMAL_DIG__ 17
|
||||||
|
#define __STDC_UTF_32__ 1
|
||||||
|
#define __INT_FAST8_WIDTH__ 8
|
||||||
|
#define __FXSR__ 1
|
||||||
|
#define __DEC_EVAL_METHOD__ 2
|
||||||
|
#define __FLT32X_MAX__ 1.79769313486231570814527423731704357e+308F32x
|
||||||
|
#define __MINGW64__ 1
|
||||||
|
#define __cpp_runtime_arrays 198712
|
||||||
|
#define __UINT64_TYPE__ long long unsigned int
|
||||||
|
#define __UINT32_C(c) c ## U
|
||||||
|
#define __INTMAX_MAX__ 0x7fffffffffffffffLL
|
||||||
|
#define __cpp_alias_templates 200704
|
||||||
|
#define __BYTE_ORDER__ __ORDER_LITTLE_ENDIAN__
|
||||||
|
#define WINNT 1
|
||||||
|
#define __FLT_DENORM_MIN__ 1.40129846432481707092372958328991613e-45F
|
||||||
|
#define __INT8_MAX__ 0x7f
|
||||||
|
#define __LONG_WIDTH__ 32
|
||||||
|
#define __PIC__ 1
|
||||||
|
#define __UINT_FAST32_TYPE__ unsigned int
|
||||||
|
#define __CHAR32_TYPE__ unsigned int
|
||||||
|
#define __FLT_MAX__ 3.40282346638528859811704183484516925e+38F
|
||||||
|
#define __cpp_constexpr 200704
|
||||||
|
#define __INT32_TYPE__ int
|
||||||
|
#define __SIZEOF_DOUBLE__ 8
|
||||||
|
#define __cpp_exceptions 199711
|
||||||
|
#define __FLT_MIN_10_EXP__ (-37)
|
||||||
|
#define __FLT64_MIN__ 2.22507385850720138309023271733240406e-308F64
|
||||||
|
#define __INT_LEAST32_WIDTH__ 32
|
||||||
|
#define __INTMAX_TYPE__ long long int
|
||||||
|
#define _INTEGRAL_MAX_BITS 64
|
||||||
|
#define __DEC128_MAX_EXP__ 6145
|
||||||
|
#define __FLT32X_HAS_QUIET_NAN__ 1
|
||||||
|
#define __ATOMIC_CONSUME 1
|
||||||
|
#define __nocona__ 1
|
||||||
|
#define __GNUC_MINOR__ 3
|
||||||
|
#define __GLIBCXX_TYPE_INT_N_0 __int128
|
||||||
|
#define __INT_FAST16_WIDTH__ 16
|
||||||
|
#define __UINTMAX_MAX__ 0xffffffffffffffffULL
|
||||||
|
#define __DEC32_MANT_DIG__ 7
|
||||||
|
#define __FLT32X_DENORM_MIN__ 4.94065645841246544176568792868221372e-324F32x
|
||||||
|
#define __DBL_MAX_10_EXP__ 308
|
||||||
|
#define __LDBL_DENORM_MIN__ 3.64519953188247460252840593361941982e-4951L
|
||||||
|
#define __INT16_C(c) c
|
||||||
|
#define __STDC__ 1
|
||||||
|
#define __FLT32X_DIG__ 15
|
||||||
|
#define __PTRDIFF_TYPE__ long long int
|
||||||
|
#define __ATOMIC_SEQ_CST 5
|
||||||
|
#define __GCC_HAVE_SYNC_COMPARE_AND_SWAP_16 1
|
||||||
|
#define __UINT32_TYPE__ unsigned int
|
||||||
|
#define __FLT32X_MIN_10_EXP__ (-307)
|
||||||
|
#define __UINTPTR_TYPE__ long long unsigned int
|
||||||
|
#define __DEC64_SUBNORMAL_MIN__ 0.000000000000001E-383DD
|
||||||
|
#define __DEC128_MANT_DIG__ 34
|
||||||
|
#define __LDBL_MIN_10_EXP__ (-4931)
|
||||||
|
#define __FLT128_EPSILON__ 1.92592994438723585305597794258492732e-34F128
|
||||||
|
#define __SSE_MATH__ 1
|
||||||
|
#define __SIZEOF_LONG_LONG__ 8
|
||||||
|
#define __cpp_user_defined_literals 200809
|
||||||
|
#define __FLT128_DECIMAL_DIG__ 36
|
||||||
|
#define __GCC_ATOMIC_LLONG_LOCK_FREE 2
|
||||||
|
#define __FLT32X_MIN__ 2.22507385850720138309023271733240406e-308F32x
|
||||||
|
#define __LDBL_DIG__ 18
|
||||||
|
#define __FLT_DECIMAL_DIG__ 9
|
||||||
|
#define __UINT_FAST16_MAX__ 0xffff
|
||||||
|
#define __GCC_ATOMIC_SHORT_LOCK_FREE 2
|
||||||
|
#define __INT_LEAST64_WIDTH__ 64
|
||||||
|
#define __SSE3__ 1
|
||||||
|
#define __UINT_FAST8_TYPE__ unsigned char
|
||||||
|
#define __WIN64__ 1
|
||||||
|
#define __ATOMIC_ACQ_REL 4
|
||||||
|
#define __ATOMIC_RELEASE 3
|
||||||
|
#define __declspec(x) __attribute__((x))
|
||||||
193
debug/moc_recognizesystem.cpp
Normal file
193
debug/moc_recognizesystem.cpp
Normal file
@@ -0,0 +1,193 @@
|
|||||||
|
/****************************************************************************
|
||||||
|
** Meta object code from reading C++ file 'recognizesystem.h'
|
||||||
|
**
|
||||||
|
** Created by: The Qt Meta Object Compiler version 67 (Qt 5.14.2)
|
||||||
|
**
|
||||||
|
** WARNING! All changes made in this file will be lost!
|
||||||
|
*****************************************************************************/
|
||||||
|
|
||||||
|
#include <memory>
|
||||||
|
#include "../Core/recognizesystem.h"
|
||||||
|
#include <QtCore/qbytearray.h>
|
||||||
|
#include <QtCore/qmetatype.h>
|
||||||
|
#if !defined(Q_MOC_OUTPUT_REVISION)
|
||||||
|
#error "The header file 'recognizesystem.h' doesn't include <QObject>."
|
||||||
|
#elif Q_MOC_OUTPUT_REVISION != 67
|
||||||
|
#error "This file was generated using the moc from 5.14.2. It"
|
||||||
|
#error "cannot be used with the include files from this version of Qt."
|
||||||
|
#error "(The moc has changed too much.)"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
QT_BEGIN_MOC_NAMESPACE
|
||||||
|
QT_WARNING_PUSH
|
||||||
|
QT_WARNING_DISABLE_DEPRECATED
|
||||||
|
struct qt_meta_stringdata_RecognizeSystem_t {
|
||||||
|
QByteArrayData data[10];
|
||||||
|
char stringdata0[104];
|
||||||
|
};
|
||||||
|
#define QT_MOC_LITERAL(idx, ofs, len) \
|
||||||
|
Q_STATIC_BYTE_ARRAY_DATA_HEADER_INITIALIZER_WITH_OFFSET(len, \
|
||||||
|
qptrdiff(offsetof(qt_meta_stringdata_RecognizeSystem_t, stringdata0) + ofs \
|
||||||
|
- idx * sizeof(QByteArrayData)) \
|
||||||
|
)
|
||||||
|
static const qt_meta_stringdata_RecognizeSystem_t qt_meta_stringdata_RecognizeSystem = {
|
||||||
|
{
|
||||||
|
QT_MOC_LITERAL(0, 0, 15), // "RecognizeSystem"
|
||||||
|
QT_MOC_LITERAL(1, 16, 20), // "UpdateBytesAvailable"
|
||||||
|
QT_MOC_LITERAL(2, 37, 0), // ""
|
||||||
|
QT_MOC_LITERAL(3, 38, 4), // "size"
|
||||||
|
QT_MOC_LITERAL(4, 43, 6), // "sended"
|
||||||
|
QT_MOC_LITERAL(5, 50, 12), // "LoadComplete"
|
||||||
|
QT_MOC_LITERAL(6, 63, 12), // "onNeedUpdate"
|
||||||
|
QT_MOC_LITERAL(7, 76, 4), // "flag"
|
||||||
|
QT_MOC_LITERAL(8, 81, 14), // "onSendDebugLog"
|
||||||
|
QT_MOC_LITERAL(9, 96, 7) // "message"
|
||||||
|
|
||||||
|
},
|
||||||
|
"RecognizeSystem\0UpdateBytesAvailable\0"
|
||||||
|
"\0size\0sended\0LoadComplete\0onNeedUpdate\0"
|
||||||
|
"flag\0onSendDebugLog\0message"
|
||||||
|
};
|
||||||
|
#undef QT_MOC_LITERAL
|
||||||
|
|
||||||
|
static const uint qt_meta_data_RecognizeSystem[] = {
|
||||||
|
|
||||||
|
// content:
|
||||||
|
8, // revision
|
||||||
|
0, // classname
|
||||||
|
0, 0, // classinfo
|
||||||
|
4, 14, // methods
|
||||||
|
0, 0, // properties
|
||||||
|
0, 0, // enums/sets
|
||||||
|
0, 0, // constructors
|
||||||
|
0, // flags
|
||||||
|
4, // signalCount
|
||||||
|
|
||||||
|
// signals: name, argc, parameters, tag, flags
|
||||||
|
1, 2, 34, 2, 0x06 /* Public */,
|
||||||
|
5, 0, 39, 2, 0x06 /* Public */,
|
||||||
|
6, 1, 40, 2, 0x06 /* Public */,
|
||||||
|
8, 1, 43, 2, 0x06 /* Public */,
|
||||||
|
|
||||||
|
// signals: parameters
|
||||||
|
QMetaType::Void, QMetaType::LongLong, QMetaType::ULongLong, 3, 4,
|
||||||
|
QMetaType::Void,
|
||||||
|
QMetaType::Void, QMetaType::Bool, 7,
|
||||||
|
QMetaType::Void, QMetaType::QString, 9,
|
||||||
|
|
||||||
|
0 // eod
|
||||||
|
};
|
||||||
|
|
||||||
|
void RecognizeSystem::qt_static_metacall(QObject *_o, QMetaObject::Call _c, int _id, void **_a)
|
||||||
|
{
|
||||||
|
if (_c == QMetaObject::InvokeMetaMethod) {
|
||||||
|
auto *_t = static_cast<RecognizeSystem *>(_o);
|
||||||
|
Q_UNUSED(_t)
|
||||||
|
switch (_id) {
|
||||||
|
case 0: _t->UpdateBytesAvailable((*reinterpret_cast< qint64(*)>(_a[1])),(*reinterpret_cast< quint64(*)>(_a[2]))); break;
|
||||||
|
case 1: _t->LoadComplete(); break;
|
||||||
|
case 2: _t->onNeedUpdate((*reinterpret_cast< bool(*)>(_a[1]))); break;
|
||||||
|
case 3: _t->onSendDebugLog((*reinterpret_cast< QString(*)>(_a[1]))); break;
|
||||||
|
default: ;
|
||||||
|
}
|
||||||
|
} else if (_c == QMetaObject::IndexOfMethod) {
|
||||||
|
int *result = reinterpret_cast<int *>(_a[0]);
|
||||||
|
{
|
||||||
|
using _t = void (RecognizeSystem::*)(qint64 , quint64 );
|
||||||
|
if (*reinterpret_cast<_t *>(_a[1]) == static_cast<_t>(&RecognizeSystem::UpdateBytesAvailable)) {
|
||||||
|
*result = 0;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
using _t = void (RecognizeSystem::*)();
|
||||||
|
if (*reinterpret_cast<_t *>(_a[1]) == static_cast<_t>(&RecognizeSystem::LoadComplete)) {
|
||||||
|
*result = 1;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
using _t = void (RecognizeSystem::*)(bool );
|
||||||
|
if (*reinterpret_cast<_t *>(_a[1]) == static_cast<_t>(&RecognizeSystem::onNeedUpdate)) {
|
||||||
|
*result = 2;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
using _t = void (RecognizeSystem::*)(QString );
|
||||||
|
if (*reinterpret_cast<_t *>(_a[1]) == static_cast<_t>(&RecognizeSystem::onSendDebugLog)) {
|
||||||
|
*result = 3;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
QT_INIT_METAOBJECT const QMetaObject RecognizeSystem::staticMetaObject = { {
|
||||||
|
QMetaObject::SuperData::link<QObject::staticMetaObject>(),
|
||||||
|
qt_meta_stringdata_RecognizeSystem.data,
|
||||||
|
qt_meta_data_RecognizeSystem,
|
||||||
|
qt_static_metacall,
|
||||||
|
nullptr,
|
||||||
|
nullptr
|
||||||
|
} };
|
||||||
|
|
||||||
|
|
||||||
|
const QMetaObject *RecognizeSystem::metaObject() const
|
||||||
|
{
|
||||||
|
return QObject::d_ptr->metaObject ? QObject::d_ptr->dynamicMetaObject() : &staticMetaObject;
|
||||||
|
}
|
||||||
|
|
||||||
|
void *RecognizeSystem::qt_metacast(const char *_clname)
|
||||||
|
{
|
||||||
|
if (!_clname) return nullptr;
|
||||||
|
if (!strcmp(_clname, qt_meta_stringdata_RecognizeSystem.stringdata0))
|
||||||
|
return static_cast<void*>(this);
|
||||||
|
return QObject::qt_metacast(_clname);
|
||||||
|
}
|
||||||
|
|
||||||
|
int RecognizeSystem::qt_metacall(QMetaObject::Call _c, int _id, void **_a)
|
||||||
|
{
|
||||||
|
_id = QObject::qt_metacall(_c, _id, _a);
|
||||||
|
if (_id < 0)
|
||||||
|
return _id;
|
||||||
|
if (_c == QMetaObject::InvokeMetaMethod) {
|
||||||
|
if (_id < 4)
|
||||||
|
qt_static_metacall(this, _c, _id, _a);
|
||||||
|
_id -= 4;
|
||||||
|
} else if (_c == QMetaObject::RegisterMethodArgumentMetaType) {
|
||||||
|
if (_id < 4)
|
||||||
|
*reinterpret_cast<int*>(_a[0]) = -1;
|
||||||
|
_id -= 4;
|
||||||
|
}
|
||||||
|
return _id;
|
||||||
|
}
|
||||||
|
|
||||||
|
// SIGNAL 0
|
||||||
|
void RecognizeSystem::UpdateBytesAvailable(qint64 _t1, quint64 _t2)
|
||||||
|
{
|
||||||
|
void *_a[] = { nullptr, const_cast<void*>(reinterpret_cast<const void*>(std::addressof(_t1))), const_cast<void*>(reinterpret_cast<const void*>(std::addressof(_t2))) };
|
||||||
|
QMetaObject::activate(this, &staticMetaObject, 0, _a);
|
||||||
|
}
|
||||||
|
|
||||||
|
// SIGNAL 1
|
||||||
|
void RecognizeSystem::LoadComplete()
|
||||||
|
{
|
||||||
|
QMetaObject::activate(this, &staticMetaObject, 1, nullptr);
|
||||||
|
}
|
||||||
|
|
||||||
|
// SIGNAL 2
|
||||||
|
void RecognizeSystem::onNeedUpdate(bool _t1)
|
||||||
|
{
|
||||||
|
void *_a[] = { nullptr, const_cast<void*>(reinterpret_cast<const void*>(std::addressof(_t1))) };
|
||||||
|
QMetaObject::activate(this, &staticMetaObject, 2, _a);
|
||||||
|
}
|
||||||
|
|
||||||
|
// SIGNAL 3
|
||||||
|
void RecognizeSystem::onSendDebugLog(QString _t1)
|
||||||
|
{
|
||||||
|
void *_a[] = { nullptr, const_cast<void*>(reinterpret_cast<const void*>(std::addressof(_t1))) };
|
||||||
|
QMetaObject::activate(this, &staticMetaObject, 3, _a);
|
||||||
|
}
|
||||||
|
QT_WARNING_POP
|
||||||
|
QT_END_MOC_NAMESPACE
|
||||||
BIN
debug/moc_recognizesystem.o
Normal file
BIN
debug/moc_recognizesystem.o
Normal file
Binary file not shown.
148
debug/moc_tcpclient.cpp
Normal file
148
debug/moc_tcpclient.cpp
Normal file
@@ -0,0 +1,148 @@
|
|||||||
|
/****************************************************************************
|
||||||
|
** Meta object code from reading C++ file 'tcpclient.h'
|
||||||
|
**
|
||||||
|
** Created by: The Qt Meta Object Compiler version 67 (Qt 5.14.2)
|
||||||
|
**
|
||||||
|
** WARNING! All changes made in this file will be lost!
|
||||||
|
*****************************************************************************/
|
||||||
|
|
||||||
|
#include <memory>
|
||||||
|
#include "../Core/tcpclient.h"
|
||||||
|
#include <QtCore/qbytearray.h>
|
||||||
|
#include <QtCore/qmetatype.h>
|
||||||
|
#if !defined(Q_MOC_OUTPUT_REVISION)
|
||||||
|
#error "The header file 'tcpclient.h' doesn't include <QObject>."
|
||||||
|
#elif Q_MOC_OUTPUT_REVISION != 67
|
||||||
|
#error "This file was generated using the moc from 5.14.2. It"
|
||||||
|
#error "cannot be used with the include files from this version of Qt."
|
||||||
|
#error "(The moc has changed too much.)"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
QT_BEGIN_MOC_NAMESPACE
|
||||||
|
QT_WARNING_PUSH
|
||||||
|
QT_WARNING_DISABLE_DEPRECATED
|
||||||
|
struct qt_meta_stringdata_TCPClient_t {
|
||||||
|
QByteArrayData data[6];
|
||||||
|
char stringdata0[63];
|
||||||
|
};
|
||||||
|
#define QT_MOC_LITERAL(idx, ofs, len) \
|
||||||
|
Q_STATIC_BYTE_ARRAY_DATA_HEADER_INITIALIZER_WITH_OFFSET(len, \
|
||||||
|
qptrdiff(offsetof(qt_meta_stringdata_TCPClient_t, stringdata0) + ofs \
|
||||||
|
- idx * sizeof(QByteArrayData)) \
|
||||||
|
)
|
||||||
|
static const qt_meta_stringdata_TCPClient_t qt_meta_stringdata_TCPClient = {
|
||||||
|
{
|
||||||
|
QT_MOC_LITERAL(0, 0, 9), // "TCPClient"
|
||||||
|
QT_MOC_LITERAL(1, 10, 14), // "onSendDebugLog"
|
||||||
|
QT_MOC_LITERAL(2, 25, 0), // ""
|
||||||
|
QT_MOC_LITERAL(3, 26, 7), // "message"
|
||||||
|
QT_MOC_LITERAL(4, 34, 16), // "onMessageEntered"
|
||||||
|
QT_MOC_LITERAL(5, 51, 11) // "onReadyRead"
|
||||||
|
|
||||||
|
},
|
||||||
|
"TCPClient\0onSendDebugLog\0\0message\0"
|
||||||
|
"onMessageEntered\0onReadyRead"
|
||||||
|
};
|
||||||
|
#undef QT_MOC_LITERAL
|
||||||
|
|
||||||
|
static const uint qt_meta_data_TCPClient[] = {
|
||||||
|
|
||||||
|
// content:
|
||||||
|
8, // revision
|
||||||
|
0, // classname
|
||||||
|
0, 0, // classinfo
|
||||||
|
3, 14, // methods
|
||||||
|
0, 0, // properties
|
||||||
|
0, 0, // enums/sets
|
||||||
|
0, 0, // constructors
|
||||||
|
0, // flags
|
||||||
|
1, // signalCount
|
||||||
|
|
||||||
|
// signals: name, argc, parameters, tag, flags
|
||||||
|
1, 1, 29, 2, 0x06 /* Public */,
|
||||||
|
|
||||||
|
// slots: name, argc, parameters, tag, flags
|
||||||
|
4, 1, 32, 2, 0x0a /* Public */,
|
||||||
|
5, 0, 35, 2, 0x08 /* Private */,
|
||||||
|
|
||||||
|
// signals: parameters
|
||||||
|
QMetaType::Void, QMetaType::QString, 3,
|
||||||
|
|
||||||
|
// slots: parameters
|
||||||
|
QMetaType::Void, QMetaType::QString, 3,
|
||||||
|
QMetaType::Void,
|
||||||
|
|
||||||
|
0 // eod
|
||||||
|
};
|
||||||
|
|
||||||
|
void TCPClient::qt_static_metacall(QObject *_o, QMetaObject::Call _c, int _id, void **_a)
|
||||||
|
{
|
||||||
|
if (_c == QMetaObject::InvokeMetaMethod) {
|
||||||
|
auto *_t = static_cast<TCPClient *>(_o);
|
||||||
|
Q_UNUSED(_t)
|
||||||
|
switch (_id) {
|
||||||
|
case 0: _t->onSendDebugLog((*reinterpret_cast< QString(*)>(_a[1]))); break;
|
||||||
|
case 1: _t->onMessageEntered((*reinterpret_cast< QString(*)>(_a[1]))); break;
|
||||||
|
case 2: _t->onReadyRead(); break;
|
||||||
|
default: ;
|
||||||
|
}
|
||||||
|
} else if (_c == QMetaObject::IndexOfMethod) {
|
||||||
|
int *result = reinterpret_cast<int *>(_a[0]);
|
||||||
|
{
|
||||||
|
using _t = void (TCPClient::*)(QString );
|
||||||
|
if (*reinterpret_cast<_t *>(_a[1]) == static_cast<_t>(&TCPClient::onSendDebugLog)) {
|
||||||
|
*result = 0;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
QT_INIT_METAOBJECT const QMetaObject TCPClient::staticMetaObject = { {
|
||||||
|
QMetaObject::SuperData::link<QObject::staticMetaObject>(),
|
||||||
|
qt_meta_stringdata_TCPClient.data,
|
||||||
|
qt_meta_data_TCPClient,
|
||||||
|
qt_static_metacall,
|
||||||
|
nullptr,
|
||||||
|
nullptr
|
||||||
|
} };
|
||||||
|
|
||||||
|
|
||||||
|
const QMetaObject *TCPClient::metaObject() const
|
||||||
|
{
|
||||||
|
return QObject::d_ptr->metaObject ? QObject::d_ptr->dynamicMetaObject() : &staticMetaObject;
|
||||||
|
}
|
||||||
|
|
||||||
|
void *TCPClient::qt_metacast(const char *_clname)
|
||||||
|
{
|
||||||
|
if (!_clname) return nullptr;
|
||||||
|
if (!strcmp(_clname, qt_meta_stringdata_TCPClient.stringdata0))
|
||||||
|
return static_cast<void*>(this);
|
||||||
|
return QObject::qt_metacast(_clname);
|
||||||
|
}
|
||||||
|
|
||||||
|
int TCPClient::qt_metacall(QMetaObject::Call _c, int _id, void **_a)
|
||||||
|
{
|
||||||
|
_id = QObject::qt_metacall(_c, _id, _a);
|
||||||
|
if (_id < 0)
|
||||||
|
return _id;
|
||||||
|
if (_c == QMetaObject::InvokeMetaMethod) {
|
||||||
|
if (_id < 3)
|
||||||
|
qt_static_metacall(this, _c, _id, _a);
|
||||||
|
_id -= 3;
|
||||||
|
} else if (_c == QMetaObject::RegisterMethodArgumentMetaType) {
|
||||||
|
if (_id < 3)
|
||||||
|
*reinterpret_cast<int*>(_a[0]) = -1;
|
||||||
|
_id -= 3;
|
||||||
|
}
|
||||||
|
return _id;
|
||||||
|
}
|
||||||
|
|
||||||
|
// SIGNAL 0
|
||||||
|
void TCPClient::onSendDebugLog(QString _t1)
|
||||||
|
{
|
||||||
|
void *_a[] = { nullptr, const_cast<void*>(reinterpret_cast<const void*>(std::addressof(_t1))) };
|
||||||
|
QMetaObject::activate(this, &staticMetaObject, 0, _a);
|
||||||
|
}
|
||||||
|
QT_WARNING_POP
|
||||||
|
QT_END_MOC_NAMESPACE
|
||||||
BIN
debug/moc_tcpclient.o
Normal file
BIN
debug/moc_tcpclient.o
Normal file
Binary file not shown.
BIN
debug/recognizesystem.o
Normal file
BIN
debug/recognizesystem.o
Normal file
Binary file not shown.
BIN
debug/screenchecker.o
Normal file
BIN
debug/screenchecker.o
Normal file
Binary file not shown.
BIN
debug/tcpclient.o
Normal file
BIN
debug/tcpclient.o
Normal file
Binary file not shown.
BIN
debug/tools.o
Normal file
BIN
debug/tools.o
Normal file
Binary file not shown.
BIN
release/RRJClient.exe
Normal file
BIN
release/RRJClient.exe
Normal file
Binary file not shown.
2
release/hash.xml
Normal file
2
release/hash.xml
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<FileDataList/>
|
||||||
Reference in New Issue
Block a user