1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2024-11-25 17:28:50 -05:00

Fixed sdrbase resource init

This commit is contained in:
f4exb 2019-05-31 10:14:10 +02:00
parent af32260b51
commit 1eeb334a8f
3 changed files with 3 additions and 1 deletions

View File

@ -143,7 +143,7 @@ set(sdrbase_SOURCES
mainparser.cpp
resources/res.qrc
resources/webapi.qrc
)
set(sdrbase_HEADERS

View File

@ -49,6 +49,7 @@ WebAPIRequestMapper::WebAPIRequestMapper(QObject* parent) :
HttpRequestHandler(parent),
m_adapter(0)
{
Q_INIT_RESOURCE(webapi);
qtwebapp::HttpDocrootSettings docrootSettings;
docrootSettings.path = ":/webapi";
m_staticFileController = new qtwebapp::StaticFileController(docrootSettings, parent);
@ -57,6 +58,7 @@ WebAPIRequestMapper::WebAPIRequestMapper(QObject* parent) :
WebAPIRequestMapper::~WebAPIRequestMapper()
{
delete m_staticFileController;
Q_CLEANUP_RESOURCE(webapi);
}
void WebAPIRequestMapper::service(qtwebapp::HttpRequest& request, qtwebapp::HttpResponse& response)