I have an action bar with a menuitem. How can I hide/show that menu item?
This is what I’m trying to do:
MenuItem item = (MenuItem) findViewById(R.id.addAction);
item.setVisible(false);
this.invalidateOptionsMenu();
I have an action bar with a menuitem. How can I hide/show that menu item?
This is what I’m trying to do:
MenuItem item = (MenuItem) findViewById(R.id.addAction);
item.setVisible(false);
this.invalidateOptionsMenu();