diff options
-rw-r--r-- | client.cxx | 9 | ||||
-rw-r--r-- | qicclient/client.hxx | 6 |
2 files changed, 15 insertions, 0 deletions
@@ -22,6 +22,15 @@ namespace ICClient { emit gotAllProducts(catalog); } + void Client::flyPage(size_t (*handler)(void* contents, size_t size, + size_t nmemb, void* userdata), + QString const& sku) + { + icclient_product* product = nullptr; + icclient_flypage(handler, &product, sku.toLatin1().constData()); + emit gotFlyPage(product); + } + void Client::order(icclient_ord_order** orderPtr, QString const& sku , icclient_catalog* catalog) { diff --git a/qicclient/client.hxx b/qicclient/client.hxx index ef8a5bf..1c9d4a2 100644 --- a/qicclient/client.hxx +++ b/qicclient/client.hxx @@ -4,6 +4,7 @@ #include <QObject> struct icclient_catalog; +struct icclient_product; struct icclient_ord_order; struct icclient_user; @@ -20,6 +21,10 @@ namespace ICClient { void allProducts(size_t (*handler)(void* contents , size_t size, size_t nmemb , void* userdata)); + void flyPage(size_t (*handler)(void* contents, + size_t size, size_t nmemb, + void* userdata), + QString const& sku); void order(icclient_ord_order** orderPtr, QString const& sku , icclient_catalog* catalog); void logIn(size_t (*handler)(void*, size_t, size_t, void*) @@ -59,6 +64,7 @@ namespace ICClient { signals: void gotAllProducts(icclient_catalog* catalog); + void gotFlyPage(icclient_product* product); void ordered(icclient_ord_order* order); void loggedIn(icclient_user* user); void loggedOut(); |