Re: [flexcoders] Re: icon path in ActionScript
Hey Douglas, Actually, Elvis is in Memphis. It's just me and Johnny Cash here in Nashville. :-) Ben Stucki http://blog.benstucki.net/ From: Douglas Knudsen [EMAIL PROTECTED] Sent: Wednesday, November 21, 2007 8:36 PM To: flexcoders@yahoogroups.com Subject: Re: [flexcoders] Re: icon path in ActionScript this approach might work for you http://blog.benstucki.net/?p=42 Elvis ain't the only thing in Nashville, eh? DK On Nov 21, 2007 11:27 PM, Anzer [EMAIL PROTECTED] wrote: Thanks for the reply. But it will not work for me since the icon path is coming from database and I can't give a static path. I have tried the following code, but that too will give a compile error var iconPath:String = assets/ + item.IconFile.toString(); [Embed(source=iconPath)] var iconCls:Class; Please help Anz -- Douglas Knudsen http://www.cubicleman.com this is my signature, like it?
re: [flexcoders] ID3 library?
Check out http://code.google.com/p/metaphile I'm still ramping up the resources and documentation, but it should do what you're looking for. Feel free to post any questions on the group http://groups.google.com/group/metaphile and submit any bugs or feature requests on google code. Thanks. Ben Stucki http://blog.benstucki.net/ From: David Buitenveld [EMAIL PROTECTED] Sent: Wednesday, August 29, 2007 9:40 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] ID3 library? Hi all - has anyone ever run across an actionscript library for reading/writing ID3 tags from music files? (ideally flac, but mp3 would be a start).. alternatively, does anyone have a favorite non-actionscript ID3 library that they are able to call from actionscript? Would prefer open source solutions, but would also consider just purchasing something if it was reasonable.. thanks for any pointers - david
re: [flexcoders] Circular Binding
Raz, There's a built in mechanism to prevent this problem in circular bindings. If the new value of a property is the same as the existing value when you set it, then it's bindings are not updated (the binding event never fires), although the setter method for that property itself is still called. Ben Stucki We're Hiring! Seeking a passionate developer to join our team building Flex based products. Position is in the Washington D.C. metro area. If interested contact [EMAIL PROTECTED] From: raz_gilad [EMAIL PROTECTED] Sent: Wednesday, February 28, 2007 11:20 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Circular Binding Hi Does anyone knows how Circular Binding works? I've used the follwing action script code and I've expected it to go into endless loop - but it did not. Any idea why ? BindingUtils.bindProperty(item,Threshold,txtin,text); BindingUtils.bindProperty(txtin,text,item,Threshold); Thanks Raz
re: [flexcoders] Flex Socket + MSN Protocol
Michel, Sometimes when debugging white space characters such as carriage return and new line are represented by \r and \n respectively. This is because otherwise you really wouldn't know they're there, but they are coming in from the binary. In hex I believe carriage return (\r) is 0x0D and new line (\n) is 0x0A. So you should be able to send them using writeByte(0x0D) and writeByte(0x0A). You can double check for the correct hex by calling toString(16) on the \r and \n bytes coming in. You may already be doing this correctly, I just couldn't tell for sure from the posting. Ben Stucki --- We're Hiring! Seeking a passionate developer to join our team building Flex based products. Position is in the Washington D.C. metro area. If interested contact [EMAIL PROTECTED] From: Michel Scoz [EMAIL PROTECTED] Sent: Friday, February 23, 2007 5:48 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] Flex Socket + MSN Protocol Hi all... I've been reading and searching the archives about sockets but found nothing that would solve my problem, so i was wondering if anyone could give me a light =) Currently I'm tryin to connect a Flex Project using Sockets to a MSN server using MSN Protocol Version 13. The problem im runnin into is that the protocol always ends with an \r\n to finish a command, pretty much like this: stands for send commands stands for received commands VER 1 MSNP13 CVR0\r\n VER 1 MSNP13 CVR0\r\n CVR 5 0x0409 winnt 5.1 i386 MSG80BETA 8.0.0566 msmsgs [EMAIL PROTECTED] CVR 5 8.0.0566 8.0.0566 8.0.0566 http://msgr.dlservice.microsoft.com/download/4/5/b/45beb06f-5a08-4694-abd8-d6e706b06b68/Install_Messenger_Beta.exehttp://ideas.live.com\r\n USR 6 TWN I [EMAIL PROTECTED] USR 6 TWN S lc=1033,id=507,tw=40,fs=1,ru=http%3A%2F%2Fmessenger%2Emsn%2Ecom,ct=1062764229,kpp=1,kv=5,ver=2.1.0173.1,tpf=43f8a4c8ed940c04e3740be46c4d1619\r\n See? Every command line end with an \r\n but I dont know how to replicate this using Flex. The Socket class when i send \r\n always finishes the send command givin me and EOF (end of file error) in a window executing the app. And the XMLSocket commands are always terminated by a zero (0) byte. So, can someone give me some directions on how to do it? I was able to do it with PHP with ease as I was only sending strings... how to do it with Flex? Any help ppl? Thanks in advance, Michel.
re: [flexcoders] Flex 2 XML manipulation question
Dustyn, This should do it. private function testXML():void { var xml:XML = rootleveldetail/detail/levelleveldetail/detail/level/root var test:XML = xml.copy(); delete test..*.detail; trace(test.toXMLString()); } Ben Stucki --- We're Hiring! Seeking a passionate developer to join our team building Flex based products. Position is in the Washington D.C. metro area. If interested contact [EMAIL PROTECTED] From: iondisc [EMAIL PROTECTED] Sent: Thursday, February 15, 2007 7:33 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Flex 2 XML manipulation question Does anyone know a way to suppress/remove specific nodes from an XML/XMLList or XMLCollection? I have say this XML: root level detail /detail /level level detail /detail /level /root I want to make a copy of this XML (could be either of the three types of XML objects) and remove the detail nodes from every node no matter what hiarchy they are in. Thanks in advance, Dustyn Eskelson
RE: [flexcoders] Re: New to the group
Hi Pedro, Sorry about that. This should be the correct solution. idHTTPService.lastResult.record.(subject.(@id==c001).length()) Again, the important distinction between XPath and E4X is that E4X is essentially an object representation of the XML. Here are a few E4X rules that I've learned along the way, I'll probably try to expand on this more and make a post on it sometime. - All E4X statements will return an XMLList object. E4X with no results will return a blank XMLList object. - XMLList objects with only one child node can be treated as XML objects (which is why you would get results when records had only one child, but I don't think E4X statements should ever depend on this functionality). - Any filter (items in parenthesis) will be evaluated as a Boolean value inside the context of each child from the E4X to which it's applied. False results are filtered out. You can put anything in a filter really; it doesn't have to be more E4X. - Blank XMLList objects are still evaluated as true (non-null) in a filter (which is why I used the length() method, this way blank XMLList objects will return a length of 0 which evaluates as false). I think making a transition from XPath to E4X is probably harder than just learning E4X with no background, simply because developers have an expectation of syntax and functionality similar to XPath. There is some quirky behavior in comparison, but hopefully it's not that hard once you realize you're just working with XMLList objects. Ben Stucki - We're Hiring! Seeking a passionate developer to join our team building Flex based products. Position is in the Washington D.C. metro area. If interested contact [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] l.com _ From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Pedro Pastor Sent: Saturday, February 10, 2007 4:19 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Re: New to the group Hi Ben, Thank you very much for your response. Here you are my comments: 1) The = / == error is just a typing error in my e-mail. This symbol was properly set in my code. 2) I've tried your suggestion but it doesn't work. That query provides ALL the record elements in the XML tree. Using the very same code but removing the internal () for the (@id == c001) filter, it provides me with the matching record elements BUT only those having ONLY ONE subject children (and having @id = c001). 3) The point is I need to check (filter) at children level (subject) in order to get the appropriate parent node-set (record). That's very easy in XPath, but I'm getting quite confusing with E4X. I've been developing XML application form years, and I've been dealing with XML+XSLT+ . some other dynamic HTML technologies and I find Flex+ActionScript is a big step forward in the client web application realm, but the way ActionScript deals with XML is a bit deceiving. Best regards, Pedro --- In [EMAIL PROTECTED] mailto:flexcoders%40yahoogroups.com ups.com, Ben Stucki [EMAIL PROTECTED] wrote: Hey Pedro, Welcome to FlexCoders! I came into E4X with a background in XPath as well and think the biggest hurdle in learning E4X was understanding the methodology behind it. XPath is intended as a query language for XML. In contrast I think of E4X more like an object representation of XML. This means it can treat results a little differently based on the form of the XML , such as when you get results with only one subject node but not with multiple subject nodes. I've found that while I work with XPath from the top down, I get the best results from E4X when I check it from the inside out. Here's how the original query works out. idHTTPService.lastResult.record .( [EMAIL PROTECTED]c001) The inner most part is @id=c001. The main problem with this is that it uses the assignment (=) operator and not evaluation (==). This means that istead of looking for an id attribute value of c001, it's actually creating or overrideing the id attribute. So we'll change that to ==. idHTTPService.lastResult.record .( [EMAIL PROTECTED]c001) The next part to evaluate is [EMAIL PROTECTED]c001. The problem here is that while @id==c001 is meant as a filter, it's not in parenthesis. So we'll change that to subject.(@id==c001) . The rest works already, so here's the end result. idHTTPService.lastResult.record .( subject.(@id==c001)) It takes a little getting used to, but I've found that E4X can normally handle what I need it to do. Ben Stucki
re: [flexcoders] New to the group
Hey Pedro, Welcome to FlexCoders! I came into E4X with a background in XPath as well and think the biggest hurdle in learning E4X was understanding the methodology behind it. XPath is intended as a query language for XML. In contrast I think of E4X more like an object representation of XML. This means it can treat results a little differently based on the form of the XML , such as when you get results with only one subject node but not with multiple subject nodes. I've found that while I work with XPath from the top down, I get the best results from E4X when I check it from the inside out. Here's how the original query works out. idHTTPService.lastResult.record .( [EMAIL PROTECTED]c001) The inner most part is @id=c001. The main problem with this is that it uses the assignment (=) operator and not evaluation (==). This means that istead of looking for an id attribute value of c001, it's actually creating or overrideing the id attribute. So we'll change that to ==. idHTTPService.lastResult.record .( [EMAIL PROTECTED]c001) The next part to evaluate is [EMAIL PROTECTED]c001. The problem here is that while @id==c001 is meant as a filter, it's not in parenthesis. So we'll change that to subject.(@id==c001) . The rest works already, so here's the end result. idHTTPService.lastResult.record .( subject.(@id==c001)) It takes a little getting used to, but I've found that E4X can normally handle what I need it to do. Ben Stucki -- We're Hiring! Seeking a passionate developer to join our team building Flex based products. Position is in the Washington D.C. metro area. If interested contact [EMAIL PROTECTED] From: Pedro Pastor [EMAIL PROTECTED] Sent: Friday, February 09, 2007 6:26 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] New to the group Hello to all of you. I have just entered this group. I am quite new to those technologies (Flex 2 and ActionScript 3). After reading some documentation I'm doing some practising and I have some questions to this community. 1) E4X query language: I'm used to work with XPath for dealing with XML structures. I've tried to do some (not very complicated) queries using E4X BUT it seems like E4X doesn't work the same way (and it is far from fulfilling the XML queries needs). For example, given the following XML date: ROOT record data. /data subject id=c001/name subject id=c002BB/name subject id=c003CCC/name /record record data. /data
Re: [flexcoders] Re: StartDrag() versus DragManager.doDrag()
Generally speaking, I believe that the DragManager is intended for open drag and drop operations where an item might have a target to be dropped into (such as dragging a file into a folder). The startDrag and stopDrag methods are equally as important, but are better suited for constrained or custom drag operations where the drag must be within a container or follow a set path (such as dragging a playhead across the track of an mp3 or video player). Custom dragging is great for creating unique user interfaces and custom components. Ben Stucki - We're Hiring! Seeking a passionate developer to join our team building Flex based products. Position is in the Washington D.C. metro area. If interested contact [EMAIL PROTECTED] From: Daniel Freiman [EMAIL PROTECTED] Sent: Friday, February 09, 2007 7:59 AM To: flexcoders@yahoogroups.com Subject: Re: [flexcoders] Re: StartDrag() versus DragManager.doDrag() I can't speak to Adobe's intent, but I regularly avoid startDrag because I need more fine control over the drag. For example if you want to program a drag that implements snap to functionality, you're going to want to have direct control over the placement of the object, instead of letting the player handle it. As I said, I don't know why Adobe did it in this case, but here's an example of why someone might want to do it somewhere. - Dan On 2/9/07, Derrick Grigg [EMAIL PROTECTED] wrote: I can't find anywhere that we use startDrag()in the framework, including in the DragManager. My bad, you know what they say about 'assuming'. Just did some more digging, in the DragProxy class and was very surprised to see that it actually uses a mouse move event listener and then repositions the drag proxy based on the the x/y of the mouse. var pt:Point = new Point(); var point:Point = new Point(event.localX, event.localY); point = DisplayObject(event.target).localToGlobal(point); point = DisplayObject(dragInitiator.systemManager.topLevelSystemManager).globalToLocal(point); var mouseX:Number = point.x; var mouseY:Number = point.y; x = mouseX - xOffset; y = mouseY - yOffset; This just begs the question, why??? Why go through all that instead of just using the startDrag that is a core method of the Sprite class? Just to offset the DragProxy slightly from the mouse pointer? I don't get it, why bloat (in my opinion) the code. From my understanding classes and methods that are actually compiled into the flash plugin (ie the flash.* package) run faster than those that are not (ie. the mx.* package). I don't understand why all the extra code is required to accomplish something the plugin already has the ability to do.
re: [flexcoders] Change Button Icon Programatically
Is there a way to change a button icon programmatically? Yes, using the setStyle method. ?xml version=1.0? !-- skins/EmbedWithSetStyle.mxml -- mx:Application xmlns:mx=http://www.adobe.com/2006/mxml; initialize=init() mx:Script![CDATA[ [Embed(../assets/orb_over_skin.gif)] public var os:Class; [Embed(../assets/orb_down_skin.gif)] public var ds:Class; [Embed(../assets/orb_up_skin.gif)] public var us:Class; private function init():void { b1.setStyle(upSkin,us); b1.setStyle(overSkin,os); b1.setStyle(downSkin,ds); } ]]/mx:Script mx:Button label=Click Me id=b1/ /mx:Application Is there a way to change a button icon with an image loaded at runtime (non-embedded). There's no easy way, but if that's what you're looking for send me an email and I'll send you some code to try. I'll probably blog about a solution for this soon. Ben Stucki --- We're Hiring! Seeking a passionate developer to join our team building Flex based products. Position is in the Washington D.C. metro area. If interested contact [EMAIL PROTECTED] From: richmcgillicuddy [EMAIL PROTECTED] Sent: Tuesday, February 06, 2007 8:57 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] Change Button Icon Programatically is there a way to do this? Rich
Re: [flexcoders] Intellectual property or licensing of posted/blogged work
Dan, That's one of the best descriptions of copyrights and licensing I've seen in a while. I used to release code under Creative Commons, but I am now recommending the MIT license to anyone releasing code. It's short, legally sound and widely accepted. Here's the link. http://www.opensource.org/licenses/mit-license.php P.S. Engkee, I've got an updated Reflection component being released under the MIT license soon. Working on the examples now. Ben Stucki -- We're Hiring! Seeking a passionate developer to join our team building Flex based products. Position is in the Washington D.C. metro area. If interested contact [EMAIL PROTECTED] From: Daniel Freiman [EMAIL PROTECTED] Sent: Tuesday, February 06, 2007 3:59 PM To: flexcoders@yahoogroups.com Subject: Re: [flexcoders] Intellectual property or licensing of posted/blogged work As for copyrights vs. licenses If you own the code (which if you wrote it you probably do), then you own the copyright. A license is simply giving someone permission (limited or otherwise) to use the copyrighted material. If you give the copyright to the public domain, then no one owns the copyright and thus there is no reason why someone would have to license the copyrighted material. As far as practices and standards for people like us, we can talk the issue into the ground on what we want, but the bottom line is that if there's no licensing statement with the code, people aren't safe using it (legally speaking). If you want to be nice, include one. If you're paranoid, email the author. Lastly, you don't need to be a lawyer to write a license, especially if it's really simple. For example, if you want to let people use code as they see fit, simply state in plain English (or any other language for that matter) something like You can use this for anything or I give this to the public domain. If you're paranoid you could include, I am not responsible for any harm this code does to your computer. Done and done, no lawyer or standard needed. Lastly, if you're employed by a company you might not have the right to give the copyright or licenses because (usually) anything you write on company time is owned by the company. (Don't ask me to define on company time.) This is sometimes also true for freelance work, but not usually. Personally, I'd say look for the licenses, state what you want your code used for in layman's terms or use a standard, and email the author if you're confused. - Dan On 2/6/07, Jason Hawryluk [EMAIL PROTECTED] wrote: I willing to do that creative commons license if it makes people feel more comfortable. I'll have a look and see what's involved. I fully understand the requirement to protect yourself. Very good topic that I have to date just taken for granted. I just always assumed that if I put it out there it's yours to do with as you wish. I'd hate for people *not* to use this stuff for these kinds of reasons, it goes against why I write about it in the first place. Jason-Message d'origine- De : flexcoders@yahoogroups.com [mailto: [EMAIL PROTECTED] la part de engkee Envoyé : mardi 6 février 2007 21:31 À : flexcoders@yahoogroups.com Objet : [flexcoders] Intellectual property or licensing of posted/blogged work I have to commend you all for posting a lot of wonderful components and extensions to Flex... eg. Ely's calendar, Doug and Jason's tab navigator extensions, Ben and Trey's reflection effect, Alex's distortion effect, just to name a few. Unfortunately, in these day and age, I would have to ask... am I allowed to incorporate those wonderful works in commercial products? Am I even allowed to look at the source code, if I work for a company producing commercial software, without violating some IP issues. Most of them are not explicitly associated with any specific licensing terms. Sure would be nice if there could be some standard practice of associating these works with a common license, eg. the Creative Commons (http://creativecommons.org/licenses/by/2.5/) Maybe there already is some presumed license or disclaimer for published works. If so, please send a pointer. Just a thought. -Engkee
Re: [flexcoders] MouseUpSomewhere event, whence hast thou gone?
Douglas, The method Michael is talking about should work fine for you. Although the listener is on the whole app, the function called is still scoped to your component. You really don't want to use the mouseOff event to stop dragging, as users will find that annoying to no end. Here's an example component that should make it a little more clear. ?xml version=1.0 encoding=utf-8? mx:Canvas xmlns:mx=http://www.adobe.com/2006/mxml; horizontalScrollPolicy=off verticalScrollPolicy=off mx:Script ![CDATA[ private function mouseDownHandler(event:MouseEvent):void { button.startDrag(false, new Rectangle(rule.x,rule.y+rule.height/2-button.height/2, rule.width-button.width, 0)); systemManager.addEventListener(MouseEvent.MOUSE_UP, mouseUpHandler, false, 0, true); } private function mouseUpHandler(event:MouseEvent):void { systemManager.removeEventListener(MouseEvent.MOUSE_UP, mouseUpHandler, false); button.stopDrag(); } ]] /mx:Script mx:HRule id=rule left=0 right=0 height=3 verticalCenter=0 / mx:RadioButton id=button selected=true mouseDown=mouseDownHandler(event) top={rule.y+rule.height/2-button.height/2} height=13 width=13 / /mx:Canvas Ben Stucki --- We're Hiring! Seeking a passionate developer to join our team building Flex based products. Position is in the Washington D.C. metro area. If interested contact [EMAIL PROTECTED] From: Douglas Knudsen [EMAIL PROTECTED] Sent: Monday, February 05, 2007 12:18 PM To: flexcoders@yahoogroups.com Subject: Re: [flexcoders] MouseUpSomewhere event, whence hast thou gone? that adds a mouseUp listener/handler for the whole app, eh? How do I know if this mouseUp is related to the object the user gestured a mouseDown on? Kind of coupled up too. What I have is this screen snap http://www.cubicleman.com/snaps/snap.png I have mouseDown capture on the bluish color box that allows me to drag it left/right and to shrink/expand the length of it while holding the mouse button down on it. Now, if the user is holding the mouse button down and accidentally moves the mouse off of the bluish box and then lets the mouse button go, I want to fire a event then that executes a method inside the component representing the bluish box. Starting to think maybe just fire the mouseOut event and ignore this possible user accident! DK On 2/5/07, Michael Schmalle [EMAIL PROTECTED] wrote: Hi, try adding a listener to the systemManager; IE systemManager.addEventListener(MouseEvent.MOUSE_UP, systemManager_mouseUpHandler); Peace, Mike On 2/5/07, Douglas Knudsen [EMAIL PROTECTED] wrote: I'm converting a Flex 1.5 app to 2.0. Under 1.5 I used a event on a HBox called MouseUpSomewhere. Seems this is no more in 2.0. Any ideas what it is now called? Or maybe another way to get this same functionality to work? I can't use mouseOut. I need a event that fires when the user releases the mouse button whilst over a different component. -- Douglas Knudsen http://www.cubicleman.com this is my signature, like it? -- Teoti Graphix http://www.teotigraphix.com Blog - Flex2Components http://www.flex2components.com You can find more by solving the problem then by 'asking the question'. -- Douglas Knudsen http://www.cubicleman.com this is my signature, like it?
re: [flexcoders] Can we display *.bmp and *.tiff images at runtime from a flex application?
bmp and tiff images aren't supported natively by Flex. It is entirely possible to parse the bytes coming from the stream and draw the image in code. I should have a descent example out for doing that with bmp this month, but probably won't play with rendering TIFF for quite a while. It's a considerably more complex format. From: paromitadey [EMAIL PROTECTED] Sent: Tuesday, January 30, 2007 3:23 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] Can we display *.bmp and *.tiff images at runtime from a flex application? Hi All, Need help in displaying *.bmp / *.tiff images at runtime. I am working in an application where the user may upload images (jsp) in any format (jpg/gif/png/bmp/tif) and I need to display these images from an user interface built in Flex with zoom effects. I am getting the images as image byte-stream which are returned by a java servelet call. I am able to display jpg/gif/png using the standard Image control but unable to display the bmp and tiff files. Is there any way to display tiff and bmp files? Any control or any property of the image control that needs to be configured to allow bmp / tiff image display ? Please help. Regards, Paromita
re: [flexcoders] FlexManiacs 2007 Session Topics Posted
Steve, Thank you. I'm glad to be a part of this conference. I have included the requested information below along with a modified proposal for a hands on session. Please let me know if you have any questions. Thank you. Please email a 1-2 paragraph biography to [EMAIL PROTECTED] that highlights your experience with Flex so that we may post it to the conference web site. Ben Stucki is a Software Engineer at Atellis , a Washington, D.C. based firm that specializes in developing Rich Internet Applications and products. As part of the core development team at Atellis, Ben mixes his knowledge of back-end application development and interactive user interfaces to engineer next generation Flex applications and components. Ben is also an active member of the Flex community, has contributed to published works, and maintains a weblog devoted to Flash and Flex application development at http://blog.benstucki.net/. Also, please specify in your email your top 2 choices for airports to fly to DC. Fig Leaf will make all of your travel reservations for the conference. I will not require a flight, as I live in the D.C. area. While we have filled all available lecture spots, we still need speakers for several hands-on seminars. Please let us know if you can modify your presentation for a hands-on audience. I would like to offer a toned down version of my Working with Binary Files in Apollo session proposal as a hands on session. I have been given permission to make mention of Apollo in the description and believe that this would be a very popular session due to the buzz that's likely to be around Apollo at that time. I feel confident that I can guide all attendees through the basics of parsing an example file with embedded images (which is not as complicated as it sounds), while making them comfortable with the File IO and ByteArray APIs. I'll also be showing some cool demonstration apps to keep things exciting and show how useful this knowledge is. I have included the proposal below. Please let me know if you have any questions and thank you for your consideration. Working with Binary Files in Apollo Adobe's Flex 2 framework introduced developers to ActionScript 3 and a totally revamped runtime which gives them unprecedented access to byte level information. With the introduction of Adobe Apollo this access is being extended to the desktop, including the ability to read and write local files. In this hands-on session Ben will guide attendees through reading binary data using the ByteArray class in Flex 2, from the ones and zeros to an entire file, and give an overview of the file API introduced in Apollo. Attendees will learn how to read information from an existing file format and understand best practices for creating their own custom files using ActionScript 3 and the Flex framework. Ben Stucki Software Engineer Atellis, Inc. From: Steve Drucker [EMAIL PROTECTED] Sent: Monday, January 29, 2007 10:14 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] FlexManiacs 2007 Session Topics Posted Check 'em out at http://flex2conference.figleaf.com/sessions/index.cfm! Regards, Steve Drucker CEO Fig Leaf Software www.figleaf.com
RE: [flexcoders] Custom Context Menus
The context menus are probably a special case, as they are quite obviously rendered by the OS. Windows has context icons and submenus, but do older Mac and Linux versions have these features? I dont know for sure, but Im guessing not every targeted OS has these. Its a critical goal that flash works consistently across all platforms. In a few cases like this it means going with the lowest common denominator. From: flexcoders@yahoogroups.com [mailto:flexcoders@yahoogroups.com] On Behalf Of Michael Schmalle Sent: Friday, June 30, 2006 6:19 PM To: flexcoders@yahoogroups.com Subject: Re: [flexcoders] Custom Context Menus but i don't see any reason for not allowing icons and submenus! HAHA I don't either but... Hey, have you used Flash? We have been asking for this for years man! You have to keep nagging the Flash Player team! Peace, Mike On 6/30/06, Pottavathini, Sathish [EMAIL PROTECTED] wrote: I understand #1, but i don't see any reason for not allowing icons and submenus! -Original Message- From: flexcoders@yahoogroups.com [mailto:flexcoders@yahoogroups.com]On Behalf Of Michael Schmalle Sent: Friday, June 30, 2006 1:46 PM To: flexcoders@yahoogroups.com Subject: Re: [flexcoders] Custom Context Menus Simply put; No and No. These have been asked for for along time but there is the line and you hit. You also cannot remove the About menu item, which is required so that users can find out what version of Flash Player they are using. Sorry :) Peace, Mike On 6/30/06, Jeremy Rottman [EMAIL PROTECTED] wrote: I am working on a real estate transaction app, done in flex/cf. To stream line things and to make it a little eaiser to get the data the admins want, I am using a custom context menu on my data grids. I have run into something I dont really conside a problem, but it is something I would like to do. I have already created my context menu, and it works just fine. Two things I would like to do is: 1. Remove the Settings menuitem and remove the About Adobe Flash player 9 menu item. I have an inkling that the poeple using it might confuse those with somehting else. Can this even be done? 2. I would also like to add small icons next to the menu items to give it a nice look and feel. I have searched the live docs and cant seem to find this. Any help with this would also be greatly appreciated. Here is the code I am using. import flash.ui.*; import flash.events.*; import mx.controls.dataGridClasses.*; import mx.controls.Alert; //-- //*HANDLE LISTING SEARCH CONTEXT MENU** // SET CONTEXT MENU VAR private var listSearchM:ContextMenu; private function applyContextMenu(){ createListingMenu(); listingSearchDG.contextMenu = listSearchM; } private function createListingMenu(){ listSearchM = new ContextMenu(); listSearchM.addEventListener(menuSelect, menuSelectHandler); listSearchM.hideBuiltInItems(); var customContextArray:Array = new Array(); var newList:ContextMenuItem = new ContextMenuItem(Create New Listing); newList.addEventListener(menuItemSelect, newListHandler); var conClose:ContextMenuItem = new ContextMenuItem(Convert To Closing); conClose.addEventListener(menuItemSelect, conCloseHandler); var conRental:ContextMenuItem = new ContextMenuItem(Convert to Rental); conRental.addEventListener(menuItemSelect, conRentalHandler); var canList:ContextMenuItem = new ContextMenuItem(Cancel Listing); canList.addEventListener(menuItemSelect, canListHandler); customContextArray.push(newList); customContextArray.push(conClose); customContextArray.push(conRental); customContextArray.push (canList); listSearchM.customItems = customContextArray; } private function menuSelectHandler(event:ContextMenuEvent):void { var renderer:DataGridItemRenderer = DataGridItemRenderer(event.mouseTarget); trace(rowIndex: + renderer.listData.rowIndex); trace(columnIndex: + DataGridListData(renderer.listData).columnIndex); } // TEST HANDLERS private function newListHandler(){ Alert.show(You have selected to create a new list) } private function conCloseHandler(){ Alert.show(You have selected to Convert to a Closing) } private function conRentalHandler(){ Alert.show(You have selected to Convert to a Rental) } private function canListHandler(){ Alert.show(You have selected to Cancel a listing) } -- What goes up, does come down. -- What goes up, does come down. __._,_.___ -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com SPONSORED LINKS Web site design development Computer software development Software design and
RE: [flexcoders] Help Loading ByteArray into Image
I created a work around for this issue in my recent ID3Stream Example. Its not the ideal solution, but it works. http://blog.benstucki.net/?id=24 http://lab.benstucki.net/archives/id3streamexplorer/srcview/ From: flexcoders@yahoogroups.com [mailto:flexcoders@yahoogroups.com] On Behalf Of Tim Scollick Sent: Tuesday, May 30, 2006 5:41 PM To: flexcoders@yahoogroups.com Subject: Re: [flexcoders] Help Loading ByteArray into Image Ah sorry--I misundersood. The best solution that I can come up with for that is to send the jpg data to the server and load it from there. I've done that with PNG and it works. It seems kind of laborious to round trip it. There must be a better way! On 5/30/06, mail [EMAIL PROTECTED] wrote: Tim, thank you forthe quick response. The problem with image.source and image.load is that I don't have a physical file to point to (both are expecting a URL). I have used the ByteArray to extract jpg bytesfrom an MP3's ID3 taginternally in Flex. I can then load this ByteArray into Loader.loadBytes, but I'm unsure where to go from there. From: Tim Scollick [EMAIL PROTECTED] Sent: Tuesday, May 30, 2006 1:04 PM To: flexcoders@yahoogroups.com Subject: Re: [flexcoders] Help Loading ByteArray into Image I think that you want to look at image.source and image.load. On 5/30/06, mail [EMAIL PROTECTED] wrote: What is the best way to get a ByteArray into an Image (or similar UIComponent) in AS3? I'm workingon some classes that extract the album art from an MP3 file. I'm able to load theresultingByteArray into a Loader and then use myImage.addChild(myLoader). The album art displays which is awesome, but the image doesn't recognize the child as it's content. Any suggestions? -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com SPONSORED LINKS Web site design development Computer software development Software design and development Macromedia flex Software development best practice YAHOO! GROUPS LINKS Visit your group flexcoders on the web. To unsubscribe from this group, send an email to: [EMAIL PROTECTED] Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service . -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com SPONSORED LINKS Web site design development Computer software development Software design and development Macromedia flex Software development best practice YAHOO! GROUPS LINKS Visit your group flexcoders on the web. To unsubscribe from this group, send an email to: [EMAIL PROTECTED] Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service . -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com SPONSORED LINKS Web site design development Computer software development Software design and development Macromedia flex Software development best practice YAHOO! GROUPS LINKS Visit your group "flexcoders" on the web. To unsubscribe from this group, send an email to:[EMAIL PROTECTED] Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
RE: [flexcoders] Audio Visualization Component Help
Manish, Thanks for the awesome help. The main thing I was trying to gain from extending the Canvas was the borders and background control. I was going to extend directly off of UIComponent and let the user surround it in whatever container they wanted, but I thought this might save them the trouble. Is it costing significantly more in load time to extend off of Canvas? Also, thanks for all the time you spend on this list. From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Manish Jethani Sent: Thursday, May 04, 2006 7:18 AM To: flexcoders@yahoogroups.com Subject: Re: [flexcoders] Audio Visualization Component Help On 5/4/06, Ben Stucki [EMAIL PROTECTED] wrote: I'm looking for some feedback and help on my audio visualization component. Specifically, I'd like to know the best way to handle color and alpha properties from both nonInherited and style rules. Any suggestions for better property/component naming and general tips to improve performance (perhaps all the looped var declarations should be declared in the class scope)? http://blog.benstucki.net/?id=18 Comments: 1. Unless you want to be able to add children in MXML, use percent-sizes (width=x%) and contraints-based layout, there's no need to extend Canvas. You could just extend UIComponent directly. 2. Children should be created and added in 'createChildren' rather than the constructor. 3. The call to the superclass constructor is redundant (thanks to Mr. Bruce Eckel for pointing this one out :) ) 4. Use 'getStyle' to fetch the value of a style. You should never have to access the 'nonInheritingStyles' variable directly. 5. There's no need for a 'lineColor' property. You can directly set the 'lineColor' style; you can also bind to it in MXML. 6. I don't think you'd gain much by declaring variables at the class level. -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com SPONSORED LINKS Web site design development Computer software development Software design and development Macromedia flex Software development best practice YAHOO! GROUPS LINKS Visit your group "flexcoders" on the web. To unsubscribe from this group, send an email to:[EMAIL PROTECTED] Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
[flexcoders] Audio Visualization Component Help
Im looking for some feedback and help on my audio visualization component. Specifically, Id like to know the best way to handle color and alpha properties from both nonInherited and style rules. Any suggestions for better property/component naming and general tips to improve performance (perhaps all the looped var declarations should be declared in the class scope)? http://blog.benstucki.net/?id=18 -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com SPONSORED LINKS Web site design development Computer software development Software design and development Macromedia flex Software development best practice YAHOO! GROUPS LINKS Visit your group "flexcoders" on the web. To unsubscribe from this group, send an email to:[EMAIL PROTECTED] Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.