android in-app billing - restoreTransactionInformation

前端 未结 3 1592
死守一世寂寞
死守一世寂寞 2021-01-02 17:14

I\'m attempting to make a free app upgradable to the \"paid\" version using in-app billing. I used code from this tutorial to handle the billing as the one on the official d

3条回答
  •  谎友^
    谎友^ (楼主)
    2021-01-02 17:54

    You can't really make a distinction between 'reinstalling' and 'cleared app data'. They are essentially the same: shared preferences are empty. Nor should you need to.

    As for diagnosing the issue, put a 'restore transactions' button and simply click it in different states (just installed, flag(s) set, etc.). Then watch the logcat.

    BTW, it might be better to stick with the original Google code at first, you would get more help that way. There also some projects on Google Code that wrap the IAB code to make it a bit easier to integrate.

提交回复
热议问题