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

Add share images to instagram feed (Fixed from #79) #97

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

LucazzP
Copy link

@LucazzP LucazzP commented Dec 16, 2021

Add possibility to share image to Instagram feed, both iOS and Android

This PR is adding the #79 modification (Thanks @artemsivcev) and the fixes reported by @Anant00 on his PR.

I created this new ones because I saw that the other PR was inactive for a long time, so I thought doing this will reach to a next update soon.

Closes #79
Closes #81
Closes #87
Closes #43
Closes #19

@dariuspo
Copy link

dariuspo commented Dec 29, 2021

@LucazzP i tried to use your forks, but got this error when sharing to instagram feed:

E/MethodChannel#social_share(22856): android.util.AndroidRuntimeException: Calling startActivity() from outside of an Activity  context requires the FLAG_ACTIVITY_NEW_TASK flag. Is this really what you want?
E/MethodChannel#social_share(22856): 	at android.app.ContextImpl.startActivity(ContextImpl.java:1018)
E/MethodChannel#social_share(22856): 	at android.app.ContextImpl.startActivity(ContextImpl.java:994)
E/MethodChannel#social_share(22856): 	at android.content.ContextWrapper.startActivity(ContextWrapper.java:403)
E/MethodChannel#social_share(22856): 	at com.shekarmudaliyar.social_share.SocialSharePlugin.onMethodCall(SocialSharePlugin.kt:86)
E/MethodChannel#social_share(22856): 	at io.flutter.plugin.common.MethodChannel$IncomingMethodCallHandler.onMessage(MethodChannel.java:262)
E/MethodChannel#social_share(22856): 	at io.flutter.embedding.engine.dart.DartMessenger.invokeHandler(DartMessenger.java:178)
E/MethodChannel#social_share(22856): 	at io.flutter.embedding.engine.dart.DartMessenger.lambda$handleMessageFromDart$0$DartMessenger(DartMessenger.java:206)
E/MethodChannel#social_share(22856): 	at io.flutter.embedding.engine.dart.-$$Lambda$DartMessenger$R4HPk6oFVb-i-YR_PN9YE6kqx1I.run(Unknown Source:12)
E/MethodChannel#social_share(22856): 	at android.os.Handler.handleCallback(Handler.java:938)
E/MethodChannel#social_share(22856): 	at android.os.Handler.dispatchMessage(Handler.java:99)
E/MethodChannel#social_share(22856): 	at android.os.Looper.loop(Looper.java:223)
E/MethodChannel#social_share(22856): 	at android.app.ActivityThread.main(ActivityThread.java:7656)
E/MethodChannel#social_share(22856): 	at java.lang.reflect.Method.invoke(Native Method)
E/MethodChannel#social_share(22856): 	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:592)
E/MethodChannel#social_share(22856): 	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:947)
E/flutter (22856): [ERROR:flutter/lib/ui/ui_dart_state.cc(209)] Unhandled Exception: PlatformException(error, Calling startActivity() from outside of an Activity  context requires the FLAG_ACTIVITY_NEW_TASK flag. Is this really what you want?, null, android.util.AndroidRuntimeException: Calling startActivity() from outside of an Activity  context requires the FLAG_ACTIVITY_NEW_TASK flag. Is this really what you want?

any advise?

thanks

@LucazzP
Copy link
Author

LucazzP commented Jun 9, 2022

Fixed

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