[flexcoders] Re: How can I have my class return an ArrayCollection?
If you are having problems with it giving you a null object before the ResultEvent function is called then make a function that returns an empty ArrayCollection if it is currently null. Perhaps function getServiceArray( ):ArrayCollection { if( this.serviceArray == null ) { this.serviceArray = new ArrayCollection(); } return this.serviceArray(); } If that isn't what you are having problems with, perhaps more specificity could help us help you. --- In flexcoders@yahoogroups.com, - - wrote: > > I tried that but it returns an empty ArrayCollection because it's only > created within the ResultEvent Function once the HTTPService is successful... > > Thanks. > > > > > > From: valdhor > To: flexcoders@yahoogroups.com > Sent: Wednesday, April 8, 2009 11:20:44 AM > Subject: [flexcoders] Re: How can I have my class return an ArrayCollection? > > > Umm.. Add a public function that returns serviceArray ? > > --- In flexcod...@yahoogro ups.com, "sailorsea21" wrote: > > > > Hi everyone, > > how can I have this following class return me an ArrayCollection whenever I > > call it > > > > [Bindable] > > public class Services > > { > > public var serviceArray: ArrayCollection; > > public var serviceXML:XML; > > > > public function getServices( ):void > > { > > var service:HTTPService = new HTTPService( ); > > service.url = "test.php"; > > service.useProxy = false; > > service.method = "POST"; > > service.resultForma t = "e4x"; > > service.showBusyCur sor = true; > > service.addEventLis tener(ResultEven t.RESULT, > > function (event:ResultEvent) :void > > { > > serviceArray = new ArrayCollection( ); > > serviceXML = event.result as XML; > > var ourxml:XML; > > for each(ourxml in serviceXML.elements ()) serviceArray. addItem(ourxml) ; > > } > > ); > > service.send( ); > > } > > } > > >
[flexcoders] Re: Type Coercion error in a Popup module
Glad to channel Alex Harui's old posts, since I've been using it since he wrote it. By the way, the same thing works well in an MDIWindow setup as well. But that only helps if you are using FlexMDI in FlexLib http://code.google.com/p/flexlib/ --- In flexcoders@yahoogroups.com, "hr1ny" <[EMAIL PROTECTED]> wrote: > > Thanks! That is just what I needed. > --Henry > > --- In flexcoders@yahoogroups.com, "actionscript_czar" > wrote: > > > > Alex would probably be recommending extending TitleWindow in a way > > that allows you to use it as a top level module. > > > > See this: http://blogs.adobe.com/aharui/2007/08/ > > popup_dialogs_as_modules.html > > > > --- In flexcoders@yahoogroups.com, "hr1ny" wrote: > > > > > > Gregor, > > > Thanks for your post. I agree with you that Alex's blog contains > > the > > > relevant info. I did move the popup module's Event classes into > > the > > > parent app, and the problem of Type Coercion goes away (though I'd > > > rather find a solution that did not require this). But one other > > > aspect of Alex's recommendation mystifies me. > > > > > > He recommends putting the TitleWindow inside the Module, like > this: > > > > > > > > > > > > ... > > > > > > > > > > > > > > > but if I do this, and use PopUpManager.addPopUp() to raise this > > > object, it is not draggable. > > > I think to have a draggable popup window, it needs to inherit from > > > TitleWindow. Yet that approach is the one he disparaged. So I'm > > not > > > sure how to resolve it. > > > --Henry R. > > >
[flexcoders] Re: Type Coercion error in a Popup module
Alex would probably be recommending extending TitleWindow in a way that allows you to use it as a top level module. See this: http://blogs.adobe.com/aharui/2007/08/ popup_dialogs_as_modules.html --- In flexcoders@yahoogroups.com, "hr1ny" <[EMAIL PROTECTED]> wrote: > > Gregor, > Thanks for your post. I agree with you that Alex's blog contains the > relevant info. I did move the popup module's Event classes into the > parent app, and the problem of Type Coercion goes away (though I'd > rather find a solution that did not require this). But one other > aspect of Alex's recommendation mystifies me. > > He recommends putting the TitleWindow inside the Module, like this: > > > > ... > > > > > but if I do this, and use PopUpManager.addPopUp() to raise this > object, it is not draggable. > I think to have a draggable popup window, it needs to inherit from > TitleWindow. Yet that approach is the one he disparaged. So I'm not > sure how to resolve it. > --Henry R.
[flexcoders] Re: Cairngorm AMFPHP Problem
Can you either get rid of the arguments in the constructor or set defaults ( probably to empty strings )? --- In flexcoders@yahoogroups.com, "creativepragmatic" <[EMAIL PROTECTED]> wrote: > > It does. Here is the class. > > [RemoteClass(alias="com.xtremesecurity.security.vo.UserVO")] > [Bindable] > public class UserVO implements ValueObject > { > public var id:int; > public var email:String; > public var username:String; > public var lastIP:String; > public var password:String; > public var level:int; > > public function UserVO(email:String, password:String) > { > this.email = email; > this.password = password; > } > } > > > > > --- In flexcoders@yahoogroups.com, "actionscript_czar" > wrote: > > > > Does the UserVO constructor require arguments? If it does can you > > set defaults? > > > > --- In flexcoders@yahoogroups.com, "creativepragmatic" > > wrote: > > > > > > Hello, > > > > > > I am trying to convert an existing Flex/AMFPHP app to Cairngorm > but > > am > > > having trouble returning value objects from PHP. > > > > > > public function login($userVO) > > > { > > > $user = new UserVO(); > > > > > > // yada yada yada, user authenticated, logged and full > > details > > > received > > > > > > $user->id = pg_fetch_result($result, 0, "id"); > > > $user->email = pg_fetch_result($result, 0, "email"); > > > $user->username = pg_fetch_result($result, 0, "name"); > > > $user->lastIP = pg_fetch_result($result, 0, "last_ip"); > > > $user->password = pg_fetch_result($result, 0, > "passhash"); > > > $user->level = pg_fetch_result($result, 0, "level"); > > > > > > return $user; > > > } > > > > > > Here is the error I get from Flash Player: > > > > > > ArgumentError: Error #1063: Argument count mismatch on ... > > > vo::UserVO(). Expected 2, got 0. > > > > > > > > > Here is what I get from the fault handler: > > > > > > Didn't receive an acknowledged message. > > > > > > Was expecting mx.messaging.messages.AcknowledgeMessage, but > > > received null. > > > > > > > > > Hopefully, what I am doing will be painfully obvious to someone. > > > > > > Thank you in advance for any help, > > > > > > Orville > > > > > >
[flexcoders] Re: Cairngorm AMFPHP Problem
Does the UserVO constructor require arguments? If it does can you set defaults? --- In flexcoders@yahoogroups.com, "creativepragmatic" <[EMAIL PROTECTED]> wrote: > > Hello, > > I am trying to convert an existing Flex/AMFPHP app to Cairngorm but am > having trouble returning value objects from PHP. > > public function login($userVO) > { > $user = new UserVO(); > > // yada yada yada, user authenticated, logged and full details > received > > $user->id = pg_fetch_result($result, 0, "id"); > $user->email = pg_fetch_result($result, 0, "email"); > $user->username = pg_fetch_result($result, 0, "name"); > $user->lastIP = pg_fetch_result($result, 0, "last_ip"); > $user->password = pg_fetch_result($result, 0, "passhash"); > $user->level = pg_fetch_result($result, 0, "level"); > > return $user; > } > > Here is the error I get from Flash Player: > > ArgumentError: Error #1063: Argument count mismatch on ... > vo::UserVO(). Expected 2, got 0. > > > Here is what I get from the fault handler: > > Didn't receive an acknowledged message. > > Was expecting mx.messaging.messages.AcknowledgeMessage, but > received null. > > > Hopefully, what I am doing will be painfully obvious to someone. > > Thank you in advance for any help, > > Orville >
[flexcoders] Re: extend titlewindow ?
FlexMDI is now ( and has been ) a part of FlexLib. (http://code.google.com/p/flexlib/) --- In flexcoders@yahoogroups.com, "valdhor" <[EMAIL PROTECTED]> wrote: > > Check out FlexMDI (http://code.google.com/p/flexmdi/) > > > --- In flexcoders@yahoogroups.com, "greg_knight_66" wrote: > > > > > > hi all, > > > > i am looking for an example illustrating how to extend/modify the > > header of the titlewindow. im assuming this is possible? > > specifically, i am looking to add a minimize button. > > > > thanks for your help. > > > > greg > > >
[flexcoders] Re: how do I launch an exe from flex/air?
For now AIR ( and definately not Flex Web ) projects can't do that natively. You should look at the merapi project. http://www.merapiproject.net/ --- In flexcoders@yahoogroups.com, "makeflex" <[EMAIL PROTECTED]> wrote: > > I have tried fscommand but it didnt work. any help would be greatly > appreciated. >
[flexcoders] Re: I'm trying to get a value from 1 array based off the ID in another.
Assuming that rankgradeID is the index of another array it would be easy rankGrade = model.rankArray [model.student.RANKGRADEID].RANKABBRIVIATION; Otherwise you might look into using a dictionary rather than a simple array. Then, the code above would work as long as model.rankTable used RANKGRADEID values as its key. --- In flexcoders@yahoogroups.com, "jason_graves2003" <[EMAIL PROTECTED]> wrote: > > > Something like this. > > rankGrade = model.rankArray.RANKABBRIVIATION where > model.rankArray.RANKGRADEID = model.student.RANKGRADEID > > I'm sure this is simple, but I'm at a loss. >
[flexcoders] Re: Flex Builder Professional
I have FlexBuilder 3 running standalone that I use instead of installing eclipse. I use Mylyn with it but instead of Mantis we use Jira and it seems to work fine. As for eclipse version, mine says eclipse is version 3.3.1, but then again I've used the update mechanism to... well... update it. --- In flexcoders@yahoogroups.com, "George" <[EMAIL PROTECTED]> wrote: > > Which version of Eclipse is delivered with Flex Builder Professional, > and has anyone used the capabilities of MyLyn and Mantis with Flex > Builder? >
[flexcoders] Re: protecting swc?
First of all, if you don't distribute the source code with your SWC file most people won't see it. You probably saw it because you have the library linked ( even if it was closed ) or the source files linked to the SWC build path. Secondly, SWC and SWF files can be easily decompiled using a tool like Buraks Actionscript Viewer. This however does not limit your rights as the creator of the code, it just means people can get to it. Most people won't though as they have better things to do and projects to get done. Some will though and it may or may not be worth the extra effort( think ROI ) to attempt to stop them. I think this is the reason that some companies offer to send the source as well ( but limit your priveleges with the source in the license ) for a premium over the price of just the component alone. This might be smarter. It gives people a legal way to get the source for your components so they can push your components past their initial design constraints while giving you more cash for your work. Ultimately the decision is up to you. --- In flexcoders@yahoogroups.com, "ahmad_eldardiry" <[EMAIL PROTECTED]> wrote: > > I forgot to mention that when I pressed the debug button, a dialogue > box showed with a "This file is not inside a project, many Flex > builder features will be disabled" message. > > Thank you. > > > > --- In flexcoders@yahoogroups.com, "ahmad_eldardiry" > wrote: > > > > I'm a flex beginner, and I'm making a flex component (.swc) and I want > > to sell it. While I was testing it within an AIR application on Flex > > Builder 3, an error ocurred, so I thought I can use the debugger (It > > works well on Flex compiler). > > > > When I did try to debug the application, the debugger actualy > > decompressed the output swf and opened one of the classes contained > > inside my .swc to point to the line having the error!!! > > > > So, now I can see my source code (not to mention the variables and > > objects listing inside the variables tab) inside the so thought > > 'protected' .swc, without any external decompiler, but within the Flex > > builder 3 itself! > > > > When I googled about it, I found only this similar note: > > > > > http://clintm.esria.com/2007/05/11/linking-source-code-to-a-swc-in- flexbuilder/ > > > > If I was to sell this .swc, anybody can see my source code that way, > > so is there any solution for this issue? Has anybody faced something > > similar? Or is it even a known fact? > > > > How can someone protect his flex components from flex builder debugger? > > > > Thank you. > > >
[flexcoders] Re: The end of ActionScript 3 as an EcmaScript 4 implementation
Now that I've had time to think about this, it seems like it could really be a good thing. Adobe chose to link itself to the ECMAscript4 standard and from many responses I've read it guided their decisions on whether or not to do things ( private constructors anyone? ). Perhaps now Actionscript can move in a new direction that allows some things that weren't going to be in the ES4 standard. Perhaps actionscript will link itself with some other future standard. The possibilities are plentiful. --- In flexcoders@yahoogroups.com, "hank williams" <[EMAIL PROTECTED]> wrote: > > On Thu, Aug 14, 2008 at 1:39 PM, Johannes Nel <[EMAIL PROTECTED]> wrote: > > annotations, packages what else? > > > > We dont know precisely, but Brendan Eich is telegraphing that it is > big steps backwards by saying the following: > > 1. Focus work on ES3.1 with full collaboration of all parties, and > target two interoperable implementations by early next year. > 2. Collaborate on the next step beyond ES3.1, which will include > syntactic extensions but which will be more modest than ES4 in both > semantic and syntactic innovation. > 3. Some ES4 proposals have been deemed unsound for the Web, and are > off the table for good: packages, namespaces and early binding. This > conclusion is key to Harmony. > 4. Other goals and ideas from ES4 are being rephrased to keep > consensus in the committee; these include a notion of classes based > on existing ES3 concepts combined with proposed ES3.1 extensions. > > > To me #4 the idea that classes work "the old way" is also a big deal, > though exactly what that means I am not entirely sure. AS3 changed its > class model in what I think was a good way. I'd hate to go back. > > Hank >
[flexcoders] Re: download files
While I don't believe there is a single method to do this, I think you could do this with an array of FileReference objects. Each time a file completes downloading go on to the next object in the array and download it. As to the usability of having someone select a save location for every file, not much you can do there. Another, more complicated option, is create a way for the server to dish up a zip file that all the files they want to download. Then you are only downloading one file and thus only have one save dialog. Other than that, you might need to find a solution completely outside of flash. --- In flexcoders@yahoogroups.com, "dialogtmp" <[EMAIL PROTECTED]> wrote: > > Hi! > I know I can use "fileRef.download" this method to download file in the > internet, but this method only can download a file at a time. > > If I want to download many files at a time, has any method can do that? > > > thanks, > dialogtmp >
[flexcoders] Re: popup window
In actionscript use the percentWidth variable. The MXML compiler is just smart enough to know that a width with a percent sign should actually be percentWidth. So try this: var text:Text = new Text(); text.percentWidth = 100; --- In flexcoders@yahoogroups.com, "Dan Vega" <[EMAIL PROTECTED]> wrote: > > I understand the width as a percentage but in as3 you can't do that because > its looking for a number. > > > If i do > > var text:Text = new Text(); > text.width = 100%; >
[flexcoders] Re: Detecting a click on an empty part of AdvancedDataGrid
Try using the mouseFocusChange event. I've used it a few times for deselecting items in a list when anywhere else is clicked. For your needs, you may have to adapt it but give it a try. I have a blog post about it at: http://my.opera.com/darylducharme/blog/2007/12/14/hidden-gems-mousefocus\ change --- In flexcoders@yahoogroups.com, "whatabrain" <[EMAIL PROTECTED]> wrote: > > I have an AdvancedDataGrid which has a few rows, and lots of empty > space. When I click on the empty space, I want all the rows to be > deselected. How do I detect that I've clicked in an empty space? > > I tried using grid.getObjectsUnderPoint() in the "click" event, but the > results aren't very useful. I guess I could depend on the fact that > there are always more than three objects when I click on a real row, > and exactly three when I click on empty space, but that seems like a > bad thing to depend on. Who knows what future versions of Flex will add > to the list? > > There must be a better way! > > Thanks. >
[flexcoders] Re: A *Real* Testrunner for Adobe Flex/Air?
I haven't gotten a chance to test it but you could take a look into dpUInt. It is a unit and integration test suite created by the team at digital primates. The project page is at: http://code.google.com/p/dpuint/ --- In flexcoders@yahoogroups.com, "Justin Bozonier" <[EMAIL PROTECTED]> wrote: > > Hi guys, > > I'm looking for a test runner that will run independently of the Flex/Air app to be tested. > Does one already exist? FlexUnit requires that the FlexUnit UI be in my Flex project and that's > no bueno. > > Another option I just thought of is to create a separate project for all of my unit tests. This > project would also house the FlexUnit test runner. Then I could make any code I wanted unit > tested into separate modules via a Library project. Then my unit test project could reference > that project as well as my main app. > > Any other suggestions? > > -Justin Bozonier >
[flexcoders] Re: Debugging Flex3->AMFPHP
A very good tool for helping you debug any AMF source is Service Capture. It is an inexpensive tool that has saved me hours of time by being able to read AMF, SOAP, JSON-RPC and HTML packets. I use it with AMFPHP here at the office. Here's the website. http://kevinlangdon.com/serviceCapture/ --- In flexcoders@yahoogroups.com, "mr_delphi_developer" <[EMAIL PROTECTED]> wrote: > > I'm trying to get my head wrapped around how to use AMFPHP with Flex3 > using Michale Rameriz's tutorial here: > http://www.howtoforge.com/amfphp_adobe_flex2_sdk > > I've got a lot of the gotchas worked out but I get nothing back from the > DB, the statusbar just says "Transferring data from localhost" when I > run the code on my development system. > > Anyone have any ideas as to how I may be able to debug this stupid > thing? Running the Flex debugger isn't going to work because of the > RemoteObject. >
[flexcoders] Re: mouseCatcher getting in the way
Thank you Alex, it was just that easy. Just to give anyone else a heads up, you must wait until the ApplicationComplete event fires and then do something like this: private function onAppComplete():void { var mouseCatcher:DisplayObject = SystemManager( this.systemManager ).rawChildren.getChildAt( 0 ); mouseCatcher.visible = false; } --- In flexcoders@yahoogroups.com, "Alex Harui" <[EMAIL PROTECTED]> wrote: > > Try setting mouseCatcher.visible=false > > > > > > From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On > Behalf Of actionscript_czar > Sent: Tuesday, April 22, 2008 9:11 AM > To: flexcoders@yahoogroups.com > Subject: [flexcoders] mouseCatcher getting in the way > > > > I made a Flex App that is getting loaded into a flash movie. > Unfortunately when the Flex App is loaded into the flash movie, some > of the flash movie's mouse events don't work anymore. Most notably > all of the one's to the right and bottom of the Flex movie. > > I've tracked it down to the mouseCatcher created by the SystemManager > but I can't figure out what to do with that information. > > This must be easier and I must just be overthinking it. Has anyone > run into this problem and what did you do? >
[flexcoders] mouseCatcher getting in the way
I made a Flex App that is getting loaded into a flash movie. Unfortunately when the Flex App is loaded into the flash movie, some of the flash movie's mouse events don't work anymore. Most notably all of the one's to the right and bottom of the Flex movie. I've tracked it down to the mouseCatcher created by the SystemManager but I can't figure out what to do with that information. This must be easier and I must just be overthinking it. Has anyone run into this problem and what did you do?
[flexcoders] Re: General list consensus using 'this' when referencing local vars
The most important thing is to find a way of doing things and be consistant. If you work for a company, it might be a good idea to create a style guide for code in the company. Studies have actually shown that consistantly formatted code makes it easier to understand. So going back to code you wrote 6 months ago will be easier to understand just by how it looks. A great book that taught me a lot about code formatting considerations, as well as a number of other things that don't get talked about much in how-tos, is Code Complete by Steve McConnell. --- In flexcoders@yahoogroups.com, "Mike Anderson" <[EMAIL PROTECTED]> wrote: > > Greetings All, > > Whenever I study code generated by seasoned programmers (i.e. all the > Adobe people supporting Flex on this list) as well as countless others > on this list, I notice that some use "this" when referencing local > variables contained within a Class. > > The last thing I want to do here, is start a heated discussion regarding > "best practices" for programming. My goal on a daily basis, is to > better myself as a programmer, and I want to make sure that the code I > create, conforms to certain standards. > > Could some of you please offer your 2 Cents regarding the > advantages/disadvantages of using "this"? Just a quick example: > > package > { > public class myClass() > { > private var testVar:String; > > public function myClass( value:String ) > { > this.testVar = value; > // versus: > testVar = value; > } > } > } > > Thank you all so much in advance, for any help you can offer regarding > this topic. > > Mike >
[flexcoders] Re: AMFPHP with NetConnection or RemoteObject ?
When I first started working with AMFPHP 1.9 I was using NetConnection to connect to AMFPHP. It worked well for very simple object structures. As structures became more complex it started costing me more time. Once I started to learn the Cairngorm framework it gave me a reason to start learning about and using RemoteObjects. While the setup takes a little more time, it saves time in the long run. Since objects can come back from PHP as the proper type and not just "dumb" objects. So take a look at your project. If the server communication requirements are simple enough, using NetConnection might be the best answer. However, using RemoteObjects is probably best practice and should probably be used in most cases. --- In flexcoders@yahoogroups.com, "Mario Falomir" <[EMAIL PROTECTED]> wrote: > > Hi, which approach it is better for AMFPHP Flash Remoting, to use > flash.net.NetConnection or the Flex Framework RemoteObject component? Are > there any advantages/disadvatages from one over the other? > > Regards, > Mario >
[flexcoders] Re: how to make opaque panel border?
There is a style called borderAlpha that you can set to 1.0 so that it is fully opaque. --- In flexcoders@yahoogroups.com, coder3 <[EMAIL PROTECTED]> wrote: > > > the default panel border is semi-transparent, that's why if I add 2 panels at > the same position, the title of the panel will look messy. > > I know I can use borderStyle="solid" to make it opaque, but then i will lose > the border color, which I really need. > > what's the solution of this? > -- > View this message in context: http://www.nabble.com/how-to-make- opaque-panel-border--tp16262463p16262463.html > Sent from the FlexCoders mailing list archive at Nabble.com. >
[flexcoders] Re: Sources for Charts cannot be found in datavisualization.swc
I believe this has to do with thte fact that the data visualization components aren't released as open source. So even though you have the pro version and don't have the watermark, you still don't get to see the code. --- In flexcoders@yahoogroups.com, "Ljuba M" <[EMAIL PROTECTED]> wrote: > > When i command-click on an mxml tag for, say, BarChart or any other data > visualization component, I get the error: > Source could not be found for mx.charts.BarChart in /Applications/ Adobe > Flex Builder 3/sdks/3.0.0/frameworks/libs/datavisualization.swc > I have no problem viewing the source of regular flex components, just > the charting ones. Â I'm running Flex Builder 3 Pro. Â Please > help. >
[flexcoders] Re: Detect modal mode on container
Unfortunately nothing gets set( automatically ) when a PopUp is created as modal. The easiest option would be to have your custom view/container have an option you can set so that you know what is going on and when. The only thing done automatically is that the system manager keeps track of the number of modal windows using the numModalWindows property. --- In flexcoders@yahoogroups.com, "polestar11" <[EMAIL PROTECTED]> wrote: > > Hi there > > Is there any event / way to detect that a view / container has > switched to a modular mode via a popup? > > Cheers > Tracy >
[flexcoders] Re: Flash + data-aware GUI components + mxml + layout management = Flex? (aka Flash or Flex for my next project)
This is a good question to ask. At my work we are definately a design oriented interactive agency. We have started asking this question on a per project basis. Beyond skins, there is a lot you can do with Flex, including loading in .swf files created from anywhere( runtime or embedded ). So you can use both together where the occasion calls for it. Here's an idea that you can work with: Created a data aware Flex App that is on top of a beautiful Flash developed background. 0 alpha and transparent skins can be your friend. --- In flexcoders@yahoogroups.com, "Marcelo de Moraes Serpa" <[EMAIL PROTECTED]> wrote: > > I've been off the Flash world for some time now and my next project will > probably be built on the Flash Platform. > > I love the Flash Platform. I used to work with Flash and built a big > application in the past in Flash 8 (using the FAMES combo). > > Coming back now, and not sure which way to go for this next project. > > This Flex vs Flash debate is an old one, I know. Flex is marketed at > developers, Flash at designers. However, sometimes you are both the designer > and develope of the application. Sometimes, you just stumble upon someone > who is a "deseloper", which is my case. > > This project will be a very visually stunning website. It will have > animations, transitions, and tweens everywhere. The GUI will have its visual > (skins?) heavily modified (don't think only CSS could do that). > > I'm a good, skilled developer. I don't mind creating some GUI component and > classes from scratch if needed. I also don't mind coding some layout code if > needed and build the GUI in Flash + AS3. Sometimes, coding from scratch is > better than using a bloated API. > > However, this app will have lots of data to handle, indeed. That's why I'm > considering Flex, since it is more geared to data handling than Flash. Maybe > I will blend the two, using Flash for assembling the visuals and then > melting them in the Flex app, however, don't know how FlexIble Flex is in > this respect (heavily changing visuals). > > There are many pur Flash frameworks around, such as LowRA, I might just use > that for general design patterns and build what I need. I think Flex is only > appealing becouse of the GUI components and its data-aware nature, however, > this is a very creative project and these (not sure if they are) components > are usually hard to have its appearance and visual behavior modified. > > What do you guys think? Any suggestions are welcome. > > Thanks, > > Marcelo. >
[flexcoders] Re: how to call a function in a popup parent?
Since it looks like MiniTextEditor is a custom component, you could make a public variable, or at least a public setter, inside your component so that a reference is available in your component. Then you would instantiate it like this: textPopUp = new MiniTextEditor(); textPopUp.creator = this; PopUpManager.addPopUp( textPopUp, this ); Then the variable should be available to you. --- In flexcoders@yahoogroups.com, "Derrick Anderson" <[EMAIL PROTECTED]> wrote: > > hi, > > i create a popup like this from file A: > > textPopUp = > MiniTextEditor( > PopUpManager.createPopUp(this, MiniTextEditor)); > > in this case 'this' is file B: > > from my popup I am trying to call a function in file A, and since the parent > i pass to the popup is not actually the 'parent' - i can't figure out how to > reference a function in the actual parent. any ideas? > > d. >
[flexcoders] Re: Formatting and addchild with Actionscript
First of all, when you add a component via MXML there is a lot more going on. Check out the details on the liveDocs http://livedocs.adobe.com/flex/3/html/ help.html?content=ascomponents_advanced_2.html#203434 Scroll down a bit and get to the "About the component instantiation life cycle" section. It will explain what happens and you can see what to do about getting your styles right. As for percents in the width and height parameters, there is actually a percentWidth and percentHeight parameter that you can use. MXML just does this step automagically. I hope this helps --- In flexcoders@yahoogroups.com, "netdeep" <[EMAIL PROTECTED]> wrote: > > I would like to add a chart to a panel and have it inherit the same style as its parent. When I > do this with mx tags, everything works fine, but when I manually add it in actionscript with > addChild, it uses the default look and feel. Also how do you set the width of the chart to be > 100%. The width attribute is a number, not a percentage when you set it directly in > actionscript. >
[flexcoders] Re: Ignoring folders _svn / .svn
Since Flexbuilder is built on eclipse you can follow the idea on this page: http://eric-blue.com/blog/2004/11/adding_navigator_filters_to_ec.html The difference is where you will find the filters on Flexbuilder standalone. For example the plugin.xml file I am looking for on a PC is here: C:\Program Files\Adobe\Flex Builder 3\plugins\com.adobe.flexbuilder.standalone_3.0.194161 On a mac it should be similar, from the Flex Builder install directory. For the eclipse plugin version the folder should be similar to the one in the article. --- In flexcoders@yahoogroups.com, DannyT <[EMAIL PROTECTED]> wrote: > > Does anyone know how to set flexbuilder up to not display subversion folders > on OSX? I'm using tortoise (in parallels) for source control and have the > _svn option enabled (because of .net backend). Hence I see an _svn folder in > all of my folders. > > It's clutering up my navigator and big problems like this are keeping me > awake at night. > > Cheers, > > Dan > > -- > http://danny-t.co.uk >
[flexcoders] Re: Use FileReference to get a directory rather than a file?
FileReference.browse is used to select a file( or files if you use FileReferenceList.browse ) that gets uploaded to the server. When you actually use the FileReference API to download something from the server, the normal window for your OS will come up asking you where you want to save it. I hope this helps. --- In flexcoders@yahoogroups.com, "Josh Santangelo" <[EMAIL PROTECTED]> wrote: > > I'm working on an application which includes an option to let the user > select a directory to which files should be downloaded. I'm aware of > FileReference.browse, and I can use that to let people select a file > -- but I don't want a file, I want a folder. I'm thinking something > like in a web browser options panel where you select a download folder. > > Is this possible? It doesn't seem like it from what I'm reading in the > FileReference docs... > > thanks, > -josh >
[flexcoders] Re: problem having navigation betwen states
Could we see the code so that we can check out the interaction between your states and your tabNavigator? --- In flexcoders@yahoogroups.com, cool buddy <[EMAIL PROTECTED]> wrote: > > > Hi all, > > I am using tabnavigator and states to naigate from one page to the other.. > > I have defined the states for all the pages based on HOME page(base state). > > when i define to a linkbutton which i say go to home page defining it as click="currentState=' ' " > > it does n't go to home page instead it goes to the other page after home page defined in the order on TabNavigator. > > does any one have any idea..if so please post it.. > > Thanks. > > > > > > Looking for last minute shopping deals? > Find them fast with Yahoo! Search. http://tools.search.yahoo.com/ newsearch/category.php?category=shopping >
[flexcoders] Re: ArgumentError: Error #1063: Argument count mismatch on copy/addNewLinkButton1(). Expected 0, got 1.
Your addNewLinkButton1 function is expecting a MouseEvent object. So the function should look something like this: public function addNewLinkButton1( event:MouseEvent ):void { Alert.show('Clicked'); } The reason this is different than the addNewLinkButton function is because of the way compiler generates actionscript from MXML. The generated actionscript calls your addNewLinkButton function from the Click listener function of the LinkButton object created in the MXML. Something like this: linkButton0.addEventListener( MouseEvent.CLICK, linkButton0_click_listener ); function linkButton0_click_listener( event:MouseEvent ):void { this.addNewLinkButton(); } --- In flexcoders@yahoogroups.com, "yourName" <[EMAIL PROTECTED]> wrote: > > Plz Help me in this code when i clicked newly created button i got following error > > ArgumentError: Error #1063: Argument count mismatch on copy/ addNewLinkButton1(). Expected 0, got 1. >
[flexcoders] Re: Scaling a TextArea without reflowing the text
If you don't need interaction with the textfield as you magnify it, you should be able to turn the textfield into a bitmap and just scale the bitmap. Then you take text formatting out of the equation. --- In flexcoders@yahoogroups.com, Lachlan Cotter <[EMAIL PROTECTED]> wrote: > > Hi Flexcoders, > > > > Does anybody know the secret to scaling a multi-line text container > (e.g. a TextArea) while preserving the flow (line wrapping) of the text? > > I want to be able to 'zoom in' on a TextArea while keeping the text > flow the the same as it was. > > I would have expected that when I set scaleX and scaleY properties on > the TextArea that the whole thing grows bigger while keeping the text > flow essentially the same, but this isn't the case. > > There appears to be some kind of rounding error or the text isn't > scaled in proportion because it jitters all over the place and the > line wrapping changes. > > I have tried scaling the TextArea directly, a parent of the TextArea, > and even pulling out the TextArea's internal TextField and scaling > that. All have the same results. I've also tried with embedded fonts. > > Does anyone know how to make the text behave itself? > > Example code is attached. > > > > Cheers and many thanks to all, > > Lach > > > > > >xmlns:mx="http://www.adobe.com/2006/mxml"; > xmlns:view="com.bremy.print.view.*" > layout="absolute" > > > minimum="0.5" maximum="2" liveDragging="true" > change="scaleText(event)" /> > > horizontalAlign="center" verticalGap="20" backgroundColor="white"> > > paddingLeft="10" paddingRight="10" > width="300" height="300" > text="{text}" /> > > > > > > > > > > >
[flexcoders] Re: FileReference Upload Event.COMPLETE not firing
In cases where I have run into that problem I use the flash.events.DataEvent.UPLOAD_COMPLETE_DATA event instead. It seems to work all the time. So perhaps you can try that instead. --- In flexcoders@yahoogroups.com, Kevin <[EMAIL PROTECTED]> wrote: > > I am having a problem on mac browers OS X 10.4.10 where upload > COMPLETE is not firing. Also no ProgressEvent.PROGRESS are fired > either. I have read that there were some problem with OS X 10.3, but > nothing about 10.4. > > If anyone is familiar with these problems has possible solutions or > work arounds, it would be greatly appreciated. I can't seem to find > much documentation about this. > > Thanks, Kevin >
[flexcoders] Re: Bug in Proxy
This doesn't seem to be a bug to me, just looking at it from a limited perspective. Image a class that lookes like this: class MyClass { public var go:Function; public function MyClass( goFunc:Function ) { this.go = goFunc; } } In this case go is a property that happens to be a function object. So what if using your proxy with another class you did something like this: var mo:MyOther = new MyOther(); var mp:MyProxy = new MyProxy(); mo.nextfunction = mp['go']; // could also be mp.go In that case it would use getProperty and your description is no different. When you use the [] operators it gets the property then you use the () operators to call the property. The () property is expecting a function object on the left hand side. The reason it doesn't use callProperty is because the () operators only see a function object but don't see it as part of the MyProxy object. This doesn't mean it couldn't work as you expect in the future, but my understanding says the two methods of getting to go are processed distinctly for a reason. --- In flexcoders@yahoogroups.com, "Derek Vadneau" <[EMAIL PROTECTED]> wrote: > > There seems to be a bug in flash.utils.Proxy. Here's some sample code: > > var mp:MyProxy = new MyProxy(); > > mp.myVar = 'something'; // calls flash_proxy setProperty as expected > > mp['myVar'] = 'something'; // calls flash_proxy setProperty as expected > > mp.go(); // calls flash_proxy callProperty as expected > > mp['go'](); // calls flash_proxy getProperty - NOT expected > > Why is getProperty called where the [] operator is used instead of the > . operator in the case where a function is being called, but not when > setting a property? > > And in that case you MUST return a function or a runtime error will be thrown. > > This is unexpected behaviour, as far as I can see. > > Another example: > > mp.obj.go(); > > mp['obj']['go'](); // getProperty is called twice, callProperty is NOT > called at all > > The issue is that I am dealing with a dynamic API, so I don't always > know that 'obj' or 'go' is a property vs. a method. > > But, because the getProperty is called when a callProperty should be > called I am passing an instance of my Proxy class and a runtime error > is thrown. > > -- > > Derek Vadneau >
[flexcoders] mx.utils.ArrayUtil missing in AS3 project
I don't know if this is because it is an AS3 project and not an MXML project but I'm running into this error when I try to use the ArrayUtil class: 1202: Access of undefined property ArrayUtil in package mx.utils. Is this class not available in an AS project? An really the code complete for that package is only finding 2 classes: NameUtil and StringUtil I can work around it but I'm worried about missing so much of the mx.utils class.