0

please can somebody tell me how remote control works? I have to create presentation in Flash platform using ActionScript 3. How to listen keys from remote control to show next slide, prev slide, pause, play etc? Is it like normal keys?

thanks for info

Daew dawe
  • 99
  • 8
  • do you have this remote control available? If so create test app that will listen to any keyboard input and see if the remote keys are mapped to any keyboard keys. – Lukasz 'Severiaan' Grela Jan 02 '14 at 13:00
  • Unfortunately not. Is it different for different devices? I will have available one remote with projector from my friend, but it is not same brand and model. – Daew dawe Jan 02 '14 at 17:40

2 Answers2

0

Generally projector remote controls are just left and right mouse click signals. LMB is the 'next slide', RMB is the 'previous slide'.

You're going to run into problems though, since right clicks in Flash open the context menu. Flash isn't really well suited for this purpose as you can see.

I recommend adding your Flash files into a PowerPoint presentation to save yourself all the stress of second-guessing which hardware is available to you.

1owk3y
  • 1,115
  • 1
  • 15
  • 30
  • Thanks for advice. In newest Flash player (or from 11.2 I think) you are able to remap mouse right click. So I am able to listen right and left click. I have an idea to create some configurator app, where will user map keys from remote clicker and then he can use it. But it will only work if all remote controls using clicks or keyboard key press - I am not sure about it – Daew dawe Jan 03 '14 at 08:01
  • No problem! If there's no way of being 100% sure of which clicker is going to be available, I still suggest implementing your Flash into PowerPoint. It will have the widest support for clickers, and clicker manufacturers aim for compatibility with the most popular product for displaying presentations... – 1owk3y Jan 03 '14 at 19:52
  • Thats true, but this presentation is high dynamic with a lot of animations and transitions between slides. So I will see what will be final decision. I will write result after completing presentation – Daew dawe Jan 04 '14 at 08:43
0

When programming your flash presentation for use with a remote clicker, do not target left and right mouse clicks.

Instead you need to use keyboard events to target Page Up and Page Down.

The event listener that emulates the remote clicker's forward arrow is:

stage.addEventListener(KeyboardEvent.KEY_DOWN, forwardsFunction);
function forwardsFunction(event:KeyboardEvent):void {
var myKey = event.keyCode;
if (myKey == Keyboard.PAGE_DOWN)
{

The event listener that emulates the remote clicker's backward arrow is:

stage.addEventListener(KeyboardEvent.KEY_DOWN, backwardsFunction);
function backwardsFunction(event:KeyboardEvent):void {
var myKey = event.keyCode;
if (myKey == Keyboard.PAGE_UP)
{

This will allow you to use a remote clicker to work with your Flash presentations. At least this is the case with the Logitech remote I have tested.

Also, I found it necessary to determine the focus for this to work. My Actions were placed on a frame at stage level, ie they related to movieclips placed on the stage. Adding this code to the start of my Actions enabled this to work:

stage.focus=stage;
Nib
  • 1
  • 1