Skip to content

DaVikingCode/Instagram-ANE

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Instagram-ANE

Based on Sharkhack Instagram's ANEs. We wanted to have a default implementation for iOS & Android into the same ANE.

var instagram:Instagram = new Instagram();

if (instagram.isInstalled())
	instagram.share(new DaVikingCodeLogo().bitmapData, "my caption test");

On Android we use directly the bitmapData whereas on iOS we turn it into a ByteArray. You may use a third argument for the compressor. Default is new JPEGEncoderOptions();

Also on Android be sure to add this permission (the picture need to be saved on disk): <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />

On iOS you must add in your *-app.xml:

<iPhone>
    <InfoAdditions><![CDATA[
        <key>LSApplicationQueriesSchemes</key>
        <array>
            <string>instagram</string>
        </array>
    ]]></InfoAdditions>
</iPhone>

Note, since several months the pre-filled caption has been removed from Instagram. If the user has an old version on its mobile, it will still work. Your image should be at least 640px by 640px square.

About

Instagram sharing ANE for iOS & Android

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published