About Orland MediaDevelopmentTrainingBlogRSS FeedContact us
Microphone

Adobe Flash to be in set top boxes

Date: Monday 20th April 2009
Time: 14:49
Category: Adobe Flash
Views: 4
Comments: No comments

Flash is becoming more and more prevalent on mobile devices and it is now to be built into set top boxes – and we are ready, willing and able to provide the content.

Rate this post
1 Bar2 Bars3 Bars4 Bars5 Bars   (Roll over and click)

ActionScript 3 (AS3) training course in London

Date: Sunday 19th April 2009
Time: 13:55
Category: ActionScript 3.0
Views: 12
Comments: No comments

We have just set the date for our next Applied ActionScript 3.0 course: it will be held on 5th, 6th & 7th May 2009 in London, UK.

The course teaches how to build Flash sites exclusively using ActionScript 3.0.

One or two places are still available if you would like to attend – but be quick!

Rate this post
1 Bar2 Bars3 Bars4 Bars5 Bars   (1 votes, average: 3.00 out of 5)

ProgressEvent.PROGRESS misreports bytesLoaded & bytesTotal

Date: Sunday 19th April 2009
Time: 13:35
Category: ActionScript 3.0
Views: 31
Comments: No comments

One problem we recently ran into involved ProgressEvent.PROGRESS events seeming to misreport the proportion of the file that has loaded.

This would cause the preloader’s bar to extend beyond the 100% mark. While we don’t have time currently to outline the full technical context of the issue, we did spend some time examining it, and we solved it.

The solution to the problem was not to use the bytesLoaded and bytesTotal of the actual ProgressEvent in the event listener, but to instead use the properties of the target (which is a LoaderInfo object). So your code looks like this:

private function update(e:ProgressEvent):void
{
  // causes misreport:
  // var bt:uint = e.bytesTotal;
  // var bl:uint = e.bytesLoaded;

  // prevents misreport:
  var bt:uint = e.target.bytesTotal;
  var bl:uint = e.target.bytesLoaded;

  bar.scaleX = bl/bt;
}

We’ll try to expand on this issue at a later time. In the meantime we hope this helps someone.

Rate this post
1 Bar2 Bars3 Bars4 Bars5 Bars   (2 votes, average: 2.50 out of 5)

iTunes says “Preparing to Install” every time it starts

Date: Friday 10th April 2009
Time: 12:40
Category: General
Views: 30
Comments: No comments

Here at Orland Media we make full use of iTunes on Vista, having it either on random play or tuning into to any of several hundred radio stations throughout the world while working.

The above mentioned problem can sometimes occur on upgrading iTunes, and it doesn’t go away even on a reboot. The simple cure for it is to make a new shortcut pointing to the iTunes executable file, and dispose of the old shortcut.

Rate this post
1 Bar2 Bars3 Bars4 Bars5 Bars   (3 votes, average: 3.67 out of 5)

Detecting onReleaseOutside in AS3

Date: Friday 10th April 2009
Time: 01:28
Category: ActionScript 3.0
Views: 24
Comments: 1 Comment

ActionScript 2.0 has support for the onReleaseOutside event in the following manner:

myMovieClip.onRelease =
myMovieClip.onReleaseOutside = function():Void
{
   this._x += 300;
}

This directly applied event handler will trigger when the mouse is released over myMovieClip or when that clip is clicked upon then the mouse is subsequently released elsewhere.

ActionScript 3.0, however, does not define an onReleaseOutside event type, though there are plenty of other MouseEvent types.

Usually, this is not a problem. You want to detect a CLICK event, which is dispatched when the user has pressed the mouse down then released it over the same object (with any number of other possible mouse events in between). The logic for this is that the user might have changed their mind and be deliberately releasing the mouse while not over the object, not wishing to trigger any event.

But suppose we are creating a button which reacts to a MouseEvent.MOUSE_DOWN event – perhaps a fast-forward button such as we created recently in order to speed up the playback of an MP3. In this case, we want the MP3 to revert to normal playback speed even if the user releases their mouse while not exactly over the button (as is often the case). We need a releaseOutside event for this eventuality.

So how are you supposed to detect when the user has clicked on your interactive object then released the mouse outside? The solution is to temporarily apply a new event listener until the mouse is released, as follows:

private function mouseDown(e:MouseEvent = null):void
{
   stage.addEventListener(MouseEvent.MOUSE_UP,
   mouseUp, false, 0, true);
}

private function mouseUp(e:MouseEvent = null):void
{
   stage.removeEventListener(MouseEvent.MOUSE_UP, mouseUp);
   // do other stuff
}

myButton.addEventListener(MouseEvent.MOUSE_DOWN, mouseDown, false, 0, true);

This code is minimal, but it illustrates the point. We always detect for a MOUSE_DOWN on the given object (myButton), but only when this has occurred do we then listen out for a MOUSE_UP. When this happens (regardless of where) our other listener function is triggered. Note that this then unsubscribes itself from the Stage, and then everything is cleaned up.

Rate this post
1 Bar2 Bars3 Bars4 Bars5 Bars   (1 votes, average: 3.00 out of 5)
Older posts
Lenovo Microsoft Adobe Demon Envirowise
Copyright © 2008 Orland Media Ltd | All rights reserved Company details Ethical policy Terms & conditions Privacy policy