I have an app that has been working fine, but suddenly some users running 4.0 devices (not all) are claiming the menu isn't working...
I have a menu with more than 6 options or whatever Android shows by default. The users are complaining that when they click on the MORE button that shows the remaining options, the pop up list showing all the other options appears but they can't click on any of the options. The list that pops up does not accept any user actions other than the back button, which closes it.
Does anyone have any idea WHY this would be going on? I am unable to reproduce the error on any device I have or on any emulator that I have.... I am assuming I am dealing with some fragmentation issue or OS change issue as the code is about as basic as it can be.
Anyone have any ideas? Was menuing significantly changed in some way that could cause this to happen?
Open the app and tap Device diagnosis. Choose Troubleshoot to test the touch-screen display, battery, audio, camera, connectivity, and more. Select Hardware test to run diagnostics on the display, backlight, touch screen, multi-touch capability, flash, front and rear camera, and the proximity sensor.
It appears to be an issue with Google's Android operating system. To fix the “your device is not compatible with this version” error message, try clearing the Google Play Store cache, and then data. Next, restart the Google Play Store and try installing the app again.
if i understood you issue properly then I had faced a similar type of issue,
issue--2.x has one dedicated key for menu but in 4.x do not has so we need check that in on create..
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.app_list);
checkMenu();
//other stuff
}
@SuppressLint("NewApi")
public void checkMenu() {
boolean hasMenu = ViewConfiguration.get(this).hasPermanentMenuKey();
if (!hasMenu) {
try {
getWindow().addFlags(WindowManager.LayoutParams.class.getField( "FLAG_NEEDS_MENU_KEY").getInt(null));
} catch (NoSuchFieldException e) {
e.printStackTrace();
} catch (IllegalAccessException e) {
e.printStackTrace();
}
}
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With