• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
Locked
0

Problem with iPad when I try to select a photo from gallery using browseForImage

New Here ,
Feb 06, 2015 Feb 06, 2015

Copy link to clipboard

Copied

Hi, this is my first post, and I hope you can help me with this problem...Im using cameraUI.launch for open the camera app and take a picture without problems, this works fine, but when I try to open gallery from iPad using browseForImage this open a little window to select a folder rigth? but when I try to select any folder this cancel all operation and I cant upload any picture from my gallery..please help,,,Im working with FB 4.7 , apache 4.14 and adobe Air 16.0.0.272,  on Android devices and iPhones I dont have this problem just on iPad.

this is the source code:

protected function btnGallery_clickHandler(event:MouseEvent):void {

  if( CameraRoll.supportsBrowseForImage )

     {

        if(Capabilities.manufacturer.indexOf("Android") >= 0)

        {

          loader = new Loader();

          loader.contentLoaderInfo.addEventListener( Event.COMPLETE, this.contentLoadedHandler );

        }

        cameraRoll = new CameraRoll();

        cameraRoll.addEventListener( MediaEvent.SELECT, imageSelected );

        cameraRoll.addEventListener( Event.CANCEL, browseCanceled ); /*This is activated whenever I try to select a folder to select an image on the iPad*/

        cameraRoll.addEventListener( ErrorEvent.ERROR, mediaError );

        cameraRoll.browseForImage();

     } 

  }

Views

348

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

New Here , Feb 06, 2015 Feb 06, 2015

finaly I find a solution, actually adobe solved the issue with the new beta Air 17...you have to download for flex developers and use this version on your project...

Download Adobe AIR 17 Beta - Adobe Labs

Votes

Translate

Translate
Community Beginner ,
Feb 06, 2015 Feb 06, 2015

Copy link to clipboard

Copied

I have te same unfortunate problem. Only happens in iPad. cameraRoll.browseForImage() opens a new window but wherever I touch (on folders, or anywhere on the window or out of the window) it dispatches a Cancel event and closes window.

I tried to dispatch flash.events.Event.DEACTIVATE, from nativeStage and from cameraRoll, before and after calling cameraRoll.browseForImage() , but still it was behaving same as above.


I tried setting displayState as:

Starling.current.nativeStage.displayState = StageDisplayState.NORMAL;

But no help neither.


It doesn't show any error, I don't have any other solutions to come up with. I feel that somehow I need to invoke application to deactivate, to let my touches focus on CameraRoll window, but I don't know how to do this actually (I tried to dispatch DEACTIVATE event from various sources but I dont believe it is an effective way of doing it).

I use AIR 16.0 with Starling, test on iOS 8.1.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Feb 06, 2015 Feb 06, 2015

Copy link to clipboard

Copied

LATEST

finaly I find a solution, actually adobe solved the issue with the new beta Air 17...you have to download for flex developers and use this version on your project...

Download Adobe AIR 17 Beta - Adobe Labs

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines