diff --git a/src/hwapi.cpp b/src/hwapi.cpp index 6e91dd1..af3dd37 100644 --- a/src/hwapi.cpp +++ b/src/hwapi.cpp @@ -20,6 +20,9 @@ */ #include "hwapi.h" +#include "reporting_thread.h" +#include "download_thread.h" + #include #include @@ -4373,7 +4376,11 @@ uint16_t hwapi::bna_getStackerLevel(uint32_t *amountInStacker, uint16_t *countOf return anzahl; } -void hwapi::dcDownloadInit(QString const &dcFileToDownload) { +hwapi *hwapi::getAPI() { + return this; +} + +void hwapi::dcDownloadRequest(QString const &dcFileToDownload) { char *fNameBuffer = SharedMem::getData()->m_downLoadDC.m_filename; size_t const size = sizeof(SharedMem::getData()->m_downLoadDC.m_filename); @@ -4392,7 +4399,11 @@ void hwapi::dcDownloadStart() { } void hwapi::dcDownloadReportStart() { - + if (SharedMem::getDataConst()->m_downLoadDC.m_started || + SharedMem::getDataConst()->m_downLoadDC.m_running) { + m_reportingThread = new ReportingThread(this); + m_reportingThread->start(); + } } bool hwapi::dcDownloadRequested() const {