Actionscript 3 :: Implement A Mixin/Trait Style System?
Apr 5, 2010
how to implement a Mixin/Trait style system in AS3. I want to be able to compose a number of classes together into a single object. Of course this is not a language level feature of AS3, but I'm hoping that there is maybe some way to do this using prototype based techniques or maybe some bytecode hacking that I believe AsMock uses to implement it's functionality.
An existing Java example is Qi4J where the user define interfaces that the Qi4j framework implements based on metadata tags and coding by convention.
View 3 Replies
Similar Posts:
Jan 12, 2010
I'm writing a ticket-shop-system atm for reserving tickets for various concerts.What I have is a php-backend and a webpage that shows a .swf with some actionsscript-3 code in it, to draw in flash some sort of map and make available seats clickable for the end-user.The problem with this solution is, that there are quite large halls and just making the seats smaller isn't the right solution.
View 3 Replies
Feb 12, 2009
I'm just trying to implement a simple zoom system, incrementing and decremeting the _xscale and _yscale of a mc.
Since the mc is draggable, I was wondering how I could've managed to zoom the mc right in the spot where the mask was, so, what _x and _y I had to assign to the mc after the scaling.
View 9 Replies
Nov 6, 2004
I am trying to implement a comment form for a flash page using a php email system. I am new to flash, but I got it working for the most part. The problem is that I receive emails, but they are blank and do not contain the info I put in. Below is the Actionscript I used and the php I used.
on (release) {
if (!FirstName.length) {
EmailStatus = "Please Enter your name.";
}
[code]....
View 7 Replies
Aug 31, 2006
how one might change a site element based on the users computer time? What we are trying to do is change the color of the sky and shade of the buildings in a cityscape scene on a cartoonish style site. If it is 9:00 PM on the site visitor's end, they will see a nighttime colored scene. If it's 7:00 AM, it would be sunrise-ish.
View 3 Replies
Aug 12, 2010
If I have say a dozen classes, that may or may not be called at runtime, and that all have a common function; is there an advantage to creating a separate class with just this common function in it and then having it mixin at runtime ?I am wondering would this allow me to reduce the size of each class and thereby the swf file size? I figure this must be wrong else why would we ever extend anything when we could just mixin the functionality we want at runtime?
View 4 Replies
Aug 7, 2009
I got a textfile who i am reading on a serverside script and passing it as a script to my client side as3 code. The problem is that i am using characters like ä,ö,ü,ß and this isn't well displayed. I tried System.useCodePage but the compiler complains about : 1120: Access of undefined property 'System'. It doesnt matter if I tried this on the first line of the 'Action' in the first scene or in the first line of the first .as file i am loading. (btw i am only working with .as file and not in the timeline). When i am importing flash.System.* the compiler complains he dont know useCodePage.
View 3 Replies
Oct 23, 2009
I've got a comboBox component on the stage, instance name 'combo'. I want to style the text. I followed the adobe instructions, but they seem not work, and I get no errors.
Code:
import fl.data.DataProvider;
import flash.text.TextFormat;
var tf:TextFormat = new TextFormat();
[code].....
View 2 Replies
Dec 29, 2010
Is it possible to make this a mask? The system contains one movieclip of a circle called ball, also a class called ball and a class called particle. I want the particle system movieclips to display an image...I'm sure this is possible...just have not been able to find a way. A little backround, I'm a completely selftaught n00b when it comes to AS3, but I'm grasping it fairly well... the tutorial is on this website, called A Simple Particle System Using Actionscript 3.
View 0 Replies
Jun 30, 2006
I have a menu and i need to replace the style of the menu to another menu but everything out of the style will be the same...
View 1 Replies
Sep 22, 2010
I build a web site in flex that some time take input. Will this website works on Touch Screen environment(KIOSK).My question is we have to make any change to handle input such as prompt on screen keyboard when input fields are get focused or it will manage my device and OS of system(KIOSK, Touch screen system) itself.
View 2 Replies
Dec 10, 2009
How to implement lightbox using as3? examples on the sites only talk about it when using as2.
View 1 Replies
Dec 16, 2009
I need to build an "interactive floorplan" for a shopping centre (or two). Many shopping centre websites already have this (eg Bluewater in the UK). Traditionally, the way to build such a floorplan / map is to do it in Flash. The actual floorplan is a Flash asset and the data that describes which retailer is in each location is fetched from the webserver as XML. That way editors can update the location of retailers without having to edit and recompile the SWF file. However if the floorplan itself changes (for example, a larger shop is split into two smaller ones) then the map has to be edited. Another disadvantage is that the data isn't readily available to third parties for mashups etc. So apart from Flash what would you consider using to achieve the same effect? I know of SVG but IE doesn't support it.
View 1 Replies
Apr 23, 2010
I'm learning layouts in Flex. I try to make the following layout.The red arrow means when enlarge the window, the red arrow widget will become large too. Can anyone implement this layout in Flex?
View 2 Replies
Feb 6, 2011
On the site we need to implement a mark on the photograph. By type as in facebook. It is desirable but not necessary that the selection of the object was not the rectangle, and polygon. There is a ready-realization? It does not matter what technology to use php, flash, and other, exotic but not necessary:)
View 3 Replies
Oct 3, 2004
I am lookin out for a Project to implement OOP is AS, cause i jus cant find da real need in any of ma Projects done till now.
View 4 Replies
Aug 16, 2011
How to achieve Flex Localization !! In my current project other than English, I need to change the language to French/Spanish also.I am using FB 4.0 and it integrated with Java/Jsp/xml. There is lot of integration in almost all modules. Here the requirement was, i want to display a comboBox with French/Spanish options. Now based on the selection whole application language has to change ie either French/Spanish.
View 1 Replies
Feb 29, 2008
implement closed captioning into my FLVs. I have successfully set up the FLVplayback component, and the FLVplaybackCaptioning component to work. That's not the issue. The issue is, once I have my swf, flv, and xml files (needed to successfully use CC in a FLV), I need to insert that .swf into my captivate project.
It appears to insert/import OK, but once I publish the project, the swf does not appear, and in fact the FLV icon sits on the slide rapidly blinking. Neither the video plays, nor can I even see the playback component/closed caption component (swf) that holds the FLV.
All paths are relative, so the only things I can think of that may be causing the issue are:
a)Captivate doesn't support CS3 FLVPlayback or
FLVPlaybackCaptioning components
b)Since Captivate allows importing of FLV files directly, running the FLV through the component's swf is a problem
c)The hierarchy of files needed for the Closed Captioning FLV (xml, flv, swf), interfere with compiling the new Captivate .swf
upon publishing I've also been told that the FLV captioning component only works in Actionscript 3.0 which runs on Adobe Virtual Machine 2.Captivate publishes .swf files using Actionscript 2.0 which runs on Adobe Virtual Machine 1. Therefore, what I need to do will not work.
View 4 Replies
Jun 23, 2009
Is it possible to implement threads in actionscript 2?
View 3 Replies
Nov 14, 2011
it most used on network accesses. But now, I have a class that will do several things, including but not limited to network accessing, many many single loops within a huge code(maybe). The return time is unspecific, so I think about using an async method. However, when I run my program, I found that all things in call stack are stuck when the loop running. I made a short version of my code. First, the weird AsyncClass.as class is like this:
[Code]...
View 7 Replies
Feb 3, 2012
Can I implement more than one interface to the same class?One option is to make interface A extend interface B and than have my class inplementing interface A. Is there any other way that I can implement two or more interfaces directly to the same class?
View 3 Replies
Jul 26, 2009
I've written a Flash (Flex) client connecting to a back-end server to exchange data. I've also written my server from scratch, and it serves two purposes:
(1) Web (HTTP) Server- By default listens on port 80
(2) Socket/Application- Server - By default listens on port 443
Just FYI, both servers run in the same process space, for convenience reasons. They are not expected to handle massive loads, so I'm fine with that. As soon as the Flash client is served to the browser from the HTTP socket, the client attempts to open an XMLSocket to the Socket/Application server. I now want to implement HTTP tunneling, so that my client can connect to the Application server even if the user is behind a firewall. I do not want any external servers involved (proxies etc.) - simply use the servers I already have.
My questions:
(1) Is it better to use port 443 for that? (does it better fool firewalls?)
(2) As far as I can see, what I am required to do, is just ensure that my actual application data is simply encapsulated in an HTTP structure (preceded by a dummy HTTP header), both from the client and server sides. Is that so or am I missing anything here?
(3) Do I need to keep hiding/encapsulating my data every message I send through the socket, or can I just encapsulate the first message when opening the connection?
View 1 Replies
Sep 7, 2009
I want to limit my SWF file so that it cannot be stolen and hosted on another server. So if the domain serving the SWF file isn't on a list of approved domains, the SWF will not load normally but will instead display a message that links to one of the approved locations. What I'm unsure about is how to access the domain that is hosting the file (or get the fully qualified URL of the file). If You know how to get that information, I'm using Flash CS4 to compile the code targeting FP 9.
View 2 Replies
Dec 30, 2009
Quick question. Does a class have to implement a interface directly to be accepted, or can it be a child of a parent class that implements it. so If I pass a child object into a method that only accepts IOBJECT, but the child class parent implements IOBJECT. will child object be accepted ?
View 1 Replies
Feb 11, 2010
I am a c# asp.net developer and need to implement a number of flash website banners. Previously for static image banners I have implemented on_click code behind or javascript to log the banner has been clicked back to a database and process the re-direction. I don't have much knowledge of flash other than I know that a flash program can handle on-click events of the program. Therefore, can somebody suggest the best solution for capturing and processing on-click events of a flash object on a webpage.
View 2 Replies
Feb 13, 2010
I am considering creating a website with the complexity of Facebook that should be able to scale into the millions of users. My question is: Is there any reason not to use Adobe Flex for such large project apart from the obvious point of requiring everyone to have Flash installed and not having to rely on Adobe? In my view Adobe Flex would reduce the server load for Facebook, because more of the work could me done on the client side.
View 7 Replies
Mar 4, 2010
I have a List component from which I'd like to be able to remove items using drag & drop, but without having a specific target. If you use the mac, the behaviour I'm looking for is something like what the Dock uses; when you drag something out of the bounds of the control it should get an icon that indicates that it'll be deleted (OSX uses a cloud or something?) and then if you release it it will be removed from the list.
View 2 Replies
Jun 4, 2010
I want to have flex portlets side by side with JSP portlets. How can we implement the authentication mechanism? [ Authentication will be handled by the portal and how can we share the same session with flex portlets ]
View 1 Replies
Sep 23, 2010
I want to implement video chatting on my site. I understand that I need a table of users online with their ips and that there will be flash clients but I do not understand how the streams are handled. Do I need to have some sort of special stream process running somewhere? Can I just store the ips in a db and set them connections up in php like some sort of p2p service?
View 1 Replies
Mar 18, 2011
I want to implement Video Chat with two person, the person will be randomly selected like in chatroulette. I have no idea of RTMP server so is there any opensource system that I can use or create from scratch. I am new to flash and worked on php.
View 1 Replies