ActionScript 3.0 :: When To Use Interface And When To Use Overidden
Jun 21, 2009I am confuse when to use interface and overidden.
View 2 RepliesI am confuse when to use interface and overidden.
View 2 Repliesi seem to have trouble finding on the internet what happends when one interface extends another interface.
View 2 RepliesI'm trying to publish a swf with Flash CS3.
I have one .fla file and two .as files. I think my problem is I don't know how to set the path for the action scripts. All three files are in the same directory
The files:
dtd.fla
TransformItem.as
TransformManager.as
The error: The class or interface 'gs.TransformManager' could not be loaded.
dtd.fla code appears to have an appropriate import: import gs.TransformManager; var manager_obj = new TransformManager([], onTransformEvent, true, false, false, false, false, true, true);
TransformManager.as code appears to have an appropriate import: import gs.TransformItem;
I am an actionscript newbie but have been given the task of designing a navigation menu in flash that has to connect to a database - the menu items have to be marked - unread, mandatory etc. and have to pull back database information to display then be marked as read.
View 3 RepliesI don't need to stream anything. Just wanting to look at a webcam using Flash. Hopefully be able to control (zoom) a Logitech cam on Mac os 10.6+.
It will be a screen I share in Connect. The video pod in connect is not what I want.
Im testing a program in FlashDevelop, which uses Flash player 10. Need externalInterface to work, but on running this simple test program, it displays "ExternalInterface is not available". How do I get ExternalInterface working? [URL]
<mx:Script>
<![CDATA[
import mx.controls.Alert;
private function init():void {
if (ExternalInterface.available) {
[Code] .....
By the way, this script shows "External Interface is available" when I run it in my browser. Its only when I run it in Flash Player 10, that it is not available.
I've created simple swf with interface:
public class Test extends MovieClip implements ITest
{
public function Test()
{
[Code]....
So if I have test.swf in the same directory(local way) it work's fine. But if I'm placing it on the dedicated server: (event.target.content as ITest) returns null. However, I can access speak() without interface like this event.target.content.speak("a!");
I've got a SWF with buttons that are calling a javascript function using External Interface - specifically the Milkbox photo gallery. For various reasons, the page with the embedded SWF has to work online as well as being run from someones local machine. The online version runs fine on every OS/browser. However, I've run into a snag where, for some reason, the local version isn't firing the javascript on Win XP in any browser.Is there perhaps some snag with using External Interface locally on an XP machine, or is there something else at play here? FYI, no problems at all on Vista/any browser.
View 1 RepliesI use interfaces a lot and this seems to be a glaring omission. Makes it impossible to write interfaces for display objects. Anyone know why?
View 14 RepliesI have a polymorphic situation that is thus...
Code:
private var loadXML :ILoader;
if (!Capabilities._internal) //testing locally
[code]....
I have an object in the library that is linked with class Myclass, I define MyClass in its own AS file and everything runs ok, but as soon as I remove the linkage of the object with the class the compiler generates an error with a seemingly totally different class, that class is part of an open source data structure library for AS3, unrelated to that library object or class MyClass.
The error code is 1044: Interface method ****** in namespace ******* not implemented by class ********.And of course I checked and the class implements the interface methods, all of them so there should be no errors.The library I'm using is a [URL] and the class reporting errors is HashMap and HashTable.
how can I increase the size of flash CS4 interface? Meaning also to enlarge tools buttons, so they are easier to see. I have to strain my eyes, because all of the toolbars and text related to them are too small, for constant work.Is this possible? I know there is one way - to increase display DPI settings, but that would also increase the whole desktop, but I would like just to increase flash interface text size and if it is possible then also tool buttons.
View 1 Replieshow to go about searching for this since I don't know the terms used for it. I am trying to make an interface to use on a website that would have to pull up images and text with no preloading. Think of an online encyclopedia; you put in a word and it pulls up the object/animal/etc with a description. I am looking at needing to pull up thousands of different things; hence the no preloading.
View 2 RepliesI am creating a Mac cd rom with a flash interface and want to open folders on the cd by clicking a button on the interface. I read the this can be done using a bit of applescript but I'm having trouble executing the applescript from flash, I have save the applescipt as an app and when I run it I independently it works fine but when I try to run it using FScommand from flash no joy?
This is the action I'm using on my button:
on (release) {
fscommand("exec", "test.app");
}
I have also created a folder in the root of my cd called 'fscommand' and put my script app in there but still it wont work?
I'm having a problem with Flash and Internet Explorer. I'm trying to close out a browser window with
//as code ExternalInterface.call("closeWindow");[URL].. Of course this works in all other browsers except IE, the error that I am getting is:'null' is null or not an object
i am new to the actionscript 3 . i want to create Phone book for me
i want to use front end as flash interface Back end as Ms excel or Ms access or any databases
I'm doing a simple link code. I've tried many diferrent ways to do this but this error keeps comming up saying The class or interface could not be loaded...
home_btn.addEventListener(MouseEvent.CLICK, gotoURL);
function gotoURL(event:MouseEvent):Void{
navigateToURL(new URLRequest("my site"));}
This is the most recent method I've tried in doing this. I've tried changing the publishing settings of the document to and from Action Script 3.0- using an import command. But thats too complicated.
Attachments: Flashfla.fla.zip (767.8 K)
I would like to have a flash app on a website where:A user can input some values Those values are then sent to a server which has an executable fileThe exe is run with the user's settings and then sends some data back to the userThe data is displayed in the flash app.Is it doable with CGI or is there a better alternative to this?
View 2 RepliesI was studying about EventDispatcher and tried to make my own class and interface IEventDispatcher.Then later i was wondering, what use does the interface have anyway when you still have to declare the functions that are in the interface to the class that implements the interface? The dispatcher will still work without the interface. Like addEventListener, removeEventListener, these functions are within EventDispatcher so why do i need an IEventDispatcher?
View 3 Replieswhen i publish in flash in html, in the Mozilla browser i am getting it in the left but i want it into centre.
View 7 RepliesI have created a peelback advert that peels down from the top right. All is well apart from it it obstructs the user ability of the site underneath as the peelback advert is effectively over the top. I have been giving some guidlines to stop this but i am struggling to understand them. The instructions specificall say that the file must be set with the transparent parameter.
Here are the options that i have:
OPTION 1:
import flash.external.ExternalInterface;
// Function executed in answer to the event
function onClic(pEvt:Event):void {
[code]...
I think it could be the latter two that i need but am not entirely sure, i have tried them but have failed in my attempts?!If this is definetly the way to do it i will persevere! If these are not the way, what does the corner_show/hide method method do?
I have a navigation menu set up using standard jquery to load new body text and play a swf. There are about 10 links, each having there own body text and swf file. The swf's simply play, then stop after about 30 frames. When clicking through each menu item, a new swf plays and body text appears. I've been running into a problem lately with IE not reloading a swf. Instead it stops on the last frame of the swf and appears as an image. I was told to try using the external interface so jquery can force it to reload. I've never used the external interface before though, how to do this?
View 2 RepliesThis is a computer I am provided with while I work onsite. I am having severe corruption issues. Sometimes the fly out panels appear on the opposite side of the monitor, scroll bars duplicate and appear over the top of my work, and the toolbar just disappears completly until I mouse over each button and force flash to redraw them. It seems to be redraw issues of flashs actual interface, not my work.Not sure how flash renders its own interface, but my .NET framework and java is up to date if that makes any diff.Is this an incompatibility with the video card? I've never seen this before and I wasnt able to find any solutions while googling, or even mentions of this issue, unless I was just searching for the wrong keywords
View 1 RepliesCan 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 RepliesIs something like this possible in Actionscript?
Java:
URLFetcherFactory.setCreator(
new IURLFetcherCreator() {
public IURLFetcher create() {
return new URLFetcher();
[code].....
i have an xml which contains 'interface' sub tag, iam converting xml to object using SampleXmlDecoder. compiler did not allow me to access the value of the 'inteface' attrible of the resultobject.
[Code]....
its treating interface as keyword. the solution for this.
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 RepliesI am creating a method that accepts a IOBJECT parameter. there is multiple class that implement this interface. I need to figure out which type IOBJECT is. how would i go about doing that
View 3 Repliesinterface If { ... }
class Impl implements If { ... }
function test(type:Class, obj) {
return obj instanceof type;
}
test(If, new Impl());
The call to test on the last line returns false, but it should be true. How can I do this check right, with the requirement that it must be inside the function?
Real code:
public function iterate(callback:Function, type:Class = null) {
for (var node:EntityListNode = beginNode; node != null; node = node.next) {
if (type == null || node.entity instanceof type) callback(node.entity);
}
}
I need ActionScript Proxy to be castable to a particular interface.
Here is an example without interface:
public dynamic class Tracer extends Proxy {
flash_proxy override function callProperty(method:*, ... args):* {
trace(method + " " + args)
}
}
[Code]...