Lite Video Presentation

Lite Video Presentation

Lite Video Presentation

You can use this component for various video presentations.
You can jump in different sections of the video by clicking the
thumbs.

Until the section of the video is loaded the thumb will be greyed
out.

Features:

- resizable
- change settings through a XML file
- youtube video support
- flv, mp4, 3gpp, quicktime, mov
- change the colors of each element of the video player
- the wallpaper can be enabled or disabled
- supports custom made captions through an XML ( can be disabled )
- caption text supports HTML formatting

- OOP code
- documentation
- example files ( ready to custom & deploy )

[ LINK ]

Advertisements

Detect Mouse Inactivity in Actionscript 3.0

Before we start you need to be familiar with MouseEvent and Timer classes.

var _timer:Timer = new Timer(5000);

function Start():void
{
   _timer.addEventListener(TimerEvent.TIMER, ShowMsg, false, 0, true);
   _timer.start();

   stage.addEventListener(MouseEvent.MOUSE_MOVE, StopTimer, false, 0, true);
   stage.addEventListener(MouseEvent.MOUSE_DOWN, StopTimer, false, 0, true);
   stage.addEventListener(MouseEvent.MOUSE_UP, StopTimer, false, 0, true);
}

function ShowMsg(e:TimerEvent):void
{
   trace("There is no activity");
}

function StopTimer(e:MouseEvent):void
{
   _timer.stop();
   _timer.start();
}

Start();

The first thing I’ve done is to setup a Timer object to count up to 5 seconds ( you can change that to what ever numer of seconds you want ).

The timer object also has an event listener so we can know when the 5 seconds are over.

I have setup some event listeners that will help detecting any actions of the mouse on the Stage ( MOUSE_DOWN, MOUSE_MOVE and MOUSE_UP )

If during those 5 seconds nothing happens ( mouse is not moved or performs a click ) ShowMsg() function will be fired up and give you a message of inactivity.

If the mouse is moved the StopTimer() function will be activated and reset timers count.

This is a useful and easy way to detect user activity.

Lite Slide Gallery

Lite Slide Gallery

Lite Slide Gallery

This is a nice flash application that will enhance your website.

This gallery can be used either in a fixed size mode or full browser mode, because it is resizable.

Features:

- resizable 
- change settings through a XML file 
- unlimited number of images 
- background: can be either a image or a color 
- change thumb's width and height 
- change the color of each element of the gallery 
- the thumbs panel can be either visible or hidden at startup 
- title can be visible or not - OOP code - documentation 
- commented code 
- ready to deploy files 
- examples  

[ LINK ]

Tween A Number with GreenSock’s Tweening Class

I am going to give you a little example on how to tween a number. This example can be used with other tweening classes as well like Caurina’s Tweener.

Pay attention that the variable we want to tween needs to be public otherwise you’ll get an error compiling the code.

We are going define a variable as an Object. This object will hold a value. The tweener will tween this object’s value.

public var my_number :Object  =  { value: 0 };
TweenLite.to( this.my_number,  .5, { value: 100 , onUpdate:function(){ trace (this.value); } } )