Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

微信支付回调参考 #18

Open
shouzhong opened this issue Aug 18, 2017 · 3 comments
Open

微信支付回调参考 #18

shouzhong opened this issue Aug 18, 2017 · 3 comments

Comments

@shouzhong
Copy link

shouzhong commented Aug 18, 2017

<activity
            android:name="目标Activity"
            android:exported="true" />
<activity-alias
            android:name="${applicationId}.wxapi.WXPayEntryActivity"
            android:exported="true"
            android:targetActivity="目标Activity"/>

这个就可以把回调的Activity写在任何地方了

@mayubao
Copy link
Owner

mayubao commented Aug 22, 2017

微信支付回调参考已经附在首页文档上面了 @shouzhong

@RealHacker
Copy link

@mayubao

请问一下既然要实现一个Activity来处理回调,那WechatPayReq.OnWechatPayListener有任何作用吗?是不是可以忽略?这个Activity不需要设置contentView,那就是一闪而过?
另外,看到官方文档说在“net.sourceforge.simcpux.wxapi包路径中实现WXPayEntryActivity类(包名或类名不一致会造成无法回调)”,这个包名应该是自己的包加上wxapi后缀?不是用net.sourceforge.simcpux.wxapi这个包名吧?

@mayubao
Copy link
Owner

mayubao commented Nov 7, 2017

是在自己项目的包名下面新建wxapi包,然后在wxapi下实现WXPayEntryActivity类。WechatPayReq.OnWechatPayListener已无任何作用,微信支付的回调可以通过自定义广播来接收,就是在WXPayEntryActivity的onResp方法已经发送广播了。@RealHacker

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants