summaryrefslogtreecommitdiff
path: root/client.cxx
diff options
context:
space:
mode:
authorꦌꦫꦶꦏ꧀ꦦꦿꦧꦮꦑꦩꦭ꧀ <erik@darapsa.co.id>2021-06-18 10:08:22 +0800
committerꦌꦫꦶꦏ꧀ꦦꦿꦧꦮꦑꦩꦭ꧀ <erik@darapsa.co.id>2021-06-18 10:08:33 +0800
commitac8541c6cf3b5dc6936e458dde83e1eebf0ce9d2 (patch)
tree98ffca3db82c390723a04729bd5c3656a8d25c32 /client.cxx
parent8f0eff6c7726bc6f5681784f72e054477915ec6d (diff)
Change results emitted class
Diffstat (limited to 'client.cxx')
-rw-r--r--client.cxx5
1 files changed, 3 insertions, 2 deletions
diff --git a/client.cxx b/client.cxx
index a77c956..7932ac8 100644
--- a/client.cxx
+++ b/client.cxx
@@ -14,7 +14,6 @@ static void responseHandler(icclient_response* response)
static void catalogCallback(icclient_catalog* catalog)
{
client->emitCatalog(catalog);
- icclient_free_catalog(catalog);
}
namespace QICClient {
@@ -52,12 +51,14 @@ namespace QICClient {
void Client::emitResponse(icclient_response* response)
{
- emit gotResponse(response);
+ emit gotResults(QString{response->data});
+ icclient_free_response(response);
}
void Client::emitCatalog(icclient_catalog* catalog)
{
emit gotCatalog(new Catalog{catalog});
+ icclient_free_catalog(catalog);
}
void Client::flyPage(QString const& sku,void (*handler)(icclient_response*))