Remove Floating menu button from HTC one

667 Views Asked by At

I have an app that's been running for years, and constantly get's updated. Originally it had a menu with some shortcuts, but it's not necessary to operate the app, so no big deal as the menu button started to disappear from new devices.

Now I have a customer complaining that a floating menu button appears on he's HTC one, and it actually covers some other buttons in my app. (That's not the case on my Samsung S5 nor Lenovo Yoga tablet)

I've removed "onCreateOptionsMenu" and "onOptionsItemSelected" from my activity, and I can no longer access the menu on my devices, but the HTC user says the floating menu button is still on he's HTC, it just doesn't do anything.

How do I remove that button?

2

There are 2 best solutions below

2
Arlind Hajredinaj On

In your onCreateOptionsMenu() do this

MenuItem settingsItem = menu.findItem(R.id.action_settings);
settingsItem.setVisible(false);
0
JacksOnF1re On

You have to set your targetSdk higher then 13 in your gradle build files.

Thanks to the answer of Ankush Sharma https://stackoverflow.com/a/33086729/2607567.