问题描述
给出来自https://developer.android.com/google/play/billing/integrate的代码示例
billingClient.startConnection(object : BillingClientStateListener {
override fun onBillingSetupFinished(billingResult: BillingResult) {
if (billingResult.responseCode == BillingResponseCode.OK) {
// The BillingClient is ready. You can query purchases here.
}
}
override fun onBillingServicedisconnected() {
// Try to restart the connection on the next request to
// Google Play by calling the startConnection() method.
}
})
在几个客户中,onBillingServicedisconnected
在onBillingSetupFinished
之前被调用。应该如何处理?由于startConnection
从未完成,因此实际上无法重新启动连接。无论如何应该调用startConnection
?
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)