Pressing menu button causes crash in Activity with no ActionBar
My guess is that this is a bug in the AppCompat library. If you take a look at the code for ActionBarImplICS.getThemedContext() you see that it's the mActionBar that is null:
My guess is that you're using an activity without a title (and thus also without an actionbar):
requestWindowFeature(Window.FEATURE_NO_TITLE);
If I remove this and launch the activity with a title/actionbar I haven't been able to reproduce the crash. Now, running the app with a titlebar when you don't want or need one isn't a very good option. My suggestion is that you override the Menu key press. The app stopped crashing for me when I did this:
@Overridepublic boolean onKeyDown(int keyCode, KeyEvent event) { if ( keyCode == KeyEvent.KEYCODE_MENU ) { // do nothing return true; } return super.onKeyDown(keyCode, event);}
Looks like this will be fixed in the next support library release http://code.google.com/p/android/issues/detail?id=61394