From 031f1a2a47ab4e7c9af8bf14d5d577b384974816 Mon Sep 17 00:00:00 2001 From: sunwen Date: Thu, 12 Sep 2024 17:46:59 +0800 Subject: [PATCH] feat: Stop scan process when device state is not ready. --- src/device/DeviceManager.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/device/DeviceManager.cpp b/src/device/DeviceManager.cpp index 32c555f..ab7e213 100644 --- a/src/device/DeviceManager.cpp +++ b/src/device/DeviceManager.cpp @@ -317,6 +317,7 @@ void DeviceManager::startScan(const QString& json, bool empty) { QString errMsg(empty ? tr("Device is not ready, start empty scan operation failed!") : tr("Device is not ready, start scan operation failed!")); THROW_ERROR(errMsg); + TRIGGER_EVENT(StopScanProcess, nullptr, nullptr); return; } AppGlobalValues::setEmptyScanFlag(empty);