Instagram结果代码 [英] Instagram result codes

查看:189
本文介绍了Instagram结果代码的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Instagram允许您通过意图将照片分享到应用程序.现在,您可以定义自己的请求代码startActivityForResult(intent, YOUR_CODE_HERE)

Instagram allows you to share photos to the app via intent. Now you can define your own request code startActivityForResult(intent, YOUR_CODE_HERE)

现在,当您从Instagram检索结果代码时出现问题,它只返回0,即RESULT_CANCELED.加上您开始表达意图的那一刻,无论您是否关闭Instagram,都将调用此结果代码.

Now the problem arises when you retrieve the result codes from Instagram it only gives back 0 which is RESULT_CANCELED. Plus the moment you start firing your intent this result code is called regardless whether you closed Instagram or not.

这是唯一可用的结果代码吗?即使发布图像,也不会调用RESULT_OK,因为Instagram不会关闭.

Is this the only available result code? RESULT_OK does not get called even if you post your image because Instagram doesn't close.

推荐答案

从我到目前为止的尝试来看,这似乎是您将收到的唯一结果.如果您查看Instagram开发人员文档,您会发现它们甚至没有使用'startActivityForResult',而是使用 resultless 'startActivity'.

From what I've tried so far it seems that this is the only result you'll receive. If you look at the Instagram developer docs you can see that they don't even use 'startActivityForResult', but the resultless 'startActivity'.

https://instagram.com/developer/mobile-sharing/android-intents/

如果我们得到RESULT_OK,那将会很棒.如果我们会收到有关已发布对象的一些信息(例如ID),那就更好了.

Would be awesome if we would get a RESULT_OK. Would be even better if we'd receive some info about the posted object, like the ID.

这篇关于Instagram结果代码的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆