Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

These instructions are for using Appoxee SDK with Adobe Air applications. The ANE was created on FB 4.7 using Air Compiler 19. The code samples are in ActionScript under an ActionScript Mobile Project. 
The ANE file contains :

A. The Appoxee SDK Framework (Headers and code)

B. The Appoxee SDK - Adobe Air bridge library

Integration Instructions : 

  1. Download the ANE+SWC files from the Appoxee Download Page.
  2. Create a new ActionScript Mobile Project, as shown in the image.
  3. Name your project , as shown in the image.
  4. In the new project's dialog under Platform Settings choose the Device target family. Make sure that "Apple iOS" is ticked under "Target Platforms"
  5. in the new project's dialog under Build Paths tab, in the Library Path tab, Add the Appoxee SWC. add other SWC files if you use other 3rd party libs.
  6. in the new project's dialog under Build Paths tab, in the Native Extensions tab, Add the Appoxee ANE. add other ANE files if you use other 3rd party libs.
  7. After the project is generated, go into it's properties,Make sure all ANE files you added including Appoxee's are ticked on. Press OK.

     

  8. In your app's main .as file , add the following code : 

    Code into your main .as file
    //Add this to imports : 
    
    import com.appoxee.AppoxeeANE;
    import com.appoxee.CallbackResult;
    import flash.events.Event;
    
    //Add this to class : 
    private var _appoxeeANE:AppoxeeANE;
    
    //Add the class's constructor : 
    
    _appoxeeANE = new AppoxeeANE("YOUR_APP_KEY","YOUR_SECRET_KEY");
    
    //Activate / De-Activate Event Registration
    this.addEventListener(Event.ACTIVATE,appActivate,false,0,true);
    this.addEventListener(Event.DEACTIVATE,appDeActivate,false,0,true);
    ...
    
    //Add this to class : 
    
    private function handleCallback(result:CallbackResult):void {
    //Do what is needed ...
    }
    
    private function appActivate(_event:Event):void {
    _appoxeeANE.onActivate();
    _appoxeeANE.addCallbackFunction(handleCallback)
    }
    
    private function appDeActivate(_event:Event):void {
    _appoxeeANE.onDeactivate();
    _appoxeeANE.removeCallbackFunction(handleCallback);
    }
  9. This conclude the basic integration of the ANE. Click here to see API usage.

 

  • No labels