Magic Remote
The LG Smart TV is boxed with one of the two following remote control units:
-
Magic Remote Control Unit allows for free pointing and clicking, as well as standard 5-way controls. Voice input and universal remote functionality are also provided.
-
Conventional Remote Control Unit allows for standard 5-way controls, with additional physical keys as shortcuts to commonly used actions.
Magic Remote Control
|
|
The following remote keys are available:
Button | Keycode |
---|---|
Left | 0x25 |
Up | 0x26 |
Right | 0x27 |
Down | 0x28 |
OK | 0x0D |
Back | 0x1CD |
Red | 0x193 |
Green | 0x194 |
Yellow | 0x195 |
Blue | 0x196 |
Basic Pointer Actions
-
Pressing Up, Down, Left, or Right key, while a pointer is active, will switch remote into 5-way modes.
-
In a 5-way input, the pointer function will be disabled.
Basic Key Actions
Press |
Performs the function mapped to the key.
|
|
---|---|---|
Press and hold |
|
|
Roll |
Scroll up or down the content. |
Back Behavior
Web apps can control the behavior of the remote's [Back] button. You can map the [Back] button to navigate the previous webpages or go to Home UI. Once the app is done handling the [Back] button, webOS TV will take over the behavior of the [Back] button. For more details, see Back Button.
Remote Control & Apps
-
Pointer mode:
The remote control works similarly to a mouse (or, we prefer to refer to a wand). You can point or select items, or scroll up or down using the wheel. You can use the standard JavaScript events for the mouse, such as theonmouseover
event and theonclick
event. -
5-way mode:
The arrow (Up, Down, Left, and Right) and the Enter keys are the major function keys in this mode. The scroll wheel is also active.
-
Pressing any of the arrow keys (Up, Down, Left, or Right) while using pointer mode will switch the navigation mode to 5-way mode.
-
Shaking the magic remote while in 5-way mode will switch the navigation mode to Pointer mode.
-
When the magic remote is in 5-way mode, the cursor will not be displayed on the screen. In Pointer mode, the cursor is displayed on the screen. You can check the cursor visibility with the
cursorStateChange
event. -
The LG Smart+ TV's primary input mode is Pointer mode but all apps MUST also support 5-way mode. Developing functions that do not support the "5-way" input should be avoided.
-
The Moonstone library supports both Pointer mode and 5-way modes of LG remote control.
-
While the overlay type system UI such as Launcher or Settings menu is displayed on the screen, apps cannot receive the pointer events. You can check it using the
onblur
event and theonfocus
event from your app.
Refer to Remote Control sample app to find out how to customize the behavior of specific keys on the remote control.