"There is no keyboard for id 0" - what does it mean?

Every time the Optionsmenu menu opens (onCreateOptionsMenu (..) is called), I get these warnings:

"There is no keyboard for id 0"

and

"Using the default key: /system/usr/keychars/qwerty.kcm.bin"

I could not understand what they mean, does anyone know? I did not like this answer .

Here is the simple code that I use:

@Override public boolean onCreateOptionsMenu(Menu menu) { super.onCreateOptionsMenu(menu); getMenuInflater().inflate(R.menu.optmenu_start, menu); return true; } 

and optmenu_start.xml:

 <menu xmlns:android="http://schemas.android.com/apk/res/android"> <item android:id="@+id/optmenu_prefs" android:title="@string/optmenu_prefs" android:icon="@drawable/icon_menu_prefs" /> <item android:id="@+id/optmenu_help" android:title="@string/optmenu_help" android:icon="@drawable/icon_menu_help" /> </menu> 
+8
android warnings keyboard
source share
2 answers

Google answer

"The log is normal, this happens the first time you connect a keyboard to a device in the process."

http://groups.google.com/group/android-developers/browse_thread/thread/477caf755085b108

So, if you started Activity2 before Activity1, you will see a warning in Activity2, not Activity1!

As I said, I think many developers receive this message, and this is just a warning, not an error; it can be ignored.

+13
source share

As @Blundell said, this is normal. But it always consumes the first KeyPressed event. Finally, I add this to init:

 setFocusableInTouchMode(true); 

I don’t know why, but this warning never annoys me again.

+1
source share

All Articles