RE: [flexcoders] ArrayCollection filterFunction returning item in array;
I think you want return statusGroup.indexOf(item.STATUSID) != -1 Make sure STATUSID is a number/int and not a String, or convert it. Alex Harui Flex SDK Developer Adobe Systems Inc.http://www.adobe.com/ Blog: http://blogs.adobe.com/aharui From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of kpjj31 Sent: Friday, August 07, 2009 3:02 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] ArrayCollection filterFunction returning item in array; Is it possible to use the ArrayCollection filterFunction that returns items from an Array? This returns null... private function filterStatus(item:Object):Boolean { var statusgroup:Array = [0, 1, 88, 44]; return item.STATUSID in (statusgroup); }
[flexcoders] open source imageCFC
in my flex app i upload files using a codlfusion script upload.cfm and it works perfectly. i would like to take it a step further by allowing for image manipulation while uploading so that when a person uploads an image of any size, it is resized, croped and compressed to jpeg then saved on the server. i would like to use imageCFC for this but dont know how. can someone please help me? here is the upload script i use. how can i modify it to use imageCFC to resize, crop and compress the image that is being uploaded? thanks alot upload.cfm !--- Flex Multi-File Upload Server Side File Handler This file is where the upload action from the Flex Multi-File Upload UI points. This is the handler the server side half of the upload process. --- !--- set the full path to the images folder --- cfset mediapath = expandpath('/IESTATE_V1/assets/agent_profilepics') !--- set the desired image height cfset thumbsize = 320 !--- set the desired image width --- cfset imagesize = 192 cftry !--- Because flash uploads all files with a binary mime type (application/ocet-stream) we cannot set cffile to accept specfic mime types. The workaround is to check the file type after it arrives on the server and if it is non desireable delete it. --- cffile action=upload filefield=filedata !--- destination=#ExpandPath('\')#realestate portal\images\agent_pics\ --- destination=#MediaPath# nameconflict=makeunique accept=application/octet-stream/ !--- Begin checking the file extension of uploaded files --- cfset acceptedFileExtensions = jpg,jpeg,gif,png/ cfset filecheck = listFindNoCase(acceptedFileExtensions,File.ServerFileExt)/ !--- read the image cfimage name=uploadedImage source=#MediaPath#/#file.serverFile# !--- figure out which way to scale the image --- cfif uploadedImage.width gt uploadedImage.height cfset thmb_percentage = (thumbsize / uploadedImage.width) cfset percentage = (imagesize / uploadedImage.width) cfelse cfset thmb_percentage = (thumbsize / uploadedImage.height) cfset percentage = (imagesize / uploadedImage.height) /cfif !--- calculate the new thumbnail and image height/width --- cfset thumbWidth = round(uploadedImage.width * thmb_percentage) cfset thumbHeight = round(uploadedImage.height * thmb_percentage) cfset newWidth = round(uploadedImage.width * percentage) cfset newHeight = round(uploadedImage.height * percentage) !--- see if we need to resize the image, maybe it is already smaller than our desired size --- cfif uploadedImage.width gt imagesize cfimage action=resize height=#newHeight# width=#newWidth# source=#uploadedImage# destination=#MediaPath#/#file.serverFile# overwrite=true/ /cfif !--- create a thumbnail for the image --- cfimage action=resize height=#thumbHeight# width=#thumbWidth# source=#uploadedImage# destination=#MediaPath#/thumbs/#file.serverFile# overwrite=true/ !--- If the variable filecheck equals false delete the uploaded file immediatley as it does not match the desired file types --- cfif filecheck eq false cffile action=delete file=#MediaPath#/#file.serverFile#/ /cfif !--- Should any error occur output a pdf with all the details. It is difficult to debug an error from this file because no debug information is diplayed on page as its called from within the Flash UI. If your files are not uploading check to see if an errordebug.pdf has been generated. --- cfcatch type=any cfdocument format=PDF overwrite=yes filename=errordebug.pdf cfdump var=#cfcatch#/ /cfdocument /cfcatch /cftry
[flexcoders] URLLoader and Flex/AIR
Hi, I am facing strange problem in Air only it works fine in browser. I am trying to download Binary octet/stream data with URLLoader using AIR. Its working . i have a download button a inputBox to enter file name and a list which shows the progrss of files being download. when i click download button it creates new instance of urlloader and adds it into the list . It works fine upto two file downloads concurrently but when i add third download in the list . It simply dosent works. and After 3,4 minutes it gives Error #2032: Stream Error This application works fine in browser but not working fine in air. Then i tried to analyze the packets whether AIR actually sends the urlRequest or not. and the answer is no . It do not sends more then two request :s . Anyone facing similar problem ? regards, ATIF
Re: [flexcoders] Flex 3d Tweening and best practice/results for Text
Chet, The blurry effect doesnt occur any more with sdk4. The component I wrote uses sdk3.3, which leaves blurry the buttons from the example code you sent. thomas --- http://www.web-attitude.fr/ msn : thomas.parqu...@web-attitude.fr softphone : sip:webattit...@ekiga.net sip%3awebattit...@ekiga.net téléphone portable : +33601 822 056 2009/8/8 Chet Haase cha...@adobe.com That’s not what I’m seeing: in the code below, the rotator effect rotates the button around the Y axis, ending at rotationY==0, at which point the text in the button is no longer blurry: ?xml version=1.0 encoding=utf-8? mx:Application xmlns:mx=http://www.adobe.com/2006/mxml; layout=absolute mx:AnimateProperty id=rotator property=rotationY fromValue=360 toValue=0 target={button1}/ mx:Button id=button x=10 label=Move Me click=button.z = (button.z == 100) ? 0 : 100/ mx:Button id=button1 x=10 y=50 label=Rotate Me click=rotator.play()/ /mx:Application Are you doing anything with the 3D properties besides setting rotationY? Post all of the code (if you can boil it down to a simple case) Chet. *From:* flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] *On Behalf Of *thomas parquier *Sent:* Friday, August 07, 2009 3:40 PM *To:* flexcoders@yahoogroups.com *Subject:* Re: [flexcoders] Flex 3d Tweening and best practice/results for Text Chet, Yet in a mxml component I had to do the following : mx:AnimateProperty property=rotationY toValue=0 duration=700 effectEnd=twoSidedDO3D.transform.matrix=new Matrix(1,0,0,1,width/2,0); / thomas --- http://www.web-attitude.fr/ msn : thomas.parqu...@web-attitude.fr softphone : sip:webattit...@ekiga.net sip%3awebattit...@ekiga.net téléphone portable : +33601 822 056 2009/8/7 Chet Haase cha...@adobe.com You don’t necessarily have to reset the 2d matrix – you just have to make sure that all of your 3d properties are set back to the values they would have if the object were again in 2d. In the original example, if the only thing you did was to change the z location, and then you reset it to 0, then the text should not be blurry any longer (we recognize that the object no longer needs a 3D transform and just do the right 2D thing instead). I suspect that you are setting more 3D properties than simply the z property (like rotationX, rotationY, etc.), so even though you’re zeroing-out the ‘z’ property, that’s not enough to take the object out of 3D and put it on the 2D plane again. Figure out the other 3D properties that you’re tweaking (just take a look at the matrix when it’s back in the state where you think it should be 2D) and reset the ones that are still in 3D. Chet. *From:* flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] *On Behalf Of *thomas parquier *Sent:* Friday, August 07, 2009 11:21 AM *To:* flexcoders@yahoogroups.com *Subject:* Re: [flexcoders] Flex 3d Tweening and best practice/results for Text Hi, When objects are back to 2d, you have to reset 2d matrix to get rid of blurry effect. thomas --- http://www.web-attitude.fr/ msn : thomas.parqu...@web-attitude.fr softphone : sip:webattit...@ekiga.net sip%3awebattit...@ekiga.net téléphone portable : +33601 822 056 2009/8/5 djhatrick djhatr...@yahoo.com I have a displayObject, a panel, doing 3d stuff with the panel... However after I tween my object to z=0, the text looks blurry after the animation has stopped. Is there a way to make the text look sharp: fontAntiAliasType=advanced I've tried but that gives not-passable results. Thanks, Patrick
Re: [flexcoders] unable to resolve 'image filename' for transcoding
Tom Chiverton-2 wrote: On Tuesday 10 October 2006 00:25, Iko Knyphausen wrote: [Embed(source=layout1.png)] The image file resides in the same directory as the SWF (and it is reading It is embedded at compile time. The image file therefore needs to be in the same directory as the MXML source. We are having an issue with embedded images when using the compc command-line compiler to generate an .swc for a bunch of library classes. Our directory structure is like this: (some directory structure)/flexprojects/MyLib/src/ (flex packages and classes here) (some other directory structure)/myapp.war/image/ (image files here) note that myapp.war is an exploded directory structure (in other words, it's a directory whose contents would normally be zipped into a file named myapp.war for deployment on an application server). When we use the Adobe Flex Builder IDE to build the .swc file, it is able to reference them properly, but I'm struggling with the command-line version (we use it for the Ant-based build process). After reading this post, I tried as an experiment to copy the entire image/ directory into the MyLib/src directory and compiling, and it worked. It looks like there should be some compc option or argument that would allow me to let compc know about the location of the image files, but the closest I could find was include-file which is too limiting (I would have to include over 300 image files, and if a new file is added we would have to manually update the list of images). Is there some other way to get this done? -- View this message in context: http://www.nabble.com/unable-to-resolve-%27image-filename%27-for-transcoding-tp6728875p24873502.html Sent from the FlexCoders mailing list archive at Nabble.com.
[flexcoders] Can you import pure Flash packages and use them with Flex 3? Is it compatible?
I am new to Flex 3 and I wonder if you can import Flash packages while using Flex 3 and using them without compatibility issues? I notice that a lot of Flex 3 packages start with mx. Thanks.
RE: [flexcoders] Flex 3d Tweening and best practice/results for Text
Ah, okay. The yes: resetting the matrix seems to be the way to workaround this problem (which must be what we’re doing internally, as of Flex 4). Thanks, Chet. From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of thomas parquier Sent: Saturday, August 08, 2009 6:31 AM To: flexcoders@yahoogroups.com Subject: Re: [flexcoders] Flex 3d Tweening and best practice/results for Text Chet, The blurry effect doesnt occur any more with sdk4. The component I wrote uses sdk3.3, which leaves blurry the buttons from the example code you sent. thomas --- http://www.web-attitude.fr/ msn : thomas.parqu...@web-attitude.frmailto:thomas.parqu...@web-attitude.fr softphone : sip:webattit...@ekiga.netmailto:sip%3awebattit...@ekiga.net téléphone portable : +33601 822 056 2009/8/8 Chet Haase cha...@adobe.commailto:cha...@adobe.com That’s not what I’m seeing: in the code below, the rotator effect rotates the button around the Y axis, ending at rotationY==0, at which point the text in the button is no longer blurry: ?xml version=1.0 encoding=utf-8? mx:Application xmlns:mx=http://www.adobe.com/2006/mxml; layout=absolute mx:AnimateProperty id=rotator property=rotationY fromValue=360 toValue=0 target={button1}/ mx:Button id=button x=10 label=Move Me click=button.z = (button.z == 100) ? 0 : 100/ mx:Button id=button1 x=10 y=50 label=Rotate Me click=rotator.play()/ /mx:Application Are you doing anything with the 3D properties besides setting rotationY? Post all of the code (if you can boil it down to a simple case) Chet. From: flexcoders@yahoogroups.commailto:flexcoders@yahoogroups.com [mailto:flexcoders@yahoogroups.commailto:flexcoders@yahoogroups.com] On Behalf Of thomas parquier Sent: Friday, August 07, 2009 3:40 PM To: flexcoders@yahoogroups.commailto:flexcoders@yahoogroups.com Subject: Re: [flexcoders] Flex 3d Tweening and best practice/results for Text Chet, Yet in a mxml component I had to do the following : mx:AnimateProperty property=rotationY toValue=0 duration=700 effectEnd=twoSidedDO3D.transform.matrix=new Matrix(1,0,0,1,width/2,0); / thomas --- http://www.web-attitude.fr/ msn : thomas.parqu...@web-attitude.frmailto:thomas.parqu...@web-attitude.fr softphone : sip:webattit...@ekiga.netmailto:sip%3awebattit...@ekiga.net téléphone portable : +33601 822 056 2009/8/7 Chet Haase cha...@adobe.commailto:cha...@adobe.com You don’t necessarily have to reset the 2d matrix – you just have to make sure that all of your 3d properties are set back to the values they would have if the object were again in 2d. In the original example, if the only thing you did was to change the z location, and then you reset it to 0, then the text should not be blurry any longer (we recognize that the object no longer needs a 3D transform and just do the right 2D thing instead). I suspect that you are setting more 3D properties than simply the z property (like rotationX, rotationY, etc.), so even though you’re zeroing-out the ‘z’ property, that’s not enough to take the object out of 3D and put it on the 2D plane again. Figure out the other 3D properties that you’re tweaking (just take a look at the matrix when it’s back in the state where you think it should be 2D) and reset the ones that are still in 3D. Chet. From: flexcoders@yahoogroups.commailto:flexcoders@yahoogroups.com [mailto:flexcoders@yahoogroups.commailto:flexcoders@yahoogroups.com] On Behalf Of thomas parquier Sent: Friday, August 07, 2009 11:21 AM To: flexcoders@yahoogroups.commailto:flexcoders@yahoogroups.com Subject: Re: [flexcoders] Flex 3d Tweening and best practice/results for Text Hi, When objects are back to 2d, you have to reset 2d matrix to get rid of blurry effect. thomas --- http://www.web-attitude.fr/ msn : thomas.parqu...@web-attitude.frmailto:thomas.parqu...@web-attitude.fr softphone : sip:webattit...@ekiga.netmailto:sip%3awebattit...@ekiga.net téléphone portable : +33601 822 056 2009/8/5 djhatrick djhatr...@yahoo.commailto:djhatr...@yahoo.com I have a displayObject, a panel, doing 3d stuff with the panel... However after I tween my object to z=0, the text looks blurry after the animation has stopped. Is there a way to make the text look sharp: fontAntiAliasType=advanced I've tried but that gives not-passable results. Thanks, Patrick
[flexcoders] drawings dont get clipped by holder
Hi, I writing an app which can draw shapes on sprites within a uicomponent (contentHolder), which holds some other canvas components. This contentHolder can be move within a canvas (drawingCanvas) which has clipContent=true. But clipping seems erratic : shapes dont seem to be taken into account especially at left hand side of drawingCanvas when some graphics are negative in sprites coordinates space. thomas --- http://www.web-attitude.fr/ msn : thomas.parqu...@web-attitude.fr softphone : sip:webattit...@ekiga.net sip%3awebattit...@ekiga.net téléphone portable : +33601 822 056
RE: [flexcoders] Can you import pure Flash packages and use them with Flex 3? Is it compatible?
Many of the fl.*.* packages are incompatible, especially the ones dealing with UI widgets, however Flex usually has equivalents so you don't need them. Alex Harui Flex SDK Developer Adobe Systems Inc.http://www.adobe.com/ Blog: http://blogs.adobe.com/aharui From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of fred44455 Sent: Friday, August 07, 2009 9:57 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Can you import pure Flash packages and use them with Flex 3? Is it compatible? I am new to Flex 3 and I wonder if you can import Flash packages while using Flex 3 and using them without compatibility issues? I notice that a lot of Flex 3 packages start with mx. Thanks.
[flexcoders] Design Table in MXML with static content
Hi , Do we have any buildin tags are available to create Table view in MXML with static content. Please find the below UI .Please help me. Thanks, Ramesh