May 12th, 2008
I came across this error and am blogging about it so I won’t forget the solution and maybe it will help someone else.
1172: Definition fl.video:VideoEvent could not be found.
In order to access a number of the “fl” packages you need to have a component in your library. In this case I added the FLVPlayback component and all was well. Apparently you can use flash.utils.getDefinitionByName as well.
May 9th, 2008
I am in the process of creating a common interface to control media players whether it be Adobe’s VideoPlayer or exanimo’s SoundPlayer. My initial desire was to have it accept Adobe’s own Video Components like PlayPauseButton and SeekBar as well as my own custom controls, but I have run into an issue. Adobe’s Video UI Components do not work on their own but require UIControls.
So if I want a PlayPauseButton to work with SoundPlayer I need to roll my own. If I want a BufferingBar to work, I need to roll my own.
Hopefully in the next version of Flash they will resolve this and give us components that would accept an interface for a target.
October 28th, 2007
If you build just about any Flash application you will need a menu that will manage button states and let you know when something has been clicked. This class will do that and can be implemented in projects big and small. Below is a very basic example on how it can be used, on the Mall World page it is implemented six times. Can you guess where?
A very basic implementation
Creating a Menu Object can be as simple as this
var menu = new Menu();
menu.addItem({clip: buttonOne, id: 1});
menu.addItem({clip: buttonTwo, id: 2});
menu.addEventListener(MenuEvent.NAVIGATE, this.menuNavigateHandler);
This code is released under the MIT License with just one request. If you improve it in some way that could benefit other users leave a comment.
Download the code & example files