Question

Is it possible to know position of hardware settings button? I want to write an intro for my programm and show the user how to use it's features.

Was it helpful?

Solution

No, it is not. You'd try to check what device you are running on and then get position from your prepopulated database, but otherwise there's no way. Please note hardware buttons are deprecated since Honeycomb (and the good thing is that software buttons order is known and almost device independent).

OTHER TIPS

The ViewConfiguration class might help. It has a method hasPermanentMenuKey()

public boolean hasPermanentMenuKey ()

Since: API Level 14 Report if the device has a permanent 
menu key available to the user.

Returns true if a permanent menu key is present, false otherwise.

But to know the exact position of the menu key isn't possible. You could just find out if it exists or not, in hardware.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top