No software buttons for the ICS emulator?

試著忘記壹切 提交于 2019-12-20 12:05:08

问题


So I'm working on an update for my application from 3.0 to 4.0 and I'm having issues with the emulator. Specifically, the software buttons do not appear when using the Galaxy Nexus~ish skin (I'm not sure its exact, but it should be close enough).

This is the WXGA720, its values:

Hardware Back/Home keys = no
Abstracted LCD Density = 320
Keyboard Lid Support = no
Max VM Heap = 48
Device Ram Size = 1024

The first line is the most important, because it tells the emulator we need software keys for back/home. This works using the WXGA800 skin (tablet) - even using API level 14 (ICS).

(Don't mind the jaged edges in the screenshot, I have the emulator scaled down - this doesn't affect the keys not appearing) As you can see its difficult to interact with the emulator since I have no back/home buttons.

So the software keys show up for the tablet skin but not the phone. Has anyone else solved this issue?

EDIT

I've changed the screenshot to reflect the latest version of the tools, r16. The buttons appear using the WVGA800 skin and hardware back/home = no.


回答1:


Here's a workaround that works for me: create your AVD by selecting the WXGA720 preset for the Skin, but before you click the "Create AVD" button, click on the "Resolution" radio button for the Skin and enter 720 x 1280 manually on the provided inputs.

You might also want to make sure that you add "Keyboard support: no" and "DPad support: no" in the Hardware section.




回答2:


Use your Keyboard's "Home" for Home, "Esc" for back and "Page Up" for Menu.




回答3:


You can get the software keys up if you edit the AVD's "config.ini" file. I don't know where this is in windows, but in linux it's ~/.android/avd/.avd/config.ini

You need to put in these lines (not sure if you need to put in all 3):

hw.mainKeys=no
hw.keyboard=no
hw.dPad=no



回答4:


On a MacBook air (which has no Home or Page Up keys) use the fn key + arrows:

  • fn + Left Arrow = "Home Button"
  • fn + Up Arrow = "Menu Button"
  • esc = "Back Button"



回答5:


I needed to add the following to my AVD's config.ini file:

skin.dynamic=yes

This can also be set via the AVD Manager GUI by checking Skin: Display a skin with hardware controls, see screenshot below:

This is for ADT Build: v21.0.1-543035



来源:https://stackoverflow.com/questions/8396510/no-software-buttons-for-the-ics-emulator

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!