the Android system relies on the fact that these button presses are sent as
from the Linux kernel
as input event with specific codes. Doing anything reliably with intents is
not supported (and opens
a whole can of worms security wise, so don't expect this to be available).

On Tue, May 26, 2009 at 10:51 AM, Gowda <thotego...@gmail.com> wrote:

>
> Hi All
>
> We are porting Android to a device which doesn't have any hardware
> buttons, so it should have software buttons for the equivalent HOME/
> BACK/MENU hardware buttons functionality.
>
> I could able to achieve the functionality of the HOME button by
> sending an intent with following details,
>
>        Intent mHomeIntent =  new Intent(Intent.ACTION_MAIN, null);
>        mHomeIntent.addCategory(Intent.CATEGORY_HOME);
>        mContext.startActivity(mHomeIntent);
>
> Is this the correct way of implementing it?
>
> I have no idea of implementing the other two buttons (BACK and MENU)
> functionality.
> Can someone help me on this, probably where to look in the android
> source code?
>
>
> Regards
> Gowda
> >
>

--~--~---------~--~----~------------~-------~--~----~
unsubscribe: android-porting+unsubscr...@googlegroups.com
website: http://groups.google.com/group/android-porting
-~----------~----~----~----~------~----~------~--~---

Reply via email to