Clean code.
This commit is contained in:
@@ -58,10 +58,6 @@ void DeviceManager::initDevice() {
|
|||||||
// empty scan
|
// empty scan
|
||||||
connect(EventCenter::Default(), &EventCenter::RequestEmptyScan, [=](QObject* sender, QObject* detail) {
|
connect(EventCenter::Default(), &EventCenter::RequestEmptyScan, [=](QObject* sender, QObject* detail) {
|
||||||
std::string json = getJsonFromPatInf(detail);
|
std::string json = getJsonFromPatInf(detail);
|
||||||
// qDebug()<<json.c_str();
|
|
||||||
// void * jss = malloc(json.size());
|
|
||||||
// memcpy(jss,json.c_str(),json.size());
|
|
||||||
// processScan((char*)jss,true);
|
|
||||||
processScan(json.c_str(), true);
|
processScan(json.c_str(), true);
|
||||||
});
|
});
|
||||||
// Patient scan
|
// Patient scan
|
||||||
@@ -70,9 +66,6 @@ void DeviceManager::initDevice() {
|
|||||||
qDebug() << json.c_str();
|
qDebug() << json.c_str();
|
||||||
if (!json.empty())
|
if (!json.empty())
|
||||||
{
|
{
|
||||||
// void * jss = malloc(json.size());
|
|
||||||
// memcpy(jss,json.c_str(),json.size());
|
|
||||||
// processScan((char*)jss);
|
|
||||||
processScan(json.c_str());
|
processScan(json.c_str());
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@@ -93,11 +86,6 @@ void DeviceManager::initDevice() {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// if (inf.status == BUSY) {
|
|
||||||
// QString msg("Device is busy, Stop operation fail!");
|
|
||||||
// THROW_ERROR(msg);
|
|
||||||
// return;
|
|
||||||
// };
|
|
||||||
AppGlobalValues::setInProcessing(true);
|
AppGlobalValues::setInProcessing(true);
|
||||||
TRIGGER_EVENT(GUIEvents::InvokeOperationStart, nullptr, nullptr);
|
TRIGGER_EVENT(GUIEvents::InvokeOperationStart, nullptr, nullptr);
|
||||||
//ScanControl fail
|
//ScanControl fail
|
||||||
@@ -203,9 +191,6 @@ void DeviceManager::timerEvent(QTimerEvent* event) {
|
|||||||
//error exit, callback error
|
//error exit, callback error
|
||||||
if (errorOccurred)
|
if (errorOccurred)
|
||||||
{
|
{
|
||||||
// qDebug() << "Error occurred, exit progress timer";
|
|
||||||
// QString msg("Error occurred, exit current operation!");
|
|
||||||
// THROW_ERROR(msg);
|
|
||||||
goto exitTimer;
|
goto exitTimer;
|
||||||
}
|
}
|
||||||
// previewing exit
|
// previewing exit
|
||||||
|
|||||||
@@ -186,7 +186,7 @@ SelectFormWidget::SelectFormWidget(QWidget* parent) :
|
|||||||
btnSelect->setEnabled(true);
|
btnSelect->setEnabled(true);
|
||||||
});
|
});
|
||||||
|
|
||||||
// btn add slot
|
// EditPatientForm editAccept slot
|
||||||
connect(edit_patient, &EditPatientForm::editAccept, [=](PatientInformation* inf, bool& result) {
|
connect(edit_patient, &EditPatientForm::editAccept, [=](PatientInformation* inf, bool& result) {
|
||||||
int selectedRow = table->currentIndex().row();
|
int selectedRow = table->currentIndex().row();
|
||||||
bool isAdd = inf->PatientUID.isEmpty();
|
bool isAdd = inf->PatientUID.isEmpty();
|
||||||
|
|||||||
Reference in New Issue
Block a user