diff --git a/src/MainWindow/MoreInformation.ui b/src/MainWindow/MoreInformation.ui index 91d835ba0..4deb58840 100644 --- a/src/MainWindow/MoreInformation.ui +++ b/src/MainWindow/MoreInformation.ui @@ -53,7 +53,10 @@ p, li { white-space: pre-wrap; } <html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } </style></head><body style=" font-family:'SimSun'; font-size:9pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">v1.2.0 2019年</p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">v1.2.1 2019年03月22日</p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"> 01. 修复串口自收发输出空数据的bug</p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><br /></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">v1.2.0 2019年03月22日</p> <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"> 01. 添加读写延时参数设置功能</p> <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"> </p> <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">v1.1.0 2019年03月10日</p> diff --git a/src/MainWindow/SAKVersion.cpp b/src/MainWindow/SAKVersion.cpp index d1dcb67b0..9301ae1b6 100644 --- a/src/MainWindow/SAKVersion.cpp +++ b/src/MainWindow/SAKVersion.cpp @@ -37,7 +37,7 @@ SAKVersion::SAKVersion() copyQQ = ui->pushButtonCopy; - version->setText(QString("1.2.0")); + version->setText(QString("1.2.1")); datetime->setText(QString(__DATE__) + " " + QString(__TIME__)); author->setText(QString("Qter")); email->setText(QString("Qter.vip@outlook.com")); diff --git a/src/TabPageSerialPort/SerialportSAKIODevice.cpp b/src/TabPageSerialPort/SerialportSAKIODevice.cpp index 1e872b3bf..bda6cb633 100644 --- a/src/TabPageSerialPort/SerialportSAKIODevice.cpp +++ b/src/TabPageSerialPort/SerialportSAKIODevice.cpp @@ -25,12 +25,16 @@ SerialportSAKIODevice::~SerialportSAKIODevice() } -QByteArray SerialportSAKIODevice::ReadAll() +void SerialportSAKIODevice::ReadAll() { while (mpSerialPort->waitForReadyRead(readDelayTime())); QByteArray data = mpSerialPort->readAll(); + + if (data.isEmpty()){ + return; + } + emit bytesRead(data); - return data; } void SerialportSAKIODevice::writeBytes(QByteArray data) diff --git a/src/TabPageSerialPort/SerialportSAKIODevice.h b/src/TabPageSerialPort/SerialportSAKIODevice.h index 94436ddce..c1b53ecf7 100644 --- a/src/TabPageSerialPort/SerialportSAKIODevice.h +++ b/src/TabPageSerialPort/SerialportSAKIODevice.h @@ -29,7 +29,7 @@ public slots: void open(QString portName, QString baudRate, QString dataBits, QString stopBits, QString parity) override; void writeBytes(QByteArray data) override; - QByteArray ReadAll(); + void ReadAll(); protected: void run() override; private: