Oh good lord, don't freaking do that.
On Tue, Jun 5, 2012 at 12:10 PM, b0b <[email protected]> wrote:
>
>
>
>> Unless I missed something in the previous discussions, or there has
>> been a breakthrough since, there is NO possible way to make the
>> overflow button show up if there is a physical hardware key.
>>
>>
>>
> There is. With hack below you can force the appearance of the overflow
> menu even if there is a physical button menu
> with target SDK >= 14. Of course you must never use it since it is a
> horrible hack, and nobody shall use hacks ever, especially on Android !
>
> static public void setHasPermanentMenuKey(Context context, boolean value)
> {
> if (isICSOrLater()) {
> ViewConfiguration config = ViewConfiguration.get(context);
> try {
> Field f = ViewConfiguration.class
> .getDeclaredField("sHasPermanentMenuKey");
> f.setAccessible(true);
> if (f != null) {
> f.set(config, value);
> log.info("Successfully hacked permanent menu key");
> }
> } catch (Exception ex) {
> log.info("Unable to hack permanent menu key: " + ex);
> }
> }
> }
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to [email protected]
> To unsubscribe from this group, send email to
> [email protected]
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>
--
Dianne Hackborn
Android framework engineer
[email protected]
Note: please don't send private questions to me, as I don't have time to
provide private support, and so won't reply to such e-mails. All such
questions should be posted on public forums, where I and others can see and
answer them.
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en