Hi Neverbirth, I was trying to use drawViewPortToBitmapData. But not able to get it work right.
I am trying to take a screenshot and open that image in email, as shown here: http://pbrd.co/11s3Nux Code: //method under myMapComponent to get bitmap data public function getMapBitmapData():BitmapData { var bitmapData:BitmapData = new BitmapData(FlexGlobals.topLevelApplication.width,FlexGlobals.topLevelApplication.height); if(map) { map.drawViewPortToBitmapData(bitmapData); } return bitmapData; } // on click of 'Email' button var pngSource:BitmapData = new BitmapData(FlexGlobals.topLevelApplication.width,FlexGlobals.topLevelApplication.height); pngSource = myMapComponent.getMapBitmapData(); //code to attach the image and open email client var file:File = File.applicationStorageDirectory.resolvePath("screenshot.png"); var extension:ScreenShot = new ScreenShot(); extension.getScreenShotPNG(file.nativePath, pngSource); email.removeEventListener(MailExtensionEvent.MAIL_COMPOSER_EVENT, handleMailComposerEvent); email.addEventListener(MailExtensionEvent.MAIL_COMPOSER_EVENT, handleMailComposerEvent); var attachmentStr:String = file.nativePath + "|" + 'image/png'+ "|" + 'screenshot.png'; email.sendMail(model.selectedViewLabel, "", "", "", "",[attachmentStr]); I think there is some issue with setting up width\height. But I'm not sure what and where should I be changing it. Kindly let me know if there is a way. On Wed, Oct 29, 2014 at 7:31 PM, Neverbirth <[email protected]> wrote: > Yes, sorry for that. I submitted my reply and then realized I misunderstood > the problem. > > When using an ANE the view will always be placed over your Flash content. > The Maps ANE has a drawViewPortToBitmapData which may help you, I've never > used it myself. > > > > -- > View this message in context: > http://apache-flex-users.2333346.n4.nabble.com/Google-Map-ANE-Issue-on-Flex-AIR-iPad-App-tp8523p8542.html > Sent from the Apache Flex Users mailing list archive at Nabble.com. >
