summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorꦌ ꦫꦶ ꦏ꧀ꦦꦿ ꦧ ꦮ ꦑ ꦩ ꦭ꧀ <erik@darapsa.co.id>2019-11-18 19:25:35 +0700
committerꦌ ꦫꦶ ꦏ꧀ꦦꦿ ꦧ ꦮ ꦑ ꦩ ꦭ꧀ <erik@darapsa.co.id>2019-11-18 19:25:35 +0700
commit2bf032f097da081fc45ff7249f789bdfe142fd28 (patch)
treef45764a8bef15d3a8a5a51c8949052fba2e8c3a6
parent5b388f581333d9d3eee1c993054354243be13183 (diff)
logIn takes page arguments and is not a slot any more
-rw-r--r--client.cxx10
-rw-r--r--qicclient/client.hxx7
2 files changed, 12 insertions, 5 deletions
diff --git a/client.cxx b/client.cxx
index 1dad6fe..0aafc46 100644
--- a/client.cxx
+++ b/client.cxx
@@ -29,11 +29,15 @@ namespace ICClient {
emit ordered(order);
}
- void Client::logIn(QString const& username, QString const& password)
+ void Client::logIn(QString const& username, QString const& password
+ , QString const& successPage, QString const& nextPage
+ , QString const& failPage)
{
icclient_login(username.toLatin1().constData()
- , password.toLatin1().constData(), nullptr, nullptr
- , nullptr);
+ , password.toLatin1().constData()
+ , successPage.toLatin1().constData()
+ , nextPage.toLatin1().constData()
+ , failPage.toLatin1().constData());
emit loggedIn(username);
}
diff --git a/qicclient/client.hxx b/qicclient/client.hxx
index 893e47b..47f25fb 100644
--- a/qicclient/client.hxx
+++ b/qicclient/client.hxx
@@ -21,14 +21,17 @@ namespace ICClient {
, void* userdata));
void order(icclient_ord_order** orderPtr, QString const& sku
, icclient_catalog* catalog);
+ void logIn(QString const& username
+ , QString const& password
+ , QString const& successPage = nullptr
+ , QString const& nextPage = nullptr
+ , QString const& failPage = nullptr);
public slots:
/*
void remove(unsigned int const& indices);
void checkout();
*/
- void logIn(QString const& username
- , QString const& password);
/*
void account(QString const& firstName
, QString const& lastName