Using colour keys on keypad from Chrome on Google TV - google-tv

I'm writing a Web app for Google TV and want to make use of the colour keys on the remote control for navigation.
I'm not getting any input from the keys in response to onkeypress or onkeydown events, does anyone know if it is possible to use these keys for input in Web apps? I have seen the keys used in apps on Google TV but I suspect these may be Android apps. I can get input from the keyboard keys and the D controller without any difficulty.
Thanks in advance,
Gordon.

The color key's are not currently supported within web applications. Chrome does not receive key events from the remote for the color keys.

These color keys are designed for universal remote functionalities on TV. Since there are no desktop equivalents to them, Chrome does not pass any keycode for them.
In general for available keys and keycodes, use the keycode tester here:
https://developers.google.com/tv/web/docs/implement_for_tv#keyboard

Related

Allow users to select any option on Google Home device

I am developing an AoG / Google Assistant app which will provide feature to list some items and user can select any one item to know more about it.
I am using List to show the items and an intent with actions_intent_OPTION will listen for user input. It is working fine for mobile and screen devices. Now I want to do same thing on Google Home ( Speaker only) device.
Is it possible to provide option selection feature on Google Home. One thing I would like to add here is that, "I can not use entities to get inputs because we are creating items dynamically."
A List object will not work on audio-only devices, as there is no screen. As such, you will probably want to use either #sys.any to capture a parameter on audio devices, or use session entities to define the types of parameters that you'd want to capture.

Google TV - Javascript Remote Keycodes

Anyone have a reference to the keycodes for sony remote, I have play and stop working but need pause keycode, play pause seems to be referencing the same keycode but the buttons are seperate on the remote
Here are the media keycodes:
https://developers.google.com/tv/android/docs/gtv_controlguide#MediaKeys
The controls are mapped to similar Android keys. The corresponding key codes can be found here: https://developer.android.com/reference/android/view/KeyEvent
Please also note Google TV guidelines for building TV navigation.
If you need to know which keycode a specific key on your remote has I can recommend using KeyMapper which is free, available for Google TV and allows you to remap almost any hardware key to another function. It also shows you what keycode is triggered by a key.

iPhone/iPad Get State of Wireless keyboard

Is there any way in the iPhone SDK (not a jailbroken API, this needs to be AppStore-Compliant), to get the state of a connected wireless keyboard? e.g. which keys are pressed and which aren't? I have searched for this with google, but I am coming up short.
Any help would be greatly appreciated!
Not really. You can tell whether a keyboard is connected or not, but you won't get callbacks for corded shortcuts. There is clearly a way to do this, because Pages supports keyboard shortcuts (Cmd-Z, etc), but it's not in the public SDK.

Toggle iPhone tethering by code

I live in Canada, so am fortunate that I can tether. One issue is that to toggle tethering, you need to drill down four screens in Settings, which is just a big hassle.
A Google search returned nothing, so I was wondering if anyone here knew the code to turn on/off tethering?
I know there's a toggle for SBSettings, but I do not have a jailbroken phone, I just want to create an app I build onto my phone and have an icon for quickly toggling it.
Thanks
You cannot alter phone settings from within an application using any APIs allowed by the iPhone SDK. As you point out - there is an SBSettings toggle - which relies on a Private API (which you agree not to use when you get the iPhone SDK from Apple, incidentally).
There is a file located in the Preferences folder, along with the com.apple.SpringBoard.plist:
/var/mobile/Library/Preferences/com.apple.MobileInternetSharing.plist
In that file, you will want to set 1023 for key State to enable the Tethering feature. To disable the feature, you will want to set 1022 for key State.
This action is only possible on a jailbroken device

Does iPhone provide any API for inserting menu selections into e-mail, SMS and Addressbook context menus?

The Blackberry APIs allow one to insert custom menu items (and corresponding event handlers) into their standard email, SMS and Address book context menus. Is there any supported way to do this with iPhone APIs?
No, Apple doesn't provide these kinds of hooks. However there are some tricks I've seen - one example is what Twitterific does to tweet pages that you are viewing in Safari, via Bookmarklet which uses a Custom URL to launch Twitterific.
Perhaps you can do something similar by having a text containing a custom URL. I've never tried this but it's worth experimenting with.
As of SDK 3.1.2, no, that's not possible. In fact there's very little you can change! There's not even an easy way to change the colour of the title bar!